Cyberblack.net

Cyberblack Official Site

1.ECCUBE Environment Construction - PHP

PHPのインストール手順

1.epelリポジトリの設定

# yum -y install epel-release
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * epel: nrt.edge.kernel.org
Package epel-release-7-12.noarch already installed and latest version
Nothing to do
# rpm -ivh http://rpms.famillecollet.com/enterprise/remi-release-7.rpm
Retrieving http://rpms.famillecollet.com/enterprise/remi-release-7.rpm
warning: /var/tmp/rpm-tmp.X8785e: Header V4 DSA/SHA1 Signature, key ID 00f97f56: NOKEY
Preparing...                          ################################# [100%]
Updating / installing...
   1:remi-release-7.7-2.el7.remi      ################################# [100%]

2.phpのインストール

# yum -y install --enablerepo=epel,remi-php72 php php-mbstring php-pear php-fpm php-mcrypt php-mysql php-intl php-zip php-pecl-apc
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * epel: nrt.edge.kernel.org
 * remi-php72: ftp.riken.jp
 * remi-safe: ftp.riken.jp
remi-php72                                               | 3.0 kB     00:00
remi-safe                                                | 3.0 kB     00:00
(1/2): remi-php72/primary_db                               | 234 kB   00:00
(2/2): remi-safe/primary_db                                | 1.7 MB   00:00
Package php-mcrypt is obsoleted by php-pecl-mcrypt, trying to install php-pecl-mcrypt-1.0.3-1.el7.remi.7.2.x86_64 instead
Package php-mysql is obsoleted by php-mysqlnd, trying to install php-mysqlnd-7.2.29-1.el7.remi.x86_64 instead
Resolving Dependencies
--> Running transaction check
---> Package php.x86_64 0:7.2.29-1.el7.remi will be installed
--> Processing Dependency: php-cli(x86-64) = 7.2.29-1.el7.remi for package: php-7.2.29-1.el7.remi.x86_64
--> Processing Dependency: php-common(x86-64) = 7.2.29-1.el7.remi for package: php-7.2.29-1.el7.remi.x86_64
--> Processing Dependency: libargon2.so.0()(64bit) for package: php-7.2.29-1.el7.remi.x86_64
---> Package php-fpm.x86_64 0:7.2.29-1.el7.remi will be installed
---> Package php-intl.x86_64 0:7.2.29-1.el7.remi will be installed
--> Processing Dependency: libicudata.so.62()(64bit) for package: php-intl-7.2.29-1.el7.remi.x86_64
--> Processing Dependency: libicui18n.so.62()(64bit) for package: php-intl-7.2.29-1.el7.remi.x86_64
--> Processing Dependency: libicuio.so.62()(64bit) for package: php-intl-7.2.29-1.el7.remi.x86_64
--> Processing Dependency: libicuuc.so.62()(64bit) for package: php-intl-7.2.29-1.el7.remi.x86_64
---> Package php-mbstring.x86_64 0:7.2.29-1.el7.remi will be installed
--> Processing Dependency: libonig.so.5()(64bit) for package: php-mbstring-7.2.29-1.el7.remi.x86_64
---> Package php-mysqlnd.x86_64 0:7.2.29-1.el7.remi will be installed
--> Processing Dependency: php-pdo(x86-64) = 7.2.29-1.el7.remi for package: php-mysqlnd-7.2.29-1.el7.remi.x86_64
---> Package php-pear.noarch 1:1.10.10-7.el7.remi will be installed
--> Processing Dependency: php-composer(fedora/autoloader) for package: 1:php-pear-1.10.10-7.el7.remi.noarch
--> Processing Dependency: php-posix for package: 1:php-pear-1.10.10-7.el7.remi.noarch
--> Processing Dependency: php-xml for package: 1:php-pear-1.10.10-7.el7.remi.noarch
---> Package php-pecl-apcu-bc.x86_64 0:1.0.5-1.el7.remi.7.2 will be installed
--> Processing Dependency: php-pecl-apcu(x86-64) >= 5.1.2 for package: php-pecl-apcu-bc-1.0.5-1.el7.remi.7.2.x86_64
---> Package php-pecl-mcrypt.x86_64 0:1.0.3-1.el7.remi.7.2 will be installed
--> Processing Dependency: libmcrypt.so.4()(64bit) for package: php-pecl-mcrypt-1.0.3-1.el7.remi.7.2.x86_64
---> Package php-pecl-zip.x86_64 0:1.18.2-1.el7.remi.7.2 will be installed
--> Processing Dependency: libzip5(x86-64) >= 1.6.1 for package: php-pecl-zip-1.18.2-1.el7.remi.7.2.x86_64
--> Processing Dependency: libzip.so.5()(64bit) for package: php-pecl-zip-1.18.2-1.el7.remi.7.2.x86_64
--> Running transaction check
---> Package libargon2.x86_64 0:20161029-3.el7 will be installed
---> Package libicu62.x86_64 0:62.1-3.el7.remi will be installed
---> Package libmcrypt.x86_64 0:2.5.8-13.el7 will be installed
---> Package libzip5.x86_64 0:1.6.1-1.el7.remi will be installed
---> Package oniguruma5.x86_64 0:6.9.4-1.el7.remi will be installed
---> Package php-cli.x86_64 0:7.2.29-1.el7.remi will be installed
---> Package php-common.x86_64 0:7.2.29-1.el7.remi will be installed
--> Processing Dependency: php-json(x86-64) = 7.2.29-1.el7.remi for package: php-common-7.2.29-1.el7.remi.x86_64
---> Package php-fedora-autoloader.noarch 0:1.0.1-2.el7 will be installed
---> Package php-pdo.x86_64 0:7.2.29-1.el7.remi will be installed
---> Package php-pecl-apcu.x86_64 0:5.1.18-1.el7.remi.7.2 will be installed
---> Package php-process.x86_64 0:7.2.29-1.el7.remi will be installed
---> Package php-xml.x86_64 0:7.2.29-1.el7.remi will be installed
--> Processing Dependency: libxslt.so.1(LIBXML2_1.0.11)(64bit) for package: php-xml-7.2.29-1.el7.remi.x86_64
--> Processing Dependency: libxslt.so.1(LIBXML2_1.0.13)(64bit) for package: php-xml-7.2.29-1.el7.remi.x86_64
--> Processing Dependency: libxslt.so.1(LIBXML2_1.0.18)(64bit) for package: php-xml-7.2.29-1.el7.remi.x86_64
--> Processing Dependency: libxslt.so.1(LIBXML2_1.0.22)(64bit) for package: php-xml-7.2.29-1.el7.remi.x86_64
--> Processing Dependency: libxslt.so.1(LIBXML2_1.0.24)(64bit) for package: php-xml-7.2.29-1.el7.remi.x86_64
--> Processing Dependency: libexslt.so.0()(64bit) for package: php-xml-7.2.29-1.el7.remi.x86_64
--> Processing Dependency: libxslt.so.1()(64bit) for package: php-xml-7.2.29-1.el7.remi.x86_64
--> Running transaction check
---> Package libxslt.x86_64 0:1.1.28-5.el7 will be installed
---> Package php-json.x86_64 0:7.2.29-1.el7.remi will be installed
--> Finished Dependency Resolution

Dependencies Resolved

================================================================================
 Package                 Arch     Version                    Repository    Size
================================================================================
Installing:
 php                     x86_64   7.2.29-1.el7.remi          remi-php72   3.2 M
 php-fpm                 x86_64   7.2.29-1.el7.remi          remi-php72   1.7 M
 php-intl                x86_64   7.2.29-1.el7.remi          remi-php72   223 k
 php-mbstring            x86_64   7.2.29-1.el7.remi          remi-php72   496 k
 php-mysqlnd             x86_64   7.2.29-1.el7.remi          remi-php72   237 k
 php-pear                noarch   1:1.10.10-7.el7.remi       remi-php72   361 k
 php-pecl-apcu-bc        x86_64   1.0.5-1.el7.remi.7.2       remi-php72    18 k
 php-pecl-mcrypt         x86_64   1.0.3-1.el7.remi.7.2       remi-php72    30 k
 php-pecl-zip            x86_64   1.18.2-1.el7.remi.7.2      remi-php72    57 k
Installing for dependencies:
 libargon2               x86_64   20161029-3.el7             epel          23 k
 libicu62                x86_64   62.1-3.el7.remi            remi-safe    8.8 M
 libmcrypt               x86_64   2.5.8-13.el7               epel          99 k
 libxslt                 x86_64   1.1.28-5.el7               base         242 k
 libzip5                 x86_64   1.6.1-1.el7.remi           remi-safe     57 k
 oniguruma5              x86_64   6.9.4-1.el7.remi           remi-safe    197 k
 php-cli                 x86_64   7.2.29-1.el7.remi          remi-php72   4.8 M
 php-common              x86_64   7.2.29-1.el7.remi          remi-php72   1.1 M
 php-fedora-autoloader   noarch   1.0.1-2.el7                epel          11 k
 php-json                x86_64   7.2.29-1.el7.remi          remi-php72    67 k
 php-pdo                 x86_64   7.2.29-1.el7.remi          remi-php72   128 k
 php-pecl-apcu           x86_64   5.1.18-1.el7.remi.7.2      remi-php72    75 k
 php-process             x86_64   7.2.29-1.el7.remi          remi-php72    84 k
 php-xml                 x86_64   7.2.29-1.el7.remi          remi-php72   209 k

