LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (http://www.linuxquestions.org/questions/linux-server-73/)
-   -   Recovering the OS from software RAID HDD crash with rPath (or RHEL/CentOS/Fedora)? (http://www.linuxquestions.org/questions/linux-server-73/recovering-the-os-from-software-raid-hdd-crash-with-rpath-or-rhel-centos-fedora-749421/)

pwjohnston 08-21-2009 09:01 PM

Recovering the OS from software RAID HDD crash with rPath (or RHEL/CentOS/Fedora)?
 
Newb here.

I'm trying to build a home NAS using openfiler. I don't have a hardware RAID so I have set up a software RAID.

So my disks are
/dev/sda
/dev/sdb
/dev/sdc
/dev/sdd

df -h

Filesystem Size Used Avail Use% Mounted on
/dev/md3 2.0G 693M 1.2G 37% /
/dev/md0 251M 19M 219M 8% /boot
tmpfs 1.9G 0 1.9G 0% /dev/shm < (swap?)
/dev/md1 745M 17M 690M 3% /var/log

/dev/md0 is raid 1 mirrored using sda1 and sdc1
/dev/md1 is raid 1 mirrored using sda2 and sdc2
swap is raid 1 mirrored using sda3 and sdc3
/dev/md3 is raid 1 mirrored using sdb1 and sdd1

I set that up using this doc
https://forums.openfiler.com/viewtopic.php?id=2501
and this for reference
http://www.redhat.com/docs/manuals/l...ware-raid.html

So you guys probably can't speak for OpenFiler, so just tell me if this holds true for RHEL/CentOS.

Lets say the sda drive dies. The info is mirrored on sdc. I've done some reading and I just want to make sure that this sounds right.

Using the instructions here:
http://www.linuxquestions.org/questi...e-raid-527345/


1. Partition /dev/sda the same as /dev/sdc:
sfdisk -d /dev/sdc | sfdisk /dev/sda

2. Add the partition to the array:
mdadm /dev/md0 --add /dev/sda1

3.
mdadm /dev/md1 --add /dev/sda1

4.
mdadm /dev/md3 --add /dev/sda1


(what about swap?)


All times are GMT -5. The time now is 04:04 AM.