WordPress object cache with memcached backend for vanilla WordPress

WordPress object cache with memcached backend is mainly meant for WPMU and doesn’t work well if you happened to have many vanilla WordPress installations using the same memcached backend like it is pointed out here and here.

I have created a simple patch which you can apply against object-cache.php (downloadable from WordPress plugin repository) or here is the file already patched. The patch prepends the $blog_id to the object key. You will have to specify global variable $blog_id in wp-config.php and give it a unique id (like your blog url).

global $blog_id;
$blog_id = 'mohanjith_net';
If you enjoyed this post, make sure you subscribe to my RSS feed!

4 thoughts on “WordPress object cache with memcached backend for vanilla WordPress”

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.