


1、安装libmemcached
2、安装php_memcached扩展
wget https://launchpad.net/libmemcached/1.0/1.0.18/+download/libmemcached-1.0.18.tar.gz
tar zxvf libmemcached-1.0.18.tar.gz
cd libmemcached-1.0.18
./configure --prefix=/usr/local/libmemcached --with-memcached
make && make install
支持:php7.0,7.1,7.2,7.3(将目录变更为自己的php安装目录)
wget http://pecl.php.net/get/memcached-3.1.5.tgz
tar zxvf memcached-3.1.5.tgz
cd memcached-3.1.5
./configure --with-php-config=/usr/php7.2/bin/php-config --enable-memcached --enable-memcached-json --with-libmemcached-dir=/usr/local/libmemcached/
make
cp modules/memcached.so /usr/php7.2/modules/
echo 'extension=memcached.so' >>/etc/php7.2/php.ini



亲爱的:若该文章解决了您的问题,可否收藏+评论+分享呢?
文章评论 本文章有个评论