1

I'm able spin up the stock CentOS 7.7 ISO onto a virtual machine (and on a USB drive) just fine, but when I try to make a custom ISO directly from the stock ISO, I'm at a roadblock.

After the initial choice to Install CentOS, the system hangs at Starting dracut initqueue hook..., and then repeats initqueue[696]: Warning: dracut-initqueue timeout - starting timeout scripts until it finally says Could not boot. and then /dev/root does not exist, after which it goes to a Dracut Emergency Shell.

I'm following the steps I've seen like this:

sudo mkdir -p /media/mydrive
sudo mount -o loop ~user/CentOS-7-x86_64-DVD-1908.iso /media/mydrive
mkdir ~/customiso
sudo rsync -av /media/mydrive ~/customiso
cd ~/customiso
sudo genisoimage -o ../centoscustom.iso -b isolinux/isolinux.bin -c isolinux/boot.cat -no-emul-boot -boot-load-size 4 -boot-info-table -J -R -v -T -V 'centos custom' .

(also used mkisofs instead of genisoimage, to no satisfaction)

It always fails at that same point after choice to install. I've even messed around with isolinux.cfg to make the append line match the filename, so

append inird=inird.img inst.stage2=hd:LABEL=centoscustom quiet

I'm trying to put some kickstart actions into a custom ISO of CentOS 7.7. I initially thought I was something related to the USB making or the ks.cfg file, but I've regressed to just trying to get a straight copy of the stock ISO working first.

1
  • I don't believe that you tried mkisofs as those OSS hostile distros that ship genisoimage make mkisokfs a link to genisoimage instead of installing the rel program. BTW: if you like help, you should describe your problem.
    – schily
    Nov 30 '19 at 4:57
1

I just struggled with this very issue (or, same symptoms, rather). Turned out I had actually forgotten to to include the entire images/install.img which, surprise, surprise, means the installer has trouble finding stage2.

mkisofs/genisoimage just blindly includes whatever is in the "staging area" directory.

In short, you need both isolinux and install.img to succeed. The way I resolved things was to loopmount the stock image and inspect it.

For reference, the entire thing goes something like this (substitute a suitable mirror yourself.)

mkdir iso
rsync -av rsync://mirrors.dotsrc.org/centos/8.2.2004/BaseOS/x86_64/os/isolinux ./iso/
rsync -av rsync://mirrors.dotsrc.org/centos/8.2.2004/BaseOS/x86_64/os/images/*.img ./iso/images/
cp my_custom_isolinux.cfg iso/isolinux/isolinux.cfg #Optional
cp my_custom_splash.png iso/isolinux/splash.png #Optional
cd iso && mkisofs -o ../qeyeboot8.iso -b isolinux/isolinux.bin -c isolinux/boot.cat -no-emul-boot -boot-load-size 4 -boot-info-table -V "CentOS-8-2-2004-x86_64-dvd" -R -J -v -T .
isohybrid ../qeyeboot8.iso #Optional, allows the image to also be booted from USB
0

I just figured it out. The 2 things that need to match each other in the genisoimage command and isolinux.cfg file are stated as THISNEEDSTOMATCH:

genisoimage -o ../centoscustom.iso -b isolinux/isolinux.bin -c isolinux/boot.cat -no-emul-boot -boot-load-size 4 -boot-info-table -J -R -v -T -V 'THISNEEDSTOMATCH' .

append inird=inird.img inst.stage2=hd:LABEL=THISNEEDSTOMATCH quiet

1
  • 1
    Please do not use genisoimage, as it creates defective filesystem images. genisoimage is a fork from a mkisofs from 2004 with plenty of Debian specific bugs added. The original mkisofs meanwhile fixed bugs and evolved a lot while genisoimage is dead since 2005. Check schilytools.sf.net
    – schily
    Jan 28 '20 at 11:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.