0

Good morning
my server is a dedicated from SoYouStart. I purchased 8 failover IP.

OS is Centos 7.4 + CloudLinux. The machine will run a cPanel box.

What I need is associate the cPanel and CloudLinux licenses to one of the failover IP's rather than the main server IP.
In order to check the license, both cPanel and CloudLinux check the result of

#hostname --ip-address  

or

curl -L http://cpanel.net/showip.cgi  

I mean that the IP resulting from above command is the IP used for the license.

My question is: how I can configure network in order that #hostname --ip-address returns one of the failover IP's?

I searched on cPanel and CL docs/forums but not found a solution.

Thank you very much.

  • cPanel has to be licensed on the primary IP of the server. It's possible to change the licenced address to one of your secondary addresses but that has to become the primary interface address. – Simon Greenwood Dec 27 '17 at 09:38
  • Yes. This is what I'm trying to do. And CloudLunux too need check license against main server IP – Carlo Queirolo Dec 27 '17 at 09:56
  • Added an answer, but I would honestly say it's more trouble than it's worth unless you are having external issues with your IP address. You can change your mail gateway, for example, without changing your cPanel address. – Simon Greenwood Dec 27 '17 at 11:11

1 Answers1

1

There may be OVH-specific requirements to change the primary IP address on your server, so check your customer dashboard: for one you should switch to a stock kernel from the OVH netboot kernel if you haven't all ready. You also need to change your cPanel license to the new address at your reseller, which is usually buycpanel.net.

Changing IP addresses should be a case of editing /etc/sysconfig/network-scripts/ifcfg-eth0 with your required address as IPADDR, netmask and the gateway from your address range allocation. Restart the network using systemctl restart networking or just reboot.

Set your hostname using hostname and then edit /etc/hosts to link the new primary IP to the hostname.

Change the cPanel IP address with /usr/local/cpanel/cpkeyclt and confirm that this is validating with curl -L http://cpanel.net/showip.cgi.

Simon Greenwood
  • 1,343
  • 9
  • 12
  • Thank you for your suggestions. I will try what you suggest, despite I already tried lot of things you wrote. Furthermore, the issue is not only with cPanel but with CloudLinux too. I contacted CloudLinux guys directly before posting here, and they replied that the only valid licensed IP is the result of **#hostname --ip-address** – Carlo Queirolo Dec 27 '17 at 12:02
  • If you licensed Cloudlinux with cPanel then it should work correctly. If you licensed Cloudlinux separately there is some more that you have to do but I'm not familiar with that. When you have done as I've described the output of `hostname --ip-address` should be the new IP address. – Simon Greenwood Dec 27 '17 at 12:31
  • Simon Greenwood, thank you very much. I will try and will report here. – Carlo Queirolo Dec 27 '17 at 12:49
  • Simon Greenwood, thank you. It worked. Thank you again. – Carlo Queirolo Dec 28 '17 at 06:08