Transaction Summary
================================================================================
Install  9 Packages (+14 Dependent packages)

Total download size: 22 M
Installed size: 82 M
Downloading packages:
(1/23): libargon2-20161029-3.el7.x86_64.rpm                |  23 kB   00:00
(2/23): libmcrypt-2.5.8-13.el7.x86_64.rpm                  |  99 kB   00:00
warning: /var/cache/yum/x86_64/7/remi-safe/packages/libzip5-1.6.1-1.el7.remi.x86_64.rpm: Header V4 DSA/SHA1 Signature, key ID 00f97f56: NOKEY
Public key for libzip5-1.6.1-1.el7.remi.x86_64.rpm is not installed
(3/23): libzip5-1.6.1-1.el7.remi.x86_64.rpm                |  57 kB   00:00
(4/23): oniguruma5-6.9.4-1.el7.remi.x86_64.rpm             | 197 kB   00:00
Public key for php-7.2.29-1.el7.remi.x86_64.rpm is not installed MB   --:-- ETA
(5/23): php-7.2.29-1.el7.remi.x86_64.rpm                   | 3.2 MB   00:00
(6/23): php-fedora-autoloader-1.0.1-2.el7.noarch.rpm       |  11 kB   00:00
(7/23): libicu62-62.1-3.el7.remi.x86_64.rpm                | 8.8 MB   00:00
(8/23): php-cli-7.2.29-1.el7.remi.x86_64.rpm               | 4.8 MB   00:00
(9/23): php-common-7.2.29-1.el7.remi.x86_64.rpm            | 1.1 MB   00:00
(10/23): php-fpm-7.2.29-1.el7.remi.x86_64.rpm              | 1.7 MB   00:00
(11/23): php-json-7.2.29-1.el7.remi.x86_64.rpm             |  67 kB   00:00
(12/23): php-intl-7.2.29-1.el7.remi.x86_64.rpm             | 223 kB   00:00
(13/23): php-mbstring-7.2.29-1.el7.remi.x86_64.rpm         | 496 kB   00:00
(14/23): php-mysqlnd-7.2.29-1.el7.remi.x86_64.rpm          | 237 kB   00:00
(15/23): php-pdo-7.2.29-1.el7.remi.x86_64.rpm              | 128 kB   00:00
(16/23): php-pear-1.10.10-7.el7.remi.noarch.rpm            | 361 kB   00:00
(17/23): php-pecl-apcu-5.1.18-1.el7.remi.7.2.x86_64.rpm    |  75 kB   00:00
(18/23): php-pecl-apcu-bc-1.0.5-1.el7.remi.7.2.x86_64.rpm  |  18 kB   00:00
(19/23): php-pecl-mcrypt-1.0.3-1.el7.remi.7.2.x86_64.rpm   |  30 kB   00:00
(20/23): php-pecl-zip-1.18.2-1.el7.remi.7.2.x86_64.rpm     |  57 kB   00:00
(21/23): php-process-7.2.29-1.el7.remi.x86_64.rpm          |  84 kB   00:00
(22/23): php-xml-7.2.29-1.el7.remi.x86_64.rpm              | 209 kB   00:00
(23/23): libxslt-1.1.28-5.el7.x86_64.rpm                   | 242 kB   00:02
--------------------------------------------------------------------------------
Total                                              9.5 MB/s |  22 MB  00:02
Retrieving key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-remi
Importing GPG key 0x00F97F56:
 Userid     : "Remi Collet "
 Fingerprint: 1ee0 4cce 88a4 ae4a a29a 5df5 004e 6f47 00f9 7f56
 Package    : remi-release-7.7-2.el7.remi.noarch (installed)
 From       : /etc/pki/rpm-gpg/RPM-GPG-KEY-remi
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
Warning: RPMDB altered outside of yum.
  Installing : libargon2-20161029-3.el7.x86_64                             1/23
  Installing : php-common-7.2.29-1.el7.remi.x86_64                         2/23
  Installing : php-json-7.2.29-1.el7.remi.x86_64                           3/23
  Installing : php-cli-7.2.29-1.el7.remi.x86_64                            4/23
  Installing : php-fedora-autoloader-1.0.1-2.el7.noarch                    5/23
  Installing : php-process-7.2.29-1.el7.remi.x86_64                        6/23
  Installing : php-pecl-apcu-5.1.18-1.el7.remi.7.2.x86_64                  7/23
  Installing : php-pdo-7.2.29-1.el7.remi.x86_64                            8/23
  Installing : libxslt-1.1.28-5.el7.x86_64                                 9/23
  Installing : php-xml-7.2.29-1.el7.remi.x86_64                           10/23
  Installing : libzip5-1.6.1-1.el7.remi.x86_64                            11/23
  Installing : libicu62-62.1-3.el7.remi.x86_64                            12/23
  Installing : libmcrypt-2.5.8-13.el7.x86_64                              13/23
  Installing : oniguruma5-6.9.4-1.el7.remi.x86_64                         14/23
  Installing : php-mbstring-7.2.29-1.el7.remi.x86_64                      15/23
  Installing : php-pecl-mcrypt-1.0.3-1.el7.remi.7.2.x86_64                16/23
  Installing : php-intl-7.2.29-1.el7.remi.x86_64                          17/23
  Installing : php-pecl-zip-1.18.2-1.el7.remi.7.2.x86_64                  18/23
  Installing : 1:php-pear-1.10.10-7.el7.remi.noarch                       19/23
  Installing : php-mysqlnd-7.2.29-1.el7.remi.x86_64                       20/23
  Installing : php-pecl-apcu-bc-1.0.5-1.el7.remi.7.2.x86_64               21/23
  Installing : php-7.2.29-1.el7.remi.x86_64                               22/23
  Installing : php-fpm-7.2.29-1.el7.remi.x86_64                           23/23
  Verifying  : 1:php-pear-1.10.10-7.el7.remi.noarch                        1/23
  Verifying  : oniguruma5-6.9.4-1.el7.remi.x86_64                          2/23
  Verifying  : libargon2-20161029-3.el7.x86_64                             3/23
  Verifying  : libmcrypt-2.5.8-13.el7.x86_64                               4/23
  Verifying  : libicu62-62.1-3.el7.remi.x86_64                             5/23
  Verifying  : php-xml-7.2.29-1.el7.remi.x86_64                            6/23
  Verifying  : libzip5-1.6.1-1.el7.remi.x86_64                             7/23
  Verifying  : php-cli-7.2.29-1.el7.remi.x86_64                            8/23
  Verifying  : php-fpm-7.2.29-1.el7.remi.x86_64                            9/23
  Verifying  : php-intl-7.2.29-1.el7.remi.x86_64                          10/23
  Verifying  : php-pecl-apcu-bc-1.0.5-1.el7.remi.7.2.x86_64               11/23
  Verifying  : php-mbstring-7.2.29-1.el7.remi.x86_64                      12/23
  Verifying  : libxslt-1.1.28-5.el7.x86_64                                13/23
  Verifying  : php-pecl-mcrypt-1.0.3-1.el7.remi.7.2.x86_64                14/23
  Verifying  : php-json-7.2.29-1.el7.remi.x86_64                          15/23
  Verifying  : php-fedora-autoloader-1.0.1-2.el7.noarch                   16/23
  Verifying  : php-common-7.2.29-1.el7.remi.x86_64                        17/23
  Verifying  : php-process-7.2.29-1.el7.remi.x86_64                       18/23
  Verifying  : php-pecl-apcu-5.1.18-1.el7.remi.7.2.x86_64                 19/23
  Verifying  : php-pecl-zip-1.18.2-1.el7.remi.7.2.x86_64                  20/23
  Verifying  : php-mysqlnd-7.2.29-1.el7.remi.x86_64                       21/23
  Verifying  : php-pdo-7.2.29-1.el7.remi.x86_64                           22/23
  Verifying  : php-7.2.29-1.el7.remi.x86_64                               23/23

