CentOS安装redis php扩展

下载redis php扩展
wget http://pecl.php.net/get/redis-3.1.1.tgz

解压redis php扩展
tar zxvf redis-3.1.1.tgz

cd redis-3.1.1

whereis phpize
返回 phpize: /opt/lampp/bin/phpize

whereis php-config
返回 php-config: /opt/lampp/bin/php-config

sudo  /opt/lampp/bin/phpize

sudo ./configure --with-php-config=/opt/lampp/bin/php-config

sudo make

sudo make test

sudo make install

whereis php.ini
返回 /etc/php.ini
添加 extension = redis.so
重启apache

猜你喜欢

转载自blog.csdn.net/xbw12138/article/details/79165431