Hi,
I've searched Google and the Eyebrowse for this and can't find anything
relevant (EyeBrowse seems to have a lot of issues -- about half the links
I click on just lead to a stacktrace). I'm not sure if this is an issue
with log4net or my configuration. Any pointers are much appreciated.
Problem: my log files are rolled daily, but every day at noon the existing
data is blanked out of the log (the file is truncated). The effect is
that when I look at yesterday's file, I only see information for yesterday
after noon, not before noon. I have actually watched this happen; the
first statement that writes to the file after noon truncates everything
already in the file.
My version: 1.2.0.30714. I'm on Windows, MS.NET Framework v1.1.4322 using
Visual Studio 2003 and linking to the pre-built DLL from SourceForge.
Sample of my App.config file:
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<configSections>
<section name="log4net"
type="log4net.Config.Log4NetConfigurationSectionHandler, log4net" />
</configSections>
<log4net>
<appender name="FileAppender"
type="log4net.Appender.RollingFileAppender">
<file value="//server/share$/log/log-" />
<appendToFile value="true" />
<datePattern value="yyyy-MM-dd.\\tx\\t" />
<rollingStyle value="Date" />
<staticLogFileName value="false" />
<layout type="log4net.Layout.PatternLayout">
<conversionPattern value="%-5p %-20t %d %c line %L%n
%m%n" />
</layout>
</appender>
<root>
<level value="INFO" />
<appender-ref ref="FileAppender" />
</root>
</log4net>