[CentOS] Help with software raid + LVM on Centos 6

Fri Apr 27 14:58:41 UTC 2012
Bob Hoffman <bob at bobhoffman.com>

On 4/27/2012 10:52 AM, aurfalien wrote:
> Hi all,
>
> Please excuse the many posts.
>
> Wondering if any one can help me with the the setup.
>
> I have 2x2TBdisks.
> I would like to mirror them.
> I would like to create two LVMs so that I can snap shot from one to the other.
>
> During Centos 6 install, how would I go about this as its confusing?
>
> So far I am here;
>
> 1) Created the following raid devices;
> md0 500MB (use it for /boot)
> md1 4000MB (use it for swap)
> md2 All remaining space (use it for /)
>
> 2) Created two physical LVMs, one on md0, the other on md1.
>
> 3) ?
> This is were I am confused, do I create two LVM volume groups?
>
> I was thinking that my primary LVM can be ~1TB and that my other LVM which I snapshot to can also be ~1TB.
>
> Anyways, I am very green on this topic as I usually do hardware raids but I don't have that option.
>
> Thanks in advance,
> - aurf
>
md0, your boot, cannot be a physical volum...so don't add things to it...
md1 and md2 can be merged, make instead md1 with all remaining space.
create  a raid partition on each drive with 'remaining space' (making 
sure both are the same size)
then create a physical volume raid device and select each drive that has 
the big raid partition

then select create volume group...
add /swap  and '/' to as mount points, these will be volume groups. 
there is  a drop down when adding a mount point that determines file 
type, one is 'swap'

you only need one group..

the physical volume holds the logical group, which holds the logical 
volumes.