How to configure a Dedibox failover IP on CentOS
This page shows you how to configure a failover IP on Dedibox servers running on CentOS.
Before you start
To complete the actions presented below, you must have:
Failover IP configuration using the Network Manager
-
Connect to your server using SSH.
-
Use the Network Manager tool to configure the interface by running the command:
nmtui
-
From the Network Manager interface, select Edit a connection and select the interface you want to add an alias to. Then Click Edit....
-
Browse through the Add ... section to add another IP address.
-
Enter the details of your failover IP and save the settings to generate the configuration file.
-
Check the configuration file, to verify that the failover IP address has been added:
cat /etc/sysconfig/network-scripts/ifcfg-ens192 ... # Alias on the interface IPADDR1="62.120.123.123" PREFIX1="32"
Manual configuration of a failover IP
- Connect to your Dedibox using SSH.
- Copy the default network configuration of your primary interface to create an alias:
cp /etc/sysconfig/network-scripts/ifcfg-eth0 /etc/sysconfig/network-scrits/ifcfg-eth0:0
- Open the file
/etc/sysconfig/network-scrits/ifcfg-eth0:0
in a text editor, for example,nano
, and edit it as follows:NM_CONTROLLED="no" DEVICE="eth0:0" BOOTPROTO="static" IPADDR="my_failover_ip" NETMASK="255.255.255.255" ONBOOT="yes"
- Bring up the interface using the following command:
ifup eth0:0
See Also
Still need help?Create a support ticket