[ClusterLabs] [pacemaker+ clvm] Cluster lvm must be active exclusively to create snapshot

Digimer lists at alteeve.ca
Mon Dec 5 22:37:17 EST 2016


On 05/12/16 10:32 PM, su liu wrote:
> Digimer, thank you very much!
> 
> I do not need to have the data accessible on both nodes at once. I want
> to use the clvm+pacemaker+corosync in OpenStack Cinder.

I'm not sure what "cinder" is, so I don't know what it needs to work.

> then only a VM need access the LV at once. But the Cinder service which
> runs on the controller node is  responsible for snapshotting the LVs
> which are attaching on the VMs runs on other Compute nodes(such as
> compute1 node). 

If you don't need to access an LV on more than one node at a time, then
don't add clustered LVM and keep things simple. If you are using DRBD,
keep the backup secondary. If you are using LUNs, only connect the LUN
to the host that needs it at a given time.

In HA, you always want to keep things as simple as possible.

> Need I active the LVs in /exclusively mode all the time? to supoort
> snapping it while attaching on the VM./

If you use clustered LVM, yes, but then you can't access the LV on any
other nodes... If you don't need clustered LVM, then no, you continue to
use it as simple LVM.

Note; Snapshoting VMs is NOT SAFE unless you have a way to be certain
that the guest VM has flushed it's caches and is made crash safe before
the snapshot is made. Otherwise, your snapshot might be corrupted.

> /The following is the result when execute lvscan command on compute1 node:/
> /
> /
> /
> [root at compute1 ~]# lvs
>   LV                                          VG             Attr      
> LSize Pool Origin Data%  Meta%  Move Log Cpy%Sync Convert
>   volume-1b0ea468-37c8-4b47-a6fa-6cce65b068b5 cinder-volumes -wi-------
> 1.00g
> 
> 
> 
> and on the controller node:
> 
> [root at controller ~]# lvscan ACTIVE
> '/dev/cinder-volumes/volume-1b0ea468-37c8-4b47-a6fa-6cce65b068b5' [1.00
> GiB] inherit
> 
> 
> 
> thank you very much!

Did you setup stonith? If not, things will go bad. Not "if", only
"when". Even in a test environment, you _must_ setup stonith.

-- 
Digimer
Papers and Projects: https://alteeve.ca/w/
What if the cure for cancer is trapped in the mind of a person without
access to education?




More information about the Users mailing list