[libvirt] two hostdev devices problem

Laine Stump laine at laine.org
Thu May 23 22:31:10 UTC 2013


On 05/22/2013 06:32 PM, Dominik Mostowiec wrote:
>
> I tested on 1.0.5 patched version and vm with 2 vfs working fine.
>
> I have another problem
> When i set max_vfs=63:
> internal error missing IFLA_VF_INFO in netlink response
>
> Its working when max_vfs=31
>

What is the platform, kernel version, and what version of libnl are you
using (libnl 1 or libnl3?)

There have been multiple bugs recently filed and fixed in this area on
RHEL6/CentOS6. In particular, there was a problem with max_vfs > 50 that
had exactly this symptom. It was solved by a patch to libnl-1.1. If your
platform uses libnl-1.1, this could be the source of the problem. It is
fixed in the upstream libnl-1.1.4 maintenance release.

I unfortunately am not sure where the libnl-1.1 git is (I only have the
git tree for libnl3), so I can't give you the exact commit message, but
in short the problem was that libnl was using too small of a buffer for
the netlink socket, so when there were a lot of vfs, the netlink message
containing vf info was truncated.


> --
> Dominik
>
> 21 maj 2013 15:19, "Dominik Mostowiec" <dominikmostowiec at gmail.com
> <mailto:dominikmostowiec at gmail.com>> napisał(a):
>
>     Hmm,
>     It seems to be working (after only simple tests).
>
>     --
>     Dominik
>
>
>     2013/5/21 Ján Tomko <jtomko at redhat.com <mailto:jtomko at redhat.com>>
>
>         On 05/21/2013 01:37 PM, Laine Stump wrote:
>         > On 05/21/2013 04:03 AM, Ján Tomko wrote:
>         >> On 05/21/2013 09:32 AM, Dominik Mostowiec wrote:
>         >>> hi,
>         >>> I try to add 2 VF by "hostdev".
>         >>> Networks (vnet0, vnet1) with:
>         >>>  <forward mode='hostdev' managed='yes'>
>         >>>     <pf dev='eth1'/>
>         >>> .....
>         >>>
>         >>> Domain:
>         >>> <interface type="network">
>         >>>              <source network="vnet0"/>
>         >>> ....
>         >>> <interface type="network">
>         >>>              <source network="vnet1"/>
>         >>> ....
>         >>>
>         >>> virsh create error:
>         >>> "error: internal error process exited while connecting to
>         monitor: kvm:
>         >>> -device
>         pci-assign,configfd=25,host=01:10.1,id=hostdev0,bus=pci.0,addr=0x4:
>         >>> Duplicate ID 'hostdev0' for device"
>         >>>
>         >> Hi,
>         >>
>         >> it seems we have been assigning the same id to all network
>         hostdevs until this
>         >> recent commit (not yet released):
>         >>
>         >> http://libvirt.org/git/?p=libvirt.git;a=commitdiff;h=6597cc25
>         >
>         >
>         > If that patch has such an effect, it's purely accidental.
>         Have you
>         > tested this? (I plan to test a before and after as soon as
>         I've had
>         > breakfast)
>         >
>
>         I haven't tested it and looking at the code again, I might've
>         been wrong :(
>
>         Sorry about that.
>
>         Jan
>
>
>
>
>
>
>     -- 
>     Pozdrawiam
>     Dominik
>




More information about the libvir-list mailing list