OpenPNEと抹茶をphp-5.6.40で動作させる。

スポンサーリンク
Linux
スポンサーリンク

以前、抹茶を動作させるためにphp-5.6をインストールしたが、mysqlモジュールが正しく組み込まれなかったと思われる。
複数のphp-fpmを動作させているので、まとめられないかと思い再度トライした。なお、OpenPNEでも動作させるためGDライブラリを組み込んだ。

スポンサーリンク

icu4c-56_2をインストールする

php-5.6.40のintl拡張のmakeで、インストールされたICUとg++でビルドしているために、以下の様なエラーとなる。

/usr/local/src/php/php-5.6.40/ext/intl/intl_convertcpp.cpp:64:18: エラー: request for member ‘isEmpty’ in ‘from’, which is of non-class type ‘const int’
   64 |         if (from.isEmpty()) {
      |                  ^~~~~~~
/usr/local/src/php/php-5.6.40/ext/intl/intl_convertcpp.cpp:74:38: エラー: request for member ‘getBuffer’ in ‘from’, which is of non-class type ‘const int’
   74 |         const UChar *utf16buf = from.getBuffer();
      |                                      ^~~~~~~~~
/usr/local/src/php/php-5.6.40/ext/intl/intl_convertcpp.cpp:76:76: エラー: request for member ‘length’ in ‘from’, which is of non-class type ‘const int’
   76 |         u_strToUTF8WithSub(*res, capacity - 1, &actual_len, utf16buf, from.length(),
      |                                                                            ^~~~~~
make: *** [Makefile:948: ext/intl/intl_convertcpp.lo] エラー 1
#

よって、php-5.6.40に対応したICU(International Components for Unicode)をインストールする。

ソースファイルを取得する

# wget https://github.com/unicode-org/icu/releases/download/release-56-2/icu4c-56_2-src.tgz
--2026-04-28 15:34:08--  https://github.com/unicode-org/icu/releases/download/release-56-2/icu4c-56_2-src.tgz
github.com (github.com) をDNSに問いあわせています... 20.27.177.113
github.com (github.com)|20.27.177.113|:443 に接続しています... 接続しました。
HTTP による接続要求を送信しました、応答を待っています... 302 Found
場所: https://release-assets.githubusercontent.com/github-production-release-asset/49244766/82be4900-5c92-11e9-9f7f-d29a8950e5f2?sp=r&sv=2018-11-09&sr=b&spr=https&se=2026-04-28T07%3A28%3A46Z&rscd=attachment%3B+filename%3Dicu4c-56_2-src.tgz&rsct=application%2Foctet-stream&skoid=96c2d410-5711-43a1-aedd-ab1947aa7ab0&sktid=398a6654-997b-47e9-b12b-9515b896b4de&skt=2026-04-28T06%3A27%3A49Z&ske=2026-04-28T07%3A28%3A46Z&sks=b&skv=2018-11-09&sig=OwSEmsUAp6RQaPdIZ%2FYeiU%2BTmlaLSw7KwaugHvkrbVc%3D&jwt=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmVsZWFzZS1hc3NldHMuZ2l0aHVidXNlcmNvbnRlbnQuY29tIiwia2V5Ijoia2V5MSIsImV4cCI6MTc3NzM1OTg0OSwibmJmIjoxNzc3MzU4MDQ5LCJwYXRoIjoicmVsZWFzZWFzc2V0cHJvZHVjdGlvbi5ibG9iLmNvcmUud2luZG93cy5uZXQifQ.JPsHf2fRPmBH4odVKY8D3Fja-2Nd0l4nOB3ZNwYFv-I&response-content-disposition=attachment%3B%20filename%3Dicu4c-56_2-src.tgz&response-content-type=application%2Foctet-stream [続く]
--2026-04-28 15:34:09--  https://release-assets.githubusercontent.com/github-production-release-asset/49244766/82be4900-5c92-11e9-9f7f-d29a8950e5f2?sp=r&sv=2018-11-09&sr=b&spr=https&se=2026-04-28T07%3A28%3A46Z&rscd=attachment%3B+filename%3Dicu4c-56_2-src.tgz&rsct=application%2Foctet-stream&skoid=96c2d410-5711-43a1-aedd-ab1947aa7ab0&sktid=398a6654-997b-47e9-b12b-9515b896b4de&skt=2026-04-28T06%3A27%3A49Z&ske=2026-04-28T07%3A28%3A46Z&sks=b&skv=2018-11-09&sig=OwSEmsUAp6RQaPdIZ%2FYeiU%2BTmlaLSw7KwaugHvkrbVc%3D&jwt=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmVsZWFzZS1hc3NldHMuZ2l0aHVidXNlcmNvbnRlbnQuY29tIiwia2V5Ijoia2V5MSIsImV4cCI6MTc3NzM1OTg0OSwibmJmIjoxNzc3MzU4MDQ5LCJwYXRoIjoicmVsZWFzZWFzc2V0cHJvZHVjdGlvbi5ibG9iLmNvcmUud2luZG93cy5uZXQifQ.JPsHf2fRPmBH4odVKY8D3Fja-2Nd0l4nOB3ZNwYFv-I&response-content-disposition=attachment%3B%20filename%3Dicu4c-56_2-src.tgz&response-content-type=application%2Foctet-stream
release-assets.githubusercontent.com (release-assets.githubusercontent.com) をDNSに問いあわせています... 185.199.109.133, 185.199.111.133, 185.199.110.133, ...
release-assets.githubusercontent.com (release-assets.githubusercontent.com)|185.199.109.133|:443 に接続しています... 接続しました。
HTTP による接続要求を送信しました、応答を待っています... 200 OK
長さ: 22121451 (21M) [application/octet-stream]
`icu4c-56_2-src.tgz' に保存中

icu4c-56_2-src.tgz                                100%[===============>]  21.10M  10.3MB/s 時間 2.0s     

2026-04-28 15:34:12 (10.3 MB/s) - `icu4c-56_2-src.tgz' へ保存完了 [22121451/22121451]
# 
[

 

ソースファイルを展開する

 

# tar xvfz icu4c-56_2-src.tgz
icu/
icu/as_is/
icu/as_is/os400/
icu/as_is/os400/bldiculd.sh
icu/as_is/os400/cxxfilt.cpp
icu/as_is/os400/convertConfigure.sed
    :
icu/source/aclocal.m4
icu/source/mkinstalldirs
icu/source/install-sh
icu/source/configure.ac
icu/icu4c.css
#

 

configureを実行する

 

# cd icu/source/
#
# export CXXFLAGS="--std=c++0x"
#
# ./configure --prefix=/usr/local/icu56
checking for ICU version numbers... release 56.2, library 56.2, unicode version 8.0
checking build system type... aarch64-unknown-linux-gnu
checking host system type... aarch64-unknown-linux-gnu
checking whether to build debug libraries... no
checking whether to build release libraries... yes
     :
config.status: creating samples/Makefile
config.status: creating samples/date/Makefile
config.status: creating samples/cal/Makefile
config.status: creating samples/layout/Makefile

ICU for C/C++ 56.2 is ready to be built.
=== Important Notes: ===
Data Packaging: library
 This means: ICU data will be linked with ICU. A shared data library will be built.
 To locate data: ICU will use the linked data library. If linked with the stub library located in stubdata/, the application can use udata_setCommonData() or set a data path to override.
Building ICU: Use a GNU make such as /usr/bin/gmake to build ICU.
checking the version of "/usr/bin/gmake"... 4.3 (we wanted at least 3.80)
ok
#

 

makeする

 

# make
rebuilding config/icucross.mk
rebuilding config/icucross.inc
cd ./config; \
        make -f pkgdataMakefile
make[1]: ディレクトリ '/usr/local/src/icu/source/config' に入ります
rm -rf pkgdata.inc
make[1]: ディレクトリ '/usr/local/src/icu/source/config' から出ます
rm -rf config/icu-config
/usr/bin/install -c ./config/icu-config-top config/icu-config
chmod u+w config/icu-config
LC_ALL=C sed -f ./config/make2sh.sed < ./config/Makefile.inc | grep -v '#M#' | uniq >> config/icu-config
LC_ALL=C sed -f ./config/make2sh.sed < ./config/mh-linux | grep -v '#M#' | uniq >> config/icu-config
cat ./config/icu-config-bottom >> config/icu-config
chmod u-w config/icu-config
config/icu-uc.pc updated.
config/icu-i18n.pc updated.
config/icu-le.pc updated.
config/icu-lx.pc updated.
config/icu-io.pc updated.
Note: rebuild with "make VERBOSE=1 " to show all compiler parameters.
/bin/sh ./mkinstalldirs lib
mkdir lib
/bin/sh ./mkinstalldirs bin
mkdir bin
make[0]: Making `all' in `stubdata'
make[1]: ディレクトリ '/usr/local/src/icu/source/stubdata' に入ります
   (deps)        stubdata.c
   gcc   ...  stubdata.c
gcc -O2 -std=c99 -Wall -pedantic -Wshadow -Wpointer-arith -Wmissing-prototypes -Wwrite-strings    -nodefaultlibs -nostdlib -shared -Wl,-Bsymbolic -Wl,-soname -Wl,libicudata.so.56 -o libicudata.so.56.2 stubdata.o
rm -f libicudata.so.56 && ln -s libicudata.so.56.2 libicudata.so.56
rm -f libicudata.so && ln -s libicudata.so.56.2 libicudata.so
make[1]: ディレクトリ '/usr/local/src/icu/source/stubdata' から出ます
make[0]: Making `all' in `common'
make[1]: ディレクトリ '/usr/local/src/icu/source/common' に入ります
     :
make[2]: ディレクトリ '/usr/local/src/icu/source/samples' から出ます
make[1]: ディレクトリ '/usr/local/src/icu/source/samples' から出ます
make[0]: Making `all' in `test'
make[1]: ディレクトリ '/usr/local/src/icu/source/test' に入ります
make[1]: 'all' に対して行うべき事はありません.
make[1]: ディレクトリ '/usr/local/src/icu/source/test' から出ます
make[1]: ディレクトリ '/usr/local/src/icu/source' に入ります
Note: rebuild with "make VERBOSE=1 all-local" to show all compiler parameters.
make[1]: ディレクトリ '/usr/local/src/icu/source' から出ます
#

 

インストールする

/usr/local/icu56にインストールする。

# make install
make[0]: Making `install' in `stubdata'
make[1]: ディレクトリ '/usr/local/src/icu/source/stubdata' に入ります
/bin/sh ../mkinstalldirs /usr/local/icu56/lib
mkdir /usr/local/icu56
mkdir /usr/local/icu56/lib
/usr/bin/install -c libicudata.so.56.2 /usr/local/icu56/lib
cd /usr/local/icu56/lib && rm -f libicudata.so && ln -s libicudata.so.56.2 libicudata.so
cd /usr/local/icu56/lib && rm -f libicudata.so.56 && ln -s libicudata.so.56.2 libicudata.so.56
     :
/usr/bin/install -c -m 644 ./../license.html /usr/local/icu56/share/icu/56.2/license.html
/usr/bin/install -c ./config/icu-config /usr/local/icu56/bin/icu-config
/usr/bin/install -c -m 644 ./config/Makefile.inc /usr/local/icu56/lib/icu/56.2/Makefile.inc
/usr/bin/install -c -m 644 ./config/pkgdata.inc /usr/local/icu56/lib/icu/56.2/pkgdata.inc
cd /usr/local/icu56/lib/icu/56.2/..; \
    rm -f current && ln -s 56.2 current; \
    rm -f Makefile.inc && ln -s current/Makefile.inc Makefile.inc; \
    rm -f pkgdata.inc && ln -s current/pkgdata.inc pkgdata.inc
/bin/sh ./mkinstalldirs /usr/local/icu56/share/man/man1
/usr/bin/install -c -m 644 config/icu-config.1 /usr/local/icu56/share/man/man1
#

 

php-5.6.40をインストールする

 

ソースファイルを取得する

以下のURLからソースファイルを取得する。
https://downloads.mysql.com/archives/community/

 

ソースファイルを展開する

# tar xvfz php-5.6.40.tar.gz
php-5.6.40/
php-5.6.40/php.ini-production
php-5.6.40/.gdbinit
php-5.6.40/Makefile.gcov
php-5.6.40/acinclude.m4
php-5.6.40/.editorconfig
php-5.6.40/netware/
php-5.6.40/netware/sendmail_nw.h
php-5.6.40/netware/start.c
php-5.6.40/TSRM/
php-5.6.40/TSRM/acinclude.m4
     :
php-5.6.40/pear/install-pear.txt
php-5.6.40/pear/install-pear-nozlib.phar
php-5.6.40/pear/fetch.php
php-5.6.40/pear/Makefile.frag
php-5.6.40/README.SUBMITTING_PATCH
#

 

パッチを取得する

利用するか判らないが、SSLを組み込みたい。
以下のURLに対処法が記載されていた。patchを適用する必要が有る。
PHP5.6でOpenSSL-1.1.0に対応する

patchを適用する

# cd php-5.6.40
#
# patch -p1 < ../php-5.6_openssl.patch
patching file ext/openssl/openssl.c
patching file ext/openssl/tests/bug41033.phpt
patching file ext/openssl/tests/bug66501.phpt
patching file ext/openssl/tests/openssl_error_string_basic.phpt
patching file ext/openssl/tests/sni_server.phpt
patching file ext/openssl/xp_ssl.c
patching file ext/phar/util.c
#

 

aarch64のため修正

CPUタイプがaarch64のため、修正が必要である。

# cp Zend/zend_multiply.h Zend/zend_multiply.h_org 
# 
# vi Zend/zend_multiply.h
#
# diff -c Zend/zend_multiply.h_org Zend/zend_multiply.h
*** Zend/zend_multiply.h_org    2026-04-26 14:39:45.128996255 +0900
--- Zend/zend_multiply.h        2026-04-26 14:40:39.932876210 +0900
***************
*** 63,69 ****
                "smulh %1, %2, %3\n"                                    \
                "sub %1, %1, %0, asr #63\n"                             \
                        : "=X"(__tmpvar), "=X"(usedval)                 \
!                       : "X"(a), "X"(b));                              \
        if (usedval) (dval) = (double) (a) * (double) (b);              \
        else (lval) = __tmpvar;                                         \
  } while (0)
--- 63,69 ----
                "smulh %1, %2, %3\n"                                    \
                "sub %1, %1, %0, asr #63\n"                             \
                        : "=X"(__tmpvar), "=X"(usedval)                 \
!                       : "r"(a), "r"(b));                              \
        if (usedval) (dval) = (double) (a) * (double) (b);              \
        else (lval) = __tmpvar;                                         \
  } while (0)
