Installing cPanel & WHM
For:
- cPanel & WHM 11.28
- cPanel DNSONLY
Note: Once you have installed cPanel & WHM on a server, you must reformat the server to remove it. At this time, we do not provide an uninstaller.
Choosing a Server
Important: cPanel and WHM
cannot be installed on a production web server; you must use a server with a freshly installed operating system.
It is important to consider how many sites you plan to host with your web server. For example, if your server is going to host a lot of websites, each with its own set of email addresses and databases, your server’s requirements for processing power, disk space, and RAM will increase.
It is also important to consider what kind of web hosting you plan to do when choosing a server. While cPanel and WHM will run on the minimum requirements specified below, your server’s requirements may increase if you plan to host videos, music, or other high-volume websites such as blogs or forums.
Minimum Requirements
- Pentium or AMD chipset at 266 MHz.
- Both i386 (32-bit) and x86-64 (64-bit) architectures will work with cPanel.
- 512 MB of RAM (1 GB minimum is recommended when hosting many accounts).
- 10 GB free hard drive space (More is required to host multiple accounts).
- A fresh installation of an operating system specified below.
Important: Because cPanel is designed for commercial hosting, we only license
publicly visible, static IP addresses. We do not license dynamic, sticky, or internal IPs.
Choosing an Operating System
We recommend you use one of the following versions of the Red Hat® Enterprise Linux® or CentOS operating systems:
- Red Hat Enterprise Linux version 4.x or 5.x
- CentOS version 4.x or 5.x
| CentOS |
Red Hat Enterprise Linux |
| Free |
Paid |
| Community-supplied updates |
Updates from Red Hat |
| Community-supplied support |
Support from Red Hat |
CentOS vs. Red Hat Operating Systems
To install cPanel & WHM on CentOS:
- Download a free CentOS DVD ISO.
- To use this ISO, you must burn the image to a DVD. Then, insert the DVD into the server and turn it on.
- Upon its first reboot, the ISO will install cPanel & WHM in the background.
- For more details, read our documentation on Installing cPanel & WHM below.
To install an operating system other than CentOS:
- You can download Red Hat Linux from http://redhat.com.
- You can download FreeBSD® from http://www.freebsd.org.
- You will need to use a web-accessible computer to download the operating system. Then, burn it to CD or DVD so that you can install it on your server.
Important: CentOS, Red Hat, and FreeBSD are the only operating systems supported by cPanel and WHM. No other OS is compatible.
A note about FreeBSD
While FreeBSD is supported, it is only recommended for system administrators who are familiar with it. FreeBSD can require a detailed manual configuration in order to run smoothly.
cPanel uses FreeBSD’s ports system for updates. When cPanel is installed, do not use binary packages (
pkg_add). Use of both systems can cause major administration problems when dependencies are removed from one system without the other system being made aware. The ports used by cPanel come directly from FreeBSD's ports repository.
Port upgrades may require you to manually interact with the system to ensure it is functioning as expected. There are some issues we cannot solve automatically in a FreeBSD system.
For this reason, we ask those without FreeBSD administration experience to use Red Hat or CentOS. This will provide a better overall experience with our software.
Installing Your Operating System (OS)
When the operating system discs are placed in your server, you will be prompted to test the discs prior to running the installation. We highly recommend that you test the disc(s) before installing, as it could save time later, if a disc proves to be unreadable.
Before installing your OS, here are some points to consider:
- You should install a minimal version of the operating system. All services that cPanel requires will be installed during the cPanel & WHM installation process. This means you need to deselect software package groups such as a Gnome, KDE, and any other GUI desktop environments. Installing services prior to the installation of cPanel & WHM will cause compatibility issues.
- The minimal installation does, however, need to include a working package handler such as yum or up2date (included in default installations of CentOS and Red Hat Enterprise Linux).
- If possible, configure your Ethernet device with a static IP address and a fully qualified hostname during the operating system’s installation. This will minimize the amount of work you will need to do after the installation of the OS and cPanel software.
- You will need to register your fully qualified hostname. This hostname cannot be the same as any domain used on your server.
- You will need to define the IP address, subnet address, and default gateway IP for your server. Your data center will be able to provide you with this information.
Install the OS, following the prompts and referring to the OS documentation when necessary.
Configuring Your Operating System
You will be asked to configure a number of features when installing your operating system.
You will need to:
- Correctly partition your hard drive.
- Deactivate the firewall.
- Disable SELinux.
- Ensure your newly-installed OS has the latest updates and patches.
Disable SELinux Security Features
For a fully successful installation you should disable SELinux. When installing a Red Hat or CentOS distribution, you will be able to use the graphical interface to disable SELinux when configuring the operating system.
This can also be accomplished by editing
/etc/selinux/config from the command line, and setting the
SELINUX parameter to disabled with a text editor such as
nano or
vi. The file should resemble the following text:
# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
# enforcing - SELinux security policy is enforced.
# permissive - SELinux prints warnings instead of enforcing.
# disabled - No SELinux policy is loaded.
SELINUX=disabled
# SELINUXTYPE= can take one of these two values:
# targeted - Only targeted network daemons are protected.
# strict - Full SELinux protection.
SELINUXTYPE=targeted
Important: SELinux must remain disabled in order for WHM and cPanel to run on your web server. Ensure that the pound sign (
#) does
not precede
SELINUX=disabled. If
# precedes this configuration option, the line will be ignored.
Warning: Do not transfer the SELinux configuration file between computers as it may destroy the file’s integrity.
Recommended Partitions
Please note that these partitions pertain to Linux. When installing Linux, use an
ext file system.
While each operating system provides a default partition setup, a simplified setup is recommended. The
/tmp partition is created for security reasons.
| Partition Name |
Size |
| /tmp |
1 GB (1024 MB) |
| / |
Grow to fill disk. |
| swap |
2x memory (RAM) |
Partitioning Guide
In some cases it may be optimal to increase the number of partitions (especially on servers that use high volumes of email), as the number of files that the operating system can access per partition is limited.
Note: Advanced partitioning information is available in the
Advanced Options documentation.
Preparing to Install cPanel & WHM or DNSONLY
Once you have successfully installed your operating system, you are ready to install WHM and cPanel. There are some basic steps to installing the cPanel software. You will need to:
- Access your server.
- This can be done remotely if you do not have physical access.
- Check your server's configuration.
- Run installation commands in a command-line interface.
Connecting to Your Server Remotely via SSH
To begin the cPanel & WHM installation process, a connection must be made from your computer to the server unless you have physical access to the server.
To begin in a *nix environment:
- Access the command line interface (using a terminal application).
- Type the following command:
ssh root@$IP (where $IP is meant to represent your target server’s IP address.)
- Enter your server’s root password.
If you are installing cPanel from a Windows® computer, you should use PuTTy to connect to your server. You can visit the
PuTTy site for more details.
To begin using PuTTy:
- Download and install the client from the URL above.
- Open the client.
- Under the Sessions menu, input the IP address of the server.
- Make sure that the SSH button is selected.
- Click Open.
- Use
root as the login name.
- Enter the root password.
If you typed username and password correctly, you should be logged into the server.
Remember: Once you are logged into the server you will need to use the POSIX standardized commands to manipulate files on that server, regardless of whether you are using PuTTy or a native SSH client.
Removing YUM groups
You will need to make sure certain
yum groups are not installed. To obtain a list of
yum groups, use the following command:
yum grouplist
Make sure the following
yum groups are not installed:
- FTP Server
- GNOME Desktop Environment
- KDE (K Desktop Environment)
- Mail Server
- Mono
- Web Server
- X Window System
To remove a
yum group, you can use the
yum groupremove command. For example, if you wanted to remove
Mono and
Mail Server:
yum groupremove "Mono" "Mail Server"
Note: You can specify more than one group per line. You will need to use quotation marks (
"") around each group you wish to remove.
Obtaining a cPanel License
If you do not have a license for cPanel & WHM, you will need to obtain one for your IP address. You should acquire your license before you attempt to install cPanel. You can obtain a license at
http://www.cpanel.net/store.
Note: We also offer 15-day test licenses for no cost at
http://www.cpanel.net/store.
Installing cPanel & WHM
To begin your installation, use the following commands:
- Open the
/home directory by typing the command cd /home
- Fetch the latest installation file from the cPanel servers by typing the command wget -N http://httpupdate.cpanel.net/latest
- Open and run the installation files by typing the command sh latest
If licensing has failed (due to a strict firewall or changed IP), execute the following command to activate your license:
- /usr/local/cpanel/cpkeyclt
Note: During the installation process, Apache 2.2 and PHP 5.2.17 are installed by default. You can customize your server's Apache and PHP configuration using our
EasyApache? feature after the installation is complete.
Installing cPanel DNSONLY
To begin your installation, use the following commands:
- Open the
/home directory by typing the command cd /home
- Fetch the latest installation file from the cPanel servers by typing the command wget -N http://httpupdate.cpanel.net/latest-dnsonly
- Open and run the installation files by typing the command sh latest-dnsonly
Configuring Your Network Connection
Red Hat and CentOS let you run the setup command to configure network connections. If you did not set up a static IP address for your server during the OS installation, you will need to define the IP address, subnet address, and default gateway IP for your server using the the setup tool. Your data center will be able to provide you with this information.
When configuring your network settings, do
not use NAT. Your server should have its own public IP address.
If you are using FreeBSD, you should consult that community’s documentation when configuring your server’s connection.
For information about obtaining IP addresses, visit:
Note: You should configure your Ethernet connection(s) when installing your operating system whenever possible.
Getting Started in WHM
To access the WHM interface:
- Type https://$IP:2087 in your preferred web browser.
- $IP is meant to stand for the IP address of your web server.
- Use root as the login name in the Name field.
- Enter the root password into the Password field.
- Click Log In.
- For more details, see our documentation on the WHM Initial Setup wizard.
- To set up cPanel accounts for your users, navigate to the WHM Create a New Account screen. cPanel allows your users to create email and FTP accounts, as well as perform other website management tasks.