How do I add additional IP addresses? [CentOS, Ubuntu, Debian]


To add additional IP addresses to your CentOS server you'll need to copy the ifcfg-eth0 or ifcfg-em1 file and rename it to ifcfg-eth0:0 or ifcfg-em1:0. In this tutorial we will use the em1 adapter:
cd /etc/sysconfig/network-scripts
cp ifcfg-em1 ifcfg-em1:0

Once we copied the ifcfg-em1 file and renamed it to ifcfg-em1:0 we can edit the file:
nano ifcfg-em1:0

Edit your file to match this (edit the ADDITIONAL.IP, the gateway and netmask to the details you'll find in the clientarea on the My Services page -> Server or contact support):


Once you edited the file and saved it, you can start the adapter:
ifup em1:0

It can be the connection to your server is discontinued for 5-10 minutes.

If you want to add more IP's, repeat the process above. Rename the the filename to ifcfg-em1:X and set the device name to em1:X.

Debian and Ubuntu

To add an additional IP to debian or ubuntu like systems edit the file interfaces in /etc/network:
nano /etc/network/interfaces

You'll see a file that looks like this:
auto eth0
iface eth0 inet static

Edit the file to look like this:

auto eth0
iface eth0 inet static

auto eth0:0
iface eth0:0 inet static

Save the file and bring up the device with this command:
ifup eth0:0

Ha estat útil la resposta?

Llegir també

What is the connection speed of my dedicated server?

The most dedicated servers at SKB Enterprise come with 1x a 1Gbit network card and have a network...

What will happen when I reach my bandwidth maximum?

Each dedicated server comes with a bandwidth limit. If you exceeds your maximum monthly...

How can I order additional IP addresses?

You can purchase additional IPs for €2,50 a piece, per month. Create a helpticket at the client...

How long does it takes before my server is delivered?

We guarantee that all our standard server configurations will be set up within 1-2 business...

What is RAID?

RAID, or Redundant Array of Independent Disks, is a method for storing data on multiple hard...

Powered by WHMCompleteSolution