标签:
安装redis
1、一条命令就行了:apt-get install redis-server
2、wget http:
//download.redis.io/releases/redis-3.0.7.tar.gz
tar -xvf redis-3.0.7.tar.gz
安装redis的php扩展
1.sudo wget http://open.imop.us/pr.tar.gz
2.tar zxvf pr.tar.gz //解压
3. cd owlient-phpredis-5a07edc
4./usr/local/php/bin/phpize
5./configure --with-php-config=/usr/local/php/bin/php-config
6.make && make install
配置php.ini(/usr/local/php/etc/php.ini)
加入
[Redis]
extension=redis.so
extension_dir = "/usr/local/php/lib/php/extensions/no-debug-non-zts-20060613/"
重启nginx: /usr/local/nginx/sbin/nginx -s reload
重启php-fpm:/etc/init.d/php-fpm restart
标签:
原文地址:http://www.cnblogs.com/gpfeisoft/p/5848385.html