Re: iproute2 and ethX:X subdevices

Linux Advanced Routing and Traffic Control

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

 



Alan,

 : Quick question -- is it possible to create eth0:0 - style
 : psuedo-devices using the 'ip' tool?

They aren't really "pseudo-devices", but we understand what you mean.  In
the days prior to the iproute2 tools, when a device would have one
interface, which would have one IP address, they were called IP aliases.

 : I see they recognise them when using 'ip addr show':
 :
 : 5: eth2: <BROADCAST,MULTICAST,ALLMULTI,UP> mtu 1500 qdisc pfifo_fast qlen 1000
 :     inet 192.168.0.1/24 brd 192.168.0.255 scope global eth2:0
 :
 : But I can't see a way of creating them. Is it possible?

The answer is yes, there is a way to create interfaces using the "ip
address" tool, so that they are recognizable to ifconfig.  You are looking
for the "label" keyword to the "ip address add" command [0].

 : (I know somebody may say "why would I want to" -- it's just for
 : neatness, so that people using 'ifconfig' can still see all the
 : addresses in use.)

I know exactly why an administrator would wish to do this.  Some
administrators, who a) have not joined the 21st century with Linux, or b)
do not commonly use Linux, but rather other UNIX-like operating systems,
may not know about the "ip" utility, but they certainly know about
ifconfig!  So, if only for the humans, this can be helpful.

-Martin

 [0] http://linux-ip.net/html/tools-ip-address.html#ex-tools-ip-address-del

-- 
Martin A. Brown --- SecurePipe, Inc. --- mabrown@xxxxxxxxxxxxxx

_______________________________________________
LARTC mailing list / LARTC@xxxxxxxxxxxxxxx
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

[Index of Archives]     [LARTC Home Page]     [Netfilter]     [Netfilter Development]     [Network Development]     [Bugtraq]     [GCC Help]     [Yosemite News]     [Linux Kernel]     [Fedora Users]
  Powered by Linux