I'm working on upgrading a system from RHEL6 to RHEL7 and in the meantime I need to do a few tests before I actually upgrade. My question is: I have a working RHEL7 stock ISO file downloaded from Red Hat's website, and I attempted to copy the contents of the ISO to a folder on my computer, and then turn that folder into a new ISO (using various ISO-creating utilities), just to make sure I could do that. However, the problem is, despite me making no changes before "recompiling it", when I try to use this recreated ISO in VirtualBox, I get a fatal error: no bootable medium found error. What could be causing this?
2 Answers
Steps for copying and doing a fixup on an iso image:
Make a temporary directory for the contents of your iso:
# mkdir /var/tmp/isodir
Make a temporary mount dir for the iso:
# mkdir /id
Mount the iso:
# mount -oro,loop /path/to/file.iso /id
Copy the contents to the new path:
# cd /id # cp -av . /var/tmp/isodir
- Go over into /var/tmp/isodir and do whatever mods you need.
Recreate your .iso:
# cd /var/tmp/isodir # mkisofs -o /path/to/new/file.iso -b isolinux.bin -c boot.cat -no-emul-boot -boot-load-size 4 -boot-info-table -R -J -v -T isolinux/
Cleanup:
# umount /id # rmdir /id
Explanation: The mkisofs command above uses the -b flag to specify the boot image (isolinux.bin). (The rest of the flags can be found in the man page for mkisofs.)
-
Thanks a lot! I've gotten the rebuilt ISO to boot, although it's getting stuck in the install process.– cmoughonCommented Jun 23, 2016 at 15:16
To be bootable a disk has to have a valid boot sector. When you copy the contents, (...), and you make a new disk without the correct boot sector you have a normal disk full with the data. Check here about how to do a bootable iso image. (Look for -b
option of genisoimage
).
Look here for a Minimal guide.
-b
option ofgenisoimage
). Minimal guide.