There are a number of boot problems related to missing modules in the initrd image, boot device can't be found, and also many mount or device scanning problems that result in errors like:
switchroot:mount failed
Kernel panic-not synching:Attempted to kill init!
In order to get better errors, you want to add some debugging to the initrd image. An easy way to do this, is by hopefully by selecting and booting a kernel/initrd that does work, or booting Linux Rescue (with networking) and getting a copy of the initrd.
Once you have the initrd image, you can unpack it, edit, and re-pack it with the following commands.
Now vi init and change the following lines.
switchroot:mount failed
Kernel panic-not synching:Attempted to kill init!
In order to get better errors, you want to add some debugging to the initrd image. An easy way to do this, is by hopefully by selecting and booting a kernel/initrd that does work, or booting Linux Rescue (with networking) and getting a copy of the initrd.
Once you have the initrd image, you can unpack it, edit, and re-pack it with the following commands.
cd /tmp
mkdir initrd
cd initrd
gzip -dc /boot/initrd-2.6.18-194.el5.img | cpio -ivd
Now vi init and change the following lines.
#!/bin/nash mount -t proc /proc /proc setquiet <<----- remove or # out
find . | cpio --quiet -c -o | gzip > /boot/initrd_test.img
echo Mounting proc filesystem echo Mounting sysfs filesystem mount -t sysfs /sys /sys echo Creating /dev
For multipath issues,
add in an extra line to display the mpath devices, and also change the verbosity on the multpath scan so you can see if any devices are getting created.
echo Creating multipath devices /bin/multipath -v 0 <<<<---- change this to -v1 dmsetup ls --target multipath --exec 'kpartx -a -p p' /bin/multipath -l <<<<---- add this to list mpath devices
Now, repack the modified initrd.
find . | cpio --quiet -c -o | gzip > /boot/initrd_test.img