TFS2012: New tools for TFS Administrators

This is a brand new feature in TFS 2012 that hasn’t really been documented or talked about yet. If you’re a TFS administrator and you browse to this address on your server, you will see a new web-based administration interface for some things inside of TFS:


Activity Log

The first page that we see, is a view on the TFS Activity Log. Internally, TFS has two tables in the Tfs_Configuration and Tfs_CollectionX databases called tbl_Command and tbl_Parameter. This tables keep a record of every single command that every single user has executed against TFS for the last 14 days.

In this screenshot, you can see that the following columns are displayed:

  • Command Id – A unique ID (per database) given to the command execution.
  • Application – Which component of TFS does it relate to? Version Control, WorkItem Tracking, Framework, Lab Management, etc
  • Command Name – The server name of the command. You can usually work out what the equivalent client/API call is – but these command names are not documented anywhere.
  • Status – 0 = Success, –1 = Failure
  • Start Time – When was the request first received by TFS
  • Execution Time – How long did the command run for (Divide by 1,000,000 to get seconds)
  • Identity Name – The user name of the user who executed the command
  • IP Address – IPv4 or IPv6 address
  • Unique Identifier – Used to group/correlate multiple server requests that originate from a single client request.
  • User Agent – the ‘User-Agent’ HTTP Header from the client. Tells you the name of the executable if it’s using the TFS API and what version/SKU.
  • Command Identifier – When using the TFS Command Line tools, this helps you correlate to what command the user was using. ‘tf get’, ‘tf edit’, etc.
  • Execution Count – How many times was this command executed. The logging mechanism has some smarts to reduce the noise in the log. If you download a bazillion files, it doesn’t log a bazillion individual rows in the log. It just sets this value to a bazillion for that entry.
  • Authentication Type – NTLM or Kerberos.

Screenshot of TFS Activity Log Web Interface

One of the things the TFS Activity Logger does, is that it logs the parameters passed in with a request when:

  • The command fails (i.e. a status of != 0)
  • Or, the command takes longer than 30 seconds

You can see these parameters by double-clicking a row in the table:


At the top of the Activity Log screen, you can also filter the log based upon Host/Collection and Identity Name. This is useful if a particular user complains about slow performance or TFS errors – you can easily look at the server logs to see what the server is seeing.


You can also click the ‘Export’ link to download a CSV file of the same content.

If you’d like to know more about how to query or interpret the contents of the TFS Activity Log – grab a copy of my Professional Team Foundation Server 2012 book and look at Chapter 23 – Monitoring Server Health and Performance.

TFS Job Monitoring

Built-in to TFS is the TFS Background Job Agent. This job agent is responsible for the scheduling and queuing of maintenance jobs and other jobs within TFS. You can see my blog post on all the different jobs in TFS 2012 for more information.

If we click the ‘Job Monitoring’ tab, we get some fairly ugly charts that give us some insight into how long the jobs are taking to execute.


There is another chart further down the ‘Job Summary’ page that shows us the number of times that a job has been run, and what was the status of each of those runs.


We can click on one of the green bars in that chart, or the blue bars in the previous chat, or the ‘Job History’ link in the navigation bar to see a different view of the TFS jobs.

This view shows us the number of jobs that were executing at a particular time, the average time that they waited in the job queue, and the average run time.


If you then click the ‘Job Queue’ link in the navigation bar, you can see which jobs are currently queued, their priorities and when they are expected to start.


Comments (10)
  1. Jesse Houwing says:

    These are great! Much better than manually invoking the respective services from the Application tier.

  2. This is awesome!  Thanks Grant.

  3. Wade says:

    The tbl_Command and tbl_Parameter information is great to finally see without querying the database directly.  Is there any way to configure TFS for how long commands stay in the database or when paramaters are saved.  Working at a company with a high degree of regulatory oversight  2 weeks of security change history is severely lacking.

  4. @Wade – the cleanup setting is stored in the job definition in each of the configuration/collection databases. There was a supported way to change it in TFS2010 – but that doesn't seem to work anymore in TFS2012.…/tfs2010-update-activity-logging-cleanup-interval.aspx

    I'll find out a supported way to change it (via a servicing activity) and write a new blog post on it.

  5. vinod shalgar says:

    this is really great Grant, how many such hidden and unknown things which are not known or documented in TFS2012 :)



  6. This is really useful, thanks!!!

  7. Ramesh says:

    Grant, can you please tell me step by step after installing Admin report Pack and Performance report packs.

    where can we see the activity log..

    i installed these two in DB Server…

    Please help me

  8. Kevin says:

    It does not seem possible to control the filtering in the job monitoring tabs. The filtering in the activity tab does not apply to monitoring.. Any ideas?

  9. Nhan says:

    I got "Error: The page you are looking for is currently unavailable. Page not found". Any idea what's been wrong? How to get it up? Thanks

  10. Nhan says:

    We got it now. Just a permission issue. Great tool! Thanks.

Comments are closed.

Skip to main content