Tag Archives: Nginx restart

Restart and stop of nginx in Linux service

Case 1: nginx has service

Nginx installed in Linux will register service service by default. You can directly start, stop and restart according to the following operations

service nginx start  # start
service nginx stop  # stop
service nginx restart  # restart

Case 2: the original nginx service is not clear

Find the installation directory of nginx to understand the situation of nginx

# Find Nginx installation information
find/-name nginx

# Go to the nginx sbin directory and restart
. /nginx -s reload

# If you have modified the Nginx configuration, check the configuration with -t
. /nginx -t

# Check to see if it starts
ps aux | grep nginx
# or
ps -ef | grep nginx

Nginx more

Adding prefix to nginx agent of Python flash project
deployment of ngnix + gunicorn + Flash project in Ubuntu environment