Memcached is a high-performance, distributed memory object caching system, generic in nature, but intended for use in speeding up dynamic web applications by alleviating database load.

1. Setting-up RPMForge respository. RPMForge repository ( is the biggest rpm respository for RHEL, CentOS for all versions. Setup the RPMForge repository as mentionedhere.

2. Install memcached.

Use yum to install memcached

As soon as memcached installation completed, edit options for memcached in /etc/sysconfig/memcached to meet your need.

Save the file. All options can be seen by using following command

Start memcached

To check the running status of memcached


3. Install PHP Extension.

Download and install latest stable memcache version from PECL. will be installed in php modules directory, now enable extension in php.ini

To find out your php.ini location, execute following command

Save the file and restart httpd server.

To check is memcache extension loaded in php, execute following command.

This information can also be seen using phpinfo().