Around The Sun 2024
Howdy! Today I will be tuning the underlying webserver that is running this WordPress application. My hope is to reduce overall CPU load as well as to get experience with more advanced settings. Hopefully I can teach you a thing as well.
Apache is the OG web server. Released in 1993; its daemon name within Linux is httpd. It serves HTML files over the HTTP protocol using port 80. To accomplish this, each connection spins up a thread on the CPU to grab and serve the content. As long as the connection remains active, so does the thread. This improves latency when loading additional pages. However if the underlying webserver is not well equiped for the load, these concurrent CPU threads can eventually overload the server.
The next big webserver is NGINX. Released in 2003 it was originally a proxy software that has evolved into a full fledged HTTP server. Instead of a process/thread heavy design, they created an event-driven method. This allows a single thread to remain open at all times serving HTTP requests. Once this thread cannot process anymore concurrent events, it will spin us another thread. This is considered horizontal scaling. This allows NGINX to serve more page visitors with fewer overall resources.
OpenLiteSpeed is an open-source project hosted on GitHub under the GPLv3 license. It is published by a group known as LiteSpeedTech. Their organization appears to offer this free and open-source product along with a few other complementary products such as CyberPanel and LiteSpeed Enterprise Webserver.
OpenLiteSpeed is a mixture of Apache and NGINX elements combined. It features an NGINX-like event driven architecture to keep CPU utilization down while also supporting Apache-style rewrite rules. This increases compatibility in a manner that I think is advantagous for newer system administrators.
I have linked an article that folks should read. It is well written and in-depth comparing Apache, NGINX, and OpenLiteSpeed. My takeaway from this blog post is that while OpenLiteSpeed is event-driven and very quick to respond to socket requests, it has a much heavier memory footprint than its nearest competitor.
Even with this caveat, my $5/month Nanode has been running OpenLiteSpeed webserver just fine for a year with satisfactory performance and resource utilization.
Navigating into Server Configuration; I went ahead and configured the following variables…
By declaring the Server Name here and within the /etc/hosts
file, we can reduce INFO logs regarding mismatched hostnames. Next we want to disable Geo Location lookup. This will reduce CPU load during concurrent connections.
If you navigate over towards the App Server tab, you can configure and tweak the environment variables for underlying applications such as NodeJS, Ruby, and PythonWSGI. I went ahead and explicitly defined most the default values presented; except where they would exceed the resources I had available.
While taking a deep dive into OpenLiteSpeed, I learned that PHP must communicate with the overhead webserver using a locally shared socket. LiteSpeed PHP is an API interface for the OpenLiteSpeed webserver and the PHP application. Using this API and some additional logic OpenLiteSpeed, LSPHP, LiteSpeedCache can perform cacheing, minifying, and other optimizations faster and smoother than typical “php-fpm” of “mod-php” deployments.
Matt’s Guide to CB Radios and more.
De-Google-Fi, Step 1
Matt’s Guide to Securing a Linux Box for Production.
Quick overview of my websites architecture.
One Night in Glacier NP - 2024
Exploring and capturing the scenery in American Truck Simulator, Nebraska DLC
how-to be safe while downloading linux isos.
Exploring South Dakota with the Jacksons.
how I reduced my home page 610 percent.
how-to add oneko.js to the minimal-mistakes jekyll template.
My personal running notes for growing cannabis.
Dealing with CIFS errors between TrueNAS and Debian.
how-to bounce a Juniper JunOS switchport.
how-to fix ‘the list of sources could not be read.’ when using apt.
how-to troubleshoot a home network, by a Network Engineer.
Moving my webserver from OpenLiteSpeed to Caddy
how-to resolve, could not resolve packages.adoptium.net
how-to validate XZ-Utils impact.
How and Why I use Ninite
Manually renewing Certbot on OpenLiteSpeed
Yet Another Benchmark Results
Linux Basics and Core Concepts by Matt F.
how-to Buy and Manage a Web Domain
My Udemy Course Completion Certification.
Scion FRS Service Manual Download and Sources
My Discord Server Widget
How I moved from QUIC.Cloud to BunnyNet CDN.
My High Uptime Plan for 2024.
Personal notes for Magic the Gathering
HTML Hobbiest Webring Landing Page/Post
Method of Procedure for migrating from WordPress to plain HTML.
W900 Tuning Pack DLC Review.
Google Domains is Ending.
Deep dive into OpenLiteSpeed webserver.
how-to resolve my Jekyll/Cloudflare Pages deployment error.
In High School I had one dream that stands out. Own a Porsche by the time I was 26. Looking back, I have no idea where this dream came from; because I was ra...
Personal ramblings about my new town.
Knowledge Filled PDF Bundle
how-to Jellyfun.
ProtonMail Review - 1 Year
how-to manage Pi-Hole.
My new Gaming PC. Its boring but it’ll do.
how-to setup Pi-Hole and Wireguard on Linode.
how-to update the hostname of a Raspberry Pi.
Can a Raspberry Pi Zero host a family VPN Server? Yes.
Logitech G413 Keyboard review.
Razer Huntsman Mini review.
YouTube video cruising through Colorado!
Ramblings about PiAware after one month of operation.
Guide to setup a Raspberry Pi from start to finish!
Guide to configuring the Timezone on a Raspberry Pi.