Thibault VINCENT
2011-May-24 16:22 UTC
[libvirt-users] Xen and live migration with VIR_MIGRATE_PERSIST_DEST
Hi, I'm having a hard time to figure how to perform Xen live migration using the python API with the same rate of success than virt-manager. # virsh version Compiled against library: libvir 0.8.3 Using library: libvir 0.8.3 Using API: Xen 3.0.1 Running hypervisor: Xen 3.2.0 The goal is to have the migration done in only one call, including a definition in the remote xend and undefinition from the source, which requires the VIR_MIGRATE_PERSIST_DEST and VIR_MIGRATE_UNDEFINE_SOURCE flags. Here's the code doing the migration: ---------- flags = (libvirt.VIR_MIGRATE_LIVE ^ libvirt.VIR_MIGRATE_PERSIST_DEST ^ libvirt.VIR_MIGRATE_UNDEFINE_SOURCE) uri = 'xenmigr://remote.host.com:8002' domain_obj.migrate(con_handle, flags, None, uri, 0) ---------- There are various problems that occur randomly, such as the VM completely disappearing 5 seconds after a succesful migration, but the main issue is with VIR_MIGRATE_PERSIST_DEST that doesn't seem to have any effect. The domU is not defined in xend and will vanish when destroyed or on hypervisor reboot. Could that be a known problem or related to a bug ? I'm really out of ideas. Any help appreciated, Thank you ! -- Thibault VINCENT - IT SmartJog S.A.S. - Groupe TDF - P?le multim?dia 27 Bd Hippolyte Marques, 94200 Ivry-sur-Seine, France Phone: +33.1.58.68.62.38 / Fax: +33.1.58.68.60.97