Freigeben über


Enabling Symbol and Source Server Support in TFS Build 2010

One of the really nice new features in TFS Build 2010 is support for symbol and source server. While the names “Symbol Server” and “Source Server” are somewhat misleading (there isn’t really a separate server involved), the functionality is really useful. Symbols are those *.pdb files that get generated by your builds. Those files make it possible to map execution points in your assemblies to their corresponding class and method. “Source Server” support makes it possible for the debugger to locate the correct version of the source file from the version control repository – particularly useful for server builds where the version of a file used in the build may differ from the version in your local workspace.

Here are the steps for setting up symbol server with TFS Build 2010 Beta 1:

  • Create a network share to store your symbols (e.g. \\server\symbols) – the symbols beneath your drop folder are effectively copied to the symbol store location so that they’re available even if your drop folder isn’t
  • Grant the build service account write permissions to that share
  • Grant your team project contributors read access to that share
  • Edit your build definition and, on the Process tab, set the Index Sources parameter to true and the Path to Publish Symbols parameter to the UNC path of the symbol share you created

To use the symbols generated at build time, your users will need to do the following in Visual Studio:

  • Select Tools, Options from the Visual Studio 2010 main menu
  • Expand the Debugging item in the tree and select Symbols
  • Add the path to your symbol store (e.g. \\server\symbols) to the list of symbol file locations
  • Select the General node beneath the Debugging node and scroll down to the “Enable source server support” check box and make sure it’s checked (it’s unchecked by default) – this will allow VS to load the appropriate version of the source file you’re debugging

Now you’ll be able to debug server builds with full symbol and source server support. You’ll also be able to do historical debugging and profiling of server builds. Note that, by default, when a build is deleted due to a retention policy, its corresponding symbols will be deleted as well. You can, however, customize this behavior in the build definition editor’s retention tab.


@Midas79: You don’t need to install the Debugging Tools for Windows on your build machine to use this functionality. We include the required components with the build service install. Also, Aaron Hallberg has a blog post on Writing Custom Activities for TFS Build 2010 Beta 1.

Comments

  • Anonymous
    June 15, 2009
    The comment has been removed
  • Anonymous
    June 17, 2009
    Introduction Jim Lamb wrote a good post about Enabling Symbol and Source Server Support in TFS Build