skip to Main Content
+971 55 881 1725 hmimthiaz @ imthi.com

Apache Log Format for Amazon EC2 with Elastic Load Balancer

The journey through the Amazon Cloud (AWS) is quite amazing. Recently I had to use two EC2 instance with Elastic Load balancer. Once the website was served with load balancer only the load balancer IP was logged as remote IP.

After Googling for few hour and with trial and error method I got the correct Apache log format so that the real remote IP is logged.

I created a custom log format with a name “combined_new” and used it in all the virtual host configured in Apache. But you can use the format however you want.

Before you make any changes to httpd.conf please go through Apache log module.

I hope this small tip helps 😉

Note: Always backup your original httpd.conf before you make any changes.

This Post Has One Comment

Comments are closed.

Back To Top