Skip to content

Pre-flight checklist for a LiteSpeed update on cPanel

A LiteSpeed update on cPanel can change PHP handlers, cache behavior, and rewrite parsing. Here is the pre-flight we run before pushing the upgrade.

A LiteSpeed Web Server point release looks small in the changelog and turns out to subtly change how a customer’s .htaccess is parsed, or shifts the default PHP handler, or quietly disables the LSCache module on a configuration the previous version tolerated. The right time to discover that is on a staging clone, not on the production box at 03:00.

What’s happening

LSWS upgrades on cPanel touch several moving parts: the lsws daemon, the PHP handler binding (lsphp versions and SAPI), mod_lsapi if you’re running it, and the LSCache plugin handshake on the WordPress side. Most upgrades are clean. The ones that aren’t usually fail in one of a few well-known ways: a deprecated rewrite directive starts emitting a 500, an older lsphp version is no longer packaged and sites pinned to it fall back silently, or the LiteSpeed Cache plugin can’t talk to the new server build until its cache root is reset.

The fix is not bigger maintenance windows. The fix is a pre-flight that catches these before they’re a customer call.

How to verify

Walk the checklist before scheduling the upgrade. From WHM or the shell:

/usr/local/lsws/bin/lshttpd -v
ls /usr/local/lsws/lsphp*/bin/lsphp | xargs -I{} {} -v 2>/dev/null | grep PHP
grep -l 'LSCACHE_VARY' /home/*/public_html/wp-content/plugins/litespeed-cache/data/.htaccess.conf

You want: current LSWS build, every lsphp version that any customer site is actually using, and an inventory of every LSCache-enabled site. Pull the release notes for the target version and check for changes to the handler list, mod_lsapi API version, or default cache headers.

Run a config dry-run:

/usr/local/lsws/bin/lswsctrl restart -t
/scripts/rebuildhttpdconf --check

Both should return zero errors before you proceed.

The fix

For the upgrade itself: clone one representative site to a staging account, push the LSWS upgrade there first, and run a synthetic check that exercises a logged-out page, a logged-in page, a WooCommerce checkout if applicable, and a wp-cron-driven path. Confirm X-LiteSpeed-Cache: hit returns where it should. If staging is clean, run the production upgrade through /scripts/lsws_upgrade rather than the WHM button — the script handles handler rebind and cagefs remount in the right order.

After the production upgrade, verify the same handler list survived (lshttpd -v, lsphp -v for each version) and that LSCache headers return on three known-cacheable URLs from a clean curl.

If you skip this and the upgrade strips an lsphp version, every site pinned to it serves PHP 8.1 instead of 7.4 starting at restart. Customers will notice.


Stack Harbor runs LSWS upgrade pre-flights as standard practice under deployment management and validates cache behavior post-upgrade with monitoring and support. For a managed LiteSpeed upgrade with a real staging step, contact our team.