How to Configure Additional IP Addresses on AlmaLinux Rocky Linux CentOS

Additional IP addresses refer to extra network addresses assigned to a device or network interface beyond its primary or default IP address. IP addresses are unique numerical labels assigned to each device connected to a computer network that uses the Internet Protocol for communication.

Identify the Network Interface

Determine the name of your network interface. You can use the ip a or ifconfig command to list available interfaces.

Common names for interface include ens3, eth0, enp3s0 and many more,

ip a


root@vps ~]# ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host 
       valid_lft forever preferred_lft forever
2: ens3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
    link/ether brd ff:ff:ff:ff:ff:ff
    altname enp0s3
    inet brd scope global noprefixroute ens3
       valid_lft forever preferred_lft forever
    inet6 2604:0456:0145::1/64 scope link noprefixroute 
       valid_lft forever preferred_lft forever
[root@vps ~]# 

from the above output, the network interface is ens3.

also, you can find the IP address information from CrownPanel, Refer to our wiki on How to View Network Information in CrownPanel.

Modify the Connection

Run the following command to modify the connection and add additional IP addresses,

nmcli connection modify "ens3" +ipv4.addresses "" +ipv4.gateway "" +ipv4.dns ","

The same command for another range of additional IP Addresses,

nmcli connection modify "ens3" +ipv4.addresses "" +ipv4.gateway "" +ipv4.dns ","

Note: Replace "interface" ens3 with the actual interface name that is on your server.
Replace "address" with the actual IP address that is assigned to your server.
Replace "gateway" with the actual Gateway address assigned to the server.

Restart Network Service

Once the modification for network interface has been updated with the additional IPs information, we will go onto restart the NetworkManager for the changes to take effect.

systemctl restart NetworkManager

This concludes our topic of configuring Additional IP Addresses on the AlmaLinux, Rocky Linux, and CentOS Stream 9 using NetworkManager.