OpenLiteSpeed combines speed, security, scalability, optimization and simplicity in one friendly open-source package. The source code of the project is released under the GPLv3 license and available publicly on GitHub.
The application provides a web based administration interface, compatibility with Apache rewrite rules, as well as customised PHP processing for improved performance.
1 . Start with downloading and installing the OpenLiteSpeed GPG key:
wget -O /etc/apt/trusted.gpg.d/lst_debian_repo.gpg http://rpms.litespeedtech.com/debian/lst_debian_repo.gpg wget -O /etc/apt/trusted.gpg.d/lst_repo.gpg http://rpms.litespeedtech.com/debian/lst_repo.gpg
2 . Add the OpenLiteSpeed repository to the APT packet manager:
echo "deb http://rpms.litespeedtech.com/debian/ bionic main" > /etc/apt/sources.list.d/openlitespeed.list
3 . Update the inventory of the
apt packet manager:
4 . Install OpenLiteSpeed and PHP 7.3 via
apt install openlitespeed lsphp73 lsphp73-mysql -y
5 . Configure PHP 7.3 with OpenLiteSpeed by creating a symlink to the PHP binary:
ln -sf /usr/local/lsws/lsphp73/bin/lsphp /usr/local/lsws/fcgi-bin/lsphp5
1 . Start by installing the MariaDB database server via
apt install mariadb-server -y
2 . Run the setup utility to configure the MariaDB server and to set a password for the root user of it:
3 . Connect to MariaDB as
root user with the password configured in the previous step:
mysql -u root -p
4 . The MariaDB shell displays:
Welcome to the MariaDB monitor. Commands end with ; or \g. Your MariaDB connection id is 49 Server version: 10.1.40-MariaDB-0ubuntu0.18.04.1 Ubuntu 18.04 Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. MariaDB [(none)]>
5 . Create a SQL database for Wordpress and grant the required permissions to it:
CREATE DATABASE wordpress; GRANT ALL PRIVILEGES ON wordpress.* TO wordpress@localhost IDENTIFIED BY '<a_secure_password>';
6 . Leave the MariaDB shell:
1 . Start OpenLiteSpeed by running the following command:
2 . A test site is running at
http://instance_ip:8088. Open the test site in your browser. You can run differnt demo applications like a CGI-script, a check of the installed PHP version, password authentication, file upload and so on:
1 . Open the administration interface in your web browser at
Login using the following credentials:
Important: For security reasons, it is recommended to change the admin password by running the following script:
2 . The administration interface displays:
The status of OpenLiteSpeed is visible in the interface and you can configure additional settings.
1 . Enter the OpenLiteSpeed directory:
2 . Create an directory structure for the new virtual host. You can name it as you want. In this example it is called
mkdir wordpress.example.com mkdir wordpress.example.com/html
4 . Open the OpenLiteSpeed configuration assistant in a web browser and click on Virtual Hosts to enter the virtual host configuration.
5 . The virtual host list displays. Click on + to create a new virtual host.
6 . Enter the details of the virtual host and click on the disk icon:
7 . As the configuration file is not yet created, OpenLiteSpeed proposes to create a new one. Click on Click to create to let OpenLiteSpeed automatically generate a configuration file. Then Save the configuration by clicking on the disk icon:
8 . Go back to the virtual host configuration and click on the General-tab to configure the Document Root for the virtual host. Click on the disk icon to save the configuration once set:
9 . Click on the Rewrite tab in the virtual host configuration. Then activate the Enable Rewrite and Auto Load from .htaccess options and save the configuration:
A listener defines the port on which the application launches. To make WordPress available on the standard HTTP port (Port 80), a new listener has to be configured in OpenLiteSpeed.
1 . Enter the Listeners section of the administration panel, then click on + to configure a new listener:
2 . Enter the details of the new listener:
ANYto listen on all IP addresses configured on the instance.
80to listen on the standard HTTP port
Noto use plain HTTP.
Once all values are set, save the configuration by clicking on the disk icon.
3 . Map the listener to a virtual host and set the domain name by clicking on + in the Virtual Host Mappings section:
4 . Choose the Virtual Host from the drop-down list (i.e.
Wordpress) and enter the domain name to use for the virtual host. Once set, click on the disk icon to save the configuration:
5 . Launch a graceful restart of OpenLiteSpeed by clicking on the logo, then on the corresponding button:
1 . Enter the web directory of the virtual host:
2 . Download and unpack the latest WordPress release:
wget http://wordpress.org/latest.tar.gz tar xvzf latest.tar.gz
3 . Set the ownership of the Wordpress folder and the files within it to the user
nobody and the group
nogroup. This is required so that OpenLiteSpeed can modify files within this folder:
chown -R nobody:nogroup wordpress
4 . Open a web browser and go to
http://instance_ip/wordpress. The Wordpress installer displays. Choose the language for your blog and click on Continue:
5 . Wordpress displays some information about the tasks that will be performed by the automatic installer. Click on Let’s Go to move forward.
6 . Enter the information about the database to use. The database, as well as the login credentials have been created in an earlier step. Click on Submit to continue.
7 . Enter the details of your blog and click on Install Wordpress to launch the installation:
8 . Login to Wordpress to begin writing your blog:
You now have configured sucessfully a basic setup of OpenLiteSpeed and installed a Wordpress blog on it. For more information about OpenLiteSpeed, refer to the official documentation.