First thing first: memcache vs memcached
According to http://blackbe.lt/php-memcache-vs-memcached/
PHP has two separate module implementations wrapping the memcached (as in memcache daemon) server.
The memcache module utilizes this daemon directly, whereas the memcached module wraps the libMemcached client library and contains some added bonuses.
Memcached module will be faster than memcache module => I’ll go with Memcached module
Install Memcached daemon on my dedicate Memcached host
sudo apt-get install memcached libmemcached-tools
My memcache server listen all of its address. So edit /etc/memcached.conf
-m 20000 #amount of RAM in MB
-p 11211 #listen port 11211
-l 0.0.0.0 #listen on all interfaces
Install memcached client
In other WordPress PHP server we need to install memcahed client and server (optional):
sudo apt-get install php5-memcached memcached libmemcached-tools php-pear
global $memcached_servers;
$memcached_servers = array(‘default’ => array(‘192.1.3.30:11211′,’192.1.1.11:11211′,’192.1.1.12:11211’));
Now your WordPress can Memcached it.