Thursday, March 12, 2015

Good old ifconfig utility gone in Linux 7

I knew that ifconfig was deprecated in favor of ip, but it was quite a shock: good old /sbin/ifconfig utility is no longer there AT ALL.... I guess all those old shell scripts relying on it will have to be thrown away...

just use "ip addr show"

This guide provides a good set of equivalent commands... and of course the IP map page

It seems however reasonable to install a compatibility version of ifconfig in case you really have scripts relying on it.

Read also this comparison article

Farewell, ifconfig.... we'll miss you....

For instance, to add an ip you do:

ip addr add dev eth0

ip route add default via

service network restart

simple, no?

Ah if you want to specify netmask, look no further, you need to provide the IP in CIDR format (here a priceless conversion table, for instance CIDR notation for netmask is /24)

Things get more and more complicated....ifconfig syntax was definitely simpler...

No comments: