centos 7.0 安装Memcached以及配置php的Memcache扩展

因项目需求,需要在centos 7.0上安装Memcached以及配置php的Memcache扩展。所以只好通过网上资料一步一步来安装和配置了。 第一步: 准备工具 下载memcached和memcache源码 1.  memcached官网: http://memcached.org/downloads 2. php扩展: http://pecl.php.net/package/memcache 第二步: 安装 1. 安装memcached #下载memcached源码 wget wget http://memcached.org/files/memcached-1.4.25.tar.gz #解压 tar -zxvf memcached-1.4.25.tar.gz #切换到解压后的目录 cd memcached-1.4.25 #配置 ./configure –prefix=/usr/local/memcached If it’s already installed, specify its path using –with-libevent=/dir/ 需要安装libevent,从http://libevent.org/下载libevent-2.0.22-stable.tar.gz,并编译安装。 #下载libevent源码 wget https://github.com/libevent/libevent/releases/download/release-2.0.22-stable/libevent-2.0.22-stable.tar.gz #解压 tar -zxvf libevent-2.0.22-stable.tar.gz #切换到解压后的目录 cd libevent-2.0.22-stable #配置 ./configure –prefix=/usr/local/libevent #编译安装 make && make install … Continue reading “centos 7.0 安装Memcached以及配置php的Memcache扩展”