nginx: [error] invalid PID number

created at 07-04-2021 views: 2

description

Nginx restarts and reports an error:

nginx: [error] invalid PID number "" in "/var/run/nginx/nginx.pid"

 error message

solution

  • Check /etc/nginx/nginx.conf, and test it: nginx -t
  • Found that's right, simply kill the current nginx process

nginx

  1. Execute the following: nginx -c /etc/nginx/nginx.conf
  2. nginx -s reload successfully executed

nginx -s reload

Please log in to leave a comment.