Configurating cPanel Using Ubuntu 20.04 on CloudRaya – Part 2
In the previous article, we have successfully created Ubuntu VM by using cPanel. In this article, we are going to continue the configuration process on the cPanel.
There are several parts that we can do for the initial configuration:
Update MySQL Server
At the time this article was created, there was a known issue with the MySQL server that had been installed and could not run properly. Upon checking, the MySQL service cannot run, and when attempting to upgrade MySQL, an error will occur.
Therefore, based on the following article:
cPanel has launched an autofixer on existing cPanel instances. Please run the following command:
After that, import the key on the server before proceeding with the installation:
After the completion of that process, you can proceed with the installation of the mysql-server, where on Ubuntu, supported MySQL version is MySQL 8. Run the following command for the installation of mysql-server.
If there are options that appear, please type ‘y’.
Please wait until it’s complete, then update the MySQL server.
apt install mysql-community-server
If the MySQL server installation process has completed, the MySQL menu in cPanel will appear and be ready for use.
Update cPpanel Version to the Latest
In this step, we will update the cPanel version to the latest version. Please select the “Upgrade to Latest Version” menu.
Click the “Click to Upgrade” button to proceed with the upgrade process. This process will take some time; please wait for the upgrade process to complete and reboot the VM if it’s finished.
Activating ModSecurity in cPanel
ModSec, or ModSecurity, is one of the open-source Web Application Firewalls (WAF). ModSec functions to detect and protect websites from various attacks.
In cPanel, you can activate ModSec. Please select “Modsecurity Vendors.” On the initial view, you will see that ModSec is not yet active. Press the “Install” button to start the installation process using the vendor provided by cPanel.
Please click on “Install and Restart Apache”.
After the installation process is done, then it will show as follows:
Activating Apache Evasive Module
In Apache, there is a module useful for detecting HTTP DDOS attacks or brute force attacks, namely mod_evasive. In cPanel, you can activate this module through EasyApache 4.
Please select EasyApache 4 and press the “Customize” button for the currently used package:
In the “Apache Modules” you can search for mod-evasive and select it so that the module can be installed on Apache.
On the last screen, a review of which modules will be installed on Apache will appear. Please click “Provision” to initiate the installation process.
Click Done after you finish.
Here is the initial configuration that you can perform when installing CPanel on your server for the first time. If you need consultation or encounter difficulties during the configuration, you can contact our support. Our support team will be happy to assist you.