[libvirt] Ask for help about libvirt error: can't get physical interface data for kvm.

Laine Stump laine at laine.org
Wed Jun 30 16:19:25 UTC 2010


  On 06/30/2010 05:18 AM, Feng Dan Liu wrote:
>
> I saw both libvirt api and virsh commands support to get the physical 
> interfaces data, but it always fail when I using them for KVM 
> hypervisor. I was thought that it was due to the old version of 
> libvirt/KVM hypervisor, but the error still exist when using the 
> latest libvirt and kvm hypervisor.
>
> So I wonder if the following functions of libvirt haven't been 
> implemented for KVM, could you pls help me get the answer about this? 
> Thanks in advance!
>
> _virConnectListInterfaces_ 
> <http://www.libvirt.org/html/libvirt-libvirt.html#virConnectListInterfaces> 
>
> _virConnectNumOfDefinedInterfaces_ 
> <http://www.libvirt.org/html/libvirt-libvirt.html#virConnectNumOfDefinedInterfaces> 
>
> _virConnectNumOfInterfaces_ 
> <http://www.libvirt.org/html/libvirt-libvirt.html#virConnectNumOfInterfaces> 
>
> _virConnectListDefinedInterfaces_ 
> <http://www.libvirt.org/html/libvirt-libvirt.html#virConnectListDefinedInterfaces> 
>
> _virInterfaceLookupByName_ 
> <http://www.libvirt.org/html/libvirt-libvirt.html#virInterfaceLookupByName> 
>
>
>

Just to make sure you understand what these functions do - they are used 
to examine and configure the interfaces on the *physical host* that is 
running the hypervisor, not the virtual hosts (guests) running under 
that hypervisor. (One of the main motivations to add this API was to 
make it easier for management software to create bridge devices on the 
host, for use by the guests).

These functions only work on a system that has the netcf library 
installed (regardless of hypervisor). Currently, only Fedora (12 and 
beyond), and Red Hat Enterprise Linux 6 (in beta) have a port of that 
library, although there has been some talk of a Suse port (and also 
someone was supposedly working on a Gentoo port last year, but I never 
saw anything more about that).

netcf information can be found at https://fedorahosted.org/netcf, and 
there is a mailing list at 
https://fedorahosted.org/mailman/listinfo/netcf-devel.

Patches to port netcf to other platforms are gratefully accepted. If you 
are running on a platform that doesn't have netcf support and would like 
to take on that task, please send mail to the list and we'll do what we 
can to help.

(P.S. When you send mail to the libvirt list, you should probably try to 
avoid embedded graphics, as you have used to show your error message - 
many people reading the list are using text-only mail readers, and won't 
be able to see the graphical content.)

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20100630/04d1dce8/attachment-0001.htm>


More information about the libvir-list mailing list