Install Memcached – CentOS 7
yum install memcached
Edit the config located at /etc/sysconfig/memcached
add neww
PORT=”11211″
USER=”memcached”
MAXCONN=”1024″
CACHESIZE=”640″
OPTIONS=”-l 127.0.0.1″
Make sure you set the OPTIONS section as above, also increase the CACHESIZE according to your needs
Start it up:
systemctl start memcached
Add it to startup:
systemctl enable memcached
Add memcache to PHP – CentOS 7
ssue the following at shell:
yum install php-pecl-memcache
Now add memcache to PHP, create a file at: /etc/php.d/memcache.ini and the following to it
extension=memcache.so
Restart apache
systemctl restart httpd
Recent Comments