Leon Meijer's Weblog

About my personal life, technology and business/work related...
posts - 128, comments - 305, trackbacks - 0

Migrate TFS 2005 to a domain environment

I successfully migrated my TFS 2005 machine to a domain environment by following a few steps. The machine is a Win2003 Standard Edition x32 with Team Foundation Server 2005 Workgroup Edition and Visual Studio 2005 and 2008 are locally installed.

The steps are:

  • Inform users that the server will be offline for a while;
  • Backup the TFS (SQL Server) and Reporting Services databases;
  • Take snapshot in VMWare Server (as a backup);
  • Connect the TFS machine with a VPN to the network where the Active Directory resides;
  • Join the machine to the domain;
  • Reboot;
  • Log on with a domain account (Administrator-rights);
  • The Active Directory accounts have to be known at the TFS machine (the drive:\Documents and settings\username folder has to be there). I did this by running Management Studio with 'Run As...' and specifying the username, password and the name of the domain;
  • Open a command prompt to drive:\%ProgramFiles%\Microsoft Visual Studio 2005 Team Foundation Server\Tools,
    • Run TfsAdminUtil ChangeAccount OldDomainOrOldComputerName\OldTFSServiceAccount NewDomainOrNewComputerName\NewTFSServiceAccount NewPassword
    • Run TfsAdminUtil ChangeAccount OldDomainOrOldComputerName\OldTFSReportingServiceAccount NewDomainOrNewComputerName\NewTFSReportingServiceAccount NewPassword
  • IISReset to be sure;
  • Log off and log on again on with a local account (which was member of the TFS Licensed Users group);
  • Connect to Team Explorer, go to the Group Membership and add the domain accounts to the TFS Licensed Users group;
  • Log off and log on again with a domain account;

The environment migration is now complete. It's a good practice to clean up the local workspaces (although they may not exist, because you have a new domain account profile). To do this,

  • Open a Visual Studio 2005 or 2008 command prompt;
  • Run tf workspaces /remove:*

If I run Visual Studio now I get this error:

"System.Web.Services.Protocols.SoapException: The working folder <path> is already in use by another workspace on this computer."

This happens because the workspace I deleted in the steps above is only deleted locally. The server still things we have a workspace somewhere else.

This is what I did to fix it:

  • Log in with an account that has 'Administer Workspaces' permissions;
  • Open a command promt to drive:\%ProgramFiles%\Microsoft Visual Studio 2005 Team Foundation Server\Tools,
    • Run tf workspace /delete [workspacename];[domain]\[username] /server:[servername]

For example, let's say my computer name is SERVER01. The command will be: tf workspace /delete SERVER01;SERVER01\Leon /server:localhost

 

Hope this helps,

Print | posted on Tuesday, March 04, 2008 1:00 AM |

Feedback

Gravatar

# re: Migrate TFS 2005 to a domain environment

You have to be careful with this:

If you have event subscriptions on your old account (servername\user) and you make the same subscriptions with your new account (domain\user account) then you'll receive duplicate events from TFS! This especially annoying if you have a service listening to events....

You can query the TfsIntegration.dbo.tbl_subscription and join it with tbl_security_identity_cache to see if you have these kind of "old" subscriptions.
Then you can use the BisSubscribe tool to remove these.
3/5/2008 12:01 PM | thijs

Post Comment

Title  
Name  
Email
Url
Comment   
Please add 4 and 1 and type the answer here:

Powered by: