<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Clustering LVM (CLVM) provides a way to manage logical volumes in a consistent way.<div><br class="webkit-block-placeholder"></div><div>By analogy, if you connect the same disk to two machines, put a file system on it (like ext3), and mount the file system on both machines, you can expect corruption.  Both machines will be attempting to create/modify/read metadata without the knowledge that someone else is doing the same...  You need a cluster aware file system in this type of scenario - like GFS.  The same thing is true of LVM... you don't want to have two machines sharing the same volume group - extending/shrinking/creating/deleting logical volumes without knowledge of the other machine... it would lead to corruption of your volume group layout.  This is what CLVM is all about.  It is especially useful when coupled with a cluster-aware file system, like GFS and others.  Active/Active setups are where CLVM is most useful.  Active/Passive setups can get away with a little less (<a href="http://sourceware.org/cluster/wiki/LVMFailover)">http://sourceware.org/cluster/wiki/LVMFailover)</a>.</div><div><br class="webkit-block-placeholder"></div><div>In active/active environments, the concept of CLVM becomes even more important when dealing with more complex RAID.  For example, LVM mirroring must be handled in a different way depending on whether a logical volume is clustered or not.  (This is handled transparently by (C)LVM.)  This is because mirroring creates its own metadata to track the degree to which the component legs are in-sync... this status tracking must be cluster-aware or the state will be corrupted.  This is the reason why there is no snapshotting in CLVM yet.  The cluster-coherent version has not yet been written.</div><div><br class="webkit-block-placeholder"></div><div> brassow</div><div><br><div><div>On Feb 7, 2008, at 10:36 AM, Gerrard Geldenhuis wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0; "><div lang="EN-US" link="blue" vlink="blue" style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div class="Section1"><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="2" color="navy" face="Arial"><span style="font-size: 10pt; font-family: Arial; color: navy; ">Thanks, the “missing snapshotting” would be a problem. I am still slightly unclear as to the goals of the clustering in LVM…<o:p></o:p></span></font></div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="2" color="navy" face="Arial"><span style="font-size: 10pt; font-family: Arial; color: navy; "><o:p> </o:p></span></font></div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="2" color="navy" face="Arial"><span style="font-size: 10pt; font-family: Arial; color: navy; ">Regards<o:p></o:p></span></font></div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="2" color="navy" face="Arial"><span style="font-size: 10pt; font-family: Arial; color: navy; "><o:p> </o:p></span></font></div><div style="border-top-style: none; border-right-style: none; border-bottom-style: none; border-width: initial; border-color: initial; border-left-style: solid; border-left-color: blue; border-left-width: 1.5pt; padding-top: 0cm; padding-right: 0cm; padding-bottom: 0cm; padding-left: 4pt; "><div><div class="MsoNormal" align="center" style="text-align: center; margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="3" face="Times New Roman"><span style="font-size: 12pt; "><hr size="2" width="100%" align="center" tabindex="-1"></span></font></div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><b><font size="2" face="Tahoma"><span style="font-size: 10pt; font-family: Tahoma; font-weight: bold; ">From:</span></font></b><font size="2" face="Tahoma"><span style="font-size: 10pt; font-family: Tahoma; "><span class="Apple-converted-space"> </span><a href="mailto:linux-lvm-bounces@redhat.com">linux-lvm-bounces@redhat.com</a> [<a href="mailto:linux-lvm-bounces@redhat.com" style="color: blue; text-decoration: underline; ">mailto:linux-lvm-bounces@redhat.com</a>]<span class="Apple-converted-space"> </span><b><span style="font-weight: bold; ">On Behalf Of<span class="Apple-converted-space"> </span></span></b>Jonathan Brassow<br><b><span style="font-weight: bold; ">Sent:</span></b><span class="Apple-converted-space"> </span>07 February 2008 16:21<br><b><span style="font-weight: bold; ">To:</span></b><span class="Apple-converted-space"> </span>LVM general discussion and development<br><b><span style="font-weight: bold; ">Subject:</span></b><span class="Apple-converted-space"> </span>Re: [linux-lvm] Docs on clustererd option of vgcreate</span></font><o:p></o:p></div></div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="3" face="Times New Roman"><span style="font-size: 12pt; "><o:p> </o:p></span></font></div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="3" face="Times New Roman"><span style="font-size: 12pt; ">The reason the results are likely so sparse is because the two modes of operation (single machine and cluster) are so similar.<o:p></o:p></span></font></div><div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="3" face="Times New Roman"><span style="font-size: 12pt; "><o:p> </o:p></span></font></div></div><div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="3" face="Times New Roman"><span style="font-size: 12pt; ">Once you've setup a cluster and installed the lvm2-cluster rpm*, new volume groups that are created automatically receive the "clustered" attribute.  [Toggle the cluster attribute by doing vgchange -c[ny] <vg>]  The lvm commands stay the same as if you were running them on a single machine.**<o:p></o:p></span></font></div></div><div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="3" face="Times New Roman"><span style="font-size: 12pt; "><o:p> </o:p></span></font></div></div><div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="3" face="Times New Roman"><span style="font-size: 12pt; "> brassow<o:p></o:p></span></font></div></div><div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="3" face="Times New Roman"><span style="font-size: 12pt; "><o:p> </o:p></span></font></div></div><div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="3" face="Times New Roman"><span style="font-size: 12pt; ">* Of course you could compile the sources or use another install method.<o:p></o:p></span></font></div></div><div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="3" face="Times New Roman"><span style="font-size: 12pt; ">** Some targets (like snapshots) are not available when using LVM in a clustered mode.<o:p></o:p></span></font></div></div><div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="3" face="Times New Roman"><span style="font-size: 12pt; "><o:p> </o:p></span></font></div><div><div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="3" face="Times New Roman"><span style="font-size: 12pt; ">On Feb 7, 2008, at 8:38 AM, Gerrard Geldenhuis wrote:<o:p></o:p></span></font></div></div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="3" face="Times New Roman"><span style="font-size: 12pt; "><br><br><o:p></o:p></span></font></div><span style="orphans: 2; widows: 2; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; word-spacing: 0px; "><div link="blue" vlink="purple"><div><div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="2" color="black" face="Arial"><span lang="EN-GB" style="font-size: 10pt; font-family: Arial; color: black; ">Hi<u1:p></u1:p></span></font><font color="black"><span style="color: black; "><o:p></o:p></span></font></div></div><div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="2" color="black" face="Arial"><span lang="EN-GB" style="font-size: 10pt; font-family: Arial; color: black; ">I am after a bit more documentation about the usage of the<u1:p></u1:p></span></font><font color="black"><span style="color: black; "><o:p></o:p></span></font></div></div><div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="2" color="black" face="Arial"><span lang="EN-GB" style="font-size: 10pt; font-family: Arial; color: black; ">--clustered option in vgcreate.<u1:p></u1:p></span></font><font color="black"><span style="color: black; "><o:p></o:p></span></font></div></div><div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="2" color="black" face="Arial"><span lang="EN-GB" style="font-size: 10pt; font-family: Arial; color: black; "><u1:p> </u1:p></span></font><font color="black"><span style="color: black; "><o:p></o:p></span></font></div></div><div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="2" color="black" face="Arial"><span lang="EN-GB" style="font-size: 10pt; font-family: Arial; color: black; ">At the moment I don’t have a spare san drive with which I can experiment. My understanding is that you would set this flag when different hosts(nodes) connect to the same storage area typically a san with lvm configured.<u1:p></u1:p></span></font><font color="black"><span style="color: black; "><o:p></o:p></span></font></div></div><div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="2" color="black" face="Arial"><span lang="EN-GB" style="font-size: 10pt; font-family: Arial; color: black; "><u1:p> </u1:p></span></font><font color="black"><span style="color: black; "><o:p></o:p></span></font></div></div><div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="2" color="black" face="Arial"><span lang="EN-GB" style="font-size: 10pt; font-family: Arial; color: black; ">I am after a bit more information describing this “clusterering” functionality in lvm and how/where it is used. The man pages on lvm and commands is a bit sparse and I am trawling through google results but not with great success at the moment.<u1:p></u1:p></span></font><font color="black"><span style="color: black; "><o:p></o:p></span></font></div></div><div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="2" color="black" face="Arial"><span lang="EN-GB" style="font-size: 10pt; font-family: Arial; color: black; "><u1:p> </u1:p></span></font><font color="black"><span style="color: black; "><o:p></o:p></span></font></div></div><div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="2" color="black" face="Arial"><span lang="EN-GB" style="font-size: 10pt; font-family: Arial; color: black; ">Regards<u1:p></u1:p></span></font><font color="black"><span style="color: black; "><o:p></o:p></span></font></div></div></div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="1" color="black" face="Helvetica"><span style="font-size: 9pt; font-family: Helvetica; color: black; ">_______________________________________________<br>linux-lvm mailing list<br><a href="mailto:linux-lvm@redhat.com" style="color: blue; text-decoration: underline; ">linux-lvm@redhat.com</a><br><a href="https://www.redhat.com/mailman/listinfo/linux-lvm" style="color: blue; text-decoration: underline; ">https://www.redhat.com/mailman/listinfo/linux-lvm</a><br>read the LVM HOW-TO at<span class="apple-converted-space"> </span><a href="http://tldp.org/HOWTO/LVM-HOWTO/" style="color: blue; text-decoration: underline; ">http://tldp.org/HOWTO/LVM-HOWTO/</a><o:p></o:p></span></font></div></div></span></div><div style="margin-top: 0cm; margin-right: 0cm; margin-left: 0cm; margin-bottom: 0.0001pt; font-size: 12pt; font-family: 'Times New Roman'; "><font size="3" face="Times New Roman"><span style="font-size: 12pt; "><o:p> </o:p></span></font></div></div></div></div>_______________________________________________<br>linux-lvm mailing list<br><a href="mailto:linux-lvm@redhat.com" style="color: blue; text-decoration: underline; ">linux-lvm@redhat.com</a><br><a href="https://www.redhat.com/mailman/listinfo/linux-lvm" style="color: blue; text-decoration: underline; ">https://www.redhat.com/mailman/listinfo/linux-lvm</a><br>read the LVM HOW-TO at<span class="Apple-converted-space"> </span><a href="http://tldp.org/HOWTO/LVM-HOWTO/" style="color: blue; text-decoration: underline; ">http://tldp.org/HOWTO/LVM-HOWTO/</a></div></span></blockquote></div><br></div></body></html>