How to use a stack trace dump to debug an exception?

Charles H.

I received a trace dump of a stack overflow exception we were seeing in our application. We eventually found the problem without using the trace dump, but I am curious:

How can I use the trace dump of a thread in the future to more quickly diagnose an issue?

I understand that the hexadecimal numbers after a function name is some kind of offset in the compiled code. I do not know what four of the bottom five lines mean (the ones that start with 0x). I've assumed that that is referring to a location in our application's code; if it is, is there a way to determine where that line comes from in an application?

ntdll!ZwTerminateProcess  
KERNELBASE!TerminateProcess+2c  
clr!EEPolicy::HandleFatalStackOverflow+1c9  
clr!EEPolicy::HandleStackOverflow+1ac  
clr!COMPlusFrameHandler+9b  
ntdll!ExecuteHandler+26  
ntdll!ExecuteHandler+24  
ntdll!RtlDispatchException+127  
ntdll!KiUserExceptionDispatcher+f  
//Cut 40 lines here...  
clr!MethodDesc::DoPrestub+59d  
clr!ReflectionInvocation::CompileMethod+54  
mscorlib_ni+393a09  
mscorlib_ni+34e3bc  
System_Core_ni+1bf152  
System_Core_ni+1bb05e  
System_Core_ni+3d0f57  
0x2413854b  
0x23df1ad3  
clr!ArrayNative::ArrayCopy+3ce  
0x20e680b9  
0x20e61c65  

Note: I'm not asking for help in debugging this specific issue, but how I can use something like this to debug future problems when all I have is the source code and a trace dump.

Dan Gartner

With just that stacktrace alone, you're probably not going to get very far. Those first 5 lines are stackframes, but there is no context likely due to lack of symbols.

If by trace dump, you mean memory dump, then you have a few options for debugging.

1) You can open the dump in Visual Studio - probably the easiest -- see here: http://msdn.microsoft.com/en-us/library/d5zhxt22.aspx

2) You can open the dump using WinDBG There's a bit of a learning curve, but it is a neat skill to have. I always point folks to Tess's blog to ramp on this. The posts are old, but still relevant: http://blogs.msdn.com/b/tess/archive/2008/02/04/net-debugging-demos-information-and-setup-instructions.aspx

If I were handed this stacktrace, I wouldn't waste a ton of time trying to determine what it means. I'd repro the issue and capture a crash dump and use one of the techniques above to determine root cause.

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Dev

How to use a stack trace dump to debug an exception?

From Dev

how to print stack trace to stdout in java for debug?

From Java

What is a stack trace, and how can I use it to debug my application errors?

From Java

How to print the stack trace of an exception object in Python?

From Dev

How can an Exception be created/thrown with no stack trace?

From Dev

How to print the stack trace of an exception object in Python?

From Dev

How does the console obtain the stack trace of an exception?

From Dev

How to print the selenium exception stack trace in Extent reports

From Dev

How to get stack trace string without raising exception in python?

From Dev

Python exception: how to print the last ten lines of stack trace?

From Dev

How to get stack trace string without raising exception in python?

From Dev

how to read full exception stack trace from errorChannel

From Dev

How to print the selenium exception stack trace in Extent reports

From Dev

Exception Stack Trace Missing Items

From Dev

Why is the exception stack trace not logged in?

From Dev

Dump debug logs if exception occured

From Dev

how to trace this stack and pointer

From Dev

Request repr() unavailable in Django 500 error email: how do I debug how to get the full stack trace?

From Dev

Request repr() unavailable in Django 500 error email: how do I debug how to get the full stack trace?

From Dev

Debug a stack overflow exception with nodejs

From Dev

Debug a stack overflow exception with nodejs

From Dev

Exception that emails stack trace when raised

From Dev

locals() and globals() in stack trace on exception (Python)

From Dev

Rethrow an Exception with correct line numbers in the stack trace

From Dev

logback: newline before exception stack trace but not otherwise?

From Dev

Exception stack trace and aggregation in Parallel.ForEach

From Dev

Suppressing stack trace when catching exception

From Dev

locals() and globals() in stack trace on exception (Python)

From Dev

cxf null pointer exception without stack trace

Related Related

  1. 1

    How to use a stack trace dump to debug an exception?

  2. 2

    how to print stack trace to stdout in java for debug?

  3. 3

    What is a stack trace, and how can I use it to debug my application errors?

  4. 4

    How to print the stack trace of an exception object in Python?

  5. 5

    How can an Exception be created/thrown with no stack trace?

  6. 6

    How to print the stack trace of an exception object in Python?

  7. 7

    How does the console obtain the stack trace of an exception?

  8. 8

    How to print the selenium exception stack trace in Extent reports

  9. 9

    How to get stack trace string without raising exception in python?

  10. 10

    Python exception: how to print the last ten lines of stack trace?

  11. 11

    How to get stack trace string without raising exception in python?

  12. 12

    how to read full exception stack trace from errorChannel

  13. 13

    How to print the selenium exception stack trace in Extent reports

  14. 14

    Exception Stack Trace Missing Items

  15. 15

    Why is the exception stack trace not logged in?

  16. 16

    Dump debug logs if exception occured

  17. 17

    how to trace this stack and pointer

  18. 18

    Request repr() unavailable in Django 500 error email: how do I debug how to get the full stack trace?

  19. 19

    Request repr() unavailable in Django 500 error email: how do I debug how to get the full stack trace?

  20. 20

    Debug a stack overflow exception with nodejs

  21. 21

    Debug a stack overflow exception with nodejs

  22. 22

    Exception that emails stack trace when raised

  23. 23

    locals() and globals() in stack trace on exception (Python)

  24. 24

    Rethrow an Exception with correct line numbers in the stack trace

  25. 25

    logback: newline before exception stack trace but not otherwise?

  26. 26

    Exception stack trace and aggregation in Parallel.ForEach

  27. 27

    Suppressing stack trace when catching exception

  28. 28

    locals() and globals() in stack trace on exception (Python)

  29. 29

    cxf null pointer exception without stack trace

HotTag

Archive