Gao Yongwei
2012-Jul-23 09:24 UTC
[libvirt-users] INTERNAL ERROR:can not attach network interface for vm
hello,i got a error message when use virsh attach-interface for a vm: first, list the vm's interface,there's no interface now. virsh # domiflist ubuntum-124 Interface Type Source Model MAC ------------------------------------------------------- then,i did an attach-interface action: virsh # attach-interface ubuntum-124 bridge br0 --persistent Interface attached successfully virsh # domiflist ubuntum-124 Interface Type Source Model MAC ------------------------------------------------------- vnet0 bridge br0 - 52:54:00:3d:d1:ea second,detach the interface: virsh # detach-interface ubuntum-124 bridge Interface detached successfully virsh # domiflist ubuntum-124 Interface Type Source Model MAC ------------------------------------------------------- 3rd,attach interface again,at this step ,i got erros like below: virsh # attach-interface ubuntum-124 bridge br0 --persistent error: Failed to attach interface error: internal error unable to execute QEMU command 'device_add': Duplicate ID 'net0' for device virsh # attach-interface ubuntum-124 bridge br0 error: Failed to attach interface error: internal error unable to execute QEMU command 'device_add': Duplicate ID 'net0' for device virsh # version Compiled against library: libvir 0.9.10 Using library: libvir 0.9.10 Using API: QEMU 0.9.10 Running hypervisor: QEMU 0.12.1 any one can help?thanks.
Osier Yang
2012-Jul-23 13:10 UTC
[libvirt-users] INTERNAL ERROR:can not attach network interface for vm
On 2012?07?23? 17:24, Gao Yongwei wrote:> hello,i got a error message when use virsh attach-interface for a vm: > > first, list the vm's interface,there's no interface now. > virsh # domiflist ubuntum-124 > Interface Type Source Model MAC > ------------------------------------------------------- > > then,i did an attach-interface action: > virsh # attach-interface ubuntum-124 bridge br0 --persistent > Interface attached successfully > > virsh # domiflist ubuntum-124 > Interface Type Source Model MAC > ------------------------------------------------------- > vnet0 bridge br0 - 52:54:00:3d:d1:ea > > second,detach the interface: > virsh # detach-interface ubuntum-124 bridge > Interface detached successfully > > virsh # domiflist ubuntum-124 > Interface Type Source Model MAC > ------------------------------------------------------- > > 3rd,attach interface again,at this step ,i got erros like below: > virsh # attach-interface ubuntum-124 bridge br0 --persistent > error: Failed to attach interface > error: internal error unable to execute QEMU command 'device_add': > Duplicate ID 'net0' for device > > virsh # attach-interface ubuntum-124 bridge br0 > error: Failed to attach interface > error: internal error unable to execute QEMU command 'device_add': > Duplicate ID 'net0' for device > > virsh # version > Compiled against library: libvir 0.9.10 > Using library: libvir 0.9.10 > Using API: QEMU 0.9.10 > Running hypervisor: QEMU 0.12.1 >It's known bug of qemu, there is some race there, though I can't tell what it is exactly. I guess if you sleep several secs before attaching it again, you will succeed. Or you might want to ask in qemu list. Regards, Osier
Maybe Matching Threads
- Re: nwfilter and address of network ip address
- [PATCH v4 1/4] virtio: split device_register into device_initialize and device_add
- [PATCH v4 1/4] virtio: split device_register into device_initialize and device_add
- Managing eths in vm from HV
- [PATCH] virtio: Don't access index after unregister.