This article assumes you have already installed the LiteSpeed Cache (LSCache) plugin for WordPress. If you have not yet installed and enabled LiteSpeed WordPress cache plugin for your WordPress site please refer to our KB article: How to install and enable LiteSpeed Cache plugin for WordPress
All Hawk Host shared, reseller, and semi-dedicated plans provide support for Redis and Memcached. Instead of using an IP/port for these services we provide a socket you can use to connect to either application. This article will describe how to configure your LiteSpeed WordPress cache plugin to use a Redis or Memcached socket:
- Login to your cPanel account and use the search to access the "Server Application Manager" interface:
- From the Server Application Manager interface click "Enable" to spin up your Redis or Memcached instance:
- It will take approximately 5 minutes for the instance to start. While you wait for your Redis or Memcached instance to start, use the cPanel search for the "Select PHP Version" interface to ensure we have the right PHP extensions enabled:
- From the "Select PHP Version" interface click the "Extensions" tab:
- From the Extensions tab make sure you have enabled either the Redis or Memcached PHP extension, whichever you intend on using for your LSCache setup:
- Use cPanel search to go back to the "Server Application Manager" interface. You should now see a Socket created with a path provided:
- Now that everything is completed in cPanel you will need to login to your websites WordPress admin dashboard. From the WordPress admin dashboard use the left side navigation menu and click the "LiteSpeed Cache" plugin:
- From the LiteSpeed Cache plugin dashboard click the "Cache" menu from the left side navigation:
- From the LiteSpeed Cache Settings interface click the " Object" tab:
- Change the "Object Cache" toggle to "ON":
- Select your desired cache method, either Memcached or Redis.
- In the "Host" field enter the Socket path from the Server Application Manager in cPanel from step 6.
- Change the "Port" field to 0.
- All other settings can be left as default unless you have a reason to change them. Verify your entries and click "Save Changes" to complete the process:
- If your configuration is correct you should see a "Connection Test: Passed" under the Status display: