MichaelBurns
January 7th, 2011, 07:30 PM
I dd'ed a backtrack iso onto a usb stick:
dd if=backtrack.iso of=/dev/sda
(i.e. not to a partition, but directly to the stick). It won't boot (no surprise of course). I checked the boot sector:
dd if=/dev/sda skip=0 count=1 bs=512
and it is full of null bytes (i.e. empty, and particularly not marked as bootable). I browsed the isofs for a boot install script, but didn't find one. (There are actaully very few files in there, maybe about 20 total.) I am thinking to use fdisk to set the bootable flag, but it wants to write a partition table. How can I prevent fdisk from writing a partition table?
edit:
I decided to just copy the boot flag from my running Ubuntu installation (after first confirming that it is indeed the expected 55aa):
dd if=/dev/hda skip=255 count=1 bs=2 of=/dev/sda seek=255
Of course, I don't expect this to work since it is just a flag, and there is no boot code in the rest of the sector, but I have no idea what I'm doing, so I'm just going to try it. We'll see. If my computer doesn't explode, I'll try to remember to report back here with the results.
dd if=backtrack.iso of=/dev/sda
(i.e. not to a partition, but directly to the stick). It won't boot (no surprise of course). I checked the boot sector:
dd if=/dev/sda skip=0 count=1 bs=512
and it is full of null bytes (i.e. empty, and particularly not marked as bootable). I browsed the isofs for a boot install script, but didn't find one. (There are actaully very few files in there, maybe about 20 total.) I am thinking to use fdisk to set the bootable flag, but it wants to write a partition table. How can I prevent fdisk from writing a partition table?
edit:
I decided to just copy the boot flag from my running Ubuntu installation (after first confirming that it is indeed the expected 55aa):
dd if=/dev/hda skip=255 count=1 bs=2 of=/dev/sda seek=255
Of course, I don't expect this to work since it is just a flag, and there is no boot code in the rest of the sector, but I have no idea what I'm doing, so I'm just going to try it. We'll see. If my computer doesn't explode, I'll try to remember to report back here with the results.