Try logrotate:
http://iain.cx/src/logrotate/
On 2/8/06, Nehal Sangoi [EMAIL PROTECTED] wrote:
Hi
I need to rotate logs in apache 2.0 once they reach the size limit of 5 MB.
What commands would work to carry out the reqd. job?
Thanks
Nehal
Hi
I tried this option. But it is working differently then what i am thinking
for.
I did follwoing entries in my httpd.conf file.
CustomLog |/appl/apache/bin/rotatelogs /appl/apache/logs/mod_jk.log 5M
common
CustomLog |/appl/apache/bin/rotatelogs /appl/apache/logs/SMLOG.txt 5M
common
CustomLog
Hi, I am also having the problem in rotatelogs for errorlogs. In this case, Unless giving it as Errorlog "|C:/app2/bin/rotatelogs.exe C:/log/log123 1M" it does not work. Means it requires to absolute path. But if I give Errorlog logs/apache.log then it works,and if the directory
Nehal Sangoi wrote:
Hi
I tried this option. But it is working differently then what i am thinking
for.
I did follwoing entries in my httpd.conf file.
CustomLog |/appl/apache/bin/rotatelogs /appl/apache/logs/mod_jk.log 5M
The second arg to rotatelogs provided with Apache is the number of
The second arg to rotatelogs provided with Apache is the number of seconds
after which the log gets rotated. So the above command rotates logs every
5 seconds.
Joost
The synpsis is
rotatelogs [ -l ] logfile [ rotationtime [ offset ]] | [ filesizeM ]
so you can only use it with seconds or