[opencms-dev] how-to configure a rotation log for opencms 5.0.1

Jonathan Woods jonathan.woods at scintillance.com
Sat Jun 3 07:13:36 CEST 2006


Yes, the logging config file should be able to do what you need.  It's
actually at <opencms web app>/WEB-INF/config/log4j.properties, and the lines
you are interested in are near the end:


# Limit log size to 5mb, then rotate
log4j.appender.OC.MaxFileSize=2mb

# Keep 5 backup files
log4j.appender.OC.MaxBackupIndex=5

Change these, restart OpenCms and you should be OK.

Jon 

-----Original Message-----
From: opencms-dev-bounces at opencms.org
[mailto:opencms-dev-bounces at opencms.org] On Behalf Of Christian Steinert
Sent: 02 June 2006 23:13
To: The OpenCms mailing list
Subject: Re: [opencms-dev] how-to configure a rotation log for opencms 5.0.1

miguel schrieb:
> Dear All,
>   I manage a site with opencms 5.0.1/Tomcat 4.1/Oracle 8.1.7, and I 
> have a problem with the log file opencms.log, this file grow too much 
> and it's impossible to manage. Anybody know how-to configure a 
> rotation process for this file?
> Have Opencms any way to do?, or I need a external tool...
>
> Thanks
>
If I remember correctly then the opencms.properties file (in the real
filesystem under  <opencms web application>/WEB-INF/config/) contains some
log configuration. There you can also set the maximum log size if I remember
correctly.
I *THINK* that the log would then be rotated after reaching the maximum
sizebut I'm not sure and I don't have opencms5 here anymore to take a look
into the property-file.

Using an external tool might lead to problems. If you try to "steal" the log
file from opencms then it might have trouble with continued logging until
the next shutdown. But it's worth a try, if the configuration itself doesn't
help. A simple shell script which you can put into your crontab (if it's a
linux/unix machine) should help with renaming the files.

c.

_______________________________________________
This mail is sent to you from the opencms-dev mailing list To change your
list options, or to unsubscribe from the list, please visit
http://lists.opencms.org/mailman/listinfo/opencms-dev





More information about the opencms-dev mailing list