Solved

Local Variable name/value dump

Posted on 2007-11-14
7
298 Views
Last Modified: 2013-12-17
I'd like a system dump upon exception of all local variables (names and values) at the time of the crash. I wonder. This may require reflection, at which I am clueless.  
Any ideas?
0
Comment
Question by:andremara
  • 4
  • 3
7 Comments
 
LVL 37

Expert Comment

by:gregoryyoung
Comment Utility
What you probably want is to use a minidump (this is the standard way of doing this)

http://www.codeproject.com/debug/postmortemdebug_standalone1.asp?df=100&forumid=3419&exp=0&fr=26 includes examples ...

Cheers,

Greg
0
 

Author Comment

by:andremara
Comment Utility
THAT is really wild stuff Greg.  I'm gonna have to read it a few times, but I think I'll use symbol server as well - to make the symbol load go smoother.  The question here is, (and maybe this is due to the brief example), does this thing display variable names and values as well?  The example only shows a call stack, which I already have with Environment.StackTrace.
Thanks
0
 
LVL 37

Accepted Solution

by:
gregoryyoung earned 250 total points
Comment Utility
It is a full memory dump of your application .... you can inspect threads, look at memory/locals, etc etc.

Doing with .NET you will want to look up a tool called SOS (Son of Strike) as well...

http://msdn.microsoft.com/msdnmag/issues/03/06/Bugslayer/ and http://msdn.microsoft.com/msdnmag/issues/05/05/JITCompiler/default.aspx?side=true are worth reading (as is the whole bugslayer series which are generally by John Robbins). This is a huge topic ... so huge in fact that John has about a 1000 page book on the subject http://www.amazon.com/Debugging-Applications-Microsoft-Windows-Pro-Developer/dp/0735615365/ref=sr_1_13?ie=UTF8&s=books&qid=1195087368&sr=1-13 and http://www.amazon.com/Debugging-Microsoft-NET-2-0-Applications/dp/0735622027


Cheers,

Greg
0
Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

 

Author Comment

by:andremara
Comment Utility
Dude, your are a veritable encyclopedia!  Thanks.
Andre
0
 

Author Closing Comment

by:andremara
Comment Utility
over and beyond my expectations!
0
 
LVL 37

Expert Comment

by:gregoryyoung
Comment Utility
in particular in http://msdn.microsoft.com/msdnmag/issues/03/06/Bugslayer/ look at Figure 2 (the output from !CLRStack, it shows you locals + parameters)
0
 
LVL 37

Expert Comment

by:gregoryyoung
Comment Utility
Also if you like I have a presentation on this stuff from 2 years ago or so that I could email you the slides... just drop me a line this name@this site ...

Cheers,

Greg
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

IP addresses can be stored in a database in any of several ways.  These ways may vary based on the volume of the data.  I was dealing with quite a large amount of data for user authentication purpose, and needed a way to minimize the storage.   …
Today I had a very interesting conundrum that had to get solved quickly. Needless to say, it wasn't resolved quickly because when we needed it we were very rushed, but as soon as the conference call was over and I took a step back I saw the correct …
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
When you create an app prototype with Adobe XD, you can insert system screens -- sharing or Control Center, for example -- with just a few clicks. This video shows you how. You can take the full course on Experts Exchange at http://bit.ly/XDcourse.

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now