Installing & Enabling The LSCache Plugin For WordPress
LiteSpeed Web Server Enterprise Edition 5.0.10+.
LSCache Module. (Included with a 2-CPU or higher license. Can be purchased as an add-on for VPS, Ultra VPS, and 1-CPU licenses.)
*Disable any other page caches as these will interfere with LSCWP.
Log in to your WordPress Dashboard, navigate to “Plugins”, and click on “Add New” → “Upload Plugin”.
Select the LSCWP zip file and click “Install Now”.
Enable the plugin by navigating to Plugins » LiteSpeed Cache » Settings and checking the box for Enable LiteSpeed Cache.
Note: If you are using any of our other LiteSpeed Cache plugins, please see Handling Logged-in Cookie Conflicts.
* Please see this wiki article if the other cache plugin is intended for uses other than full page caching.
You can check if a page is being served from LSCWP by:
Make sure you are not logged-in especially admin log in any tab for your browser. Navigating to your site from a non-logged-in browser and using your browser's developer tools to check the response header for the first file.
Right click on the page and select some form of “Inspect”, then click on the “Network” tab in the inspector.
Refresh the page.
Click the first resource (this should be an HTML
file and the inspector should change similarly to the image below). For example, if your page is
, your first resource should either be something like
In a different, logged-in browser, navigate to the cache manager and purge your cache.
Reload the page in the non-logged-in browser and select the same resource again. If you see “X-LiteSpeed-Cache: miss”, “X-LiteSpeed-Cache-Control:public,max-age=1800”, and “X-LiteSpeed-Tag:F,B.1” (as an example), this will store the page in the cache.
If you reload page a second time and see “X-LiteSpeed-Cache: hit” in the response header for the HTML
file, then the page is being served by the cache and LSCWP is configured correctly.
Currently, this plugin only provides caching for non-logged-in users and further development is in progress.
Note: If your first refresh after purging returns “X-LiteSpeed-Cache: hit“ in the response header, this may be because someone visited the page after you purged but before you refreshed it yourself.
Turning On the WordPress Debug Log
To enable the WordPress debug log, modify “wp-config.php” under WordPress' root directory as follows:
Set “WP_DEBUG” to true.
Add the following:
a “debug.log” file should now be generated under “wp-content” which will log information whenever WordPress hits the backend.
You can monitor this log during debugging using the following command:
tail -f wp-content/debug.log