Simon, There have been a number of fixes to the File & RollingFile appenders since 1.2.8. If you cannot upgrade the latest version you may want to consider taking the latest source for 2 appenders, back porting them where necessary, and building them into a new dll. You could then uses these appenders with the old 1.2.8 build of log4net, just specify the assembly qualified type name in the logging configuration.
Cheers, Nicko > -----Original Message----- > From: Simon Wallis [mailto:[EMAIL PROTECTED] > Sent: 28 October 2005 19:27 > To: Log4NET User > Subject: Re: log files get reset at 12:00 noon every day > > I'm using 1.2.8. Unfortunately I cannot upgrade to 1.2.9 > because I have written a set of log4net extensions and there > are a lot of small breaking changes in 1.2.9. > > I've been using 1.2.8 for almost a year and have not seen > this happen until now when I deployed my code to a set of new > servers. I'll search the archives for your postings, but > unfortunately upgrading is not an option right now. > > Thanks, > Simon. > > -----Original message----- > From: Baron Schwartz [EMAIL PROTECTED] > Date: Fri, 28 Oct 2005 08:00:49 -0700 > To: Log4NET User log4net-user@logging.apache.org > Subject: Re: log files get reset at 12:00 noon every day > > > I had this problem as well a while ago. Upgrading solved > it. Search > > the mail archives for my message for specifics. Be sure > you are using > > the latest versions from the log4net site, not the > sourceforge site -- > > it is stale there. > > > > Simon Wallis wrote: > > > Yes, datePattern specifies when it should roll over. The > pattern I used specifies a daily roll over. The log files do > roll over correctly at midnight. So at midnight last night, a > new log file was created named WS.error.20051028.log (the > "log" appends "log" to the filename). > > > > > > But then, why does it roll over again at noon? The log > file will be full of entries until 11:59:59, and then the > next second the file is empty and starts to record again at 12:00:00. > > > > > > Again, this works on my local machine, but on the servers > Ive deployed it to it does the above strange behaviour. > > > > > > Does anyone have any clues??? > > > > > > Simon. > > > > > > -----Original message----- > > > From: Matthew Brown [EMAIL PROTECTED] > > > Date: Fri, 28 Oct 2005 05:34:25 -0700 > > > To: Log4NET User log4net-user@logging.apache.org > > > Subject: Re: log files get reset at 12:00 noon every day > > > > > > > > >><datePattern value=".yyyyMMdd."log"" /> > > >> > > >>Isn't datePattern the parameter to specify when the > rollover should > > >>occur? If it is, you have it set to daily. Not sure why it would > > >>choose 12pm rather than 12am but I am curious what effect the > > >>"log" string would have on that... > > >> > > >>On 10/27/05, Simon Wallis <[EMAIL PROTECTED]> wrote: > > >> > > >>>Hi, > > >>> > > >>>This is totally weird. Every day at 12:00 noon the log > files from our app> lication get reset. If I check them in > the morning, there are entries start> ing in the night, > there's entries throughout the morning, and then exactly > at > noon log4net seems to delete the file and recreate it, so all > the entrie> s from midnight until noon are deleted. > > >>> > > >>>This is only happening in our recently deployed QA and > production environ> ments. It works fine locally. I'm also > logging to a database and that is fi> ne. I made sure that > the Regional date settings (in control panel) are the > same, > I just have no idea why this is happening. It is quite bizarre. > > >>> > > >>>Here is the snipped from my log4net config file: > > >>> > > >>> <!-- ERROR LOG - text file that rolls on a daily > basis --> > > >>> <appender name="ErrorRollingFileAppender" > type="log4net.Appen> der.RollingFileAppender"> > > >>> <filter type="log4net.Filter.LevelRangeFilter"> > > >>> <levelMin value="WARN" /> > > >>> <levelMax value="FATAL" /> > > >>> </filter> > > >>> <rollingStyle value="Date" /> > > >>> <datePattern value=".yyyyMMdd."log"" /> > > >>> <file > value="D:\\myfolder\\Logging\\hidc2\\WS.error" /> > > >>> <appendToFile value="true" /> > > >>> <param name="StaticLogFileName" value="false" /> > > >>> <layout type="log4net.Layout.PatternLayout"> > > >>> <conversionPattern value="%d > %-7p %c "%m&> quot; %P{SessionId} %P{ProfileId} > %P{XmlData} %n" /> > > >>> </layout> > > >>> </appender> > > >>> > > >>>Is anything wrong with it? > > >>> > > >>>Thanks for your help, > > >>>Simon. > > >>> > > > > > > > > > > >