开发者

log4net - Missing logs

We're using log4net in a number of our services. Most of the time it works flawlessly. However, we'll occ开发者_高级运维asionally see log4net "freezes" for a period of time before continuing to work normally. For example, the logs below shows that log4net was "frozen" for over 4 hours. We know this application is verbose, so we expect to see logs written every second.

2010-11-04 04:02:09,393 DEBUG Some message...
2010-11-04 08:48:07,114 DEBUG Some other message...

Another problem we'll occasionally see is that entire log files get deleted. We have log4net configured to roll over by date. Sometimes we'll see that an entire weeks worth of logs go missing. Is log4net mistakenly deleting these logs files? We do not have log4net configured to keep a number of logs.

Has anyone encountered this before?


I have not seen this, but remember that Log4net is designed to continue even if it can not log its information - See this FAQ Article

If anything locks the log file (eg Backup/AntiVirus) then you will get missing information.

You could trying running DebugView to see if any such warning appears when the logging fails or perhaps configure log4net to keep its own logs (see another FAQ Article )

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