Before starting the cPanel installation, make sure you meet the following prerequisites:
First, update your system and ensure the necessary packages are installed:
sudo dnf update -y
Before installing cPanel, set a proper hostname. For example:
hostnamectl set-hostname server.example.com
Ensure that some required packages are installed:
sudo dnf install perl wget screen -y
It is a good idea to start a screen session before starting the installation, so the process continues even if the connection is interrupted:
screen
Now download and run the cPanel installation script:
cd /home
curl -o latest -L https://securedownloads.cpanel.net/latest
sh latest
This will start the installation of cPanel and WHM on your server. The installation process may take some time.
Once the installation is complete, you can access WHM. Open your web browser and navigate to your server's IP address on port 2087:
https://your_server_ip:2087
Here, you can log in with your root username and password.
When you log in to WHM for the first time, you will be greeted by the setup wizard. Here, you will need to enter your license key and complete other basic settings.
Firewall Settings: For cPanel to work correctly, certain ports need to be open. If you are using Firewalld, open the necessary ports:
sudo firewall-cmd --permanent --add-service=http
sudo firewall-cmd --permanent --add-service=https
sudo firewall-cmd --permanent --add-port=2083/tcp
sudo firewall-cmd --permanent --add-port=2087/tcp
sudo firewall-cmd --reload
Selinux Settings: Selinux should be disabled. Edit the /etc/selinux/config
file and set SELINUX=disabled
. Then reboot the system:
sudo setenforce 0
sudo reboot
Once the installation of cPanel and WHM is complete, you can create user accounts, manage domains, and configure your server in detail via WHM.
You have now successfully completed the installation of cPanel on AlmaLinux! With this guide, you should be able to install cPanel without any issues. If you encounter any errors or need additional help, you can refer to the official cPanel documentation.
You can click for our VDS packages where you can install Almalinux.
You have examined the knowledge base in detail, but if you cannot find the information you need,
Create a Support Ticket