Description of problem: hostdev interface with teaming setting will not be hotplugged on target host during postcopy migration Version-Release number of selected component (if applicable): # rpm -q libvirt-libs qemu-kvm kernel libvirt-libs-6.0.0-15.module+el8.2.0+6106+b6345808.x86_64 qemu-kvm-4.2.0-16.module+el8.2.0+6092+4f2391c1.x86_64 kernel-4.18.0-187.el8.x86_64 How reproducible: 100% Steps to Reproduce: 1. Prepare vm with below interfaces about netowrk failover: <interface type='network'> <mac address='fe:54:00:d2:24:55'/> <source network='hostdevnet'/> <model type='virtio'/> <teaming type='transient' persistent='ua-backup0'/> <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/> </interface> <interface type='network'> <mac address='fe:54:00:d2:24:55'/> <source network='persistent-net'/> <model type='virtio'/> <teaming type='persistent'/> <alias name='ua-backup0'/> <address type='pci' domain='0x0000' bus='0x07' slot='0x00' function='0x0'/> </interface> # virsh net-dumpxml hostdevnet <network connections='1'> <name>hostdevnet</name> <uuid>0b378c46-c023-455e-b8d6-532ce4bca4e6</uuid> <forward mode='hostdev' managed='yes'> <address type='pci' domain='0x0000' bus='0x04' slot='0x10' function='0x1'/> <address type='pci' domain='0x0000' bus='0x04' slot='0x10' function='0x3'/> </forward> </network> # virsh net-dumpxml persistent-net <network connections='1'> <name>persistent-net</name> <uuid>88ea7bd7-4a67-497d-a68b-0559083812f4</uuid> <forward dev='eno1' mode='bridge'> <interface dev='eno1' connections='1'/> </forward> </network> 2. start the vm and check on the vm, there are 3 interfaces as below, which is as expected; # ifconfig enp1s0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 10.73.33.* netmask 255.255.254.0 broadcast 10.73.33.255 inet6 fe80::fc54:ff:fed2:2455 prefixlen 64 scopeid 0x20<link> ether fe:54:00:d2:24:55 txqueuelen 1000 (Ethernet) RX packets 32 bytes 8163 (7.9 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 74 bytes 7540 (7.3 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 enp7s0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 10.73.33.* netmask 255.255.254.0 broadcast 10.73.33.255 inet6 2620:52:0:4920:e304:603e:2a0f:317d prefixlen 64 scopeid 0x0<global> inet6 fe80::f18c:7fce:cb0a:10e6 prefixlen 64 scopeid 0x20<link> ether fe:54:00:d2:24:55 txqueuelen 1000 (Ethernet) RX packets 37 bytes 9227 (9.0 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 84 bytes 9024 (8.8 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 enp7s0nsby: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet6 fe80::57f4:871f:9610:c42d prefixlen 64 scopeid 0x20<link> ether fe:54:00:d2:24:55 txqueuelen 1000 (Ethernet) RX packets 5 bytes 1064 (1.0 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 10 bytes 1484 (1.4 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 ... 3. do migration with post-copy enabled # virsh migrate rhel qemu+ssh://per37/system --live --verbose --postcopy when migration in progress, open another console to run: # virsh migrate-postcopy rhel 4. After migration finished, check the vm on target host, there are only 2 interfaces, the hostdev interface is not hotplugged back enp7s0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 10.73.33.198 netmask 255.255.254.0 broadcast 10.73.33.255 inet6 2620:52:0:4920:e304:603e:2a0f:317d prefixlen 64 scopeid 0x0<global> inet6 fe80::f18c:7fce:cb0a:10e6 prefixlen 64 scopeid 0x20<link> ether fe:54:00:d2:24:55 txqueuelen 1000 (Ethernet) RX packets 304 bytes 35042 (34.2 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 110 bytes 13814 (13.4 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 enp7s0nsby: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 ether fe:54:00:d2:24:55 txqueuelen 1000 (Ethernet) RX packets 220 bytes 13964 (13.6 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 79 bytes 12302 (12.0 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 # dmesg |egrep 'eth|enp' [ 5.482422] virtio_net virtio4 eth0: failover master:eth0 registered [ 5.484439] virtio_net virtio4 eth0: failover standby slave:eth1 registered [ 5.490480] virtio_net virtio4 enp7s0nsby: renamed from eth1 [ 5.499198] virtio_net virtio4 enp7s0: renamed from eth0 [ 14.017133] virtio_net virtio4 enp7s0: failover primary slave:eth0 registered [ 14.325639] ixgbevf 0000:01:00.0 enp1s0: renamed from eth0 [ 20.730930] IPv6: ADDRCONF(NETDEV_UP): enp7s0: link is not ready [ 20.752737] IPv6: ADDRCONF(NETDEV_UP): enp1s0: link is not ready [ 20.775436] IPv6: ADDRCONF(NETDEV_UP): enp7s0: link is not ready [ 20.777163] IPv6: ADDRCONF(NETDEV_CHANGE): enp1s0: link becomes ready [ 20.778269] IPv6: ADDRCONF(NETDEV_CHANGE): enp7s0: link becomes ready [ 399.961486] virtio_net virtio4 enp7s0: failover primary slave:enp1s0 unregistered Actual results: In step 4, the hostdev interface did not exists after migration with post-copy Expected results: The hostdev interface should exists on the vm after migration Additional info:
This bug is duplicate with Bug 1817965 - Live post-copy migration of the vm with failover VF device fails
*** This bug has been marked as a duplicate of bug 1817965 ***