upstream timed out (110: Connection timed out) for static content?

后端 未结 2 363
我寻月下人不归
我寻月下人不归 2020-12-30 04:00

I\'ve a situation where two webservers are setup with nginx as loadbalancer and are backends themselves. Distribution is Debian Wheezy. Config is the same on both servers (Q

相关标签:
2条回答
  • 2020-12-30 04:03

    OK, I didn't like reading manuals, but to answer my question:

    nginx close upstream connection after request

    solved it. So what was the problem: I've configured upstream to use keepalive but Nginx doc suggests to set following options in proxy location:

        proxy_http_version 1.1;
        proxy_set_header Connection "";
    

    That's it and thousand of TIME_WAIT connections in backend are gone, there are only round about 150 now instead of 30-40k.

    0 讨论(0)
  • 2020-12-30 04:20

    im my case was php-fpm that need to be restarted

    0 讨论(0)
提交回复
热议问题