Learn how to Install the OpenLiteSpeed Web Server on Ubuntu 20.04 with full commands, admin setup, and port configuration in simple steps. Our Live Support Team is always here to help you.

How to Install the OpenLiteSpeed Web Server on Ubuntu 20.04

OpenLiteSpeed is a powerful, high-performance web server, and getting it running on Ubuntu 20.04 can significantly boost your site’s speed and reliability. Here’s a practical guide to Install the OpenLiteSpeed Web Server on Ubuntu 20.04 with all commands included, from installation to configuration.

install-the-openlitespeed-web-server-on-ubuntu-20-04

Installing OpenLiteSpeed

Before using the server, you need to install it. OpenLiteSpeed offers a repository for Ubuntu, making installation straightforward.

First, update your package manager cache:

sudo apt update

Next, install any pending upgrades:

sudo apt upgrade

If prompted, enter your password, then confirm the installation with Y.

To enable the repository, download and add the developer’s software signing key:

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

This script automatically adds the LiteSpeed repository to Ubuntu’s apt package manager. Now, install OpenLiteSpeed and the corresponding LS-PHP interpreter:

sudo apt install openlitespeed lsphp81

If prompted, confirm with Y. This command installs OpenLiteSpeed and LSPHP 8.1, which integrates PHP with LiteSpeed’s server API.

Setting Up the Administrative Password

Next, secure the server by updating the default admin account:

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

You will be asked to enter a username. Press ENTER to use the default admin or type your preferred username. Then, create and confirm a new password. The script will confirm:

Administrator's username/password is updated successfully!

Connecting to the Server

OpenLiteSpeed starts automatically after installation. Check its status:

If it’s not active, start it manually:

sudo systemctl start lsws

Next, open firewall ports:

sudo ufw allow 8088,7080,443,80/tcp

Port 8088 is for the default OpenLiteSpeed site. Visit your server in a browser:

http://server_domain_or_IP:8088

You will see the default OpenLiteSpeed page with pre-configured features like a CGI script, custom PHP instance, and authentication gates.

To access the admin interface, go to:

https://server_domain_or_IP:7080

Expect a self-signed SSL warning. Click through, then log in with the admin credentials set earlier.

Changing the Default Page Port

To switch the default site from port 8088 to the standard HTTP port 80, go to the admin interface’s Listeners section. Click View (magnifying glass) next to the Default listener, then Edit (pen icon) in the Address Settings. Change the port to 80 and save.

Restart OpenLiteSpeed gracefully using the arrow icon, and your site will now be accessible on port 80 without specifying a port number.

Finally, you can add your website files, HTML, CSS, JS, or other content, to:

/usr/local/lsws/Example/html

[If needed, Our team is available 24/7 for additional assistance.]

Conclusion

This completes the process to Install the OpenLiteSpeed Web Server on Ubuntu 20.04. The server is now ready to host high-performance websites with easy administration and full control.