mod_rpaf enabled; still apache log showing 127.0.0.1 as source !!
ar at xlrs.de
Mon Apr 28 13:03:22 UTC 2014
are there any advantages of using mod_rpaf instead of using and logging
On 2014-04-28 15:55, Maxim Dounin wrote:
> On Mon, Apr 28, 2014 at 07:03:28PM +0530, Joydeep Bakshi wrote:
>> Hello list,
>> To get the wan IP in apache log I have already enabl mod_rapf in
>> # a2enmod rpaf mod_rpaf
>> "rpaf" already present
>> a2enmod mod_rpaf
>> "mod_rpaf" already present
>> Here is a nginx vhost section for passing IP to apache log
>> proxy_redirect off; # Do not redirect this proxy - It needs to be
>> proxy_set_header Host $host;
>> proxy_set_header X-Real-IP $remote_addr;
>> proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
>> proxy_set_header X-Server-Address $server_addr;
>> proxy_pass_header Set-Cookie;
>> After restarting both apache and nginx, the apache log for that
>> vhost still showing 127.0.0.1 as source IP at apache log.
>> Am I missing something ?
> Most notably, you've missed configuration of mod_rpaf. It needs
> to be enabled in configuration, and you have to at least configure
> IP address it will accept headers from, as well as a header to
> look into.
More information about the nginx