You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-user@logging.apache.org by Tech Apprentice <te...@yahoo.com> on 2005/06/30 18:05:28 UTC
log4j:ERROR Failed to rename
Hi All:
I am having problems with the DailyRollingFileAppender. I am using Log4j ver. 1.2.9 with Tomcat 5.0. My log file is recreated at midnight but the previous log file is not saved. I find the following error in the stdout.log file of Tomcat.
log4j:ERROR Failed to rename [C:/Tomcat5.0/logs/AphroditeTracer.log] to [C:/Tomcat5.0/logs/AphroditeTracer.log.2005-06-30-08-49].
My log4j.xml file is as follows:
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/">
<!-- A time/date based rolling appender -->
<appender name="FILE" class="org.apache.log4j.DailyRollingFileAppender">
<param name="File" value="C:/Tomcat5.0/logs/AphroditeTracer.log"/>
<param name="Append" value="false"/>
<!-- Rollover at midnight each day
<param name="DatePattern" value="'.'yyyy-MM-dd"/>-->
<!-- Rollover at the top of each minute-->
<param name="DatePattern" value="'.'yyyy-MM-dd-HH-mm"/>
<layout class="org.apache.log4j.PatternLayout">
<!-- The default pattern: Date Priority [Category] Message\n -->
<param name="ConversionPattern" value="%d %-5p [%c] %m%n"/>
</layout>
</appender>
<root>
<priority value ="info" />
<appender-ref ref="FILE" />
</root>
</log4j:configuration>
When I searched in the mailing list, I found that many people had this saem problem but I couldn't find a solution that I could understand so if anyone can please help me with this problem it will be great.
Thank you,
Techie Jr.
---------------------------------
Yahoo! Sports
Rekindle the Rivalries. Sign up for Fantasy Football