How to enable x-client-ip address in apache webserver LogFormat?

Tags
web

 
Thread Tools Search this Thread
# 1  
Old 04-27-2017
How to enable x-client-ip address in apache webserver LogFormat?

how to enable x-client-ip address in apache webserver LogFormat
i tried below option, but no luck...
Code:
1. LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined

2. LogFormat "%{X-Forwarded-For}i %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" proxy

3. SetEnvIf X-Forwarded-For "^.*\..*\..*\..*" forwarded

4. CustomLog "logs/access_log" combined env=!forwarded

5. CustomLog "logs/access_log" proxy env=forwarded

any help greatly appreciated

Last edited by Don Cragun; 04-27-2017 at 03:09 PM.. Reason: Fix CODE tags.

|
Thread Tools Search this Thread
Search this Thread:
Advanced Search

More UNIX and Linux Forum Topics You Might Find Helpful
Runtime Error Enable user directory apache mnnn Red Hat 2 06-26-2016 01:15 PM
Apache webserver troubleshooting ajayram_arya Shell Programming and Scripting 12 07-22-2014 01:22 PM
apache webserver url redirection raghur77 UNIX for Advanced & Expert Users 0 02-28-2012 10:11 AM
client authentication in sunone 7.0 webserver pcs.abhishek Web Programming 0 04-07-2010 07:34 AM
Determining IP address of NFS server on client rascalrick UNIX for Advanced & Expert Users 2 12-08-2008 05:15 PM
How to get the IP address / Host name of client machine MVL Solaris 6 10-01-2008 08:43 AM
ip address of a client ka2d2 IP Networking 6 11-26-2007 05:44 PM
apache webserver jo calamine UNIX for Advanced & Expert Users 2 11-14-2006 05:57 PM
Getting IP Address of a client fayette Programming 0 03-24-2006 02:27 PM
Retrieving IP address of Client from Server matrixmadhan Programming 4 03-21-2006 05:06 AM
client IP address rolly UNIX for Dummies Questions & Answers 2 03-17-2005 09:14 PM
enable php & java support in apache bionicfysh UNIX for Dummies Questions & Answers 5 10-01-2003 01:29 PM
Client Ip Address ovingtond IP Networking 1 09-15-2003 06:45 PM
Logout Apache WebServer! cipher UNIX for Advanced & Expert Users 1 06-17-2003 06:16 PM
IP address of telnet client vtran4270 UNIX for Dummies Questions & Answers 1 09-12-2002 05:34 PM