This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
Home Products Support Community News


Re: [Xen-users] Re: cLVM on Debian/Lenny

To: Javier Guerra <javier@xxxxxxxxxxx>
Subject: Re: [Xen-users] Re: cLVM on Debian/Lenny
From: Jan Kalcic <jandot@xxxxxxxxxxxxxx>
Date: Mon, 20 Apr 2009 19:25:21 +0200
Cc: Jan Kalcic <jandot@xxxxxxxxxxxxxx>, Olivier Le Cam <Olivier.LeCam@xxxxxxxxxxxxxxxxxxxxx>, John Madden <jmadden@xxxxxxxxxxx>, Ferenc Wagner <wferi@xxxxxxx>, xen-users@xxxxxxxxxxxxxxxxxxx, Thiago Camargo Martins Cordeiro <thiagocmartinsc@xxxxxxxxx>
Delivery-date: Mon, 20 Apr 2009 10:25:40 -0700
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from :user-agent:mime-version:to:cc:subject:references:in-reply-to :content-type:content-transfer-encoding; bh=BX/uPHOTcueBlY1F+ZFLAK/c6xagzVG5OTYIBSvppNs=; b=d+6FUgfJWDUAlG1nVaj92tliDCyRNED1gVwbIlfFmb2ybyykeOkototQauJ4jj+toh slA27cJcIlZ758j/HGZ8cRopdtDZdBhIKR60Uwuliv5Eqgv2kBqwsL7TuFHRiSFpkJJ/ cb/KntFp57zDlMTDXjyY0203Q6Nfvg2q0SP2k=
Domainkey-signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; b=VYLUnU12bPuO1igiKQDjjyHGYU9An1oIaYCXZ/wAvDMuuDON/Xes4FcNKRw8ajcK4q mratMyvj+vmNmudYCUHsp5FdiOtbMSZ0U2egbl3np70uJ7q0Cx2CGSe1eQT0qfmkBS9k LKxHmBb4MYlmAZ2b9wXUkRrSthGF8Fb/Gvcb8=
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <90eb1dc70904200828p1b781433k315849f8741c1223@xxxxxxxxxxxxxx>
List-help: <mailto:xen-users-request@lists.xensource.com?subject=help>
List-id: Xen user discussion <xen-users.lists.xensource.com>
List-post: <mailto:xen-users@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=unsubscribe>
References: <49E61DED.7030607@xxxxxxxxxxxxxxxxxxxxx> <87k55kvbdn.fsf@xxxxxxxxxxxxx> <90eb1dc70904160912i5c4741c9v8385e481694159c3@xxxxxxxxxxxxxx> <49E8827B.3070305@xxxxxxxxxxxxxxxxxxxxx> <90eb1dc70904171031j6b83fa3dp76ff2f060cebe789@xxxxxxxxxxxxxx> <6b7f6eb0904171201s2cb48281h924343236b3bbb07@xxxxxxxxxxxxxx> <49EC5342.4090202@xxxxxxxxxxxxxxxxxxxxx> <49EC65CF.3020001@xxxxxxxxx> <1240235155.21421.473.camel@quagmire> <49EC8482.7020508@xxxxxxxxx> <90eb1dc70904200828p1b781433k315849f8741c1223@xxxxxxxxxxxxxx>
Sender: xen-users-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Thunderbird (X11/20081227)
Javier Guerra wrote:
> On Mon, Apr 20, 2009 at 9:19 AM, Jan Kalcic <jandot@xxxxxxxxxxxxxx> wrote:
>> cLVM does not provide a lock manager which manages *access* (I know
>> EVMS2 does for instance) to a LV or VG from the nodes of a cluster. As
>> you said, It just keeps LVM changes consistent. Let me say it provides a
>> DLM at volume level. To prevent split-brain I need a DLM at file system
>> level, of course, so a cluster-aware file system like OCFS2 is needed.
> you're mixing levels a bit.
> - dm: (kernelspace) device mapper, creates 'virtual block devices'.
> any access on these is mapped to some access on a real device.
> - LVM: (mostly userspace) uses dm to create LVs. it manages some
> metadata blocks on the block devices, and loads the mapping tables
> into the kernel.  when running on a single node it can do changes
> while online because dm supports a 'suspend' operation; the sequence
> is: change metadata blocks, suspend logical devices, change mapping
> tables in the kernel, unsuspend.
>   in theory, you can use LVM as is with shared block devices and
> several nodes; with two precautions: never mount a single LV on more
> than one node, and never do any change to the VG while other nodes are
> running.  for that, you have to disconnect the VG from all nodes, do
> the change on the only node still connected, and reconnect all the
> rest.
> - lock manager: there are several, the one from the GFS stack is now
> based on openAIS.  locks are an abstract service in the sense that can
> be used for several different things.
> - cLVM: (userspace) a small extension to LVM utilities, and a daemon
> (clvmd).   any operation that would change a shared VG first acquires
> a lock.  for that lock operation to succeed, the clvmd of all other
> nodes do a 'suspend'.  when the lock is acquired, the first node can
> be sure that no write operation will happen on the device.  it changes
> the metadata blocks and notifies all other nodes.  the other nodes
> reload the mapping tables from the changed metadata blocks, and
> unsuspend the volume group to release the lock.
> in short, the only thing cLVM adds to 'bare' LVM is to extend the
> online management capabilities of LVM to the whole cluster.
That's really clear now. Very interesting.
> on top of these, there can be several uses of these LVs.  you can put
> non-cluster filesystems, as long as you never do a double mount; or
> you can use cluster filesystems, which will use a lock manager (may be
> the same as cLVM, or may be another one) to assure consistency at that
> level, or you can use them for Xen, with similar limitations,
> depending on the filesystems used by the DomUs.

Now I think I can figure out that there is no difference between a domU
based on a file block device on top of a cluster file system, let's
suppose OCFS2, and a domU based on physical block device on top of LVM
(cLVM). In both case, I am eventually able to run the domU on both nodes
having data corruption. Neither OCFS2 nor cLVM with their different lock
managers can provide that mechanism to assure consistency. Right? If
yes, I would say that the best solution should always be using LVM, at
least it provides more features.

Do you agree?


Xen-users mailing list