logging-log4net-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dominik Psenner <dpsen...@gmail.com>
Subject Re: IIS Deadlocks happening all the sudden after years of running with no issues
Date Mon, 22 May 2017 20:27:40 GMT
2017-05-22 18:38 GMT+02:00 Jim Scott <jscott@infoconex.com>:
>
> >> Did any modifications happen lately that you are aware of?
>
> The only thing I can see is that the box has been getting regular windows
> updates which of course includes .NET and OS updates. Could it be that
> something in the framework has changed behavior of something that is now
> creating this issue?
>

Not that I am aware of, but that means nothing.


>  >> Please note that it is known that an application can also cause
> log4net to deadlock [3].
> >> [3] https://issues.apache.org/jira/browse/LOG4NET-298
>
> This particular application is not using any async/task code so not sure
> if other scenarios apply?
>

That's not true. All it needs is two threads and the well known dead lock
candidates (waits, locks, ..). Does your web application pass objects on to
the logging framework or are all arguments converted to immutable types
(string, int, bool, ..)? If the logging framework calls ToString() of an
object, beware!


> >> Further there is also this issue [4].
> >> [4] https://issues.apache.org/jira/browse/LOG4NET-178
>
> We are not seeing an issue with logging stopping and we also changed our
> app pool recycle to a specific time rather than the default of 1720
> minutes. When we have had our deadlock issue it has not been during an app
> pool recycle (unless IIS was trying to kick the process for other reasons,
> although nothing in event viewer indicating something was trying to
> recycle). Anything in this particular bug that you think I might want to
> look at that still might be related even though the symptom is not the same?
>

No idea but at the same time this is not the first thing I would spend time
on.


>
>
> We have also installed Debug Diagnostics on the machine to take memory
> dumps and analyze the results and this made it really easy to determine the
> deadlock issue and provide the traces previously. If you have any
> suggestions for further diagnosing it would be appreciated. Was thinking
> that maybe I would have enabled log4net debugging?
>

That's a great starting point. Maybe something fishy jumps out that makes
it easier. You could further investigate the behavior of your web
application when the dead lock happened.

Please note also that 1.2.11 is from 2011 and rather old. Can you give a
newer log4net version a shot?

Cheers
-- 
Dominik Psenner

Mime
View raw message