Forum Moderators: phranque

Message Too Old, No Replies

separating log files doesn't work

SetEnvIf and CustomLog don't work as they should

         

TauTau

1:39 pm on Dec 10, 2003 (gmt 0)



Hi,

I'm trying to separate the log files of our server based on subdirectories. The entries look like this:

SetEnvIf Request_URI "^/mrtg/" mrtg
CustomLog logs/mrtg.log combined env=mrtg
CustomLog logs/access_log combined env=!mrtg

There are several entries like this. The Problem is, while the accesses do get in the defined CustomLogs, they still also get into the access_log, so I have double entries:

10.199.x.x - - [10/Dec/2003:14:35:49 +0100] "GET /mrtg/ HTTP/1.1" 200 3962 "-" "Mozilla/4.0 (compatible; MSIE 6.0; MSIE 5.5; Windows NT 5.0) Opera 7.03 [en]"

though any following GETs (included graphics etc.) only get logged into the special log...

Is there something wrong with my regex syntax?

Apache is 2.0.40 on RedHat 8.0

Lars

jdMorgan

6:23 pm on Dec 15, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Can anybody help Lars out here?

<bump>

Thanks!
Jim