Memcached

Configuring MODX to Use Memcached

gourmet fare

MODX and Memcached

Here, I simply followed Jason's instructions in his MODX Blog post to start some memcached processes (daemons) for MODX to use, and to confgure MODX to use them.

Jason provides an image of what the new System Settings should look like. I can't remember things from click to click, so I prefer something that I can copy and paste. Here's my settings:

auto_publish_memcached_server -> localhost:11216
context_settings_memcached_server -> localhost:11213
db_memcached_server -> localhost:11217,localhost:11218,localhost:11219,localhost:11220
resource_memcached_server -> localhost:11214
scripts_memcached_server -> localhost:11215
system_settings_memcached_server -> localhost:11212

And the config options Jason has in his tutorial worked as advertised when added to my core/config/config.inc.php on line 13.

$config_options = array (
	'cache_handler' => 'cache.xPDOMemCached',
	'memcached_server' => 'localhost:11211',
	'system_settings_memcached_server' => 'localhost:11212',
	'cache_db' => true,
	'db_memcached_server' => 'localhost:11217,localhost:11218,localhost:11219,localhost:11220',
);

phpMemcachedAdmin

You will probably want to install phpMemcachedAdmin. It was simple enough to install, just download it, unzip it, and put its directory in the web root. It has all kinds of visual representations of just what is going on, as well as utilities for tuning and configuring your caches.

phpMemcachedAdmin

Besides Jason's MODX Blog post, there is a very brief mention in the official rtfm, and a discussion on the MDOX Forums.