I manage a .NET web application that is hosted on individual customer servers within their own intranet, meaning that there are many instances of this app hosted in entirely separate, unrelated environments.
The application utilizes Log4Net.
On SOME customer instances, not all, the same set of specific methods executed within the same thread will ALWAYS fail to write to the log file. I have seen this enough times to know it is a substantial issue, but have not been able to recreate the issue on my own machine, nor do I know how to further troubleshoot it.
To clarify, let us say that the application frequently executes Method A which spawns a thread that executes Method B and Method C before ending. During the course of execution, all logs will be recorded from Method A, but no logs will be recorded from Method B or Method C. Every single time this logic is executed, Method A will always record its logs and Methods B and C will always fail. If I have ten customers hosting this application, this error may occur on 4 of them, but on all four that fail, it will always be Methods B and C that fail on all of them every time.
Thoughts on what to investigate or troubleshoot to identify why this may be occurring?
I have double checked the log4net configuration in the web.config files of several customers. The configurations are the same on both working and erroring environments.
I have updated the .NET framework and the log4net packages to the newest versions.
Michael Moldafsky is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.