[Pacemaker] Migrate vm on drbd in correct order?

Matthew O'Connor matt at ecsorl.com
Sun Mar 17 02:38:49 CET 2013


Hi,

I hope this doesn't lead you astray, but I was under the impression that
live-migrating (if that's what you're attempting) requires the disk
image to be available on both nodes?  Perhaps try using drbd in
dual-primary mode?  I assume your VM is accessing the drbd targets
listed in your config directly.

-- Matthew

On 03/16/2013 07:16 AM, Matthias Teege wrote:
> Hi,
>
> I'm try to setup a two node cluster for virtuell machines (KVM/libvirt)
> with drbd as storage backend. For each vm I use two drbd devices. Starting
> and stopping works but I cant migrate the VM to the second node. If i
> switch a node to "standby" the VM stays "started" and there ist no call
> to VirtualDomain.
>
> I found the following in this list [0]
>
> "Yes, migration only works without order-contraints the migrating service
> depends on ... and no way to force it"
>
> and I use order constraints because I need the drbd devices up before
> the vm starts.
>
> How do I migrate a vm or other ressources in the correct order? Is there
> another way to migrate vm and drbd device, maybe start/stop?
>
> My current config looks like this:
>
> primitive vma_R ocf:linbit:drbd params drbd_resource="vma_R" \
>   op monitor interval="29s" role="Master" \
>   op monitor interval="31s" role="Slave" \
>   op start timeout="240s" \
>   op stop timeout="100s"
>
> ms ms_vma_R vma_R \
>   meta master-max="1" master-node-max="1" \
>   clone-max="2" clone-node-max="1" \
>   notify="true"
>
> primitive vma_S ocf:linbit:drbd params drbd_resource="vma_S" \
>   op monitor interval="29s" role="Master" \
>   op monitor interval="31s" role="Slave" \
>   op start timeout="240s" \
>   op stop timeout="100s"
>
> ms ms_vma_S vma_S \
>   meta master-max="1" master-node-max="1" \
>   clone-max="2" clone-node-max="1" \
>   notify="true"
>
> primitive kvm_vma ocf:heartbeat:VirtualDomain \
>   params config="/etc/libvirt/qemu/vma.xml" \
>   hypervisor="qemu:///system" migration_transport="ssh" \
>   meta allow-migrate="true" \
>   op start timeout="120s" \
>   op stop timeout="180s" \
>   op monitor depth="0" timeout="30" interval="10"
>
> colocation vma_on_drbd \
>   inf: ms_vma_R:Master ms_vma_S:Master kvm_vma:started
> order vma_after_drbd \
>   inf: ms_vma_S:promote ms_vma_R:promote kvm_vma
>
> Thanks
> Matthias
>
> [0] http://www.mail-archive.com/pacemaker@oss.clusterlabs.org/msg10499.html
>
>
> _______________________________________________
> 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://bugs.clusterlabs.org


-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5029 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://oss.clusterlabs.org/pipermail/pacemaker/attachments/20130316/86ef76ff/attachment-0001.p7s>


More information about the Pacemaker mailing list