cPanel is a popular web hosting control panel that simplifies server management tasks, making it easier for users to host websites, manage email accounts, and perform various administrative tasks. In this guide, we will walk you through the step-by-step process of installing cPanel on a CentOS 8 server.
Before you begin, ensure that you have:
- A VPS or dedicated server running CentOS 8.
- Root or sudo access to your server.
- A valid cPanel license or trial license.
Step 1: Update CentOS:
Before installing cPanel, it’s essential to update your CentOS system to ensure you have the latest packages and security patches. Open a terminal and run the following commands:
sudo yum update sudo reboot
Step 2: Set a Hostname:
Set a fully qualified domain name (FQDN) as your server’s hostname. Replace “example.com” with your desired domain:
sudo hostnamectl set-hostname example.com
/etc/hosts file and add an entry for your server’s IP address and hostname:
sudo nano /etc/hosts
Add the following line, replacing “your_server_ip” and “example.com” with your server’s actual IP and hostname:
Save the file and exit.
Step 3: Disable Network Manager:
cPanel requires that Network Manager be disabled on your server. To do this, execute:
sudo systemctl stop NetworkManager sudo systemctl disable NetworkManager
Step 4: Install Perl:
Ensure Perl is installed on your system. If it’s not, you can install it with:
sudo yum install perl
Step 5: Download cPanel Installer:
Download the cPanel installation script from the official cPanel website:
curl -o latest -L https://securedownloads.cpanel.net/latest
Step 6: Install cPanel:
Run the cPanel installation script:
The installation process may take some time. Follow the on-screen prompts, and you’ll be required to enter your cPanel license information during the installation.
Step 7: Access cPanel:
Once the installation is complete, you can access cPanel by navigating to:
Replace “your_server_ip” with your server’s IP address.
Step 8: Initial Setup:
Follow the cPanel setup wizard to configure your server settings, create accounts, and set up your hosting environment.
Congratulations! You’ve successfully installed cPanel on your CentOS 8 server. You can now start managing your server, hosting websites, and configuring email accounts using the cPanel web interface.
Please note that cPanel requires a valid license, so ensure that your license is up-to-date to continue using its services without interruptions.