The restart and termination commands of php-fpm in php5.4 are as follows:
View the php running Directory command: which php
/Usr/bin/php
View the number of php-fpm processes:
Ps aux | grep-c php-fpm
View running memory
/Usr/bin/php-I | grep mem
Restart php-fpm
/Etc/init. d/php-fpm restart
The php configuration is displayed in the output of phpinfo.
Loaded Configuration File/etc/php. ini
====================================
First you need to find the php-fpm.conf configuration file, view the pid configuration path (not the installation path), and then change the corresponding place below to normal execution.
[Root @ DO-SG-H1 ~] # Ps aux | grep php-fpm
Root 11799 0.0 0.0 103248 880 pts/0 S + grep -- color php-fpm
Root 11973 0.0 0.0 417748 964? Ss Jun01 php-fpm: master process (/etc/php-fpm.conf)
Cat/etc/php-fpm.conf
See
Pid =/var/run/php-fpm/php-fpm.pid.
Php-fpm startup:
/Usr/local/php/sbin/php-fpm
Disable php-fpm:
Kill-INT 'cat/var/run/php-fpm/php-fpm.pid'
Php-fpm restart:
Kill-USR2 'cat/var/run/php-fpm/php-fpm.pid'
View the number of php-fpm processes:
Ps aux | grep-c php-fpm
==================================
[Root @ DO-SG-H1 ~] # Find/-name 'php-fpm'-type d
/Var/log/php-fpm
/Var/run/php-fpm
The path found by the find command is incorrect.
Which php
/Usr/bin/php