In this article, we will first see why we need to switch to cloudLinux OS and then the installation of CloudLinux OS in a centos cPanel server.
Why CloudLinux :
In a non CloudLinux shared hosting environment all the resources such as CPU, I/O and RAM are fully accessible to all accounts on that server and there is no hard limit set on the usage of these resources. Sometimes this leads to rogue scripts/programs on one client’s account to take up incommensurately large amount of resources, thus leading to the server getting overloaded and resulting in a degraded server performance for all the accounts in the server.To address this issue CloudLinux comes into action.CloudLinux creates a virtual environment for all the individual accounts on a shared server and allows us to limit the amount of resources any single account can use.This eradicates the single rogue account consuming all the resources available in the server.Your clients will immensely benefit from this.
Lets take a look on the features of CloudLinux :
LVE Manager :
LVE Manager allows you to maintain your server resources, including CPU, IO, memory, inodes, numbers of processes, and connections, that any single account can use. Now you can limit abusers while allowing legitimate customers to use what they need.
- Limit resources on account basis
- Create and apply default packages
- View usage history on account basis
- Identify abusers
- Identify top users
MySQL Governor :
MySQL Governor tracks CPU and disk IO usage for every website account in real time and throttles MySQL queries by using same-per-user LVE limits. By using the dbtop utility, we can monitor the usage as it happens on a per-customer basis, ensuring that system administrators always know what is going on.
- Automatic detection and killing of long-running resource consuming queries
- MySQL 5.1 – 5.6 support
- MariaDB 5.x and 10.x support.
CageFS :
CageFS is a virtualized file system and a set of tools to contain each user in its own ‘cage’. Each customer will have its own fully functional CageFS, with all the system files, tools, etc.
The benefits of CageFS are:
- Only safe binaries are available to user.
- User will not see any other users
- User will not be able to see server configuration files
- User’s will not be able to see other’ users processes.
PHP Selector :
The PHP Selector allows end users to select the PHP version of their liking. All popular versions of PHP are available for the users to select and with more than 120 PHP extensions to choose from.
Python Selector :
The Python Selector allows users to choose the Python version of their liking. Additional modules can be installed using this feature.Python Selector uses mod_passenger for best performance.
Ruby Selector :
The Ruby Selector allows end users to choose the Ruby version of their liking.. Additional modules(gems) can be installed using this feature . Ruby Selector uses mod_passenger for best performance.
- Supports Ruby versions 1.8, 1.9, 2.0, and 2.1
- Allows users to install additional modules to application environments.
SecureLinks :
SecureLinks is a kernel-level technology that prevents all known symlink attacks. It enhances the security level of the servers and prevents malicious users from creating symbolic link files.
Mod_lsapi :
Mod_lsapi is the fastest and most reliable way to serve PHP pages. It is a drop-in replacement for SuPHP, FCGID, RUID2, and ITK. It has a low memory footprint and understands PHP directives from .htaccess files.
- Faster than any other way to serve PHP with Apache.
- Doesn’t suffer from stability issues in process management like PHP FPM and mod_fcgid.
- Benefits of opcode caching.
- No fine tuning required.
- Support for PHP directives in .htaccess files.
- Acts as a drop-in replacement for existing ways to serve PHP.
- Fully compatible with PHP Selector.
Conversion procedure of a cPanel-based server from CentOS to CloudLinux OS :
In this part, you will learn how to convert a cPanel-based server from CentOS to CloudLinux OS. First, you will need a software activation key or an IP-based license from CloudLinux.
To install, open an SSH connection to your server. Please make sure that you have the root access to your server. To initiate the conversion process, please execute the following syntax in your server :
$ wget https://repo.cloudlinux.com/cloudlinux/sources/cln/cldeploy $ sh cldeploy -k <activation_key> # if you have activation key
or
$ sh cldeploy -i # if you have IP based license $ reboot
CloudLinux OS installation script itself detects the environment, type of virtualization, control panel, specific hardware which might require additional drivers installation and more.
If you are using EasyApache 3 on the server, the script will execute the EasyApache rebuild process automatically. If you are using EasyApache 4 on the server, the script will install all the required RPM packages automatically, including the mod_hostinglimits package for the proper LVE operation.
Once the installation process is completed, the server needs to be rebooted. Server reboot is mandatory in order to boot the server with the CloudLinux kernel, which is specifically crafted for the LVE support and limits operation. To make sure that the server is running the correct kernel, you can access the server via SSH and execute the “uname -a” command.
CloudLinux kernel contains “lve” in its name – when you see it, you’ll know that the server is running using the correct kernel. Please check the WHM interface now. You will see the message, LVEmanager plugin has been installed during the conversion process.
You are all set now!! – the CentOS server with cPanel has been successfully converted to CloudLinux OS.