[libvirt] question for <interface> in ethernet type and multiple queues in KVM (start VM failed)

Michal Privoznik mprivozn at redhat.com
Wed Mar 26 09:16:00 UTC 2014


On 26.03.2014 09:59, Wangrui (K) wrote:
> Hi,
>
>      I use ethernet vif for VM (libvirt 1.1.0  qemu 1.5.1). xml as such
>
>          <interface type='ethernet'>
>              <script path='' />
>              <target dev='tap_mq'/>
>              <mac address='52:54:00:19:9e:4e'/>
>              <model type='virtio' />
>              <driver name='vhost' queues='2'/>
>          </interface>
>
>      tap_mq is a tap device with multi_queue property which was created on host by ip command, such as follows
>      #ip tuntap add tap_mq mode tap multi_queue
>
>      I want to use multiple queue feature for this vif so I set queues='2' in xml.
>
>      When start VM , an error occurs
>      "error: unsupported configuration: Multiqueue network is not supported for: ethernet".
>      This error is reported from function qemuBuildInterfaceCommandLine
>
>      /* Currently nothing besides TAP devices supports multiqueue. */
>      if (net->driver.virtio.queues > 0 &&
>          !(actualType == VIR_DOMAIN_NET_TYPE_NETWORK ||
>            actualType == VIR_DOMAIN_NET_TYPE_BRIDGE)) {
>          virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
>                         _("Multiqueue network is not supported for: %s"),
>                         virDomainNetTypeToString(actualType));
>          return -1;
>      }
>
>      The comment specifies that only TAP device supports multiqueue. But VIR_DOMAIN_NET_TYPE_ETHERNET is also TAP device I think.

Even though the device is TAP device indeed, it's not from the libvirt 
POV. Libvirt doesn't examine the target dev to see if it is TAP, 
physical NIC, sit, ... whatever.

As always, patches are welcome :)

Michal




More information about the libvir-list mailing list