Welcome! Log In Create A New Profile

Advanced

Directive proxy_next_upstream doesn't work?

December 29, 2011 02:45AM
nginx conf is:

http {
large_client_header_buffers 8 8k;

proxy_buffers 8 8K;
proxy_buffer_size 8K;

open_file_cache max=1000 inactive=20s;
open_file_cache_valid 30s;
open_file_cache_min_uses 2;
open_file_cache_errors on;


upstream backend {
server 10.10.2.100:8088 max_fails=200 fail_timeout=10;
server 10.10.2.101:8088 max_fails=200 fail_timeout=10;
server 10.10.2.102:8088 max_fails=200 fail_timeout=10;
server 10.10.2.103:8088 max_fails=200 fail_timeout=10;
}

server {
listen 80;
server_name _;
keepalive_timeout 60;
proxy_set_header Host $http_host;

proxy_connect_timeout 10;
proxy_read_timeout 10;
proxy_next_upstream error http_500 http_502 http_503 http_504;
add_header P3P "CP=CAO PSA OUR";
add_header Cache-Control "must-revalidate,no-cache,private";

location / {
proxy_pass http://backend;
}
}
}

On my production, in the cases a server of upstream response http_504, but the request doesn't to be transmitted to the next server, nginx response http 504 to client.
Subject Author Posted

Directive proxy_next_upstream doesn't work?

defage December 29, 2011 02:45AM

Re: Directive proxy_next_upstream doesn't work?

defage December 29, 2011 02:47AM

Re: Directive proxy_next_upstream doesn't work?

Maxim Dounin December 29, 2011 03:34AM

Re: Directive proxy_next_upstream doesn't work?

defage December 29, 2011 04:07AM

Re: Directive proxy_next_upstream doesn't work?

Maxim Dounin December 29, 2011 07:36AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 75
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready