[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Can we kill net-tools, please?



On Thu, Dec 29, 2016 at 09:01:51PM +0500, Andrey Rahmatullin wrote:

> > OK, you can remove the last half, but keep in mind there are plenty of
> > people who aren't using the exotic features provided by iproute2
> ... like two IPs on one iface.

Actually, that is only a problem if you re-use labels (including empty
ones). If you give distinct labels to all IPs, then ifconfig has no
trouble displaying/manipulating the addresses.

The issue is really at a lower level - ioctl() vs. netlink (*). Anything
which uses the SIOCGIF*/SIOCSIF* ioctl()s will have the same limitations
as ifconfig.  So if you _really_ care about having multiple IPs sharing
the same label, then replacing the ifconfig command with ip is just the
beginning - you'll need to find all applications and libraries which use
the ioctl() interface, and replace/re-write them to use netlink instead.
The problem is, using netlink is more complicated than using ioctl(), so
that may not be a simple task.

If you don't have any legacy applications which would use ioctl()s, then
you're lucky. Otherwise, assigning unique labels to IP addresses could
turn out to be simpler.

Gabor

(*) This is all about IPv4, IPv6 is different


Reply to: