Nginx operation and maintenance

nginx -s reload : Reload takes effect after modifying the configuration
nginx -s reopen : Re-open the log file
nginx -t -c /path/to/nginx.conf Test whether the nginx configuration file is correct

Shut down nginx:
nginx -s stop : stop nginx quickly
         quit : Stop nginx in a complete and orderly manner.

Other ways to stop nginx:

ps -ef | grep nginx

kill -QUIT Main process number: Stop Nginx calmly kill -TERM Main process
number: Quickly stop Nginx
pkill -9 nginx: Forcibly stop Nginx and



start nginx :
nginx -c /path/to/nginx.conf

Restart nginx smoothly:
kill -HUP main process number



Check the commands when nginx is compiled and installed, which modules are installed
sbin/nginx -V

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326564830&siteId=291194637