View
512
Download
3
Category
Preview:
DESCRIPTION
Slides from a presentation on managing Windows debugging symbols files.
Citation preview
A Great Clash of Symbols
Managing and Using Symbol Files
for .NET Applications
Presented by
Gregory M. Sohl
Agenda
Symbols
Visual Studio Symbol Usage
Other Tools Symbol Usage
Places to Store Symbols
Keeping Symbols with NuGet Packages
Symbols
Produced by .NET compilers
Stored in PDB files
Contain – much less than for native Source file names Line # references Local variable names Only the info that is not already contained in
managed assemblies
Symbol File Creation
Created at compile time
A unique GUID is embedded with each compile In the assembly In the PDB
Mismatched assembly + PDB
Kinds of Symbol Files
Private / Debug Debug Info = full Full debugging experience
Public Debug Info = pdb-only Examine stack traces, dumps, Intellitrace
Generally, don’t do “full” for release builds due to performance hit
Keeping Symbol Files
Symbols are as important as source! Use with dumps from QA/production Use with Intellitrace from QA/production
Without matching Symbols files, working with either much more difficult
What to Keep
Local developer builds?
Builds released to QA?
Builds released to production?
Builds released to customers?
NO
YES
YES
YES
How VS Finds Symbols
It uses a search path Folder relative to the binary
c:\MyDir\symbols\dll
c:\MyDir\dll
c:\MyDir
Configured paths, cache and Symbol Server Environment Variable: _NT_SYMBOL_PATH Tools / Options / Debugging / Symbols
List of Search Paths
Supported Search Paths
Local drives
Network drives
Symbol server Ex. srv*http://msdl.microsoft.com/download/symbols
Local cache (highly recommended) Ex. cache*c:\MySymbols;
Simple Search Path Setup in VS
DEMOVS DEBUGGING
Other Tools Symbol Usage
WinDbg / SOS – Low level debugger
Intellitrace – Runtime event recorder
Keeping Your Symbols
Application & Library Symbols Store them with your release on a file share Copy them back into place as needed for
debugging
Keeping Your Symbols
Put them on a Symbol Server symstore – part of the Windows SDK
Reference stored symbols via file path SymbolSource.Server.Basic
http interface to symstore
Stores NuGet packages & symbols
bit.ly/SymbolSourceServerBasic NuPeek
Stores NuGet packages & symbols
https://bitbucket.org/thinkbeforecoding/nupeek
Keeping Your Symbols
TFS Build System Can store source, binaries and symbols Good blog post:
http://bit.ly/TFSSourceSymbols
My Goal
Move from CruiseControl.NET to TFS Builds
Use TFS Build Management For
Binaries
Symbols On
All QA Builds with retention for 2-3 months
All Release Builds with retention as long as they are in use.
Recommended