#

 

configureを実行する

icuとOpenPNEで画像を利用して認証するためgdを有効化して、configureを実行する。

# export ac_cv_sizeof_off_t=8
# export ac_cv_type_off_t=yes
#
# ./configure \
--build=arm \
--prefix=/usr/local/php-5.6.40 \
--sysconfdir=/usr/local/php-5.6.40/etc/php \
--with-config-file-path=/usr/local/php-5.6.40/etc/php \
--with-config-file-scan-dir=/usr/local/pphp-5.6.40/etc/php/conf.d \
--with-xmlrpc \
--with-mysql=mysqlnd \
--with-mysqli=mysqlnd \
--with-pdo-mysql=mysqlnd \
--with-mysql-sock=/usr/local/mysql-5.6.51/data/mysql.sock \
--with-zlib \
--with-zlib-dir=/usr/lib \
--with-curl \
--with-gd=/usr \
--with-jpeg-dir=/usr \
--with-png-dir=/usr \
--with-gettext \
--with-xpm-dir=/usr \
--with-libxml-dir=usr \
--with-freetype-dir=/usr \
--with-fpm-user=nginx \
--with-fpm-group=nginx \
--with-bz2 \
--with-mhash \
--with-iconv=/usr/local \
--with-iconv-dir=/usr/local \
--with-libzip=/usr \
--with-readline \
--with-openssl=/usr/local/ssl-1.1.1 \
--with-openssl-dir=/usr/local/ssl-1.1.1 \
--with-gdbm=/usr \
--with-db4=/usr/local \
--with-pdo-pgsql=/user \
--with-pgsql=/usr \
--with-pear \
--with-system-ciphers \
--enable-ftp \
--enable-zip \
--enable-mysqlnd \
--enable-inline-optimization \
--enable-fpm \
--enable-xml \
--enable-gd-jis-conv \
--enable-mbstring \
--enable-mbregex \
--enable-json \
--enable-shared \
--enable-cli \
--enable-maintainer-zts \
--enable-bcmath \
--enable-calendar \
--enable-dba \
--enable-exif \
--enable-sysvshm \
--enable-sysvsem \
--enable-sysvmsg \
--enable-pcntl \
--enable-shmop \
--enable-soap \
--enable-sockets \
--enable-opcache=no \
--with-icu-dir=/usr/local/icu56 \
--enable-intl \
--disable-debug
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for a sed that does not truncate output... /usr/bin/sed
checking build system type... arm-unknown-none
checking host system type... arm-unknown-none
checking target system type... arm-unknown-none
checking for cc... cc
     :
