WPCloudDeploy Documentation

Object Cache: Redis


An object cache can help speed up database queries by caching the results of those queries in memory.  One of the most popular object cache is MemCached.  Support for this is included as part of the base WPCloudDeploy plugin. An additional object cache option is REDIS – we support this via an add-on.

To install the add-on, just upload and activate it just like you would any other WordPress plugin via the WordPress PLUGINS->ADD NEW screen.

Once the add-on has been uploaded and activated you should see it as a new option in your SERVER screen(s):

Enabling Redis

To enable Redis, the package first needs to be installed at the server level.  Once it’s installed, you can then enable it on a site-by-site basis.

Install the Redis Package

  • Go to WPCloudDeploy → All Cloud Servers
  • Click on the server where you’ll be installing Redis
  • Scroll down to the REDIS section
  • Click the Install Redis button

A popup will appear that will offer periodic feedback as the process progresses.  When the process is complete you will get a popup confirmation message and the black ‘terminal” window will show the actions that were taken while attempting to install the package.

Activate Redis For A Site

Once Redis has been installed on a server you can activate it for any site on the server.

  1. Go to WPCloudDeploy → All Apps
  2. Click on the site where you need to turn on the object cache
  3. Click on the Cache tab
  4. Scroll down to the REDIS section
  5. Click on the toggle switch

After a while the screen will refresh – if the operation is successful.  If the operation fails, you’ll get a popup message.

You can view a full log of the operation under the SSH LOG screen.

REDIS vs MemCached

Amazon AWS has an article that outlines some of the differences between REDIS and MEMCACHED.  Most of these differences do not matter in WordPress because the REDIS cache plugin doesn’t take advantage of them.  MemCached uses a multi-threaded architecture which can be useful on a multi-core VM. But REDIS, in general, is more flexible.

In WordPress, MemCached can only use a max size of 1 MB for an object.  Sometimes, WordPress objects in MemCached are larger than 1 MB because the options table is just HUGE.  This will cause MemCached to actually SLOW DOWN or TIMEOUT your WP site.  Redis is substantially better in theses situations.

Generally, given a choice between REDIS and MEMCACHED, we’ll choose REDIS.