The memcached is a high-speed, distributed memory cache system. Its official homepage in http://www.danga.com/memcached/
1. Pre-Installation Preparation
Libevent support is required to install the memcached.
CentOS through
Yum Install Libevent-devel
Installation can
Other versions can be obtained by installing the Libevent source file
2. Download and install the current version is memcached-1.2.6.tar.gz
Cd/usr/src
wget http://www.danga.com/memcached/dist/memcached-1.2.6.tar.gz
Tar xzf memcached-1.2.6.tar.gz
CD memcached-1.2.6
./configure--prefix=/usr/local/memcached
Make
Make install
3. Start
/usr/local/memcached/bin/memcached-d-M 512-l 127.0.0.1-p 11211-u Root
Indicates the way the daemon started, listening on the 11211 port of 127.0.0.1, using the root user, maximum use of 512M memory
You can open multiple memcached at the same time, but listen to different ports.
Note: If you do not have the-u root, you will be reported:
Can ' t run as root without the-u switch
FIX: With-u root on the line!
Memcached installation under CentOS