TFS Power tool TfsServerManager connecting from a non domain joined computer

*Moved to: http://fluentbytes.com/how-to-share-work-item-templates-in-your-team/

Last week at the MVP summit we got a great demo of the features that are in the just released power tools. One of them is the new TfsServerManager tool that you can use to look at your TFS server and it’s overall health and performance.

The tool can be found after installation in the “Program FilesMicrosoft Team Foundation Server 2008 Power Tools” folder and is called TfsServerManager.

I did ran into one issue and that is caused by the fact that I am not working on a machine that is joined to our domain. therefore I always need to supply credentials to fain access to the TFS server. This also happens with the tool, only after providing credentials I was confronted with a message: Login failed for user ‘marcelv’

after some digging around it appears that the tool not only connects to the web services of the TFS server, but also directly connects to the TFS database. While I am an admin on the database, it was not possible to connect to the database. This was caused by the fact that the application just runs as my local user and that user is unknown in the database. To resolve this issue, I created a small command script that runs the application in the security context of my domain user. This way the tool will authenticate as the domain user marcelv and then it is able to connect to the SQL server.

C:WindowsSystem32runas.exe /netonly /user:[yourDomain][yourUserName] TfsServerManager.exe

After I was connected I took a look at the statistics page. There I found to my surprise that the TFS server was up and running for only a few hours. I asked our TFS admin and he did not know better than the server is up and running for several days and we only had a reboot a month ago to run the latest updates.

It appears the time reported here is a value in TFS and refers to how long TFS has been up, not the server. (So last restart does not refer to a reboot of the serer!) There are many things that can cause TFS to shut down. E.g The app pool may be configured to recycle after a number of minutes, when idle for so much time or when certain memory thresholds are hit.

One other feature I find particular useful is the option to view the workspaces, shelve sets and labels.  This way you can see if there a stale workspaces and shelvesets that can be cleaned from the server. My first run already resulted in 50 workspaces and about 20 shelve sets that where never accessed for the past year. So it is good practice to run this tool once in a while and see what you can clean on your server.

Cheers,
Marcel

Follow my new blog on http://fluentbytes.com