Varnish (reverse proxy) + nginx with php and REMOTE_ADDR issue.

Rob Schultz rschultz7 at
Mon Jan 4 01:00:59 MSK 2010

No use
put this into either the in the http, server or you location section.

set_real_ip_from;  (or what ever your varnish ip address is)
real_ip_header X-Forwarded-For;

and just leave it as fastcgi_param REMOTE_ADDR   $remote_addr;


On Jan 3, 2010, at 3:50 PM, Piotr Karbowski wrote:

> I saw that but I don't understand how can I use it in fastcgi_parms.
> fastcgi_param  REMOTE_ADDR        $real_ip_header;
> This can work?
> _______________________________________________
> nginx mailing list
> nginx at

More information about the nginx mailing list