On Tue, Aug 27, 2013 at 07:46:27PM +0530, Nehal J Wani wrote:
> > So, qemu-ga doesn't understand that there can't be
more than one
> > device with same MAC addr. So, I think we are left with the following
> > options:
>
> Actually that's wrong. You *can* have 2 completely different physical
> NICs with the same MAC address.
>
> > (i) Modify qemu-guest-agent to return addresses belonging to same
> > MAC address grouped under one interface only.
>
> You would not want to group based on MAC address - you explicitly just
> want to normalize by stripping the legacy aliases suffixes.
Actually, the order in which the qemu-agent returns the value isn't always:
ethX
ethX:0
ethX:1
ethY
ethY:0
ethY:2
It can be:
ethX
ethY:2
ethX:0
ethY:0
ethX:1
ethY
which, after stripping, will just be left with:
ethX
ethY
ethX
ethY
ethX
ethY
whereas, we would want:
ethX
ethX
ethX
ethY
ethY
ethY
Hence, grouping either by the stripped down interface name or
by the MAC address will be required. So that all IP addresses
related to a single NIC are not distributed in the output.
No, we in fact just want
ethX
ethY
each of which will have multiple addresses. We should never repeat
the same interface name in the API output.
Daniel
--
|:
http://berrange.com -o-
http://www.flickr.com/photos/dberrange/ :|
|:
http://libvirt.org -o-
http://virt-manager.org :|
|:
http://autobuild.org -o-
http://search.cpan.org/~danberr/ :|
|:
http://entangle-photo.org -o-
http://live.gnome.org/gtk-vnc :|