Most bugs are fairly simple, easily reproducible, and easy to debug. What do you do when you run into ones that are hard or impossible to repro under debugger, i.e.one of these?
Our app is a multi-threaded app that is furthermore complicated by the fact that it communicates with multiple clients via remoting and sometimes there're bugs that can take weeks to track down, and sometimes we can't even be sure that the problem is fixed because of it's inconsistent nature, it could be that it's just coincidence that the issue hasn't been seen for a while.
We already have an error reporting system so if we're lucky and the bug throws an exception we'll get a stack trace, but even that's not always enough because it's not obvious from the stack for instance how a certain value turned out to be null (for example). This is especially true when an exception occurs in a worker thread (which is the case most times.
And then you have ones that don't even throw exceptions, it's just unexpected behavior. But it only happens a small percentage of times.
This is in .NET so some of the memory/pointer work is hidden away, but we have many 3rd party components that aren't managed code and a fair amount of COM interop so it still gets a little tricky.
Obviously there's no straightforward answers since I'm not asking about a specific bug but what are some general concepts principles and tactics to go about tackling these kinds of problems?