1. Home
  2. Linux
  3. How to install openlitespeed web server on linux

How to install OpenLiteSpeed web server on Linux

OpenLightSpeed is a powerful open-source web server. In the Linux community, it’s known for being reliable and speedy. So, if you’re not happy with using Apache or Nginx, OpenLiteSpeed may a great alternative. In this guide, we’ll show you how to get OpenLiteSpeed working on your Linux system.

How to install OpenLiteSpeed on Ubuntu Server

If you wish to install the OpenLiteSpeed web server on Ubuntu Server, you must start by updating your software sources. You can update your software sources by running the following apt update command.

sudo apt update

After running the above command to update your Ubuntu software sources, you’ll need to install any upgrades Ubuntu has. You can easily install these upgrades using the apt upgrade command.

sudo apt upgrade -y

With everything up to date, you’ll need to add the OpenLiteSpeed repository on your Ubuntu system. You can enable the software repository by entering the following command.

sudo wget -O - https://rpms.litespeedtech.com/debian/enable_lst_debian_repo.sh | sudo bash

This command will download a script that enables everything you need to install the OpenLightSpeed packages. From here, you can run the apt install command to install the latest version of OpenLightSpeed on your Ubuntu server system. Keep in mind, this installation may take a few minutes to complete, depending on your network.

sudo apt install openlitespeed lsphp81

Configuring OpenLightSpeed on Ubuntu

Once OpenLightSpeed is installed on your Ubuntu system, you can start the configuration process. To configure it on Ubuntu, you’ll need to start by creating a new admin password.

To create a new admin password, you’ll need to run the following command in a terminal. This command will run a script that configures the admin account for use in OpenLightSpeed.

sudo bash /usr/local/lsws/admin/misc/admpass.sh

After running the above command, you’ll see the following message. This message says “Please specify the user name of administrator. This is the user name required to login the administration Web interface.”

In the text box, enter your preferred admin account name. In this article, we’ll use “admin”. Then, press the Enter key to move to the next step in the script.

When you press the Enter key, you’ll see another message. This message says “Please specify the administrator’s password. This is the password required to login the administration Web interface.” Enter a secure, memorable password.

With your password entered, the web interface for OpenLightSpeed can be logged into on Ubuntu. Now, you must start up the server using the systemctl command.

sudo systemctl start lsws

You can enable OpenLightSpeed at boot using the systemctl enable command.

sudo systemctl enable lsws

Access your OpenLightSpeed server at the following URL:

http://ubuntu-server-ip:8088

How to install OpenLiteSpeed on Debian

OpenLightSpeed works on Debian just like it does on Ubuntu. So, if you’re using Debian as a server and wish to deploy it, simply follow the installation instructions for Ubuntu covered previously in this guide.

It should be noted that if you’re using an older version of Debian, you may need to change the “apt” commands to “apt-get.” Additionally, you may need to upgrade your Debian release to a more modern version if you cannot deploy OpenLightSpeed correctly.

How to install OpenLiteSpeed on CentOS Stream

OpenLiteSpeed is available for CentOS Stream. So, those using CentOS Stream as a server looking to get an OpenLiteSpeed web server running are in luck. To start, you’ll need to install the official OpenLiteSpeed repo package. Using the rpm command, install it.

sudo rpm -Uvh http://rpms.litespeedtech.com/centos/litespeed-repo-1.3-1.el8.noarch.rpm

With the package installed, you can safely install the OpenLiteSpeed package on your CentOS Stream system using the dnf install command.

sudo dnf install openlightspeed

With the OpenLightSpeed package installed on your CentOS Stream system, you’ll need to start it using the systemctl start command.

sudo systemctl start lsws

You can now run the systemctl enable command to enable the web server at boot.

sudo systemctl enable lsws

Configuring OpenLightSpeed on CentOS Stream

After enabling the OpenLightSpeed web server at boot, it is time to configure the server. Configuring the web server on CentOS Stream is very similar to how it is done on Ubuntu Server.

To start, run the following script. This script will help you configure a username and password for the administrator account.

sudo bash /usr/local/lsws/admin/misc/admpass.sh

After running the script, use the terminal interface provided by the script to set your OpenLightSpeed admin account and password. When you’ve finished, you’ll be able to access the OpenLightSpeed start page via the following URL.

http://centos-stream-server-ip:8088