Getting full user mode dumps automatically when your process crashes

I recently got a question about if it is possible to generate full user mode dumps automatically every time the process crashes (without having debug diag or adplus installed and monitoring your system).

This would be useful for example if you are setting up a site, and you want to make sure you get dumps if it ever crashes so that you don’t have to repro the issue at that point, just to get data.

It turns out that starting with Windows Server 2008 and Vista + SP1, Windows Error Reporting (WER) will let you do just that.  It even worked on my Win 7 machine. http://msdn.microsoft.com/en-us/library/bb787181(VS.85).aspx

The documentation here says that “Applications that do their own custom crash reporting, including .NET applications, are not supported by this feature”.  It’s a bit hard to tell what this actually means but I think this is added here due to ambiguity about what constitutes a crash.

For example if you have an exception in an ASP.NET application that is handled by the ASP.NET error handler (i.e. showing you the yellow ASP.NET error page) that is not a “crash” since ASP.NET handles the error, and the process just continues.  However for example a StackOverflow, or any unhandled .net exceptions on finalizers or non-request threads, that cause the process to “terminate unexpectedly” will be caught by WER and produce a dump if you configure it to do so.

See the original post here:
Getting full user mode dumps automatically when your process crashes

Tags: ASP.NET, Crash, debugging, dump

Comments are closed.