Skip to main content
The link increases usability by saving time to google it.
Source Link

In Linux, use the ip commands. In other OSes, use ifconfig and family.

If you use the iproute2iproute2 way (ip) as such:

ip addr add 1.1.1.1/24 dev eth0 label eth0:0

you should have the same effect as your first ifconfig command, and should even be displayed the same way by ifconfig. As mentioned, in Linux, you should prefer the ip family of commands over ifconfig, route, etc. Though ifconfig and others will remain a stable in network admin's diets for a while to come because of their wide usage and support in non-Linux OSes as well.

In Linux, use the ip commands. In other OSes, use ifconfig and family.

If you use the iproute2 way (ip) as such:

ip addr add 1.1.1.1/24 dev eth0 label eth0:0

you should have the same effect as your first ifconfig command, and should even be displayed the same way by ifconfig. As mentioned, in Linux, you should prefer the ip family of commands over ifconfig, route, etc. Though ifconfig and others will remain a stable in network admin's diets for a while to come because of their wide usage and support in non-Linux OSes as well.

In Linux, use the ip commands. In other OSes, use ifconfig and family.

If you use the iproute2 way (ip) as such:

ip addr add 1.1.1.1/24 dev eth0 label eth0:0

you should have the same effect as your first ifconfig command, and should even be displayed the same way by ifconfig. As mentioned, in Linux, you should prefer the ip family of commands over ifconfig, route, etc. Though ifconfig and others will remain a stable in network admin's diets for a while to come because of their wide usage and support in non-Linux OSes as well.

Source Link
Dave
  • 353
  • 3
  • 9

In Linux, use the ip commands. In other OSes, use ifconfig and family.

If you use the iproute2 way (ip) as such:

ip addr add 1.1.1.1/24 dev eth0 label eth0:0

you should have the same effect as your first ifconfig command, and should even be displayed the same way by ifconfig. As mentioned, in Linux, you should prefer the ip family of commands over ifconfig, route, etc. Though ifconfig and others will remain a stable in network admin's diets for a while to come because of their wide usage and support in non-Linux OSes as well.