Welcome to Server Circle. It's a friendly site and all levels of experience are welcome. Be aware that we use cookies for your login.
Server Circle - Ask questions about Servers and get answers from experts.
Beta (0.63 sec)
Ignore directories in Apache logging not just file extensions

This below stops images being logged but how do I stop web hits on /ignore/ being logged ? Is this a regex match issue ?

SetEnvIf Request_URI .gif image-request
Asked by:
Bogofilter
1565 points
 Report Abuse
 Share Page - Category: Linux Servers - Tags: Ignore directories in Apache logging not just file extensions
 Enter your response
Please use Pastie.org to paste lengthy code or to fix formatting issues with code
  • Responses in reverse (2)

Best Answer

I believe that this should work

SetEnvIf Request_URI "/directory-name" dontlog

CustomLog /var/log/apache2/useraccess_log combined env=!dontlog


Response by:
apjone
1478 points
Thanks :)

Response by:
Bogofilter
1565 points


  • Related Questions
About Us : Contact Us : Etiquette : Terms : CDN Failover : ShorterURL : CDN Fallback : © 2013 Server Circle