20

One answer here indicates that Ubuntu .iso s are not expected to boot if copied with dd to a USB thumb drive.

Why do some Linux distributions have the option to directly write their bootable .iso file to a thumb drive with dd, but others (Ubuntu?) do not?

In Ubuntu I think it has to be converted to .img first. Is this true?

Is it for some architectural difference in .isos? Or is it due to any limitation of dd itself?

I don't know if it is off-topic here. I can move it to a more proper place if the community thinks so or suggests one. Some explanation would be appreciable.

Samik
  • 2,660

3 Answers3

32

With Ubuntu 12.04 it is possible to dd the .iso file to a disk to create a bootable disk. It only works with some isos (including Ubuntu 12.04, but not earlier Ubuntu versions) because booting from CD and booting from a disk are handled differently on BIOS based systems.

Among other things, for a hard drive to be bootable it must contain boot code in the first sector, for a CD to be bootable it must contain boot code "at sector 11 (17 decimal) in the last session on the CD" according to the El Torito specification. Since the boot code, at least the initial portion loaded by the BIOS, is stored in different places for CDs and hard drives, a disk image can have boot code in both places so that the bootloader is loaded if the image is booted as a hard drive or as a CD.

Most iso files are only designed to be bootable as CDs, and so they contain no boot code in the first sector of the image and thus a hard drive containing such an image won't have boot code in its first sector and won't be bootable.

LiveWireBT
  • 29,597
Jordan Uggla
  • 4,755
0

Ubuntu's current ISOs are dd-able and have been for some time. They are "hybrid" ISOs: they have an MBR boot sector. Using dd properly will create fully bootable USB drive.

The cited article, btw, only has one answer claiming that Ubuntu ISOs are not dd-able, and this isn't true.

Please see my answer here: How to convert a iso9660 ISO to a USB ISO

This answer provides a way to determine if an iso is hybridized (you can verify this for Ubuntu ISOs), how to hybridize it if it's not (for other cases), and how to correctly use dd to create a bootable drive.

Life5ign
  • 424
-3

Notes that have no changes on the above posted accepted solution.

The question was posed as reliable, bootable iso and using dd.

In most cases linux users use the phrase iso to mean a special image of an optical disc. Bootable in that case could be one of a few methods that bios or uefi understands and allows to run from optical disc.

dd is generally considered reliable however it could fail for many reasons on it's own and have nothing to do with the source or output. In most case it seems to fail only because it doesn't ask "Are you sure you want to wipe that out??"

Modern computers tend to view a usb as a real internal hard drive.

One could use a tool like 7z also to copy over some iso's to a fat32 flash drive.

This all assumes some modern hardware and a modern usb flash drive.

In the future we will have to be creating uefi bootable media in most cases.

jefro0
  • 1