I've been trying to work out the mechanics of CAS log rolling (cas.log,
perfStats.log), and my attempts so far at implementing in the CAS webapp itself
have not worked.
E.g. included apache-log4j-extras and up-versioned log4j to 1.2.16 in the
pom.xml, with log4j.xml containing:
<appender name="cas" class="org.apache.log4j.rolling.RollingFileAppender">
<param name="File" value="logs/cas.log" />
<param name="MaxBackupIndex" value="10" />
<rollingPolicy class="org.apache.log4j.rolling.TimeBasedRollingPolicy">
<param name="FileNamePattern" value="logs/cas-%d{yyyyMMdd}.gz" />
</rollingPolicy>
<layout class="org.apache.log4j.PatternLayout">
<param name="ConversionPattern" value="%d %p [%c] - %m%n"/>
</layout>
</appender>
So either I'm doing something wrong, or I should let the container (Tomcat)
roll the logs, cf. mention of 'logrotate' (available on some flavors of Linux)
here http://wiki.apache.org/tomcat/FAQ/Logging. I don't mind doing the latter
if that's a better solution than asking the webapp to take responsibility for
log management.
Ideas?
Thanks.
Tom.
--
You are currently subscribed to [email protected] as:
[email protected]
To unsubscribe, change settings or access archives, see
http://www.ja-sig.org/wiki/display/JSG/cas-user