How to solve nginx - no live upstreams while connecting to upstream client?

后端 未结 2 671
鱼传尺愫
鱼传尺愫 2020-12-30 01:02

Currently I am running a load test using JMeter on our system build on grails 3 running on tomcat. After sending 20k request per second I got “no live upstreams while connec

2条回答
  •  醉梦人生
    2020-12-30 01:40

    I saw such behavior many times during perf. tests.

    Under heavy workload the performance of your upstream server(s) may not be enough and upstream module may mark upstream server(s) as unavailable.

    The relevant parameters (server directive) are:

    max_fails=number
    

    sets the number of unsuccessful attempts to communicate with the server that should happen in the duration set by the fail_timeout parameter to consider the server unavailable for a duration also set by the fail_timeout parameter. By default, the number of unsuccessful attempts is set to 1. The zero value disables the accounting of attempts. What is considered an unsuccessful attempt is defined by the proxy_next_upstream, directives.

    fail_timeout=time
    

    sets:

    • the time during which the specified number of unsuccessful attempts to communicate with the server should happen to consider the server unavailable;

    • and the period of time the server will be considered unavailable.

    By default, the parameter is set to 10 seconds.

提交回复
热议问题