I have two physical servers: Virt1 and Virt2. I'm setting up live migration with CentOS 5.5 between the two. I've done this by NFS mounting /etc/libvirt and /var/lib/libvirt/images on both servers. This is working well for me except for one thing. I see the same list of VMs on each server (as expected), but each server (Virt1 and Virt2) are able to start the same VM at the same time. This obviously causes IP conflicts and thrashes the disk image. Is there a way to tell my VM "cluster" that a VM is only allowed to be opened on one host at a time? -- Scott Baker - Canby Telcom System Administrator - RHCE - 503.266.8253
I've run into the same scenario... I've often wondered if it wouldn't make sense to have a lock file or some other notification in place to let both hosts know who currently has "ownership" of the VM. David. On Mon, 13 Dec 2010, Scott Baker wrote:> I have two physical servers: Virt1 and Virt2. I'm setting up live migration > with CentOS 5.5 between the two. I've done this by NFS mounting /etc/libvirt > and /var/lib/libvirt/images on both servers. This is working well for me > except for one thing. > > I see the same list of VMs on each server (as expected), but each server > (Virt1 and Virt2) are able to start the same VM at the same time. This > obviously causes IP conflicts and thrashes the disk image. Is there a way to > tell my VM "cluster" that a VM is only allowed to be opened on one host at a > time? > > -- > Scott Baker - Canby Telcom > System Administrator - RHCE - 503.266.8253 > > _______________________________________________ > libvirt-users mailing list > libvirt-users at redhat.com > https://www.redhat.com/mailman/listinfo/libvirt-users >
Matthias Bolte
2010-Dec-13 22:28 UTC
[libvirt-users] Deploying libvirt with live migration
2010/12/13 Scott Baker <bakers at canbytel.com>:> I have two physical servers: Virt1 and Virt2. I'm setting up live migration > with CentOS 5.5 between the two. I've done this by NFS mounting /etc/libvirt > and /var/lib/libvirt/images on both servers. This is working well for me > except for one thing. > > I see the same list of VMs on each server (as expected), but each server > (Virt1 and Virt2) are able to start the same VM at the same time. This > obviously causes IP conflicts and thrashes the disk image. Is there a way to > tell my VM "cluster" that a VM is only allowed to be opened on one host at a > time? >Well don't share /etc/libvirt, there is no need to. Just have the domain config on the host that currently executes the domain and tell libvirt to migrate the persistent domain condif along with the domain: virsh migrate --persistent --undefinesource vm1 qemu://virt2/system Matthias
Maybe Matching Threads
- Centos8: Glusterd do not start correctly when I startup or reboot all server together
- unable to remove brick, pleas help
- [ovirt-users] VM paused due unknown storage error
- Centos8: Glusterd do not start correctly when I startup or reboot all server together
- swig_up