Hi, 21.02.2014 00:07, Digimer wrote: > Hi all, > > I want to get clustered LV snapshotting working. I was under the > impression it was simply a matter of disabling the LV on the other node > (2-node cluster here). However, this fails because of locking issues. > > I can change the peer node's LV to 'inactive' with (confirmed with > lvscan): > > [root@an-c05n01 ~]# lvchange -aln /dev/an-c05n02_vg0/vm01-rhel2_0 > [root@an-c05n01 ~]# lvscan > > inactive '/dev/an-c05n02_vg0/vm01-rhel2_0' [50.00 GiB] inherit > > But I still can't create snapshot on the other node running the VM: > > [root@an-c05n02 ~]# lvcreate -L 25GiB --snapshot -n > vm01-rhel2_0_snapshot /dev/an-c05n02_vg0/vm01-rhel2_0 > vm01-rhel2_0 must be active exclusively to create snapshot > > So I try to set it exclusive: > > [root@an-c05n02 ~]# lvchange -aey /dev/an-c05n02_vg0/vm01-rhel2_0 > Error locking on node an-c05n02.alteeve.ca: Device or resource busy > > If I stop the VM running on the LV, then I can set the exclusive lock, > boot the VM and later create the snapshot fine: > > [root@an-c05n02 ~]# lvcreate -L 25GiB --snapshot -n > vm01-rhel2_0_snapshot /dev/an-c05n02_vg0/vm01-rhel2_0 > Logical volume "vm01-rhel2_0_snapshot" created > > But then later, I can't remove the exclusive value, so I can't re-active > the LV after deleting the snapshot. I have to shut the VM down again in > order to remove the exclusive flag. > > I'm assuming it's possible to snapshot clustered LVs while they're in > use, without stopping what is using them twice... Can someone help > clarify what the magical incantation is? First patch from this series should https://www.redhat.com/archives/linux-lvm/2013-March/msg00050.html I support that for myself and have that reworked and ported to .102, so please contact me if you need newer patches (iirc they have some fixes as well). As you see, I tried to push that into upstream LVM, but I'm strongly disagree with some points I got in replies from core LVM devs, so I wash my hands. Best, Vladislav -- Linux-cluster mailing list Linux-cluster@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/linux-cluster