您的位置:首页 > 数据库 > Memcache

CentOS 7 安装 PHP 7.0以及memcache和redis扩展

2016-05-29 16:44 851 查看
安装EPEL
EPEL 是 Extra Packages for Enterprise Linux 的缩写(EPEL),是用于 Fedora-based Red Hat Enterprise Linux (RHEL) 的一个高质量软件源,所以同时也适用于 CentOS 或者 Scientific Linux 等发行版。
rpm -Uvh https:// href="http://dl.fedoraproject.org" target=_blank>dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
yum install epel-release

安装PHP 采用webtatic的编译版本
rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm
yum install php70w php70w-devel php70w-bcmath php70w-fpm php70w-mbstring php70w-pdo php70w-soap php70w-mysql php70w-gd

安装memcached for php7
git clone https://github.com/php-memcached-dev/php-memcached.git
cd php-memcached
git checkout php7
phpize
./configure --disable-memcached-sasl
make && make install

add
extension=memcached.so
to php.ini

安装redis for php7
git clone https://github.com/phpredis/phpredis.git
cd phpredis
git checkout php7
phpize
./configure
make && make install

add
extension=redis.so
to php.ini
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: