Article 5B4NV Confirm mbr.bin is working correctly for what it is needed for?

Confirm mbr.bin is working correctly for what it is needed for?

by
JockVSJock
from LinuxQuestions.org on (#5B4NV)
I tried using the search on Linux Questions for this and didn't find anything along with googling Linux Questions and my search terms and couldn't find anything.

How do I confirm that mbr.bin is good, working and able to do its job?

I can't even find mbr.bin under /dev/sda1 which points to /boot? So does this file really live under /dev/sda?

I'm prepping a removable SSD that is 512 GB in size and have created a boot partition under /dev/sdb1 with the size of 512 MB. I want to place mbr.bin under this directory in order to boot correctly.

I've used the following command to generate mbr.bin

Code:dd if=/dev/sda of=/tmp/mbrsda.bak bs=512 count=1I can use xxd to do a hexdump of the file

Code:[root@foo tmp]# xxd mbrsda.bak
0000000: eb63 9010 8ed0 bc00 b0b8 0000 8ed8 8ec0 .c..............
0000010: fbbe 007c bf00 06b9 0002 f3a4 ea21 0600 ...|.........!..
0000020: 00be be07 3804 750b 83c6 1081 fefe 0775 ....8.u........u
0000030: f3eb 16b4 02b0 01bb 007c b280 8a74 018b .........|...t..
0000040: 4c02 cd13 ea00 7c00 00eb fe00 0000 0000 L.....|.........
0000050: 0000 0000 0000 0000 0000 0080 0100 0000 ................
0000060: 0000 0000 fffa 9090 f6c2 8074 05f6 c270 ...........t...p
0000070: 7402 b280 ea79 7c00 0031 c08e d88e d0bc t....y|..1......
0000080: 0020 fba0 647c 3cff 7402 88c2 52be 057c . ..d|<.t...R..|
0000090: b441 bbaa 55cd 135a 5272 3d81 fb55 aa75 .A..U..ZRr=..U.u
00000a0: 3783 e101 7432 31c0 8944 0440 8844 ff89 7...t21..D.@.D..
00000b0: 4402 c704 1000 668b 1e5c 7c66 895c 0866 D.....f..\|f.\.f
00000c0: 8b1e 607c 6689 5c0c c744 0600 70b4 42cd ..`|f.\..D..p.B.
00000d0: 1372 05bb 0070 eb76 b408 cd13 730d 5a84 .r...p.v....s.Z.
00000e0: d20f 83de 00be 857d e982 0066 0fb6 c688 .......}...f....
00000f0: 64ff 4066 8944 040f b6d1 c1e2 0288 e888 d.@f.D..........
0000100: f440 8944 080f b6c2 c0e8 0266 8904 66a1 .@.D.......f..f.
0000110: 607c 6609 c075 4e66 a15c 7c66 31d2 66f7 `|f..uNf.\|f1.f.
0000120: 3488 d131 d266 f774 043b 4408 7d37 fec1 4..1.f.t.;D.}7..
0000130: 88c5 30c0 c1e8 0208 c188 d05a 88c6 bb00 ..0........Z....
0000140: 708e c331 dbb8 0102 cd13 721e 8cc3 601e p..1......r...`.
0000150: b900 018e db31 f6bf 0080 8ec6 fcf3 a51f .....1..........
0000160: 61ff 265a 7cbe 807d eb03 be8f 7de8 3400 a.&Z|..}....}.4.
0000170: be94 7de8 2e00 cd18 ebfe 4752 5542 2000 ..}.......GRUB .
0000180: 4765 6f6d 0048 6172 6420 4469 736b 0052 Geom.Hard Disk.R
0000190: 6561 6400 2045 7272 6f72 0d0a 00bb 0100 ead. Error......
00001a0: b40e cd10 ac3c 0075 f4c3 0000 0000 0000 .....<.u........
00001b0: 0000 0000 0000 0000 a68b 0e00 0000 8020 ...............
00001c0: 2100 839f 0619 0008 0000 0040 0600 009f !..........@....
00001d0: 0719 83fe ffff 0048 0600 0000 0008 00fe .......H........
00001e0: ffff 83fe ffff 0048 0608 0000 7102 00fe .......H....q...
00001f0: ffff 05fe ffff 0048 770a 0020 f969 55aa .......Hw.. .iU.
[root@foo tmp]#I'm just not familiar enough with this to figure out if its good or not.

Also I've run file against the mbr.bin file and its returning more partitions which I didn't expect.

Code:
[root@foo tmp]# file mbrsda.bak
mbrsda.bak: x86 boot sector; partition 1: ID=0x83, active, starthead 32, startsector 2048, 409600 sectors; partition 2: ID=0x83, starthead 159, startsector 411648, 134217728 sectors; partition 3: ID=0x83, starthead 254, startsector 134629376, 40960000 sectors; partition 4: ID=0x5, starthead 254, startsector 175589376, 1777934336 sectors, code offset 0x63latest?d=yIl2AUoC8zA latest?i=lmuzkVJZItk:MFjtxqwGyVI:F7zBnMy latest?i=lmuzkVJZItk:MFjtxqwGyVI:V_sGLiP latest?d=qj6IDK7rITs latest?i=lmuzkVJZItk:MFjtxqwGyVI:gIN9vFwlmuzkVJZItk
External Content
Source RSS or Atom Feed
Feed Location https://feeds.feedburner.com/linuxquestions/latest
Feed Title LinuxQuestions.org
Feed Link https://www.linuxquestions.org/questions/
Reply 0 comments