In this tutorial we will show you how to install and configuration of OpenLiteSpeed on your CentOS 7 server. For those of you who didn’t know, OpenLiteSpeed is an open source HTTP server developed by LiteSpeed Technologies. OpenLiteSpeed is a high performance and lightweight HTTP server which comes with a Web Gui administration interface. As far as Linux web servers are concerned, OpenLiteSpeed has some interesting features that make it a solid choice for many installations. It features Apache compatible rewrite rules, a web administration interface, and customized PHP processing optimized for the server.
This article assumes you have at least basic knowledge of linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo’ to the commands to get root privileges. I will show you through the step by step installation OpenLiteSpeed on a CentOS 7 server.
Install OpenLiteSpeed on CentOS 7
Step 1. First, add the OpenLitespeed repository to your server.
Use this command to add the repo into your VPS:
Next, you need to enable EPEL repository on your system:
Step 2. Installing OpenLitespeed.
Now install OpenLiteSpeed with this simple yum command:
Step 3. Installing PHP for OpenLitespeed.
There is a different version of PHP used by OpenLitespeed, PHP versions for openLiteSpeed start with “ls”. Install PHP 7 with many of the extensions to get a rich feature set by typing:
Now enable PHP 5.6 by simply linking it into the location that OpenLiteSpeed calls when attempting to execute PHP code. Issue command below:
Step 4. Configure OpenLiteSpeed web server.
OpenLiteSpeed has an Admin Gui for management, so we will configure the admin password for the openLiteSpeed GUI, and then configure PHP 7 to work with openLiteSpeed and open standard HTTP port 80:
Step 5. Installing MariaDB on CentOS 7.
MariaDB is a drop in replacement for MySQL. It is a robust, scalable and reliable SQL server that comes rich set of enhancements. We will also be using yum to install MariaDB:
By default, MariaDB is not hardened. You can secure MariaDB using the mysql_secure_installation script. you should read and below each steps carefully which will set root password, remove anonymous users, disallow remote root login, and remove the test database and access to secure MySQL:
To log into MariaDB, use the following command (note that it’s the same command you would use to log into a MySQL database):
To start the database, run the commands below:
Finally, You can give it a test whether OLSWS is running or not:
Step 6. Accessing OpenLiteSpeed.
OpenLiteSpeed will be available on HTTP port 7080 by default. Open your favorite browser and navigate to http://yourdomain.com:7080 or http://server-ip:7080 and complete the required the steps to finish the installation. If you are using a firewall, please open port 7080 to enable access to the control panel.
Congratulation’s! You have successfully installed OpenLiteSpeed. Thanks for using this tutorial for installing OpenLiteSpeed web server on your CentOS 7 system. For additional help or useful information, we recommend you to check the official OpenLiteSpeed web site.