This configuration should help you:
HostnameLookups off
<Files ˜ "\.(cgi)$>
HostnameLookups on
</Files>
|
Only files which match the description used will use hostname lookups everything else will happily move along by only logging the IP of the requester. As an alternative to this you could always resolve the hostname in your CGI script .