PHP 升级到 7.1.2
备注: 如果提示 Cannot find autoconf. autoconf 已经在 环境搭建中安装了,需要执行下面命令:
export PHP_AUTOCONF=/usr/local/autoconf-2.13/bin/autoconf
export PHP_AUTOHEADER=/usr/local/autoconf-2.13/bin/autoheader
备注: #chmod 777 /tmp/php-fcgi.sock (运行 phpinfo页面会出现错误,修改通信socket的权限试试看!)
1> 重新编译安装 php
#cd /server/install
#tar -xfv php-7.1.2.tar.gz
#cd php-7.1.2
#make clean
#rm -f configure
#./buildconf --force
#./configure --prefix=/server/app/services/ --with-libxml-dir=/server/app/services/ --with-config-file-path=/server/app/services/ --enable-fastcgi --enable-force-cgi-redirect --with-curl=/server/app/services --enable-apc --enable-memcache --with-zlib-dir=/server/app/services/ --with-zlib --with-libmemcached-dir=/server/app/services/ --enable-memcached --enable-sockets --enable-fpm --enable-pdo --enable-mysqlnd --with-pdo-mysql=mysqlnd --with-mysqli=mysqlnd --with-mysql=mysqlnd --with-openssl --with-freetype=/usr/local/freetype/ --enable-ftp --enable-gd-native-ttf --enable-gd-jis-conv
#make
#make install
2> 修改配置文件的权限
#vi /server/app/services/etc/php-fpm.conf
listen = /tmp/php-fcgi.sock (使用sock形式通信)
listen.owner = nobody
listen.group = nobody
listen.mode = 0666 (对应 /tmp/php-fcgi.sock 文件的权限,如果不开启,页面访问会失败)
3>在网页中查看 phpinfo() 页面
阅读(2278) | 评论(0) | 转发(0) |