Setting up Raid 1 disks

Rick Stevens rstevens at vitalstream.com
Tue Aug 23 17:45:59 UTC 2005


john.bergeski at alpsautomotive.com wrote:
> I setup the RAID disks, the install went ok, however when the server boots
> it stops at a  screen with only GRUB in the upper left hand corner of the
> screen and just sits there. Nothing happens when I hit any keys. The
> install encountered zero problems.

Yoikes!  Yet another hoseup by anaconda.  Hoo, boy.  It looks like the
ramdisk image doesn't have the driver loaded.

I've not done software RAID in a long time, so the driver names I
mention below may not be correct.  Perhaps someone else can help.
Anyway, here's the steps needed to rebuild a boot ramdisk image with the
necessary drivers.

Here's what you do:  Boot off the first CD in "rescue" mode (enter
"linux rescue" at the "boot:" prompt.  Make sure you load the i2o block
driver again and allow the system to mount the system image at
/mnt/sysimage.

Next, at the "#" prompt, enter "cat /mnt/sysimage/boot/grub/grub.conf".
Look carefully at the output to see which kernel the system will try to
boot up.  Make note of the version number...you'll need that later for
the mkinitrd command.

Next, enter "chroot /mnt/sysimage".  This spawns a new shell where the
root of the filesystem is now "/mnt/sysimage" (so even if you do a
"cd /", you won't leave the installed CentOS environment).  You now
need to edit the /etc/modprobe.conf file.  In there, make SURE you have
an entry to the effect:

     alias scsi_hostadapter raid1 (or whatever the appropriate driver is)

This tells the system that there is a SCSI driver that MUST be included
in the boot ramdisk image.  Save the file after editing.

Once that's done, enter "cd /boot".  This puts you into the installed
CentOS' /boot directory.  You now have to rebuild the ramdisk image used
at boot time.  Enter this command:

     # mkinitrd -f -v initrd-[kernelversion].img [kernelversion]

replacing "[kernelversion]" with the version number you got when you
looked at the grub.conf file.  For example, for the 2.6.9-11.ELhugemem
kernel:

     # mkinitrd -f -v initrd-2.6.9-11.ELhugemem.img 2.6.9-11.ELhugemem

When the ramdisk image is being built, watch the output of the command
and make SURE that the raid1 (or whatever driver is appropriate) gets
loaded.  If everything appears OK at this point, try to reboot the
system.  Enter the "exit" command. This kicks you out of the chrooted
shell and back to the rescue environment.  A second "exit" command will
cause the system to reboot.  Pop the CD out and see if it'll come up.

Good luck, kemosabe!  Keep us posted!
----------------------------------------------------------------------
- Rick Stevens, Senior Systems Engineer     rstevens at vitalstream.com -
- VitalStream, Inc.                       http://www.vitalstream.com -
-                                                                    -
-           If it's stupid and it works...it ain't stupid!           -
----------------------------------------------------------------------




More information about the Redhat-install-list mailing list