Article ID: 957110 - Last Review: August 21, 2008 - Revision: 1.1

How to move a project under source control from one TFS Server to another

System TipThis article applies to a different operating system than the one you are using. Article content that may not be relevant to you is disabled.
Expand all | Collapse all
Source: Microsoft Support

RAPID PUBLISHING

RAPID PUBLISHING ARTICLES PROVIDE INFORMATION DIRECTLY FROM WITHIN THE MICROSOFT SUPPORT ORGANIZATION. THE INFORMATION CONTAINED HEREIN IS CREATED IN RESPONSE TO EMERGING OR UNIQUE TOPICS, OR IS INTENDED SUPPLEMENT OTHER KNOWLEDGE BASE INFORMATION.

Action

You have Team Foundation Server 2005 or 2008, and you have a Visual Studio project under source control. You want to unbind it from source control on the current server and add it to source control on another server. After unbinding the project from source control on the first server, you try to add it to source control on the second TFS server.

Result



You receive the following message:

The solution is in a directory mapped to team server http://<Original_TFS_server_name>:<port>.
Continuing will close the existing team server Target_TFS_Server and open team server http://<Original_TFS_Server_name>:<port>/ Continue?

Cause

The VersionControl.config file located in the Team Foundation Cache folder contains information that references the original TFS Server.

Resolution



1. Unbind the project from the first TFS server.
  • In Visual Studio, click the File menu, then click "Source Control", then click "Change Source Control".
  • In the resulting dialog, select the project and solution and click the Unbind button.


2. Exit Visual Studio.

3. Open Windows Explorer and navigate to the following folder on your local machine where Team Explorer is installed:

%userprofile%\Local Settings\Application Data\Microsoft\Team Foundation\1.0\Cache

on Windows Vista and Server 2008, this folder is:

%userprofile%/AppData\Local\Microsoft\Team Foundation\1.0\Cache

Rename the VersionControl.config to VersionControl.old.  You may want to clear out all the all the files and folders in the Cache folder.  It will not hurt anything, and may prevent future problems.

4. Restart Visual Studio  and connect to the new TFS server.

5. Add the solution to source control on the new TFS server.

You can find more information on this problem, as well as a workaround using the TF workspaces command in this blog post:

How to handle "The path X is already mapped in workspace Y" (http://blogs.msdn.com/buckh/archive/2006/09/12/path-is-already-mapped-in-workspace.aspx)

DISCLAIMER

MICROSOFT AND/OR ITS SUPPLIERS MAKE NO REPRESENTATIONS OR WARRANTIES ABOUT THE SUITABILITY, RELIABILITY OR ACCURACY OF THE INFORMATION CONTAINED IN THE DOCUMENTS AND RELATED GRAPHICS PUBLISHED ON THIS WEBSITE (THE “MATERIALS”) FOR ANY PURPOSE. THE MATERIALS MAY INCLUDE TECHNICAL INACCURACIES OR TYPOGRAPHICAL ERRORS AND MAY BE REVISED AT ANY TIME WITHOUT NOTICE.

TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW, MICROSOFT AND/OR ITS SUPPLIERS DISCLAIM AND EXCLUDE ALL REPRESENTATIONS, WARRANTIES, AND CONDITIONS WHETHER EXPRESS, IMPLIED OR STATUTORY, INCLUDING BUT NOT LIMITED TO REPRESENTATIONS, WARRANTIES, OR CONDITIONS OF TITLE, NON INFRINGEMENT, SATISFACTORY CONDITION OR QUALITY, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE, WITH RESPECT TO THE MATERIALS.

APPLIES TO
  • Microsoft Visual Studio 2005 Team Foundation Server
  • Microsoft Visual Studio Team System 2008 Team Foundation Server
Keywords: 
kbnomt kbrapidpub KB957110