live migration is not using secondary interface

A naive 'virsh migrate --live domU xen+tcp://cross-over-ip' uses the ordinary uplink instead of the requested IP address. According to the documentation an additional option has to be specified to really use the other network interface. However, neither 'tcp://cross-over-ip' nor 'xenmigr:cross-over-ip/' works, the migration does not start. 'xenmigr' was removed with 1dac5fbbbb06a0341e8087dc33af75c8352d77a4 and 7ed598438687feaddaf0a653d7cbb8a1c1ad4933, but the docs were not updated. This leaves 'tcp://ip'. What change needs to be done in the driver to support a secondary interface? Olaf

On Wed, Dec 16, 2020 at 08:34:29PM +0100, Olaf Hering wrote:
A naive 'virsh migrate --live domU xen+tcp://cross-over-ip' uses the ordinary uplink instead of the requested IP address. According to the documentation an additional option has to be specified to really use the other network interface. However, neither 'tcp://cross-over-ip' nor 'xenmigr:cross-over-ip/' works, the migration does not start.
'xenmigr' was removed with 1dac5fbbbb06a0341e8087dc33af75c8352d77a4 and 7ed598438687feaddaf0a653d7cbb8a1c1ad4933, but the docs were not updated.
This leaves 'tcp://ip'. What change needs to be done in the driver to support a secondary interface?
I am think not sure exactly what is the setup, but I am guessing you want to `--migrateuri`, possibly with `--listen-address`. For more details see virsh manual page and https://libvirt.org/migration.html ;)
Olaf

Am Fri, 18 Dec 2020 21:09:45 +0100 schrieb Martin Kletzander <mkletzan@redhat.com>:
I am guessing you want to `--migrateuri`, possibly with `--listen-address`.
Not sure if I really _want_ all these extra knobs. The intent is clear and obvious, the connection needs to go to the specified host and/or IP address. But I will read through migration.html, hopefully it has some hints why this has to be so complicated. Olaf

On Fri, Dec 18, 2020 at 10:42:16PM +0100, Olaf Hering wrote:
Am Fri, 18 Dec 2020 21:09:45 +0100 schrieb Martin Kletzander <mkletzan@redhat.com>:
I am guessing you want to `--migrateuri`, possibly with `--listen-address`.
Not sure if I really _want_ all these extra knobs. The intent is clear and obvious, the connection needs to go to the specified host and/or IP address.
But I will read through migration.html, hopefully it has some hints why this has to be so complicated.
The thing is that there are multiple connections being made (unless you use tunnelled migration) between the client and hosts (or hosts between themselves with peer2peer migration), however the connection string you are using in your command is only specifying how should virsh (or, in case of peer2peer, the source host) connect to the destination for the libvirt connection, not the other connections made between hypervisors. I agree it is not that straightforward. We could default to listening on the ip/host in the libvirt connection, however there are various setups that could break by this and the need for more knobs would not go away anyway. Migration is very complicated thing when you need to handle many special cases. Believe me when I say that libvirt makes it *way* easier than what is happening under the hood despite how many knobs it offers. If you have anything else than the most basic setup you might need to make the extra step. One thing to add, though. If you would rather configure the destination in a way that its hostname resolves to the IP you would prefer for the migration it might be enough to make this work the simple way around. Hope that helps, Martin

On Sat, Dec 19, 2020 at 12:05:51AM +0100, Martin Kletzander wrote:
One thing to add, though. If you would rather configure the destination in a way that its hostname resolves to the IP you would prefer for the migration it might be enough to make this work the simple way around.
If you /always/ want migration to use a different IP than the defaut hostname resolves to, then /etc/libvirt/qemu.conf on the target host can set the "migration_host" parameter to this IP. This avoids the need to specify the IP every time you invoke a migration. Regards, Daniel -- |: https://berrange.com -o- https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o- https://fstop138.berrange.com :| |: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
participants (3)
-
Daniel P. Berrangé
-
Martin Kletzander
-
Olaf Hering