Configuration of PHP.ini, PHP-FPM, and www.conf in PHP7
Http://www.tuicool.com/articles/NjmQNj6
PHP-FPM off:
Kill-sigint ' Cat/usr/local/php/var/run/php-fpm.pid '
PHP-FPM Restart:
KILL-SIGUSR2 ' Cat/usr/local/php/var/run/php-fpm.pid '
To view the number of PHP-FPM processes:
PS aux | Grep-c PHP-FPM
Netstat-anpo | grep "php-cgi" | Wc-l
Netstat-anop | grep "PHP-FPM" | Wc-l
Nginx running PHP through fastcgi than Apache contains PHP environment has obvious advantages, recently, there is a message that PHP5.4 will most likely put php-fpm patch in the kernel, Nginx server platform to run PHP will be more relaxed, Let's take a look at a php-fpm smooth start and configure the service example.
My PHP is the source of the installation. PHP-FPM after PHP 5.3.2 version does not support the previous php-fpm (start|restart|stop|reload), then if you configure PHP-FPM as a service, and add a smooth start/restart.
Configure php-fpm.conf (vi/usr/local/php54/etc/php-fpm.conf) to remove the PID (;p id = run/php-fpm.pid) before;
Because the compiler installs PHP, it will generate a lot of binary files in the PHP directory, find init.d.php-fpm, copy to INIT.D.
cp/usr/local/src/php54/sapi/fpm/init.d.php-fpm/etc/init.d/php-fpm
Set permissions, and add services
chmod +x/etc/init.d/php-fpm
Chkconfig--add PHP-FPM
You can use the following command to manage PHP-FPM later
Service PHP-FPM Start
Service PHP-FPM Stop
Service PHP-FPM Restart
Service PHP-FPM Reload
PHP7 php-fpm Restart