Nginx ~ Controlling - rohit120582sharma/Documentation GitHub Wiki

Nginx has one master process and one or more worker processes. The main purpose of the master process is to read and evaluate configuration files, as well as maintain the worker processes. The worker processes do the actual processing of requests.

To start nginx, run the executable file. Once nginx is started, it can be controlled by sending the signals to the master process. A signal can be sent by running the nginx command (invoking the NGINX executable) with the -s argument.

# Shut down immediately (fast shutdown)
$ nginx -s stop

# Shut down gracefully
$ nginx -s quit

# Reload the configuration file
$ nginx -s reload

# Reopen log files
$ nginx -s reopen