creating libtool
appending configuration tag "CXX" to libtool
checking for ld used by g++... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking whether the g++ linker (/usr/bin/ld) supports shared libraries... no
checking for g++ option to produce PIC... -fPIC
checking if g++ PIC flag -fPIC works... yes
checking if g++ static flag -static works... no
checking if g++ supports -c -o file.o... yes
checking whether the g++ linker (/usr/bin/ld) supports shared libraries... no
checking dynamic linker characteristics... no
(cached) (cached) checking how to hardcode library paths into programs... immediate

Generating files
configure: creating ./config.status
creating main/internal_functions.c
creating main/internal_functions_cli.c
+--------------------------------------------------------------------+
| License:                                                           |
| This software is subject to the PHP License, available in this     |
| distribution in the file LICENSE.  By continuing this installation |
| process, you are bound by the terms of this license agreement.     |
| If you do not agree with the terms of this license, you must abort |
| the installation process at this point.                            |
+--------------------------------------------------------------------+

Thank you for using PHP.

config.status: creating php5.spec
config.status: creating main/build-defs.h
config.status: creating scripts/phpize
config.status: creating scripts/man1/phpize.1
config.status: creating scripts/php-config
config.status: creating scripts/man1/php-config.1
config.status: creating sapi/cli/php.1
config.status: creating sapi/fpm/php-fpm.conf
config.status: creating sapi/fpm/init.d.php-fpm
config.status: creating sapi/fpm/php-fpm.service
config.status: creating sapi/fpm/php-fpm.8
config.status: creating sapi/fpm/status.html
config.status: creating sapi/cgi/php-cgi.1
config.status: creating ext/phar/phar.1
config.status: creating ext/phar/phar.phar.1
config.status: creating main/php_config.h
config.status: executing default commands
#

 

makeする

 

