netlink-based ifconfig() routine replacement

Peter V. Saveliev peet at altlinux.org
Sat Jul 23 13:49:14 UTC 2011


On 23.07.2011 14:25, Federico Simoncelli wrote:
<skip />
> How is this going to affect vdsm?
> If required, wouldn't make sense to add this functionality to python-ethtool
> instead of re-implementing also what is already working?
> 
> Looks like the aliases are already detected somewhere:
> 
>>>> ethtool.get_active_devices()
> ['lo', 'eth0', 'eth0:0']
> 
> Maybe it's not that hard to add what's missing.
> 

The initial question from Dan was «can the python netlink library work
faster than /sbin/ifconfig output parsing», and, strictly speaking, it
can :)

But if ethtool can do the same work and it works significantly faster,
than, surely, it is better to use it.

…

The only pitfall of ethtool is the same as for ifconfig. It work via
deprecated mechanism and can not retrieve all IP data of modern kernels
(unlabeled seondary addresses, routing classes and so on). But if it
doesn't matter for VDSM, then it is better to use ethtool, yes.

-- 
Peter V. Saveliev


More information about the vdsm-patches mailing list