Re: Wanted: method for qemu hook script to know if called for migration

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Jul 25, 2011 at 02:17:08PM -0600, Eric Blake wrote:

> Not to distract from your bug report, but have you considered using
> the new sanlock (0.9.3) or fcntl (0.9.4) lock managers, that do this
> automatically, without the need for using hook scripts.
> 
> http://libvirt.org/locking.html

Thanks Eric. Interesting alternative. 

What I'm trying not to allow is starting a second instance of a VM from a
raw image which is present on two hosts at the same time (using sometimes
DRBD, sometimes GlusterFS). So it's not a case of two running VMs being in
contention for some disk storage external to them, but of two hosts being in
contention to run the same VM. The VM exists on storage mirrored between the
two hosts.

In trying to understand whether sanlock will work in this instance, I see at
http://permalink.gmane.org/gmane.comp.emulators.libvirt/40261:
  
  sanlock will ... protect against 2 vms on the same host using the same
  disk (or the same VM being started twice due to error by libvirt).

By implication if I have the sanlock directory on a shared filesystem, it
will also prevent a VM from being started on the second host while running
on the first. Will it still allow the VM to do a live migration? Or will
live migration run up against the lock?

Whit


[Index of Archives]     [Virt Tools]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [KDE Users]

  Powered by Linux