Welcome! Log In Create A New Profile

Advanced

$upstream_http_*

Domrachev Ivan
February 14, 2010 07:54PM
Здравствуйте, nginx-ru.

не передаётся $upstream_http_*.
воспроизводится на nginx-0.7.65 и nginx-0.8.33.

делаю так:
запрос от пользователя сначала кидается на бэкенд:
location / {
proxy_pass http://127.0.0.1:10000;
}
бэкенд отвечает:
200 OK
login: 451231
X-Accel-Redirect: /after_test//

после чего запрос попадает в
location /after_test/ {
internal;
fastcgi_pass unix:tester/tester.socket;
fastcgi_param LOGIN $upstream_http_login;
fastcgi_param status $upstream_status;
fastcgi_param addr $upstream_addr;
...
}
но поле $upstream_http_login оказывается пустым.
куски дебаг лога:
2010/02/15 03:38:26 [debug] 9245#0: *1 http proxy status 200 "200 OK"
2010/02/15 03:38:26 [debug] 9245#0: *1 http proxy header: "login: 451231"
2010/02/15 03:38:26 [debug] 9245#0: *1 http proxy header: "Server: server"
2010/02/15 03:38:26 [debug] 9245#0: *1 http proxy header: "X-Accel-Redirect: /after_test//"
2010/02/15 03:38:26 [debug] 9245#0: *1 http proxy header done
...
2010/02/15 03:38:26 [debug] 9245#0: *1 post access phase: 8
2010/02/15 03:38:26 [debug] 9245#0: *1 http init upstream, client timer: 0
2010/02/15 03:38:26 [debug] 9245#0: *1 http script copy: "status"
2010/02/15 03:38:26 [debug] 9245#0: *1 http script var: "200"
2010/02/15 03:38:26 [debug] 9245#0: *1 fastcgi param: "status: 200"
2010/02/15 03:38:26 [debug] 9245#0: *1 http script copy: "LOGIN"
2010/02/15 03:38:26 [debug] 9245#0: *1 fastcgi param: "LOGIN: "
2010/02/15 03:38:26 [debug] 9245#0: *1 http script copy: "addr"
2010/02/15 03:38:26 [debug] 9245#0: *1 http script var: "127.0.0.1:10000"
2010/02/15 03:38:26 [debug] 9245#0: *1 fastcgi param: "addr: 127.0.0.1:10000"

как видно status и addr передаётся, а вот login (и любое другое слово)
не передаётся.

--
С уважением,
Domrachev mailto:Domrachev.Ivan@gmail.com


_______________________________________________
nginx-ru mailing list
nginx-ru@nginx.org
http://nginx.org/mailman/listinfo/nginx-ru
Subject Author Posted

$upstream_http_*

Domrachev Ivan February 14, 2010 07:54PM

Re: $upstream_http_*

Alex Vorona February 15, 2010 03:06AM

Re[2]: $upstream_http_*

Domrachev Ivan February 15, 2010 03:36AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 211
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready