Home  >  Article  >  Backend Development  >  Common commands for nginx server

Common commands for nginx server

WBOY
WBOYOriginal
2016-07-29 08:58:221021browse

nginx -s reload: Modify the configuration and reload it to take effect

nginx -s reopen: Reopen the log file
nginx -t -c /path/to/nginx.conf Test whether the nginx configuration file is correct
Close nginx:
nginx -s stop : Stop nginx quickly
Quit : Stop nginx completely and orderly
Other ways to stop nginx:
ps -ef | grep nginx
kill -QUIT main process number : Stop Nginx calmly
kill -TERM main process number : Stop Nginx quickly
pkill -9 nginx : Force stop Nginx
Start nginx:
nginx -c /path/to/nginx.conf
Restart nginx smoothly:
kill -HUP main process number

The above introduces the commonly used commands of nginx server, including related content. I hope it will be helpful to friends who are interested in PHP tutorials.

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