[Pacemaker] Resource Agents 1.0.4: HA LVM Patch

Dejan Muhamedagic dejanmm at fastmail.fm
Wed Apr 27 09:11:59 UTC 2011


On Wed, Apr 27, 2011 at 09:40:22AM +0200, Ulf wrote:
> Hi,
> I'm not sure if inux-ha-dev at lists.linux-ha.org will receive this message, as I'm not subscribed to.

It won't, you need to subscribe.

> >Can you please elaborate on the benefits this patch would bring.
> >Is it supposed to prevent a VG from being mounted on more than
> >one node?
> 
> Following scenario: Shared storage with a VG and a not clusteraware filesystem like ext3. An active/passive cluster.
> During the reboot of a server many distributions do a "vgscan --mknodes", which will activate the VG.

Pacemaker checks on startup for all resources on a node if
they're running (started).

> The result will be an active VG on the passive node. You really want to avoid a non cLVM VG to be active on two nodes.
> There might be some other trick with a filter to get this working, but the volume_list is the preferred solution, at least in my eyes.
> The volume_list method is a way to prevent a non cLVM VG to be active on more than one node.

What makes a VG non-cLVM? Why not just use cLVM?

> The solution has only one caveat. A VG remains active even if it looses the VG tag, so you make sure the node get STONITH.

Which is where we could have a problem. This is a best effort
method and ultimately it is not going to prevent parallel VG use.
Now, you and I may agree on that, but it could be difficult to
explain to random user. Further, if you have STONITH in place,
one side won't start resources before it has fenced the other
side.

BTW, the rgmanager resource agent has this feature, but they
decided not to start a VG which is owned by another host.

Cheers,

Dejan

> To get this working you need to add tages to /etc/lvm/lvm.conf
> tags { hosttags = 1 }
> 
> And create a /etc/lvm/lvm_HOSTNAME.conf, which needs to be individual on every node. Add the line to enable the rootvg and every VG which is tagged with the hostname.
> activation { volume_list = [ "rootvg", "@HOSTNAME" ] }
> 
> 
> Cheers,
> Ulf
> -- 
> Empfehlen Sie GMX DSL Ihren Freunden und Bekannten und wir
> belohnen Sie mit bis zu 50,- Euro! https://freundschaftswerbung.gmx.de
> 
> _______________________________________________
> Pacemaker mailing list: Pacemaker at oss.clusterlabs.org
> http://oss.clusterlabs.org/mailman/listinfo/pacemaker
> 
> Project Home: http://www.clusterlabs.org
> Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
> Bugs: http://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker




More information about the Pacemaker mailing list