Installed:
  php.x86_64 0:7.2.29-1.el7.remi
  php-fpm.x86_64 0:7.2.29-1.el7.remi
  php-intl.x86_64 0:7.2.29-1.el7.remi
  php-mbstring.x86_64 0:7.2.29-1.el7.remi
  php-mysqlnd.x86_64 0:7.2.29-1.el7.remi
  php-pear.noarch 1:1.10.10-7.el7.remi
  php-pecl-apcu-bc.x86_64 0:1.0.5-1.el7.remi.7.2
  php-pecl-mcrypt.x86_64 0:1.0.3-1.el7.remi.7.2
  php-pecl-zip.x86_64 0:1.18.2-1.el7.remi.7.2

Dependency Installed:
  libargon2.x86_64 0:20161029-3.el7
  libicu62.x86_64 0:62.1-3.el7.remi
  libmcrypt.x86_64 0:2.5.8-13.el7
  libxslt.x86_64 0:1.1.28-5.el7
  libzip5.x86_64 0:1.6.1-1.el7.remi
  oniguruma5.x86_64 0:6.9.4-1.el7.remi
  php-cli.x86_64 0:7.2.29-1.el7.remi
  php-common.x86_64 0:7.2.29-1.el7.remi
  php-fedora-autoloader.noarch 0:1.0.1-2.el7
  php-json.x86_64 0:7.2.29-1.el7.remi
  php-pdo.x86_64 0:7.2.29-1.el7.remi
  php-pecl-apcu.x86_64 0:5.1.18-1.el7.remi.7.2
  php-process.x86_64 0:7.2.29-1.el7.remi
  php-xml.x86_64 0:7.2.29-1.el7.remi

Complete!

3.phpのバージョン確認

# php -v
PHP 7.2.29 (cli) (built: Mar 17 2020 11:36:18) ( NTS )
Copyright (c) 1997-2018 The PHP Group
Zend Engine v3.2.0, Copyright (c) 1998-2018 Zend Technologies
Last updated on 20 Apr 2020
Published on 17 Oct 2017