Home  >  Article  >  Backend Development  >  what is php stop command

what is php stop command

藏色散人
藏色散人Original
2020-08-11 10:25:474531browse

The php stop command is "kill -INT `cat /usr/local/php/var/run/php-fpm.pid", and the restart command of "php-fpm" is "kill -USR2 `cat / usr/local/php/var/run/...".

what is php stop command

Recommended: "PHP Video Tutorial"

About the startup of nginx, mysql, php, etc. under the linux system, Stop and restart commands.

/usr/local/nginx/sbin/nginx
/etc/init.d/mysql start
/usr/local/php/sbin/php-fpm start
 
#nginx命令 
  
start: 
/usr/local/nginx/sbin/nginx 
 
stop: 
/usr/local/nginx/sbin/nginx -s stop 
 
reload: 
/usr/local/nginx/sbin/nginx -s reload 
 
#******************************************** 
 
#php-fpm(fast-cgi)命令 
  
start: 
/usr/local/php/sbin/php-fpm 
 
stop: 
/bin/ps -ef | grep 'php-fpm' | grep -v grep | cut -c 9-15 | xargs kill -9

Linux: PHP 5.3.3 or above version of php-fpm restart

INT, TERM: Immediately Terminate

QUIT: Graceful termination

USR1: Reopen log file

USR2: Gracefully reload all worker processes and reload configuration and binary modules

Example:

1) php-fpm shutdown:

kill -INT `cat /usr/local/php/var/run/php-fpm.pid`

2) php-fpm restart:

kill -USR2 `cat /usr/local/php/var/run/php-fpm.pid`

View the number of php-fpm processes:

ps aux | grep -c php-fpm
 
#******************************************** 
 
#mysql命令 
 
start: 
/etc/init.d/mysqld start 
 
stop: 
/etc/init.d/mysqld stop 
 
restart: 
/etc/init.d/mysqld restart 
 
#******************************************** 
 
#tomcat命令 
 
start:
/usr/local/tomcat/bin/startup.sh 
 
stop:
/bin/ps -ef | grep 'tomcat' | grep -v grep | cut -c 9-15 | xargs kill -9

The above is the detailed content of what is php stop command. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn