Alfred von Campe
2014-Dec-03 16:51 UTC
[CentOS] Creating a USB bootable modified netinstall ISO image
I?ve been creating slightly modified CentOS netinstall ISO images using the following steps: Copy contents of CentOS netinstall ISO image to a temporary directory Edit isolunux/isolinux.cfg file Create new ISO image using the following command: mkisofs -o new.iso -b isolinux/isolinux.bin -c isolinux/boot.cat -no-emul-boot -boot-load-size 4 -boot-info-table -R -J -v -T /tmp/iso I?ve been using that command for many years and found it in the RHEL 5 documentation I believe. Anyway, so far, so good. If I burn a CD from this new ISO image I can boot from it and get the modified menu as expected. However, if I use dd to copy this ISO image to a USB stick, It?s not bootable. Using the exact same dd command with the original CentOS ISO image produces a bootable USB stick. Any idea why my modified ISO image is not bootable when copied to a USB stick? Alfred
Greg Bailey
2014-Dec-03 17:01 UTC
[CentOS] Creating a USB bootable modified netinstall ISO image
On 12/03/2014 09:51 AM, Alfred von Campe wrote:> I?ve been creating slightly modified CentOS netinstall ISO images using the following steps: > > Copy contents of CentOS netinstall ISO image to a temporary directory > Edit isolunux/isolinux.cfg file > Create new ISO image using the following command: mkisofs -o new.iso -b isolinux/isolinux.bin -c isolinux/boot.cat -no-emul-boot -boot-load-size 4 -boot-info-table -R -J -v -T /tmp/iso > > I?ve been using that command for many years and found it in the RHEL 5 documentation I believe. Anyway, so far, so good. If I burn a CD from this new ISO image I can boot from it and get the modified menu as expected. However, if I use dd to copy this ISO image to a USB stick, It?s not bootable. Using the exact same dd command with the original CentOS ISO image produces a bootable USB stick. Any idea why my modified ISO image is not bootable when copied to a USB stick?I think you'd need to use the "isohybrid" command that's included in the syslinux package. From /usr/share/doc/syslinux-4.04/isolinux.txt: ++++ HYBRID CD-ROM/HARD DISK MODE ++++ Starting in version 3.72, ISOLINUX supports a "hybrid mode" which can be booted from either CD-ROM or from a device which BIOS considers a hard disk or ZIP disk, e.g. a USB key or similar. To enable this mode, the .iso image should be postprocessed with the "isohybrid" script from the utils directory: isohybrid filename.iso This script creates the necessary additional information to be able to boot in hybrid mode. It also pads out the image to an even multiple of 1 MB. This image can then be copied using any raw disk writing tool (on Unix systems, typically "dd" or "cat") to a USB disk, or written to a CD-ROM using standard CD burning tools. The ISO 9660 filesystem is encapsulated in a partition (which starts at offset zero, which may confuse some systems.) This makes it possible for the operating system, once booted, to use the remainder of the device for persistent storage by creating a second partition. -Greg
Alfred von Campe
2014-Dec-03 20:55 UTC
[CentOS] Creating a USB bootable modified netinstall ISO image
On Dec 3, 2014, at 12:01, Greg Bailey wrote:> I think you'd need to use the "isohybrid" command that's included in the syslinux package.BING! BING! BING! We have a winner! Thanks for that info, it makes the USB stick bootable. This will make kickstart installations so much easier, especially for systems that don?t have a CD-ROM (we used to have to scrounge for an external CD/DVD player every time). Thanks, Alfred
Reasonably Related Threads
- Creating a USB bootable modified netinstall ISO image
- Creating a USB bootable modified netinstall ISO image
- Looking for testers and advise about ISOLINUX within ISO 9660
- Trying to build bootable iso but very confused by syslinux documentation
- Changes to get CD to boot on EFI System.