Changing WHM Server IP with NAT Enabled
I just had an issue with regards to the change of our WHM servers IP address, as this server is using NAT and the server is configured for a private IP as opposed to a public it was throwing up errors when attempting to access basic server configuration etc.
I did a lot of research to try and fix the issue however could not find a straight forward answer so am posting this to help someone else out should they have an issue.
The Steps
I initially followed this guide: which advised of a file called "/var/cpanel/cpnat" which I needed to edit, I did this and restarted the server but to no avail.
Further down the page is mention of a NAT Build script, I thought it was a long shot but gave it a go regardless and ran the command "/scripts/build_cpnat" (Nothing is ever this simple!)
To my surprise this got it working straight away, a quick change of the configuration within the Basic cPanel & WHM Setup for the section "The IP address (only one address) that will be used for setting up shared IP virtual hosts." to the new IP and it is done!
Conclusion
It does seam on this occasion things can sometimes be simple if you find the correct article, it would be good to see if anyone else had this experience and if I did one too many steps in order to fix this or if I am missing some which will cause issues at a later date.
It was however a good challenge and one I now know what to do for next time, I hope this helps save someone else the panic I had...
-
Hello, I am happy to see the issue is now resolved. However, do keep in mind that per our documentation, we strongly recommend that you only perform these actions on a fresh installation of cPanel & WHM. Do not attempt a 1:1 NAT configuration on an existing production server. Thank you. 0
Please sign in to leave a comment.
Comments
1 comment