验证码显示不了
rpm -Uvh http://mirror.webtatic.com/yum/el6/latest.rpm
yum install libmcrypt libmcrypt-devel mcrypt mhash -y
yum install PHP70w PHP70w-bcmath PHP70w-cli PHP70w-common PHP70w-dba PHP70w-devel PHP70w-embedded PHP70w-enchant PHP70w-fpm PHP70w-gd PHP70w-imap PHP70w-interbase PHP70w-intl PHP70w-ldap PHP70w-mbstring PHP70w-mcrypt PHP70w-mysql PHP70w-MysqLnd PHP70w-odbc PHP70w-opcache PHP70w-pdo PHP70w-pdo_dblib PHP70w-pear PHP70w-pecl-apcu PHP70w-pecl-imagick PHP70w-pecl-xdebug PHP70w-pgsql PHP70w-PHPdbg PHP70w-process PHP70w-pspell PHP70w-recode PHP70w-snmp PHP70w-soap PHP70w-tidy PHP70w-xml PHP70w-xmlrpc PHP70w-pecl-redis.x86_64 --skip-broken -y
#有redis的要加redis依赖,然后重启PHP-fpm
/etc/init.d/PHP-fpm restart
vim /etc/PHP-fpm.d/www.conf
user = Nginx
group = Nginx
PHP_value[session.save_handler] = files
PHP_value[session.save_path] = /var/lib/PHP/session
PHP_value[soap.wsdl_cache_dir] = /var/lib/PHP/wsdlcache
session目录写入的权限
Chmod 755 -R /var/lib/PHP
如果你想把session写入redis,需要安装PHP的redis扩展包
yum search PHP70w-pecl-redis.x86_64 #如果安装版本不一样PHP的session就无法保存到redis中
vim /etc/PHP-fpm.d/www.conf
user = Nginx
group = Nginx
PHP_value[session.save_handler] = Redis
PHP_value[session.save_path] = 'tcp://192.168.1.2:6688'
PHP_value[soap.wsdl_cache_dir] = /var/lib/PHP/wsdlcache
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。