ifconfig
. It would show you all interfaces and their IP aliases on the server. In CentOS/RHEL 7, that’s not the case. To see all IP addresses, use the ip
tool.ip
over ifconfig
./etc/sysconfig/network-scripts/
, but you’ll find that doesn’t work in RHEL / CentOS 7 as you’d expect if the Network Manager is being used. Here’s what a config would look like in CentOS 6:nmtui
tool (Text User Interface for controlling NetworkManager).nmtui
is open, go to the Edit a network connection and select the interface you want to add an alias on./etc/sysconfig/network-scripts/
, you can see how nmtui
has added the alias.nmtui
to be much easier.ip
command. It only lasts until you reboot your server or restart the network service, after that – the IP is gone from the interface.