I was testing memcached in one of my cluster. It is seems to be very useful to increase performance. As it is “Memcached is an in-memory key-value store for small chunks of arbitrary data (strings, objects) from results of database calls, API calls, or page rendering.” , Read more about and see who all are using memcached.
But the main thing is your application need memcached support otherwise it won’t work.
So Openx have a plugin for memcached support. This will help your openx faster delivery via delivery cache. To enable this plugin go to Global Settings > Banner Delivery Settings to choose memcached caching of banners. Don’t enable it if you are not installing the following packages.
Before enabling this plugin you must need to install a perfect memcached server in your openx server. So please proceed the following instructions.
Install memcached serverDownload the memcached server from
# wget -c # tar -xzf memcached-1.4.5.tar.gz # cd memcached-1.4.5/ # yum -y install libevent libevent-devel # ./configure --prefix=/opt/memcached # make # make installNow the installation finished. Let us use the following command to start memcached .
# /opt/memcached/bin/memcached -u nobody -d -m 128 -l 127.0.0.1 -p 11211In the above command memcached will start as a daemon and listen on port 11211 on 127.0.0.1 . Here -m 128 means the amount of memory it can use, here 128 MB of RAM.
So let us create an init script for start/stop of memcached. /etc/init.d/memcached
Now give execute permission to init script as follows,
# chmod 755 /etc/init.d/memcachedIf you need to start this server during reboot , please add the following line to /etc/rc.local
# /etc/init.d/memcached startSo our server is ready. Now we need ton install the php-pecl memcached extension. Otherwise your application won’t work,
Install php-pecl memcachedDownload the latest stable memcached from
# wget -c # tar -xzf memcache-2.2.5.tgz # cd memcache-2.2.5/ # phpize # ./configure # make # make installNow restart apache and create a phpinfo page and test whether the memcache options is showing or not. If it is there go to Openx admin and enable the plugin.
Popularity: 50%