更新后的 Opcache PHP7 不显示在 phpinfo 中

Opcache after update PHP7 don't show in phpinfo

我将 php 从 7.0.31 更新到 7.2.8。然后安装了php-fpm和nginx。现在我有下一个安装包:

php-bcmath.x86_64                  5.4.16-45.el7                     @base
php-cli.x86_64                     5.4.16-45.el7                     @base
php-common.x86_64                  5.4.16-45.el7                     @base
php-fedora-autoloader.noarch       1.0.0-1.el7                       @epel
php-gd.x86_64                      5.4.16-45.el7                     @base
php-mbstring.x86_64                5.4.16-45.el7                     @base
php-mcrypt.x86_64                  5.4.16-7.el7                      @epel
php-mysql.x86_64                   5.4.16-45.el7                     @base
php-pdo.x86_64                     5.4.16-45.el7                     @base
php-pear.noarch                    1:1.9.4-21.el7                    @base
php-pecl-igbinary.x86_64           1.2.1-1.el7                       @epel
php-pecl-memcached.x86_64          2.2.0-1.el7                       @epel
php-pecl-msgpack.x86_64            0.5.5-5.el7                       @epel
php-pecl-zendopcache.x86_64        7.0.5-2.el7                       @epel
php-php-gettext.noarch             1.0.12-1.el7                      @epel
php-process.x86_64                 5.4.16-45.el7                     @base
php-tcpdf.noarch                   6.2.13-1.el7                      @epel
php-tcpdf-dejavu-sans-fonts.noarch 6.2.13-1.el7                      @epel
php-tidy.x86_64                    5.4.16-7.el7                      @epel
php-xml.x86_64                     5.4.16-45.el7                     @base
php72-php-cli.x86_64               7.2.8-1.el7.remi                  @remi-safe
php72-php-common.x86_64            7.2.8-1.el7.remi                  @remi-safe
php72-php-fpm.x86_64               7.2.8-1.el7.remi                  @remi-safe
php72-php-json.x86_64              7.2.8-1.el7.remi                  @remi-safe
php72-php-mysqlnd.x86_64           7.2.8-1.el7.remi                  @remi-safe
php72-php-opcache.x86_64           7.2.8-1.el7.remi                  @remi-safe
php72-php-pdo.x86_64               7.2.8-1.el7.remi                  @remi-safe
php72-php-pear.noarch              1:1.10.5-6.el7.remi               @remi-safe
php72-php-pecl-igbinary.x86_64     2.0.7-1.el7.remi                  @remi-safe
php72-php-pecl-memcached.x86_64    3.0.4-2.el7.remi                  @remi-safe
php72-php-pecl-msgpack.x86_64      2.0.2-4.el7.remi                  @remi-safe
php72-php-process.x86_64           7.2.8-1.el7.remi                  @remi-safe
php72-php-xml.x86_64               7.2.8-1.el7.remi                  @remi-safe
php72-runtime.x86_64               1.0-1.el7.remi                    @remi-safe

我的网站现在由 apache 运行。 Nginx + php-fpm 我只尝试设置。当我从 apache 看到 phpinfo 时,我找到了有关 opcache 的信息:

Zend Engine v3.2.0, Copyright (c) 1998-2018 Zend Technologies
    with Zend OPcache v7.2.8, Copyright (c) 1999-2018, by Zend Technologies

当我看到 php来自 nginx 的信息时,我没有看到关于 opcache 的信息:

Zend Engine v3.2.0, Copyright (c) 1998-2018 Zend Technologies 

在来自 nginx 的 phpinfo 中,这些行与 apache 不同。

Configuration File (php.ini) Path 
/etc/opt/remi/php72 
Loaded Configuration File 
/etc/opt/remi/php72/php.ini 
Scan this dir for additional .ini files 
/etc/opt/remi/php72/php.d 

但 php.ini 个文件相同并且具有 opcache.so.

的路径

我刚刚删除了php72-php-fpm,然后重新安装。 yum 安装 php72-php-fpm.x86_64 php72-php-devel.x86_64 php72-php-gd.x86_64 php72-php-mysqlnd.x86_64 php72-php-mbstring.x86_64 php72-php-pecl-igbinary.x86_64 php72-php-opcache.x86_64 php72-php-pecl -memcached.x86_64 php72-php-pecl-mcrypt.x86_64 php72-php-pecl-zip.x86_64 php72-php-pecl-msgpack.x86_64

并在 /etc/opt/remi/php72/php.d 中对 ini 文件进行了设置 memcached.ini 等等