# make
/bin/sh /usr/local/src/php/php-5.6.40/libtool --silent --preserve-dup-deps --mode=compile cc -Iext/date/lib -D HAVE_TIMELIB_CONFIG_H=1 -Iext/date/ -I/usr/local/src/php/php-5.6.40/ext/date/ -DPHP_ATOM_INC -I/usr/local/src/php/php-5.6.40/include -I/usr/local/src/php/php-5.6.40/main -I/usr/local/src/php/php-5.6.40 -I/usr/local/src/php/php-5.6.40/ext/date/lib -I/usr/local/src/php/php-5.6.40/ext/ereg/regex -I/usr/include/libxml2 -I/usr/local/ssl-1.1.1/include -I/usr/X11 -I/usr/include/freetype2 -I/usr/include/libpng16 -I/usr/include/harfbuzz -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/sysprof-4 -I/usr/local/include -I/usr/local/icu56/include -I/usr/local/src/php/php-5.6.40/ext/mbstring/oniguruma -I/usr/local/src/php/php-5.6.40/ext/mbstring/libmbfl -I/usr/local/src/php/php-5.6.40/ext/mbstring/libmbfl/mbfl -
     :
Generating phar.phar
PEAR package PHP_Archive not installed: generated phar will require PHP's phar extension be enabled.
directorygraphiterator.inc
directorytreeiterator.inc
pharcommand.inc
invertedregexiterator.inc
clicommand.inc
phar.inc

Build complete.
Don't forget to run 'make test'.
#

 

testする

 

[root@raspberrypi php-5.6.40]# make test

Build complete.
Don't forget to run 'make test'.

PHP Warning:  shell_exec() has been disabled for security reasons in /usr/local/src/php/php-5.6.40/run-tests.php on line 266
PHP Warning:  shell_exec() has been disabled for security reasons in /usr/local/src/php/php-5.6.40/run-tests.php on line 267
PHP Warning:  shell_exec() has been disabled for security reasons in /usr/local/src/php/php-5.6.40/run-tests.php on line 281

=====================================================================
PHP         : /usr/local/src/php/php-5.6.40/sapi/cli/php
CWD         : /usr/local/src/php/php-5.6.40
Extra dirs  :
VALGRIND    : Not used
=====================================================================
TIME START 2026-04-26 17:46:23
=====================================================================
PASS EXPECT [tests/run-test/test001.phpt]
PASS EXPECTF [tests/run-test/test002.phpt]
PASS EXPECTREGEX [tests/run-test/test003.phpt]
PASS INI section allows '=' [tests/run-test/test004.phpt]
PASS Error message handling (without ZendOptimizer) [tests/run-test/test005.phpt]
PASS Error messages are shown [tests/run-test/test006.phpt]
PASS dirname test [tests/run-test/test007.phpt]
SKIP Error message handling (with ZendOptimizer) [tests/run-test/test008.phpt] reason: Zend Optimizer is not loaded
PASS Error message handling (without ZendOptimizer) [tests/run-test/test008a.phpt]
PASS print_r(Object) [tests/run-test/test009.phpt]
PASS STDIN input [tests/run-test/test010.phpt]
PASS EXPECT_EXTERNAL [tests/run-test/test011.phpt]
PASS EXPECTF_EXTERNAL [tests/run-test/test012.phpt]
PASS EXPECTREGEX_EXTERNAL [tests/run-test/test013.phpt]
PASS Trivial "Hello World" test [tests/basic/001.phpt]
PASS Simple POST Method test [tests/basic/002.phpt]
PASS GET and POST Method combined [tests/basic/003.phpt]
PASS Two variables in POST data [tests/basic/004.phpt]
     :
