nginx reload, stop error
Maxim Dounin
mdounin at mdounin.ru
Mon Jul 21 11:58:25 UTC 2014
Hello!
On Fri, Jul 18, 2014 at 11:32:38PM +0100, Matthew Ngaha wrote:
> Hey, when I run './nginx -s reload' or './nginx -s stop' i get this:
>
> nginx: [error] open() "/usr/local/nginx-1.4.3/logs/nginx.pid" failed
> (2: No such file or directory)
>
> Any ideas why it's trying to open this file that doesn't exist?
There are multiple possible reasons - e.g., this can happen
because you've changed the configuration file, or if you are
trying to stop wrong nginx.
In general, it's good idea to use "kill" to control nginx on
unix-like systems (not the "nginx -s" which is mostly for Windows
and requires a configuration file to work). Use of "kill" allows
to explicitly specify PID of the master process (and/or to get one
from a pid file of your choice).
See here for details on how to control nginx using signals:
http://nginx.org/en/docs/control.html
--
Maxim Dounin
http://nginx.org/
More information about the nginx
mailing list