Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

We have IIS7 servers sitting behind an nginx reverse proxy.

The reverse proxy is sending the standard "HTTP_X_FORWARDED_FOR" header with the visitor IP address, but IIS7 logging is only logging the IP address of the nginx server (which makes sense, but it's not what I want).

How can I tell IIS7 to instead log the "HTTP_X_FORWARDED_FOR" header (or additionally log it)?

(note: I'm a linux admin, not a windows one, so explicit instructions & links are sincerely appreciated)

share|improve this question

2 Answers 2

up vote 4 down vote accepted

This isn't built into IIS, but there is a module you can install that will perform this functionality. It is called ARR helper, but it will work for any proxy in front of IIS:

http://blogs.iis.net/anilr/archive/2009/03/03/client-ip-not-logged-on-content-server-when-using-arr.aspx

share|improve this answer
    
thanks very much! –  zeroasterisk Jul 6 '10 at 16:14

There is now an IIS7 module that will let you log custom headers.

How to: http://learn.iis.net/page.aspx/579/advanced-logging-for-iis-70---custom-logging/

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.