You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4net-user@logging.apache.org by Gitit Amihud <gi...@yahoo.com> on 2005/06/26 12:54:26 UTC
RollingFileAppender stop write to log files
Hi
we use the log4net version 1.2.0.30714 below is part of the code that configure the log4net (we dont use the config file).I use .net 1.1,my process are multi threaded
it somtimes just stop writing to the log file. it happens when the file ended and it need to open new file. (I juess it dont succeed opening the new file)
after starting my program again it write to the file as needed(via log4net)
can you help me?!
thanks
rollingFileAppender = new RollingFileAppender();
rollingFileAppender.Name = "RollingFileAppender";
rollingFileAppender.Threshold = log4net.spi.Level.ALL; /////dynamic/////
rollingFileAppender.File = (m_bLimitedMode ? "" : m_strLogFilesPath) + m_strProcessName + "." + m_strLogFilesExt;
rollingFileAppender.AppendToFile = true;
rollingFileAppender.MaximumFileSize =50000 "MB";
rollingFileAppender.MaxSizeRollBackups = 60;
rollingFileAppender.RollingStyle = RollingFileAppender.RollingMode.Size;
rollingFileAppender.StaticLogFileName = false;
rollingFileAppender.DatePattern = "yyyy-MM-dd HH.mm";
rollingFileAppender.Layout = new log4net.Layout.PatternLayout(FILE_PATTERN_LAYOUT);
logger.AddAppender(rollingFileAppender);
rollingFileAppender.ActivateOptions();
---------------------------------
Yahoo! Sports
Rekindle the Rivalries. Sign up for Fantasy Football