[CentOS] Software RAID in CentOS (EL)

Joshua Baker-LePain jlb17 at duke.edu
Tue Apr 19 10:13:09 UTC 2005


On Mon, 18 Apr 2005 at 10:51pm, Francois Caen wrote

> On 4/18/05, Chuck Rock <carock at epctech.com> wrote:
> > Isn't RAID supposed to be redundant disks, not redundant partitions? If that
> > hda disk goes bad, the raid and redundancy is nowhere to be found along with
> > your data. Right?
> 
> Software is more flexible than that. It works with partitions.
> 
> Of course, for redundancy purposes, you want to mirror partitions on
> separate physical drives. But you don't have to mirror all the
> partitions on all your drives.
> 
> For example, you don't raid swap partitions. Or you may want to have a
> small /boot that's not raid. And then a big /home which is mirrored.

If you want the system to survive losing a disk (i.e. it stays up until 
you shut it down to swap the disk (if you don't have hot swap)), you 
must RAID all partitions, including swap.  In a ks.cfg, it looks something 
like this:

part raid.01 --size 8192 --ondisk sda --asprimary
part raid.11 --size 8192 --ondisk sdb --asprimary
part raid.02 --size 4096 --ondisk sda
part raid.12 --size 4096 --ondisk sdb
part raid.03 --size 4096 --ondisk sda
part raid.13 --size 4096 --ondisk sdb
part raid.04 --size 4096 --ondisk sda
part raid.14 --size 4096 --ondisk sdb
part raid.05 --size 2047 --ondisk sda
part raid.15 --size 2047 --ondisk sdb
part raid.06 --size 1023 --grow --ondisk sda
part raid.16 --size 1023 --grow --ondisk sdb

raid / --level=1 --device=md0 raid.01 raid.11
raid /usr/local --level=1 --device=md1 raid.02 raid.12
raid /tmp --level=1 --device=md2 raid.03 raid.13
raid /var --level=1 --device=md3 raid.04 raid.14
raid swap --level=1 --device=md4 raid.05 raid.15
raid /home --level=1 --device=md5 raid.06 raid.16


-- 
Joshua Baker-LePain
Department of Biomedical Engineering
Duke University



More information about the CentOS mailing list