Nginx reload problem
Maxim Dounin
mdounin at mdounin.ru
Sat Aug 17 03:16:16 UTC 2013
Hello!
On Fri, Aug 16, 2013 at 10:16:16PM -0400, B.R. wrote:
> I guess it would be nice if the doc warned about directives that need a
> server restart to be reloaded.
>
> Everyone supposes (as it seems obvious) that reloading Nginx is enough to
> apply configuration changes.
Reloading is enough. What is very wrong is to assume that sending
a HUP signal to nginx is enough for a reload. For various
reasons, ranging from configuration syntax errors to out of memory
problems, configuration reload might fail.
Quoting documentation:
... If this fails, it rolls back changes and continues to work
with old configuration. ...
http://nginx.org/en/docs/control.html#reconfiguration
> An interesting part of the question was the inquiry about the potential
> existence other directives requiring a server restart rather than its
> reload. Do you have intel on this Maxim?
There are no directives which require a server restart. But some
changes are not possible on the fly - e.g. you can't change a
shared memory zone size. If you want to change it - you have to
create another shared memory zone, or use a binary upgrade which
doesn't inherit shared memory zones and their contents (or use a
restart, which will obviously work as well).
--
Maxim Dounin
http://nginx.org/en/donation.html
More information about the nginx
mailing list