|
马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。
您需要 登录 才可以下载或查看,没有帐号?立即注册
x
如果您觉得本篇CentOSLinux教程讲得好,请记得点击右边漂浮的分享程序,把好文章分享给你的好朋友们!装置所要软件
wgethttp://launchpad.net/libmemcached/1.0/0.42/+download/libmemcached-0.42.tar.gz
wgethttp://pecl.php.net/get/memcached-1.0.2.tgz
memcached的官方网站http://www.ckuyun.com/
装置libmemcached
tarzxvflibmemcached-0.42.tar.gz
cdlibmemcached-0.42
./configure–-prefix=/usr/local/libmemcached–-with-memcached
make&&makeinstall
装置要注重的成绩:
1,装置过程当中不要忘了,–with-memcached,否则会提醒你
checkingformemcached…no
configure:error:“couldnotfindmemcachedbinary”
2,你的memcached是否是1.2.4以上的,假如不是会提醒你
clients/ms_thread.o:Infunction`ms_setup_thread’:
/home/zhangy/libmemcached-0.42/clients/ms_thread.c:225:undefinedreferenceto`__sync_fetch_and_add_4′
clients/ms_thread.o:/home/zhangy/libmemcached-0.42/clients/ms_thread.c:196:moreundefinedreferencesto`__sync_fetch_and_add_4′follow
collect2:ldreturned1exitstatus
make[2]:***[clients/memslap]Error1
make[2]:Leavingdirectory`/home/zhangy/libmemcached-0.42′
办理举措是–disable-64bitLAGS=”-O3-march=i686″,
最好的***是换个版本的软件
https://launchpad.net/libmemcached/1.0/0.51/+download/libmemcached-0.51.tar.gz
./configure--prefix=/usr/local/libmemcached--with-memcached
假如不必这个64位的long型数据,我想php扩大memcached,memcache也就没甚么区分了,装memcached也就没甚么意义了。
php的扩大memcached的装置
tarzxvfmemcached-1.0.2.tar.gz
cdmemcached-1.0.2
/usr/local/php/bin/phpize
./configure--with-memcached-with-php-config=/usr/local/php/bin/php-config--with-libmemcached-dir=/usr/local/libmemcached--enable-memcached
make&&makeinstall
vi/usr/local/php/lib/php.ini
加上extension=memcached.so重起一下办事就能够了。
欢迎大家来到仓酷云论坛! |
|