How to add a dedicated IP address to a Dedicated server

We will explain how to add a new IP address to your Dedicated server using cPanel/WHM or SSH console. Website, apps, email server or any web project can have dedicated IP addresses and this has proven to be a good practice and a professional approach to the development of any project on the Internet.

There are several reasons why this may be necessary for you, but at a first place, a separate IP address is most often used to maintain email reputation, SSL certification, better SEO, to develop specific applications that require a separate IP address, and also to build better security on separate parts of the server.

Adding an IP address through the cPanel/WHM panel

You need to login to your WHM panel using the data that we sent to you earlier. Find IP Functions and click on Add a New IP Address:

Add new IP address to server

Add a new IP address by entering it in the field New IP or IP range to add. Here you can add more IP addresses at once using IP range formats as in the following example:

Class C CIDR 192.168.0.128/25
IP Range 192.168.0.128-255
IP/Netmask 192.168.0.128/255.255.255.128

add new IP address to server whm/cpanel

Into a field, IPs and IP ranges to exclude from the range of new IPs you can add new IP addresses or IP range which you want to exclude from adding.

Finally, to add a new IP address, after entering the information, click the button Submit.

Adding an IP address via the SSH console

To add new addresses, connect to your server using SSH access using the information you received earlier.

You need to type the following in the console:

cd /etc/sysconfig/network-scripts

Backup the existing configuration file:

cp ifcfg-eth0 ifcfg-eth0.bak

Copy the configuration file for the new IP address:

cp ifcfg-eth0 ifcfg-eth0:1

Change the new configuration file by opening it in the Nano Editor:

nano ifcfg-eth0:1

Edit the following line:

DEVICE=eth0

Edit to:

DEVICE="eth0:1"

Then change the following:

IPADDR="xxx.xxx.xxx.xxx"

Instead of xxx.xxx.xxx.xxx here will be your existing IP address. This is because you copied the existing file. It is OK. Instead of this address, enter the new one you were planning to add.

After entering the address, press CTRL + X on the keyboard, and then Y (yes) to save the file with the settings that you have entered. In this way, you made the addition of a new IP address. Now you can run the following command to start:

/sbin/ifup eth0:1

By typing the next line, you can check if everything works:

/sbin/ifconfig

If you are able and if you already have a WHM panel, we recommend using the first method we have described for better efficiency and time savings. Of course, if you want to learn more and see what’s happening below the surface of the graphical interface, you can freely use the SSH console.

How to get a new IP address

You can order the new IP address by sending us an email from here. When you order an IP address, we prepare it for you. After we deliver it to you,  you can manage that address and add it to your server. If you have a problem, let us know. We can add a new IP address for you.

Tags: , , , ,

No comments yet.

Submit Comment