On Sat, Jan 07, 2017 at 11:25:20PM +0530, Anubhav Guleria
wrote:>Greetings,
>
>I was trying to understand the flow of Migration Code in libvirt and
>have few doubts:
>
>1) libvirt talks to QEMU/KVM guests via QEMU API. So overall, in
>order to manage QEMU/KVM guests I can either use libvirt (or tools
>based on libvirt like virsh) or QEMU monitor. Is it so?
>
Yes. But if you spawn it with libvirt, you should do everything through
libvirt. You can use 'virsh qemu-monitor-command' for querying some
things that libvirt doesn't allow, but definitely not change anything.
>2) Since libvirt is Hypervisor neutral so actual migration
>algorithm(precopy or postcopy) is present in the hypervisor ,i.e. in
>case of QEMU it should be present in QEMU code base . I was going
>through the code starting from libvirt-domain api and not able to
>follow after virDomainMigrateVersion3Full(.....) . Kindly help.
>
Search for "conn->driver", you will find
"domain->conn->driver->" and
"dconn->driver->", that's how source and destination APIs
are called.
I remember an image explaining the APIs called in different versions.
The migration API is "neutral", but at the same time the code needs to
know (and it knows) about all the options that will be used
(e.g. post-copy).
>Thanks in advance. And sorry if that was too basic.
>
>Anubhav
>
>_______________________________________________
>libvirt-users mailing list
>libvirt-users@redhat.com
>https://www.redhat.com/mailman/listinfo/libvirt-users