nginx1->nginx2->apache and wrong IP address in nginx2 access log
quaker at barbara.eu.org
Sun Jun 7 16:44:25 MSD 2009
2009/6/6 <mates007 at centrum.cz>:
> I have a machine 1 with nginx as a proxy before apache, and machine2 with nginx as a proxy before apache. I am moving websites from machine1 to machine2. Because DNS still points to machine1, I need to pass traffic from machone1 to machine2 for a while.
> Everything is working fine, but in machine2 nginx log I have IP of machine1 as clients address. This is a problem because of awstats.
> Can please anybody advise me that I have wrong in my configuration?
Have a look at http://wiki.nginx.org/NginxHttpRealIpModule and
configure it on machine2:
More information about the nginx