[Linux-HA] Re: RES: [DRBD-user] software RAID, LVM

Nate Reed nreed at awarix.com
Thu Feb 2 10:20:20 MST 2006


Thank you, Leonardo, this is very helpful!  I have a better understanding now, 
but one more question:

On Thursday 02 February 2006 11:00, Leonardo Rodrigues de Mello wrote:
> Hi Nate,
> -----Mensagem original-----
>
> >De:	drbd-user-bounces at lists.linbit.com em nome de Nate Reed
> >Enviada:	qui 2/2/2006 14:41
> >Para:	General Linux-HA mailing list
> >Cc:	drbd-user at lists.linbit.com
> >Assunto:	[DRBD-user] software RAID, LVM
> >
> >Here's what I was thinking of doing on each machine:
> >
> >disk 1
> >  - swap partition
> >  - / partition
> >  - Linux RAID partition
> >
> >disk 2
> >  - Linux RAID partition

I wonder if I could refine this scheme to add redundancy of / and swap as 
follows:

disk 1
  - RAID 1 (md0)
  - RAID 2 (md1)
disk 2 
  - RAID 1 (md0)
  - RAID 2 (md1)

Create two RAID devices, for example: /dev/md0 (for disk1/RAID1 and disk 
2/RAID 1) and /dev/md1 (for disk 1/RAID 2, and disk 2/RAID2).  

DRBD would access /dev/md0, and there are LV's / and swap on /dev/md1.  This 
should insulate LVM against failure of one of the disks.

What do you think of this?

Nate

> >
> >Then, create a RAID device out of the two Linux RAID partitions, then put
> > >DRBD on top of this device
>
> Good aproach. this is what i had done with success.
>
> >The other setup I was considering is:
> >
> >disk 1
> >  - Linux RAID partition
> >
> >disk 2
> >  - Linux RAID partition
> >
> >Then, create a RAID device out of these partitions, and create logical
> >volumes /, swap, /shared, etc.  Then, have DRBD replicate one of these
> >volumes.
>
> if your volumes are compose of raid devices you bypass the lvm failure
> limitation.
>
> >Finally, there is a 3rd option, but I'm not sure this makes any sense: as
> >above, put logical volumes /, swap, /shared, etc., on the RAID device, and
> >use DRBD to replicate the entire device to the other node.  This doesn't
> > make much sense since some data -- esp. swap -- should be local to each
> > machine.
>
> Doenst make sense :-D
>
> >So, what do you think?
> >
> >1. Have DRBD replicate a logical volume (/shared).  Is this possible?  Is
> >there a block device associated with a lv?
>
> Yes there is... if doenst have, you cant format it and use as a physical
> disk.
>
> >2. Have DRBD replicate a /shared partition on RAID, and keep swap and / on
> >disk #1.  Obvious downsides: no redundancy of swap and root, and wasted
> > space on disk #2.
>
> You will have to apply patchs to your system inicialization, to mount your
> DRBD partition before starting anything, i didnt done this yet, but believe
> its possible.
>
> >Am I missing some other approach?
> >
> >Thanks,
> >Nate
> >_______________________________________________



More information about the Linux-HA mailing list