Multipe IP address on Single Ethernet Interface

=========Networking Basics → Switching & Routing Lab=========
In the Lab, for Question (8),
→ We were asked to change the IP address for on jumphost to new IP on eth0. After this change, the Jump Host is able to connect to app01 to app04 (all 4). But when we see ifconfig command, the eth0 only shows “” and not the newly added IP address. My queries are as below,
Q1. Can we have multiple IPs for a single interface (eth0)?
Q2. If yes, why we are not able to see that in ifconfig output? Also, I am unable to locate the eth0 config in /etc/sysconfig/network-scripts.
Kindly help me to understand

1 Like

For Q1: Yes, you can have multiple IP addresses on the same interface.
If the route exist you can use BindAddress option in ssh to use each of the ip address to communicate with other hosts. For example:
ssh -o BindAddress= app01
ssh -o BindAddress= app01

Instead of ifconfig, what does ‘ip’ command show on your jumphost:
ip a s

For Q2: Check if the system using NetworkManager by running: systemctl status NetworkManager
If NetworkManager is not being used, you should not see config for eth0 in /etc/sysconfig/network-scripts/

hi Leh,

Thanks a lot for the explanation. My doubt is cleared now. I could find the 2 IP address on eth0 using #ip addr show command which you suggested. But I still cant see the ifcfg-eth0 config file.

[email protected]_host ~$ sudo systemctl status networkmanager
Failed to get D-Bus connection: Operation not permitted
[email protected]_host ~$ cd /etc/sysconfig/network-scripts/
[email protected]_host /etc/sysconfig/network-scripts$ ls
ifcfg-lo ifdown-eth ifdown-isdn ifdown-routes ifup ifup-eth ifup-isdn ifup-post ifup-sit init.ipv6-global
ifdown ifdown-ippp ifdown-post ifdown-sit ifup-aliases ifup-ippp ifup-plip ifup-ppp ifup-tunnel network-functions
ifdown-bnep ifdown-ipv6 ifdown-ppp ifdown-tunnel ifup-bnep ifup-ipv6 ifup-plusb ifup-routes ifup-wireless network-functions-ipv6