-1

I have a unmanaged Dedicated CentOS Server running and I've been trying to get a new IP Address for it.

My hosting provider allowed me to buy a new IP Address but it's up to me to actually change it on the server.

1) Could I actually change the IP Address of the server permanently?

2) Would all I need to do is change the eth0 setting in /etc/sysconfig/network-script and /etc/hosts? Does anyone know a good resource on doing this, many online resources seem to give conflicting steps

3) Is there a chance that I might lock myself out of the server after I do a "server network retart"? If so, would rebooting solve the trick, then logging in from the new IP Address?

2 Answers2

1
  1. Yes you can do this

  2. If your current IP address is fixed on eth0 then you should change it in /etc/sysconfig/network-scripts/ifcfg-eth0. You may need to change /etc/hosts and you may also need to change any external DNS entries that pointed to the host referencing the old IP address.

  3. Yes, you could lock yourself out. Many hosting companies provide some sort of console access that doesn't use the IP address. You should look into the whether this is available and familiarise yourself with it's use.

Aside: I don't understand what your trying to achieve. If you already have an IP address why would you pay for a new one to change it - what are you going to do with the original one ?

user9517
  • 115,471
  • 20
  • 215
  • 297
  • I think that he might be confused, the provider maybe gave him an additional IP address which he has to add by setting the corresponding sub interface – Gabriel Talavera Jan 25 '14 at 13:23
0

1) yes.

2) just in the network-script/eth-whatever

3) there's a chance yes, this is why you want some form of secondary console interface such as iLO/DRAC or similar.

Oh and please read our help pages about what, and who, this site is for before posting again.

Chopper3
  • 101,299
  • 9
  • 108
  • 239