【centos】php5.4升级到php5.6

前端之家收集整理的这篇文章主要介绍了【centos】php5.4升级到php5.6前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。

引用

centos7 升级 PHP 5.4 -> PHP5.6
标签: centosPHPPHP5
2017-04-05 17:34 186人阅读 评论(0) 收藏 举报
 分类PHP30)  
centos7 自带PHP5.4升级PHP5.6方法: 
https://webtatic.com/packages/PHP56/

CentOS/RHEL 7.x:

rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm
CentOS/RHEL 6.x:

rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-6.noarch.rpm
rpm -Uvh https://mirror.webtatic.com/yum/el6/latest.rpm后执行下面的:
3.执行下面的命令删除PHP  
yum remove PHP-common  
然后像安装那样问你是否继续的,输入yes即可  

接着继续安装:

yum install PHP56w-fpm PHP56w-opcache

当然,请顺便安装必要的扩展:
yum install -y PHP56w PHP56w-opcache PHP56w-xml PHP56w-mcrypt PHP56w-gd PHP56w-devel PHP56w-MysqL PHP56w-intl PHP56w-mbstring

好了,假如你像我一样还有postgresql的话,那么也顺便安装:

yum install PHP56w-pgsql


执行完毕之后,重启PHP-fpmNginx

systemctl restart PHP-fpm Nginx

猜你在找的CentOS相关文章