OpenLiteSpeed is the open source version of LiteSpeed Web Server Enterprise. It is a web server like Apache or NGINX, and can be installed on all Linux systems. OpenLiteSpeed is developed to be highly scalable, can accelerate WordPress performance, and work on minimal hardware specs.
In this tutorial, you will see the step by step instructions to get OpenLiteSpeed web server installed on all major Linux distros. Specifically we will cover instructions for Debian Linux based systems such as Ubuntu, and Red Hat Enterprise Linux based systems like AlmaLinux, CentOS, Rocky Linux, Fedora, etc.
In this tutorial you will learn:
How to install OpenLiteSpeed speed on debian and ubuntu based distros
How to install OpenLiteSpeed speed on RHEL and CentOS based distros
Basic configuration and testing of OpenLiteSpeed web server
Privileged access to your Linux system as root or via the sudo command.
Conventions
# – requires given linux commands to be executed with root privileges either directly as a root user or by use of sudo command $ – requires given linux commands to be executed as a regular non-privileged user
How to install OpenLiteSpeed web server step by step instructions
The instructions will vary depending on whether you want to install OpenLiteSpeed on a Debian based or RHEL based distro. Follow the appropriate commands below that apply to your system.
OpenLiteSpeed installation on Debian
On Debian, start by opening a terminal and using the following command to add the OpenLiteSpeed repository to your system.
This wget command will download a shell script from the official OpenLiteSpeed website, which can add the repository to your system. Piping the command to sudo bash allows us to run the script after downloading it, all with a single command.
Next, update the package cache and install the OpenLiteSpeed web server.
PHP should have been automatically installed as a dependency for OpenLiteSpeed. Check your PHP configuration and verify that it works by navigating to:
If you will need a database (for example, for a WordPress or other content management system installation), you can install MariaDB with the following command on Debian systems:
$ sudo apt install mariadb-server mariadb-client
Then, to configure your MySQL / MariaDB settings, execute this command:
$ sudo mysql_secure_installation
Leave the first response blank and press enter. You should reply with y (yes) to the rest of the prompts, and configure a root password when prompted to do so. This setup only takes a moment to complete.
PHP should have been automatically installed as a dependency for OpenLiteSpeed. Check your PHP configuration and verify that it works by navigating to:
If you will need a database (for example, for a WordPress or other content management system installation), you can install MariaDB with the following command on RHEL based systems:
$ sudo dnf install mariadb-server mariadb-client
Then, to configure your MySQL / MariaDB settings, execute this command:
$ sudo mysql_secure_installation
Leave the first response blank and press enter. You should reply with y (yes) to the rest of the prompts, and configure a root password when prompted to do so. This setup only takes a moment to complete.
👁 The initial setup of MySQL with mysql_secure_installation The initial setup of MySQL with mysql_secure_installation
Your website files can be found at the following directory by default:
$ cd /usr/local/lsws/Example/html
Of course, this setting and many others can be easily changed inside of the OpenLiteSpeed administration panel.
Closing Thoughts
In this tutorial, we saw how to install OpenLiteSpeed on a Linux system. OpenLiteSpeed is a fast and minimalist web server that boasts speedier results than Apache. It also has a GUI backend to make configuration much easier. It is rather easy to get up and running on Debian based and CentOS based systems, so it is worth seeing how it performs for your web hosting needs.