logging.xml MaxHistory problem
Manuel Haim
haim at hrz.uni-marburg.de
Thu Oct 20 12:59:46 BST 2011
Hi,
in our test setup, I am experiencing a strange behaviour on the
Shibboleth 2.3.2 IdP's logback logging:
The logfile rollover works fine, but the "MaxHistory" setting (as
described in
https://wiki.shibboleth.net/confluence/display/SHIB2/IdPProdLogging )
does not always ensure that old log files will be removed. If no log
data is written for a couple of days e.g. to the idp_audit.log (because
nobody logged in at the IdP), the old logfiles will not be deleted on
the next rollover.
Has anybody else experienced this? I remember that we switched to .gz
files some time ago, but we already had this problem with uncompressed
.log files before.
This is an excerpt of our logging.xml file:
<appender name="IDP_AUDIT"
class="ch.qos.logback.core.rolling.RollingFileAppender">
<File>/usr/share/shibboleth-idp/logs/idp-audit.log</File>
<rollingPolicy
class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
<MaxHistory>7</MaxHistory>
<FileNamePattern>/var/log/shibboleth-idp/logs/idp-audit-%d{yyyy-MM-dd}.log.gz</FileNamePattern>
</rollingPolicy>
<encoder class="ch.qos.logback.classic.encoder.PatternLayoutEncoder">
<charset>UTF-8</charset>
<Pattern>%msg%n</Pattern>
</encoder>
</appender>
-Manuel
More information about the users
mailing list