SKIP FPM: Test IPv4 allowed clients [sapi/fpm/tests/005.phpt] reason: IPv6 not supported.
SKIP FPM: Test IPv6 allowed clients (bug #68428) [sapi/fpm/tests/006.phpt] reason: IPv6 not supported.
SKIP FPM: Test IPv6 all addresses and access_log (bug #68421) [sapi/fpm/tests/007.phpt] reason: IPv6 not supported.
FAIL FPM: Test multi pool (dynamic + ondemand + static) (bug #68423) [sapi/fpm/tests/008.phpt]
FAIL FPM: Test Unix Domain Socket [sapi/fpm/tests/009.phpt]
XFAIL FPM: Test status page [sapi/fpm/tests/010.phpt]   XFAIL REASON: randomly intermittently failing all the time in CI, with diff:
017+ active processes:     0
018+ total processes:      1
017- active processes:     1
018- total processes:      2
FAIL FPM: Test IPv4 all addresses (bug #68420) [sapi/fpm/tests/011.phpt]
FAIL FPM: Test reload configuration (bug #68442) [sapi/fpm/tests/012.phpt]
FAIL FPM: Test for log_level in fpm_unix_init_main #68381 [sapi/fpm/tests/013.phpt]
FAIL FPM: Test for pm.start_servers default calculation message being a notice and not a warning #68458 [sapi/fpm/tests/014.phpt]
XFAIL FPM: Test various messages on start, from master and childs [sapi/fpm/tests/015.phpt]   XFAIL REASON: randomly intermittently failing all the time in CI,
ERROR: unable to read what child say: Bad file descriptor (9)
catch_workers_output = yes seems not reliable
FAIL FPM: Test splited configuration and load order #68391 [sapi/fpm/tests/016.phpt]
FAIL FPM: Test fastcgi_finish_request function [sapi/fpm/tests/017.phpt]
FAIL FPM: Test global prefix [sapi/fpm/tests/019.phpt]
FAIL FPM: Test pool prefix [sapi/fpm/tests/020.phpt]
XFAIL FPM: Test Unix Domain Socket with Posix ACL [sapi/fpm/tests/021-uds-acl.phpt]   XFAIL REASON: Mark as XFAIL because --with-fpm-acl is not enabled in default build
FAIL FPM: HTTP_PROXY - CVE-2016-5385 [sapi/fpm/tests/022-cve-2016-5385.phpt]
SKIP FPM: Apparmor Test [sapi/fpm/tests/apparmor.phpt] reason: No apparmor support built in
=====================================================================
TIME END 2026-04-26 17:51:42

=====================================================================
TEST RESULT SUMMARY
---------------------------------------------------------------------
Exts skipped    :   77
Exts tested     :    1
---------------------------------------------------------------------

Number of tests : 13882              2399
Tests skipped   : 11483 ( 82.7%) --------
Tests warned    :    0 (  0.0%) (  0.0%)
Tests failed    :   17 (  0.1%) (  0.7%)
Expected fail   :   12 (  0.1%) (  0.5%)
Tests passed    : 2370 ( 17.1%) ( 98.8%)
---------------------------------------------------------------------
Time taken      :  319 seconds
=====================================================================

=====================================================================
EXPECTED FAILED TEST SUMMARY
---------------------------------------------------------------------
Test open_basedir configuration [tests/security/open_basedir_linkinfo.phpt]  XFAIL REASON: BUG: open_basedir cannot delete symlink to prohibited file. See also
bugs 48111 and 52176.
Inconsistencies when accessing protected members [Zend/tests/access_modifiers_008.phpt]  XFAIL REASON: Discussion: http://marc.info/?l=php-internals&m=120221184420957&w=2
Inconsistencies when accessing protected members - 2 [Zend/tests/access_modifiers_009.phpt]  XFAIL REASON: Discussion: http://marc.info/?l=php-internals&m=120221184420957&w=2
Bug #48770 (call_user_func_array() fails to call parent from inheriting class) [Zend/tests/bug48770.phpt]  XFAIL REASON: See Bug #48770
Bug #48770 (call_user_func_array() fails to call parent from inheriting class) [Zend/tests/bug48770_2.phpt]  XFAIL REASON: See Bug #48770
Bug #48770 (call_user_func_array() fails to call parent from inheriting class) [Zend/tests/bug48770_3.phpt]  XFAIL REASON: See Bug #48770
Bug #64896 (Segfault with gc_collect_cycles using unserialize on certain objects) [Zend/tests/bug64896.phpt]  XFAIL REASON: We can not fix this bug without a significant (performace slow down) change to gc
Initial value of static var in method depends on the include time of the class definition [Zend/tests/method_static_var.phpt]  XFAIL REASON: Maybe not a bug
Bug #70470 (Built-in server truncates headers spanning over TCP packets) [sapi/cli/tests/bug70470.phpt]  XFAIL REASON: bug is not fixed yet
FPM: Test status page [sapi/fpm/tests/010.phpt]  XFAIL REASON: randomly intermittently failing all the time in CI, with diff:
017+ active processes:     0
018+ total processes:      1
017- active processes:     1
018- total processes:      2
FPM: Test various messages on start, from master and childs [sapi/fpm/tests/015.phpt]  XFAIL REASON: randomly intermittently failing all the time in CI,
ERROR: unable to read what child say: Bad file descriptor (9)
catch_workers_output = yes seems not reliable
FPM: Test Unix Domain Socket with Posix ACL [sapi/fpm/tests/021-uds-acl.phpt]  XFAIL REASON: Mark as XFAIL because --with-fpm-acl is not enabled in default build
=====================================================================

=====================================================================
FAILED TEST SUMMARY
---------------------------------------------------------------------
Test HTTP_RAW_POST_DATA creation [tests/basic/024.phpt]
Registration of HTTP_RAW_POST_DATA due to unknown content-type [tests/basic/026.phpt]
Test * operator : 64bit long tests [tests/lang/operators/multiply_basiclong_64bit.phpt]
testing integer overflow (64bit) [Zend/tests/int_overflow_64bit.phpt]
Zend signed multiply 64-bit [Zend/tests/zend_signed_multiply-64bit.phpt]
FPM: Startup and connect [sapi/fpm/tests/002.phpt]
FPM: Test multi pool (dynamic + ondemand + static) (bug #68423) [sapi/fpm/tests/008.phpt]
FPM: Test Unix Domain Socket [sapi/fpm/tests/009.phpt]
FPM: Test IPv4 all addresses (bug #68420) [sapi/fpm/tests/011.phpt]
FPM: Test reload configuration (bug #68442) [sapi/fpm/tests/012.phpt]
FPM: Test for log_level in fpm_unix_init_main #68381 [sapi/fpm/tests/013.phpt]
FPM: Test for pm.start_servers default calculation message being a notice and not a warning #68458 [sapi/fpm/tests/014.phpt]
FPM: Test splited configuration and load order #68391 [sapi/fpm/tests/016.phpt]
FPM: Test fastcgi_finish_request function [sapi/fpm/tests/017.phpt]
FPM: Test global prefix [sapi/fpm/tests/019.phpt]
FPM: Test pool prefix [sapi/fpm/tests/020.phpt]
FPM: HTTP_PROXY - CVE-2016-5385 [sapi/fpm/tests/022-cve-2016-5385.phpt]
=====================================================================

You may have found a problem in PHP.
This report can be automatically sent to the PHP QA team at

403 Forbidden
and http://news.php.net/php.qa.reports This gives us a better understanding of PHP's behavior. If you don't want to send the report immediately you can choose option "s" to save it. You can then email it to qa-reports@lists.php.net later. Do you want to send this report now? [Yns]: n #

 

 

インストールする

 

# make install
Installing PHP CLI binary:        /usr/local/php-5.6.40/bin/
Installing PHP CLI man page:      /usr/local/php-5.6.40/php/man/man1/
Installing PHP FPM binary:        /usr/local/php-5.6.40/sbin/
Installing PHP FPM config:        /usr/local/php-5.6.40/etc/php/
Installing PHP FPM man page:      /usr/local/php-5.6.40/php/man/man8/
Installing PHP FPM status page:   /usr/local/php-5.6.40/php/php/fpm/
Installing PHP CGI binary:        /usr/local/php-5.6.40/bin/
Installing PHP CGI man page:      /usr/local/php-5.6.40/php/man/man1/
Installing build environment:     /usr/local/php-5.6.40/lib/php/build/
Installing header files:           /usr/local/php-5.6.40/include/php/
Installing helper programs:       /usr/local/php-5.6.40/bin/
  program: phpize
  program: php-config
Installing man pages:             /usr/local/php-5.6.40/php/man/man1/
  page: phpize.1
  page: php-config.1
Installing PEAR environment:      /usr/local/php-5.6.40/lib/php/
[PEAR] Archive_Tar    - already installed: 1.4.4
[PEAR] Console_Getopt - already installed: 1.4.1
[PEAR] Structures_Graph- already installed: 1.1.1
[PEAR] XML_Util       - already installed: 1.4.3
[PEAR] PEAR           - already installed: 1.10.7
Wrote PEAR system config file at: /usr/local/php-5.6.40/etc/php/pear.conf
You may want to add: /usr/local/php-5.6.40/lib/php to your php.ini include_path
/usr/local/src/php/php-5.6.40/build/shtool install -c ext/phar/phar.phar /usr/local/php-5.6.40/bin
ln -s -f phar.phar /usr/local/php-5.6.40/bin/phar
Installing PDO headers:           /usr/local/php-5.6.40/include/php/ext/pdo/
#

 

環境を設定する

以下のファイルを設定する。
・php-fpm.conf
・php.ini

# cd /usr/local/php@-5.6.40
#
# cp php.ini-production /usr/local/php-5.6.40/etc/php/
#
# cd /usr/local/php-5.6.40
#
# mkdir log
#
# cd etc/php
#
# cp php-fpm.conf.default php-fpm.conf
#
# vi php-fpm.conf
#
# diff -c php-fpm.conf.default php-fpm.conf
*** php-fpm.conf.default        2026-04-26 15:41:45.482577801 +0900
--- php-fpm.conf        2026-04-26 16:02:07.804700346 +0900
***************
*** 22,53 ****
  ; Pid file
  ; Note: the default prefix is /usr/local/php-5.6.40/var
  ; Default Value: none
! ;pid = run/php-fpm.pid

  ; Error log file
  ; If it's set to "syslog", log is sent to syslogd instead of being written
  ; in a local file.
  ; Note: the default prefix is /usr/local/php-5.6.40/var
  ; Default Value: log/php-fpm.log
! ;error_log = log/php-fpm.log

  ; syslog_facility is used to specify what type of program is logging the
  ; message. This lets syslogd specify that messages from different facilities
  ; will be handled differently.
  ; See syslog(3) for possible values (ex daemon equiv LOG_DAEMON)
  ; Default Value: daemon
! ;syslog.facility = daemon

  ; syslog_ident is prepended to every message. If you have multiple FPM
  ; instances running on the same server, you can change the default value
  ; which must suit common needs.
  ; Default Value: php-fpm
! ;syslog.ident = php-fpm

  ; Log level
  ; Possible Values: alert, error, warning, notice, debug
  ; Default Value: notice
! ;log_level = notice

  ; If this number of child processes exit with SIGSEGV or SIGBUS within the time
  ; interval set by emergency_restart_interval then FPM will restart. A value
--- 22,53 ----
  ; Pid file
  ; Note: the default prefix is /usr/local/php-5.6.40/var
  ; Default Value: none
! pid = run/php-fpm.pid

  ; Error log file
  ; If it's set to "syslog", log is sent to syslogd instead of being written
  ; in a local file.
  ; Note: the default prefix is /usr/local/php-5.6.40/var
  ; Default Value: log/php-fpm.log
! error_log = log/php-fpm.log

  ; syslog_facility is used to specify what type of program is logging the
  ; message. This lets syslogd specify that messages from different facilities
  ; will be handled differently.
  ; See syslog(3) for possible values (ex daemon equiv LOG_DAEMON)
  ; Default Value: daemon
! syslog.facility = daemon

  ; syslog_ident is prepended to every message. If you have multiple FPM
  ; instances running on the same server, you can change the default value
  ; which must suit common needs.
  ; Default Value: php-fpm
! syslog.ident = php-fpm

  ; Log level
  ; Possible Values: alert, error, warning, notice, debug
  ; Default Value: notice
! log_level = notice

  ; If this number of child processes exit with SIGSEGV or SIGBUS within the time
  ; interval set by emergency_restart_interval then FPM will restart. A value
***************
*** 161,167 ****
  ;                            (IPv6 and IPv4-mapped) on a specific port;
  ;   '/path/to/unix/socket' - to listen on a unix socket.
  ; Note: This value is mandatory.
! listen = 127.0.0.1:9000

  ; Set listen(2) backlog.
  ; Default Value: 65535 (-1 on FreeBSD and OpenBSD)
--- 161,168 ----
  ;                            (IPv6 and IPv4-mapped) on a specific port;
  ;   '/path/to/unix/socket' - to listen on a unix socket.
  ; Note: This value is mandatory.
! ;listen = 127.0.0.1:9000
! listen = /usr/local/php-5.6.40/var/run/php-fpm-5.6.40.sock

  ; Set listen(2) backlog.
  ; Default Value: 65535 (-1 on FreeBSD and OpenBSD)
***************
*** 172,180 ****
  ; BSD-derived systems allow connections regardless of permissions.
  ; Default Values: user and group are set as the running user
  ;                 mode is set to 0660
! ;listen.owner = nginx
! ;listen.group = nginx
! ;listen.mode = 0660
  ; When POSIX Access Control Lists are supported you can set them using
  ; these options, value is a comma separated list of user/group names.
  ; When set, listen.owner and listen.group are ignored
--- 173,181 ----
  ; BSD-derived systems allow connections regardless of permissions.
  ; Default Values: user and group are set as the running user
  ;                 mode is set to 0660
! listen.owner = nginx
! listen.group = nginx
! listen.mode = 0666
  ; When POSIX Access Control Lists are supported you can set them using
  ; these options, value is a comma separated list of user/group names.
  ; When set, listen.owner and listen.group are ignored
***************
*** 187,193 ****
  ; must be separated by a comma. If this value is left blank, connections will be
  ; accepted from any ip address.
  ; Default Value: any
! ;listen.allowed_clients = 127.0.0.1

  ; Specify the nice(2) priority to apply to the pool processes (only if set)
  ; The value can vary from -19 (highest priority) to 20 (lower priority)
--- 188,194 ----
  ; must be separated by a comma. If this value is left blank, connections will be
  ; accepted from any ip address.
  ; Default Value: any
! listen.allowed_clients = 127.0.0.1

  ; Specify the nice(2) priority to apply to the pool processes (only if set)
  ; The value can vary from -19 (highest priority) to 20 (lower priority)
***************
*** 384,390 ****

  ; The access log file
  ; Default: not set
! ;access.log = log/$pool.access.log

  ; The access log format.
  ; The following syntax is allowed
--- 385,391 ----

  ; The access log file
  ; Default: not set
! access.log = log/$pool.access.log

  ; The access log format.
  ; The following syntax is allowed
***************
*** 439,445 ****
  ;  %u: remote user
  ;
  ; Default: "%R - %u %t \"%m %r\" %s"
! ;access.format = "%R - %u %t \"%m %r%Q%q\" %s %f %{mili}d %{kilo}M %C%%"

  ; The log file for slow requests
  ; Default Value: not set
--- 440,446 ----
  ;  %u: remote user
  ;
  ; Default: "%R - %u %t \"%m %r\" %s"
! access.format = "%R - %u %t \"%m %r%Q%q\" %s %f %{mili}d %{kilo}M %C%%"

  ; The log file for slow requests
  ; Default Value: not set
#
#
# cp php.ini-production  php.ini
#
# vi php.ini
#
# diff -c php.ini-production php.ini
*** php.ini-production  2026-04-26 15:48:44.901864703 +0900
--- php.ini     2026-04-26 15:57:34.913087093 +0900
***************
*** 199,205 ****
  ; Development Value: Off
  ; Production Value: Off
  ; http://php.net/short-open-tag
! short_open_tag = Off

  ; Allow ASP-style <% %> tags.
  ; http://php.net/asp-tags
--- 199,205 ----
  ; Development Value: Off
  ; Production Value: Off
  ; http://php.net/short-open-tag
! short_open_tag = On

  ; Allow ASP-style <% %> tags.
  ; http://php.net/asp-tags
***************
*** 360,366 ****
  ; threat in any way, but it makes it possible to determine whether you use PHP
  ; on your server or not.
  ; http://php.net/expose-php
! expose_php = On

  ;;;;;;;;;;;;;;;;;;;
  ; Resource Limits ;
--- 360,366 ----
  ; threat in any way, but it makes it possible to determine whether you use PHP
  ; on your server or not.
  ; http://php.net/expose-php
! expose_php = Off

  ;;;;;;;;;;;;;;;;;;;
  ; Resource Limits ;
***************
*** 569,575 ****
  ; empty.
  ; http://php.net/error-log
  ; Example:
! ;error_log = php_errors.log
  ; Log errors to syslog (Event Log on Windows).
  ;error_log = syslog

--- 569,575 ----
  ; empty.
  ; http://php.net/error-log
  ; Example:
! error_log = /usr/local/php-5.6.40/logs/php-error.log
  ; Log errors to syslog (Event Log on Windows).
  ;error_log = syslog

***************
*** 657,663 ****
  ; Its value may be 0 to disable the limit. It is ignored if POST data reading
  ; is disabled through enable_post_data_reading.
  ; http://php.net/post-max-size
! post_max_size = 8M

  ; Automatically add files before PHP document.
  ; http://php.net/auto-prepend-file
--- 657,663 ----
  ; Its value may be 0 to disable the limit. It is ignored if POST data reading
  ; is disabled through enable_post_data_reading.
  ; http://php.net/post-max-size
! post_max_size = 32M

  ; Automatically add files before PHP document.
  ; http://php.net/auto-prepend-file
***************
*** 768,774 ****
  ; of zero causes PHP to behave as before.  Default is 1.  You should fix your scripts
  ; to use SCRIPT_FILENAME rather than PATH_TRANSLATED.
  ; http://php.net/cgi.fix-pathinfo
! ;cgi.fix_pathinfo=1

  ; if cgi.discard_path is enabled, the PHP CGI binary can safely be placed outside
  ; of the web tree and people will not be able to circumvent .htaccess security.
--- 768,774 ----
  ; of zero causes PHP to behave as before.  Default is 1.  You should fix your scripts
  ; to use SCRIPT_FILENAME rather than PATH_TRANSLATED.
  ; http://php.net/cgi.fix-pathinfo
! cgi.fix_pathinfo=1

  ; if cgi.discard_path is enabled, the PHP CGI binary can safely be placed outside
  ; of the web tree and people will not be able to circumvent .htaccess security.
***************
*** 802,807 ****
--- 802,815 ----
  ; http://php.net/cgi.check-shebang-line
  ;cgi.check_shebang_line=1

+
+ ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+ ;; Disable dangerous functions
+ ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+ ;disable_functions = exec,passthru,shell_exec,system,proc_open,popen,curl_exec,curl_multi_exec,parse_ini_file,show_source
+ disable_functions = exec,passthru,shell_exec,system,popen,curl_exec,curl_multi_exec,parse_ini_file,show_source
+
+
  ;;;;;;;;;;;;;;;;
  ; File Uploads ;
  ;;;;;;;;;;;;;;;;
***************
*** 813,823 ****
  ; Temporary directory for HTTP uploaded files (will use system default if not
  ; specified).
  ; http://php.net/upload-tmp-dir
! ;upload_tmp_dir =

  ; Maximum allowed size for uploaded files.
  ; http://php.net/upload-max-filesize
! upload_max_filesize = 2M

  ; Maximum number of files that can be uploaded via a single request
  max_file_uploads = 20
--- 821,831 ----
  ; Temporary directory for HTTP uploaded files (will use system default if not
  ; specified).
  ; http://php.net/upload-tmp-dir
! upload_tmp_dir = /tmp

  ; Maximum allowed size for uploaded files.
  ; http://php.net/upload-max-filesize
! upload_max_filesize = 32M

  ; Maximum number of files that can be uploaded via a single request
  max_file_uploads = 20
***************
*** 933,939 ****
  [Date]
  ; Defines the default timezone used by the date functions
  ; http://php.net/date.timezone
! ;date.timezone =

  ; http://php.net/date.default-latitude
  ;date.default_latitude = 31.7667
--- 941,947 ----
  [Date]
  ; Defines the default timezone used by the date functions
  ; http://php.net/date.timezone
! date.timezone = Asia/Tokyo

  ; http://php.net/date.default-latitude
  ;date.default_latitude = 31.7667
***************
*** 1159,1165 ****
  ; Default socket name for local MySQL connects.  If empty, uses the built-in
  ; MySQL defaults.
  ; http://php.net/mysql.default-socket
! mysql.default_socket =

  ; Default host for mysql_connect() (doesn't apply in safe mode).
  ; http://php.net/mysql.default-host
--- 1167,1173 ----
  ; Default socket name for local MySQL connects.  If empty, uses the built-in
  ; MySQL defaults.
  ; http://php.net/mysql.default-socket
! mysql.default_socket = /usr/local/mysql-5.6.51/data/mysql.sock

  ; Default host for mysql_connect() (doesn't apply in safe mode).
  ; http://php.net/mysql.default-host
***************
*** 1218,1224 ****
  ; Default socket name for local MySQL connects.  If empty, uses the built-in
  ; MySQL defaults.
  ; http://php.net/mysqli.default-socket
! mysqli.default_socket =

  ; Default host for mysql_connect() (doesn't apply in safe mode).
  ; http://php.net/mysqli.default-host
--- 1226,1232 ----
  ; Default socket name for local MySQL connects.  If empty, uses the built-in
  ; MySQL defaults.
  ; http://php.net/mysqli.default-socket
! mysqli.default_socket = /usr/local/mysql-5.6.51/data/mysql.sock

  ; Default host for mysql_connect() (doesn't apply in safe mode).
  ; http://php.net/mysqli.default-host
***************
*** 1754,1767 ****
  ; language for internal character representation.
  ; This affects mb_send_mail() and mbstrig.detect_order.
  ; http://php.net/mbstring.language
! ;mbstring.language = Japanese

  ; Use of this INI entry is deprecated, use global internal_encoding instead.
  ; internal/script encoding.
  ; Some encoding cannot work as internal encoding. (e.g. SJIS, BIG5, ISO-2022-*)
  ; If empty, default_charset or internal_encoding or iconv.internal_encoding is used.
  ; The precedence is: default_charset < internal_encoding < iconv.internal_encoding
! ;mbstring.internal_encoding =

  ; Use of this INI entry is deprecated, use global input_encoding instead.
  ; http input encoding.
--- 1762,1775 ----
  ; language for internal character representation.
  ; This affects mb_send_mail() and mbstrig.detect_order.
  ; http://php.net/mbstring.language
! mbstring.language = Japanese

  ; Use of this INI entry is deprecated, use global internal_encoding instead.
  ; internal/script encoding.
  ; Some encoding cannot work as internal encoding. (e.g. SJIS, BIG5, ISO-2022-*)
  ; If empty, default_charset or internal_encoding or iconv.internal_encoding is used.
  ; The precedence is: default_charset < internal_encoding < iconv.internal_encoding
! mbstring.internal_encoding = UTF-8

  ; Use of this INI entry is deprecated, use global input_encoding instead.
  ; http input encoding.
***************
*** 1769,1775 ****
  ; If empty, default_charset or input_encoding or mbstring.input is used.
  ; The precedence is: default_charset < intput_encoding < mbsting.http_input
  ; http://php.net/mbstring.http-input
! ;mbstring.http_input =

  ; Use of this INI entry is deprecated, use global output_encoding instead.
  ; http output encoding.
--- 1777,1783 ----
  ; If empty, default_charset or input_encoding or mbstring.input is used.
  ; The precedence is: default_charset < intput_encoding < mbsting.http_input
  ; http://php.net/mbstring.http-input
! mbstring.http_input = auto

  ; Use of this INI entry is deprecated, use global output_encoding instead.
  ; http output encoding.
#
#
# cd /usr/local
#
# chown -R nginx:nginx php-5.6.40
#

 

起動するシェルを作成する

 

# cd /etc/rc.d
#
# vi php-fpm-5.6.40
#
# cat php-fpm-5.6.40
#/bin/bash

function func_start () {

        pro=`ps -ef | grep -v grep | grep "php-5.6.40" | grep "php-fpm.conf" | awk -F' ' '{print $2}'`
        if [ -n "${pro}" ]; then
                echo "php-fpm-5.6.40は既に起動しています。"
                exit 0
        else
                # php-fpm-7.4.33の起動
                export LD_LIBRARY_PATH=/usr/local/php-5.6.40/lib:/usr/local/ssl-1.1.1/lib:/usr/local/lib:/usr/lib64:/usr/lib
                export PATH=/usr/local/php-5.6.40/bin:/usr/local/php-5.6.40/sbin:/usr/local/ssl-1.1.1/bin:${PATH}
                rm -f /usr/local/php-5.6.40/var/run/php-fpm-5.6.40.sock
                chown nginx:nginx /usr/local/php-5.6.40/var/run
                #sudo -s -u nginx /usr/local/php-5.6.40/sbin/php-fpm --fpm-config /usr/local/php-5.6.40/etc/php/php-fpm.conf
                /usr/local/php-5.6.40/sbin/php-fpm --fpm-config /usr/local/php-5.6.40/etc/php/php-fpm.conf

                # php-fpm-5.6.40の起動チェック
                sleep 5
                pro=`ps -ef | grep -v grep | grep "php-5.6.40" | grep "php-fpm.conf" | awk -F' ' '{print $2}'`
                if [ -n "${pro}" ]; then
                        echo "php-fpm-5.6.40を起動しました。"
                        exit 0
                else
                        echo "php-fpm-5.6.40が起動できませんでした(異常)。"
                fi
        fi
}

function func_stop () {
        pro=`ps -ef | grep -v grep | grep "php-5.6.40" | grep "php-fpm.conf" | awk -F' ' '{print $2}'`
        if [ -z "${pro}" ]; then
                echo "php-fpm-5.6.40は既に停止しています。"
                exit 0
        else
                pro2=`ps -fe | grep -v grep | grep ${pro} | awk '{ print $2 }'`
                kill -9 ${pro2}
                echo "php-fpm-5.6.40を停止しました。"
        fi
}

exec_option=$1

case $exec_option in
        start )
                func_start
                ;;
        stop )
                func_stop
                ;;
        restart )
                func_stop
                func_start
                ;;
        * )
                ecoho "引数が有りません(異常)。"
                echo $0 [start|stop|restart]
                ;;
esac

exit 0

#
# chmod 755 php-fpm-5.6.40
#
# /etc/rc.d/php-fpm-5.6.40 start
php-fpm-5.6.40を起動しました。
#
# ps -fea | grep php
root      723007       1  0 18:03 ?        00:00:00 php-fpm: master process (/etc/php-fpm.conf)
nginx     723009  723007  0 18:03 ?        00:00:03 php-fpm: pool www
nginx     723010  723007  0 18:03 ?        00:00:00 php-fpm: pool www
nginx     723011  723007  0 18:03 ?        00:00:00 php-fpm: pool www
nginx     723012  723007  0 18:03 ?        00:00:00 php-fpm: pool www
nginx     723013  723007  0 18:03 ?        00:00:00 php-fpm: pool www
nginx     725148  723007  0 18:15 ?        00:00:00 php-fpm: pool www
root      727189       1  0 18:27 ?        00:00:00 php-fpm: master process (/usr/local/php-5.6.40/etc/php/php-fpm.conf)
nginx     727190  727189  0 18:27 ?        00:00:03 php-fpm: pool www
nginx     727191  727189  0 18:27 ?        00:00:02 php-fpm: pool www
nginx     727482  727189  0 18:29 ?        00:00:00 php-fpm: pool www
root      728933  380187  0 18:36 pts/0    00:00:00 grep --color=auto php
#

 

nginxの設定変更

OpenPNEと抹茶のfastcgi_passの定義を以下の内容に修正する。

fastcgi_pass    unix:/usr/local/php-5.6.40/var/run/php-fpm-5.6.40.sock;

 

nginxを再起動する

# nginx -t
nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
nginx: configuration file /etc/nginx/nginx.conf test is successful
#
# systemctl restart nginx
#