在重启nginx时报错误。
wangkongming@ThinkPad-T410 ~ $ sudo /usr/sbin/nginx -s reload nginx: [error] invalid PID number "" in "/run/nginx.pid"
google一番,下面是解决办法
nginx -s reload is only used to tell a running nginx process to reload its config. After a stop, you don't have a running nginx process to send a signal to. Just run nginx (possibly with a -c /path/to/config/file)
我本机的是用下面的命令
wangkongming@ThinkPad-T410 /etc/nginx $ sudo /usr/sbin/nginx -c /etc/nginx/nginx.conf