David Kuntz on 8 Mar 2013 12:52:03 -0800


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: [PLUG] Booting from a RAID partition?


Eric,
See comments below:

On Fri, Mar 8, 2013 at 3:11 PM, Eric Lucas <eric@lucii.org> wrote:
I have a Red Hat 5.x box with RAID (software) mirroring:
Two drives, sda and sdb

/dev/md0  /boot   Â(/dev/sda1 Âand /dev/sdb1)
/dev/md1 Â/ Â Â Â Â Â Â ( /dev/sda2 Âand /dev/sdb2)
/dev/md2 Â <swap> Â Â ( /dev/sda13 and /dev/sdb3)
/dev/md3 Â/home   Â(/dev/sda4 Âand /dev/sdb4)

When I remove sda and replace it with a blank drive (partitioned and
formatted) the system is unable to boot.
I get the normal grub menu but after hitting the return key I get:

> Âroot (hd0,0)
hd0 is most likely /dev/sda, which is now missing. Try substituting hd1 and see if that works.

Â
> Â Filesystem type is ext2fs, partition type 0xfd
> Âkernel /vmlinuz-2.6..18-164.el5 ro root=/dev/md1 rhgb quiet crashkernel=64M@48M
>
> ÂError Â15: File not found
>
> ÂPress any key to continue...Â

When I remove sdb and replace it with a blank drive (partitioned and
formatted) the system is unable to boot - it tries the CD/DVD device
and then just sits there... no grub.


It sounds like grub is only installed on /dev/sdb. Try running grub-install /dev/sda and ensure there is an entry for both sda and sdb in /etc/grub/device.map. Once grub is on sda, pull sdb and test.

>

I expect that RAID mirroring should work with only one drive.... isn't
that the idea?
Should it NOT boot from a RAID drive but instead just have two
identical /dev/sd0 boot partitions NOT in RAID?

TIA
Eric

RAID should work just fine with /boot on /dev/md0. I used to do it on a bunch of servers at my old gig - saved my bacon a couple of times. But booting while missing one of the drives in the mirror can get tricky, and it's far better to just replace the drive while everything is up and spinning :-D
HTH
David
Â
___________________________________________________________________________
Philadelphia Linux Users Group     --    Âhttp://www.phillylinux.org
Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce
General Discussion Â-- Â http://lists.phillylinux.org/mailman/listinfo/plug

___________________________________________________________________________
Philadelphia Linux Users Group         --        http://www.phillylinux.org
Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce
General Discussion  --   http://lists.phillylinux.org/mailman/listinfo/plug