[libvirt] [PATCH 3/5] [FIX] macvtap support for libvirt -- qemu support

Ed Swierk eswierk at aristanetworks.com
Fri Feb 12 16:29:59 UTC 2010


On Thu, Feb 11, 2010 at 10:19 AM, Stefan Berger <stefanb at us.ibm.com> wrote:
> This part adds support for qemu making a macvtap tap device available
> via file descriptor passed to qemu command line. This also attempts to
> tear down the macvtap device when a VM terminates. This includes support
> for attachment and detachment to/from running VM.

In qemudShutdownVMDaemon(), calling delMacvtapByMACAddress() before
virKillProcess() doesn't work. delMacvtapByMACAddress() tries to be
polite and not delete the macvtap interface if it appears to be owned
by someone else, but in this case it's our own qemu still holding the
tap fd open:

  libvirtd: 16:10:04.836: error : openTap:567 : cannot open macvtap
tap device /dev/tap63: Device or resource busy

When the qemu process does finally stop, the macvtap interface is still around.

--Ed




More information about the libvir-list mailing list