cPanel is a the most popular application that enables users to administer servers using a GUI interface instead of traditional command line. cPanel is straight forward to install, but sometimes can take a couple of hours to complete.
Once you install cPanel on your CentOS server, it cannot be removed unless you complete a server restore. cPanel offers no uninstaller.
Prior to installing cPanel on your Virtual Server or Cloud Server, we must take 2 preliminary steps.
First of all, we need to make sure that Perl is installed on the server.
sudo yum install perl -y
Once Perl is installed, there is one more step. We must ensure that cPanel has a FQDN (Fully Qualified Domain Name), also known as a hostname. If you miss this step, it’s likely you will bump into hostname issues which will prevent the cPanel installer from running.
It’s a very easy solution, if you have a FQDN you can type it in with the command –
The cPanel installation is pretty straight forward however it can be time consuming depending on the resources of your service. We generally use “screen” when setting up client’s servers with cPanel as it is very helpful for exiting an SSH session and returning at a later point to check progress.
Before we start with cPanel, let’s install screen and wget
sudo yum install screen wget - y
Once screen is installed, you can start a new session by running –
Use this command to install cPanel with WHM –
wget -N http://httpupdate.cPanel.net/latest
With the latest package downloaded from cPanel, we can go ahead and start the script –
Next, close out of screen.
Ctrl +A +D
To return to screen, you can use the following command –
It may take up to 2 hours for the installation to complete. Check back in an hour or so to see the progress of the cPanel installation.
Once the cPanel installation has finished, you can login by going to your IP address and using the username and password credentials –
And, you’re done! Now you can create your first cPanel user and login directly to cPanel by going to one of the following – http://0.0.0.0/cpanel or http://mydomain.com/cpanel