Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: DRBD: Users

nested lvm & dual primary

 

 

DRBD users RSS feed   Index | Next | Previous | View Threaded


cbex at xplornet

Sep 5, 2008, 11:46 AM

Post #1 of 6 (377 views)
Permalink
nested lvm & dual primary

Does anybody know if it is possible to use 'nested lvm' with 'dual primary
mode', or is that a conflict between lvm/clvm?

My configuration is:
- 2 debian-lenny nodes, updated & clean default installation w/versions:
- clvm (2.02.39-2)
- lvm2 (2.02.39-2)
- drbd8-modules-2.6.26-1-amd64 (2.6.26+8.0)
- drbd8-utils (2:8.0.13-1)

- each has 1 hard disk (sda)
- each disk has two partitions (boot, crypt-lvm)
- the lvm partition contains debian default logical volumes + 1 extra for drbd
- drbd is configured primary/primary and is up and running

*here is where the problem starts on the '/dev/r0':
-pv creates ok
-vg creates ok
-lv creation has error about not being able to 'wipe' before creation

I think I need to use clvm here, but changing lvm.conf seems to interfere with
the pre-existing (normal) logical volumes.

*Am I missing something?
*Is there another approach?
*Or, can TWO instances of lvm run on seperate '.conf' with different filters?
 (one instance for filtered for lvm, and one filtered for clvm)

Thanks,
Colin.
_______________________________________________
drbd-user mailing list
drbd-user[at]lists.linbit.com
http://lists.linbit.com/mailman/listinfo/drbd-user


jamundso at gmail

Sep 5, 2008, 7:51 PM

Post #2 of 6 (363 views)
Permalink
Re: nested lvm & dual primary [In reply to]

On Fri, Sep 5, 2008 at 1:46 PM, Colin <cbex[at]xplornet.com> wrote:
> Does anybody know if it is possible to use 'nested lvm' with 'dual primary
> mode', or is that a conflict between lvm/clvm?

Why are you using clvm with drbd? In other words, what is the use case?

jerry

--
There's plenty of youth in America - it's time we find the "fountain of smart".
_______________________________________________
drbd-user mailing list
drbd-user[at]lists.linbit.com
http://lists.linbit.com/mailman/listinfo/drbd-user


cbex at xplornet

Sep 5, 2008, 8:06 PM

Post #3 of 6 (363 views)
Permalink
Re: nested lvm & dual primary [In reply to]

Thanks for the response Jerry. I'm in the middle of trying a different
approach, but I'm willing to do it the "right way" if there such a thing.

My use case is:

I have two identical servers, each with a single SATA 500G drive. Each has 2
NIC's being used as 1GB x-over, and 100MB for the network.
I plan to host virtual machines on a Debian Lenny OS with a large shared DRBD
mirrored partition. (and hopefully linux-ha with bonded IP's)

I also want (but don't need) the disk fully encrypted, excepting the small
boot partition.
---------------------
Currently, my new plan is this:
unencrypted sda1 /boot
encrypted sda2 /
unencrypted sda3 drbd-meta
unencrypted sda4 drbd-data
(and hopefully be able to use encryption on the drbd-resource)

TIA,
Colin.

On Friday 05 September 2008 19:51:04 Jerry Amundson wrote:
> On Fri, Sep 5, 2008 at 1:46 PM, Colin <cbex[at]xplornet.com> wrote:
> > Does anybody know if it is possible to use 'nested lvm' with 'dual
> > primary mode', or is that a conflict between lvm/clvm?
>
> Why are you using clvm with drbd? In other words, what is the use case?
>
> jerry


_______________________________________________
drbd-user mailing list
drbd-user[at]lists.linbit.com
http://lists.linbit.com/mailman/listinfo/drbd-user


jamundso at gmail

Sep 5, 2008, 8:22 PM

Post #4 of 6 (363 views)
Permalink
Re: nested lvm & dual primary [In reply to]

On Fri, Sep 5, 2008 at 10:06 PM, Colin <cbex[at]xplornet.com> wrote:
> Thanks for the response Jerry. I'm in the middle of trying a different
> approach, but I'm willing to do it the "right way" if there such a thing.

Yes, with *nix, there is always a "right way". (Un)Fortunately, there
is N+1 ways of implementing it the "right way", for all values of N,
and for any value of "it". :-)

> My use case is:
>
> I have two identical servers, each with a single SATA 500G drive. Each has 2
> NIC's being used as 1GB x-over, and 100MB for the network.
> I plan to host virtual machines on a Debian Lenny OS with a large shared DRBD
> mirrored partition. (and hopefully linux-ha with bonded IP's)

And...so?
Back to my original question - where does clvm fit in?

jerry

--
There's plenty of youth in America - it's time we find the "fountain of smart".
_______________________________________________
drbd-user mailing list
drbd-user[at]lists.linbit.com
http://lists.linbit.com/mailman/listinfo/drbd-user


cbex at xplornet

Sep 5, 2008, 8:35 PM

Post #5 of 6 (363 views)
Permalink
Re: nested lvm & dual primary [In reply to]

Well it came in to play when I had one large 'resource' configured
(Primary/Primary, if I didn't mention that yet), and I wanted to create
several 'logical volumes' on that resource, so that my multiple virtual
machines would have a defined sized box to live in. This brought me to the
DRBD User's Guide, Chap. 10, Using GFS with DRBD.
On the page: Configuring LVM to recognize the DRBD resource, it states that
GFS uses CLVM.

This is where I was blindly following along without knowing exactly what I was
doing. All I knew was that I needed a 'cluster-aware' filesystem like OCFS2
or GFS.

Where I got stopped was: errors creating the logical volumes, and not knowing
how to configure CLVM to work with my system.

So that is a different path than I am on now... but If it leads somewhere
where I want to be, I'm all ears!

Thanks,
Colin.

On Friday 05 September 2008 20:22:08 Jerry Amundson wrote:
> On Fri, Sep 5, 2008 at 10:06 PM, Colin <cbex[at]xplornet.com> wrote:
> > Thanks for the response Jerry. I'm in the middle of trying a different
> > approach, but I'm willing to do it the "right way" if there such a thing.
>
> Yes, with *nix, there is always a "right way". (Un)Fortunately, there
> is N+1 ways of implementing it the "right way", for all values of N,
> and for any value of "it". :-)
>
> > My use case is:
> >
> > I have two identical servers, each with a single SATA 500G drive. Each
> > has 2 NIC's being used as 1GB x-over, and 100MB for the network.
> > I plan to host virtual machines on a Debian Lenny OS with a large shared
> > DRBD mirrored partition. (and hopefully linux-ha with bonded IP's)
>
> And...so?
> Back to my original question - where does clvm fit in?
>
> jerry


_______________________________________________
drbd-user mailing list
drbd-user[at]lists.linbit.com
http://lists.linbit.com/mailman/listinfo/drbd-user


cbex at xplornet

Sep 6, 2008, 2:17 PM

Post #6 of 6 (354 views)
Permalink
Re: nested lvm & dual primary [In reply to]

//forwarding this email to the mailing list//

OK Tom, I'm slowly getting the picture.  Maybe you (or anyone) could give me a
boost, by telling me (us) how you would set up the disks/filesystems?  
Assuming:

2 node system
1 disk per node
Gb NIC w/crossover cable
100Mb NIC for the network

wanting:
data encrypted on disk
a (large) portion of disk mirrored between nodes

for the purpose of:
hosting several virtual machines
where one node can host all machines during failover
==============

Thanks,
Colin.


On Saturday 06 September 2008 12:20:03 you wrote:
> On Sat, 6 Sep 2008, Colin wrote:
> > Tom, I think you are correct there.
> >
> > I guess a cluster-aware filesystem would only be needed if all the
> > virtual machines were on the same logical volume, and both nodes would be
> > running different VM's from that LV?
>
> as far as I know, you need the cluster aware filesystem if multiple nodes
> have the same filesystem mounted. So, for example, if you were using image
> files (yuck) stored on a single filesystem and handed out by each dom0 to
> guests on both nodes you would need it... as both dom0's have the
> filesystem mounted.
>
> That isn't to say that the cluster aware lvm version isn't a good thing...
> if both dom0's see the drbd resource, they better agree on how you've
> sliced it up into logical volumes... but the domUs using the LV slices can
> simply run a normal filesystem and get much better performance as they
> don't have to do any checking/locking to see if another node is messing
> with the same files.
>
> -Tom
>
> > I wonder if that kind of setup would be better or worse?
> > (Maybe more simple because only one LV is needed, but worse because of
> > the unnecessary  complication of using a 'distributed lock manager'?)
> >
> > Colin.
> >
> > On Saturday 06 September 2008 11:35:42 you wrote:
> >> On Fri, 5 Sep 2008, Colin wrote:
> >>> Well it came in to play when I had one large 'resource' configured
> >>> (Primary/Primary, if I didn't mention that yet), and I wanted to create
> >>> several 'logical volumes' on that resource, so that my multiple virtual
> >>> machines would have a defined sized box to live in.  This brought me to
> >>> the DRBD User's Guide, Chap. 10, Using GFS with DRBD.
> >>> On the page: Configuring LVM to recognize the DRBD resource, it states
> >>> that GFS uses CLVM.
> >>
> >> AFAICS, you do NOT need a cluster-aware filesystem. You're not going to
> >> have multiple nodes writing to the same filesystem at the same time. If
> >> you're given each virtual machine a chunk of space to call it's own,
> >> then that virtual machine will either be on one node or the other... and
> >> it will be the only writer to that chunk of space... yes/no?
> >>
> >> -Tom
>

_______________________________________________
drbd-user mailing list
drbd-user[at]lists.linbit.com
http://lists.linbit.com/mailman/listinfo/drbd-user

DRBD users RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact lists@gossamer-threads.com
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.