apache hostnamelookups sanity-check

seth vidal skvidal at fedoraproject.org
Tue May 3 21:21:25 UTC 2011


Hey folks,
 looking at the logs for something today I noticed that our logs are
showing hostnames, not ip addresses of the remote hosts. Which is
somewhat wasteful since - for the local logs we don't need that extra
resolver lookup - and it makes grepping complicated b/c you never know
what the dns reverse map is going to look like :(

so I was thinking of changing the combined, error and common log format
for apache in our configs from using %h (remotehost) to using %a (remote
ip) [1]

Whle we have hostnamelookups off in all of our configs it appears that
using %h overrides (or ignores) that.

so - is there anything I'm not thinking about or forgetting that
changing the log format from %h to %a will result in?


thx
-sv

1. http://httpd.apache.org/docs/current/mod/mod_log_config.html#formats





More information about the infrastructure mailing list