Booting RHES4-U2 from mirrored disk

Alfred Hovdestad alfred.hovdestad at usask.ca
Fri Jan 27 15:17:28 UTC 2006


The problem is that you are using software raid, so there is no raid 
device /dev/md0 until the OS boots, but you can't boot because there is 
no boot device (catch-22).

We recently worked through a similar install on an HP xw9300.  We 
submitted our findings to HP, they verified them, and the last I hearde 
was that this was an "unofficial" document (I don't know if they ever 
supported the procedure, but they did verify that it worked).

It looks lke you have the raid system configured, and the OS installed. 
  All that remains is to duplicate the boot partition.  Here is the 
procedure for duplicating the boot partition:



Duplicating the Boot Partition:

1. The first step you need to accomplish is to boot into “single user” 
mode. The easiest way to accomplish this is to enter “init 1” at the 
command prompt in a terminal window. NOTE: You will need to be logged in 
as ROOT to perform these steps

2. At the prompt, type in "vi /etc/mtab". Locate the entry /dev/md0 and 
replace it with /dev/sda1. Exit vi, saving your changes. Make note of 
the changes made in this and the following steps as they will need to be 
restored to their original values in the final step.

3. Next, enter "/sbin/grub-install  /dev/sda" and press ENTER, this will 
place the GRUB Boot Loader in the boot sector of  the first HDD. When 
the operation is complete it will report back that the installation has 
completed and report any errors if detected. Now, restore /etc/mtab to 
it's original contents.

4. Next, type in "vi /etc/mtab" again. Locate the entry /dev/md0 and 
replace it with /dev/sdb1. Exit vi, saving your changes.  Type in "vi 
/boot/grub/device.map" and replace the entry “/dev/sda” with “/dev/sdb”, 
exit vi, saving your changes.

5. Next, enter "/sbin/grub-install  /dev/sdb" and press ENTER, this will 
place the GRUB Boot Loader in the boot sector of  the second HDD. When 
the operation is complete it will report back that the installation has 
completed and report any errors if detected. Now, restore /etc/mtab to 
its original contents and then restore the content of 
/boot/grub/device.map to its original contents.

6. Reboot the system, the RAID1 is now completed.


      Alfred Hovdestad, RHCE
      University of Saskatchewan


Ramer Ortega wrote:
> I'm trying to install RHES4-U2 in a mirrored SATA disks.  I have 2 disks 
> and during the installation, I defined all the partitions as Software 
> RAID and eventually created RAID1 for each partition, including the 
> /boot partition.
> 
> Install went smoothly but after the completion and during reboot, the 
> screen simply displays "GRUB".
> 
> I booted from the install CD and entered the rescue mode to check the 
> partitions and the grub.conf.  The contents of /etc/fstab rightfully 
> shows that all my partitions are mapped to the corresponding /dev/md? 
> devices.
> 
> My question is, is there any limitation on grub to boot from a mirrored 
> /boot partition?
> 
> Is there any other area that I should be looking at?
> 
> TIA
> 




More information about the redhat-list mailing list