linux重启nginx后出现nginx的pid丢失的解决方案

kill 2070

重新加载

/usr/local/nginx/sbin/nginx -s reload
[error]: open() “/usr/local/nginx/logs/nginx.pid” failed (2: No such file or directory)

如果继续报错执行以下语句

/usr/local/nginx/sbin/nginx -c /usr/local/nginx/conf/nginx.conf
/usr/local/nginx/sbin/nginx -s reload