Welcome! Log In Create A New Profile

Advanced

Re: Service availability during reload

Maxim Dounin
November 29, 2013 07:14AM
Hello!

On Fri, Nov 29, 2013 at 09:12:39AM -0200, Andre Nathan wrote:

> Hello
>
> In an apache webserver with many virtual hosts, a "reload" command can
> cause a (quick) unavailability of the service while apache re-reads its
> configuration files.
>
> Does anyone have any experience with this on Nginx? Will sending it a
> SIGHUP cause the main process to block and not be able to handle
> connections during that instant?

Short answer:

This is not a problem with nginx.

Long answer:

Connections are handled by worker processes. On SIGHUP, master
process parses new configuration and spawns new worker processes
(while old workers still handle requests). Then it asks old
workers to gracefully shutdown. That is, all the time requests
are handled by worker processes and service is available.

Moreover, it is possible to upgrade nginx binary on the fly
without loosing any single request.

See here for more details:

http://nginx.org/en/docs/control.html

--
Maxim Dounin
http://nginx.org/en/donation.html

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Service availability during reload

Andre Nathan November 29, 2013 06:14AM

Re: Service availability during reload

B.R. November 29, 2013 07:02AM

Re: Service availability during reload

Maxim Dounin November 29, 2013 07:14AM

Re: Service availability during reload

Andre Nathan November 29, 2013 07:30AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 180
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready