I have a long poll clients that connect to nginx and upstream to kestrel dot net. Clients have keepalive set that after 2 minutes connection breaks. On nginx side i have listen 0.0.0.0:xxx ssl so_keepalive=5m:10:5; So roughly 6 minutes
I pull the eth cable out of the cable, preventing any transfers and client detects a connection break, but my upstream server does not. Upstream server never detects this.
Now is the nginx not detecting this break ? and then not closing connection to upstream ? Or what am i doing wrong?
Thank you
Your
listen
option specifies keepalive only for the listening socket. It does not apply to upstream connections.To enable TCP keepalive for upstream connections, you need to add
proxy_socket_keepalive on;
in your nginx configuration.