[tutorial] How to install cPanel on a dedicated server / VPS – CentOS

LUN

New member
About cPanel

cPanel is a handy software that enables users to manage servers by means of a GUI interface rather then command line. Although the set up for cPanel is quite easy, the script does take several hours to run.

Notes

Once cPanel is installed, it’s not removable from the server without a complete server restoration. It does not comes with an uninstaller.
Additionally, cPanel is subject to a licensing price which may come out to be around $200 a yr. You can find out extra about cPanel pricing by google or by visiting the cPanel website.

Setup

Before installing cPanel on your server, we have to take two additional steps.

We need to make conform that Perl is set up on the server

sudo yum install perl

After Installing perl we have to take care of one more preliminary step. cPanel requires a fully qualified domain name. We must provide it with a legitimate hostname. Skipping this step will get you a very common, error.

2015-11-01 16:00:54 461 (ERROR): Your hostname () is not set properly. Please
2015-11-01 16:00:54 462 (ERROR): change your hostname to a fully qualified domain name,
2015-11-01 16:00:54 463 (ERROR): and re-run this installer.


Luckily this error can be fixed by:

hostname your FQDN

Example:

hostname server.yourdomain.com

If you want to proceed with the cPanel installation without the hostname, you can do so by inputting a dummy hostname. Once cPanel is set up, you’ll be able to alter the hostname to the proper one later.

hostname host.example.com

Install cPanel

Even though the cPanel installation has very few steps, the installation does take a long time. Hence using “screen” is recommended, but it’s not mandatory. It’s useful in you’re SSH connection drops for some reason.

Go ahead and install screen and wget:

sudo yum install screen wget

As soon as screen is installed, create a new session by:

screen

After starting screen, you can proceed with the cPanel with WHM or DNS only version installation.

Command for cPanel with WHM:

wget -N http://httpupdate.cPanel.net/latest

Command for DNS only version:

wget -N http://httpupdate.cPanel.net/latest-dnsonly

With the requested package downloaded, we can start the installation:

sh latest

It may take anywhere between 2 to 6 hrs depending upon your hardware configuration and network. You can now close SSH if you want, but make sure you detach screen first.

Cntrl-a-d

To reattach to your screen you should use the command:

screen -r

Once cPanel is installs, you will get a message conforming that cPanel is installed and that you need to configure your firewalls.
Install cPanel
cPanel Successful Installation

cPanel-Successful-Installation.jpg



Go and run the script (as root):

/scripts/configure_firewall_for_cpanel

Now you can login to WHM by using your favorite browser and going to your ip followed by 2087 port number. eg x.x.x.x:2087.

LUN Host Web hosting and VPS Blog - Updates on news and events - LUN Host Web hosting and VPS Blog
LUN Host | Cheap Website Hosting | VPS | SEO Hosting
 
Back
Top