Re: Nginx prematurely closing connections when reloaded

2024-03-29 Thread Sébastien Rebecchi
Hi Igor, I did not have error_log directive at main context, so it took default conf, which seems why i got only 1 log file. I added directive and now I have more logs when I do nginx -s reload: 2024/03/29 09:04:20 [notice] 1064394#0: signal process started 2024/03/29 09:04:20 [notice] 3718160#0:

Re: Nginx prematurely closing connections when reloaded

2024-03-28 Thread Igor Ippolitov
Sébastien, Is it possible that messages go to another log file? These messages go to the main error log file, defined in the root context. Another common pitfall is a log level above notice. Try setting error log to a more verbose one, maybe? Regards, Igor. On 28/03/2024 18:27, Sébastien Re

Re: Nginx prematurely closing connections when reloaded

2024-03-28 Thread Sébastien Rebecchi
Hi Igor, Thanks for the answer. I really got that message 'signal process started' every time i do 'nginx -s reload' and this is the only log line I have, I don't have the other lines you mentioned. Is there anything to do to enable those logs? Sébastien Le jeu. 28 mars 2024, 16:40, Igor Ippoli

Re: Nginx prematurely closing connections when reloaded

2024-03-28 Thread Igor Ippolitov
Sébastien, The message about the signal process is only the beginning of the process. You are interested in messages like the following: 2024/03/26 13:36:36 [notice] 723#723: signal 1 (SIGHUP) received from 69064, reconfiguring 2024/03/26 13:36:36 [notice] 723#723: reconfiguring 2024/03/26 13:

Re: Nginx prematurely closing connections when reloaded

2024-03-26 Thread Sébastien Rebecchi
Hi Igor There is no special logs on the IP_1 (the reloaded one) side, only 1 log line, which is expected: --- BEGIN --- 2024/03/26 13:37:55 [notice] 3928855#0: signal process started --- END --- I did not configure worker_shutdown_timeout, it is unlimited. Sébastien. Le lun. 25 mars 2024 à 17:5

Re: Nginx prematurely closing connections when reloaded

2024-03-25 Thread Igor Ippolitov
Sébastien, Nginx should keep active connections open and wait for a request to complete before closing. A reload starts a new set of workers while old workers wait for old connections to shut down. The only exception I'm aware of is having worker_shutdown_timeout configured: in this case a wor

Re: Nginx prematurely closing connections when reloaded

2024-03-25 Thread Craig Hoover
Sent from my mobile phone (301) 785-4377On Mar 25, 2024, at 8:32 AM, Sébastien Rebecchi wrote:HelloI have an issue with nginx closing prematurely connections when reload is performed.I have some nginx servers configured to proxy_pass requests to an upstream group. This group itself is composed of

Re: Nginx prematurely closing connections when reloaded

2024-03-25 Thread Craig Hoover
What language is your upstream API written in and are you hosting in Amazon? Even if you aren't hosting in Amazon, it seems your values are quite low for connect, read and send. If you are running NodeJS for the upstream, one thing I have found is that certain values need to be offset to avoid th

Nginx prematurely closing connections when reloaded

2024-03-25 Thread Sébastien Rebecchi
Hello I have an issue with nginx closing prematurely connections when reload is performed. I have some nginx servers configured to proxy_pass requests to an upstream group. This group itself is composed of several servers which are nginx themselves, and is configured to use keepalive connection