2015年4月1日星期三

Centos Linux software raid problems reminder

Linux Software raid is a good arrangement for data protection against harddisk failure.

But , install Software Raid is not easy expect you use some lazy admin Linux like SME Linux http://wiki.contribs.org.

Some reminder for you & me are below:

Boot procedure after power on.

1. You need to confirm EFI function enabled or not or your server must use it or not.
If yes , something like high end server, you must create a EFI Boot Partition. If no, you can boot server up.

2. Some Server use hardware RAID Card. You cannot remove the card and connect the harddisk to system. So, if you still want to use software raid because some reason. You can try to config the RAID CARD that all single harddisk be a RAID 0 array. After that , Linux will see the harddisk as a single harddisk and not a array of group harddisk. Then you can install them with Linux Software Raid.

3. I use Centos 6.5 to install server. Sometimes cannot boot up after installation. I find that the Grub don't like the hardware RAID. So , we need to boot into rescue mode and chroot /mnt/sysimage.
Then , uncomment the lines in /etc/grub.conf.

boot=/dev/cciss/c0d0

Make sure /boot/grub/device.map is correct and something like that
(hd0)         /dev/cciss/c0d0
(hd1)         /dev/cciss/c0d1

Then run Grub

/sbin/grub --batch --device-map=/boot/grub/device.map --config-file=/boot/grub/grub.conf --no-floppy
grub> root (hd0,0)
grub> setup (hd0)
grub> root (hd1,0)
grub> setup (hd1)
grub> quit

After that , reboot and should be enjoy!

or some of them can use this to make it boot -------------------------------------

boot rescue mode
chroot /mnt/sysimage
grub-install /dev/md0




----------------------------------------------------------------------
Sample for Software Raid Partition but use HP P400i hardware raid controller.




Mount point
/dev/md0 as /boot
LogVol01 as /

If their EFI Boot partittion
/dev/sda1 as /boot/EFI

/dev/sda1 which is the partition you created for EFI boot setting.
But also need to copy this partition on the second harddisk as
/dev/sdb1.



沒有留言: