i'm looking for a way to force apache server to log all client info based on custom logformat.
the issue arise when there are certain website were access through a reverse proxy. so have configure the logformat to be as follow:
LogFormat "%h %{X-Forwarded-For}i %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
but the logs are not be able to be process by awstat. what i am thinking is, can we do have two logformat.
LogFormat "%h %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined LogFormat "%{X-Forwarded-For}i %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" reverseproxy
and having some variable like if else condition. for example if i see request coming from 1.1.1.1 which is my reverse proxy ip then apache need to use reverseproxy logformat.
looking for expert reply.