I've been trying to figure out how to rotate the error log in a Windows
environment. I'm rotating the access logs in the vhost config file as
follows:
<IfModule log_config_module>
LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\"
\"%{User-Agent}i\"" combined
LogFormat "%h %l %u %t \"%r\" %>s %b" common
<IfModule logio_module>
# You need to enable mod_logio.c to use %I and %O
LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\"
\"%{User-Agent}i\" %I %O" combinedio
</IfModule>
CustomLog logs/cob/access-log-%Y-%m-%d.log combined
</IfModule>
<IfModule log_rotate_module>
RotateLogs On
RotateLogsLocalTime On
RotateInterval 86400
</IfModule>
And I'm successfully logging errors by configuring the http.conf file as
follows:
LogLevel info
ErrorLog c:/apache2/logs/error.log
However, I'm unclear how to rotate the error logs. I tried using this
directive but the server wouldn't restart. I couldn't refer to the error
log to see what might be wrong with this directive because it applies to
the error log:
ErrorLog "| c:/apache2/bin/rotatelogs.exe c:/apache2/logs/%Y%m%d_error.log
86400"
If someone could point me in the right direction I'd appreciate it.
Thanks
____________________________
Steven
Kenji Kikuchi
<[EMAIL PROTECTED]
-g.co.jp> To
[email protected]
11/30/2007 01:03 cc
AM
Subject
[EMAIL PROTECTED] Apache 2.2.3
Please respond to rotatelogs.exe on WindowsXP
[EMAIL PROTECTED]
e.org
Hi All
I have installed apache2.2.3 on Windows XP and am using rotatelogs.exe for
ErrorLog directive like
httpd.conf
---------------
ErrorLog "| C:/test/logs/rotatelogs.exe C:/test/logs/%Y%m%d_error.log
86400"
---------------
Regards,
Kenji Kikuchi
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: [EMAIL PROTECTED]
" from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]