美文网首页
centos 如何通过 yum 安装 php72 ?

centos 如何通过 yum 安装 php72 ?

作者: AnneSan | 来源:发表于2019-03-28 16:14 被阅读0次

    参考文档:

    https://newsn.net/say/centos-php72-yum.html#comments

    清理冲突的php:

    yum -y remove php*

    方法一:

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

    方法二:

    yuminstallepel-release -yrpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm


    安装php72w及其它相关扩展:

    方法一(基本):

    yum -yinstallphp72w php72w-cli php72w-fpm php72w-common php72w-devel

    方法二(豪华版):

    yum -yinstallphp72w php72w-cli php72w-fpm php72w-common php72w-devel php72w-embedded php72w-gd php72w-mbstring php72w-mysqlnd php72w-opcache php72w-pdo php72w-xml

    php-fpm相关服务命令:

    systemctlenablephp-fpm.service

    systemctl start php-fpm.service

    systemctl stop php-fpm.service

    systemctl restart php-fpm.service

    相关文章

      网友评论

          本文标题:centos 如何通过 yum 安装 php72 ?

          本文链接:https://www.haomeiwen.com/subject/ztnqbqtx.html