3

Updated TL;DR question:

I have 2 machines A and B; both are bootable from usb. When I create a stick with dd on machine A, the stick is neither booting machine A nor machine B nor any other bootable machine. When I create a stick from the very same iso with the very same usb stick on machine B with the very same dd-command, the stick is booting machine A and machine B and any other bootable machine. What's the secret ingredient that makes a "dd-stick" actually bootable?

(TL;DR ends here.)


First off: I'm totally aware of that question and its answer: Why does 'dd' not work for creating bootable USB? - however the problem pointed out in the accepted answer (and also in the other answers) is not the one I have.

Additional Disclaimer: that answer: https://superuser.com/a/1141527/180563 is not answering this question. It assumes that different ISOs with different configurations are used on different systems. As I pointed out in the comments, this is not the case. The only thing thats differnt in my tests is the machine where the Boot-Stick was made; the rest, i.e. the ISO and the machine that should be booted is the same. Please don't upvote that answer as it is not addressing the question that has been asked and is therefore a wrong answer.

I know that its a common issue to confuse the correct device to dd to and its often that the user confuses the first partition with the whole device.

But that is not my problem! I'm using the command in a right way, i.e. I'm not copying to the first partition but to the device, like:

dd if=linux.iso of=/dev/disk3 bs=1m

(1m is correct as I'm using bsd-dd which uses lower m rather than capital M, so please no comments on that. 1M would be not even a valid parameter for my version of dd)

/dev/disk3 is the device file of the stick and not of one of its partitions.

Now although, I'm doing everything according to the documentation and even in the same way as others I know are doing it (with success), my sticks aren't bootable. So my question goes like in the other one: What is the secret ingredient that makes a dd-copied stick bootable?

Update: The same iso-File I'm using will work on anothers person's pc. Update2: This is the iso-File i'm talking about: http://cdimage.ubuntu.com/kubuntu/releases/16.10/release/kubuntu-16.10-desktop-amd64.iso A friend was able to create a bootable stick with dd from it while I am not.

ohcibi
  • 157

1 Answers1

2

Usually the secret ingredient is isohybrid. .iso files are really CD images – they contain an ISO 9660 filesystem (hence the name), usually with El Torito extensions to make it bootable. That's however a bit different from how regular disks boot (be they internal or USB).

(For BIOS systems, regular disks are expected to have bootcode in their 0th sector – part of the MBR. While the CD boot process tries to emulate that in some ways, its initial bootcode is still stored elsewhere.)

So many Linux distributions use isohybrid to combine various different boot images and even different filesystems (BIOS, El Torito, and UEFI; ISO 9660 and FAT) into a single image that somehow still happens to work.

But if your image hasn't been built that way, then it will have only CD bootcode, not "disk" one.

Or the image might be a hybrid one, but it might only support BIOS while your system requires UEFI, or vice versa. Or you might be trying to boot it on something that's not x86.

grawity
  • 501,077