Amazon ELB and Apache

When you place your Apache Web Server behind an Amazon Elastic Load Balancer, Apache receives all requests from the ELB’s IP address.

Therefore, if you wish to do anything with the real client IP address, such as logging or whitelisting, you need to make use of the X-Forwarded-For HTTP Header Amazon ELB includes in each request which contains the IP address of the original host.

Two very helpful blog posts I found explaining both how to whilelist a particular request by IP address and how to set up your Apache logging behind the ELB to capture the original client IP address.

 

Friday, March 18th, 2011 Code

No comments yet.

Leave a comment

You must be logged in to post a comment.

Agile CTO