码迷,mamicode.com
首页 > 系统相关 > 详细

memcache安装

时间:2015-08-12 14:51:20      阅读:158      评论:0      收藏:0      [点我收藏+]

标签:memcache安装

memcache安装:


wget http://www.monkey.org/~provos/libevent-1.2.tar.gz


tar zxvf libevent-1.2.tar.gz


cd libevent-1.2


./configure --prefix=/usr

make

make install


wget http://www.danga.com/memcached/dist/memcached-1.2.0.tar.gz


tar zxvf memcached-1.2.0.tar.gz


cd memcached-1.2.0


./configure --with-libevent=/usr

make

make install


安装Memcache的PHP扩展

pecl install memcache


Build process completed successfully

Installing ‘/usr/lib64/php/modules/memcache.so‘

install ok: channel://pecl.php.net/memcache-2.2.7

configuration option "php_ini" is not set to php.ini location

You should add "extension=memcache.so" to php.ini



编辑php配置文件

vi /etc/php.ini

extension_dir = "/usr/lib64/php/modules/"

extension=memcache.so



ln -s /usr/lib/libevent-1.2.so.1 /usr/lib64/libevent-1.2.so.1


启动memcached

/usr/local/bin/memcached -d -m 10 -u root -l 192.168.10.109 -p 12000 -c 256 -P /tmp/memcached.pid

本文出自 “linux&云计算” 博客,请务必保留此出处http://czbinghe.blog.51cto.com/9824423/1683966

memcache安装

标签:memcache安装

原文地址:http://czbinghe.blog.51cto.com/9824423/1683966

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!