Welcome! Log In Create A New Profile

Advanced

Re: Keepalived Connections Reset after reloading the configuration (HUP Signal)

October 08, 2020 03:31AM
Thanks Maxim to taking the time to respond.

> This feature wasn't removed in 5e6142609e48, but rather it was
> changed how things work: instead of doing a full scan over all
> connections on each event loop iteration, nginx now does it only
> once, and also makes sure no new idle connections are added after
> the shutdown signal.
>

I don't fully understand what happens to non-idle keep-alive connections after the shutdown signal is sent.

If I understand correctly, non-idle keep-alive connections will continue to serve requests after a graceful shutdown, until they are terminated by "normal" events, such as:
* connection is closed/terminated by the client
* or by the server, e.g if (r->connection->requests >= clcf->keepalive_requests)
* or if keepalive_timeout is meet
* any other event that would close the connection during normal operation

From reading the code, it looks like this is the expected flow after a graceful shutdown.

I read somewhere that they expected nginx to return "Connection: close" headers to keepalive connections after graceful shutdown signal is sent. But I don't see that is true, and not expected either from reading the code.

Thanks,
Tore
Subject Author Posted

Keepalived Connections Reset after reloading the configuration (HUP Signal)

Jocelyn Mocquant May 13, 2011 07:24PM

Re: Keepalived Connections Reset after reloading the configuration (HUP Signal)

Maxim Dounin May 16, 2011 07:34AM

Re: Keepalived Connections Reset after reloading the configuration (HUP Signal)

Jocelyn Mocquant May 16, 2011 06:14PM

Re: Keepalived Connections Reset after reloading the configuration (HUP Signal)

darthhexx March 28, 2019 08:49PM

Re: Keepalived Connections Reset after reloading the configuration (HUP Signal)

zakirenish September 11, 2020 05:54PM

Re: Keepalived Connections Reset after reloading the configuration (HUP Signal)

tored October 07, 2020 04:29AM

Re: Keepalived Connections Reset after reloading the configuration (HUP Signal)

Maxim Dounin April 01, 2019 01:06PM

Re: Keepalived Connections Reset after reloading the configuration (HUP Signal)

Maxim Dounin October 07, 2020 09:56AM

Re: Keepalived Connections Reset after reloading the configuration (HUP Signal)

tored October 08, 2020 03:31AM

Re: Keepalived Connections Reset after reloading the configuration (HUP Signal)

Maxim Dounin October 12, 2020 04:16PM

Re: Keepalived Connections Reset after reloading the configuration (HUP Signal)

allenhe February 17, 2021 11:40PM

Re: Keepalived Connections Reset after reloading the configuration (HUP Signal)

allenhe February 18, 2021 03:14AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 203
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