问题
I would like to create a clone/copy of our production Collection on the same TFS Server to use as a sandbox/dev environment. Restoring a backup of the Collection and renaming it is easy enough, but I know there will be GUID conflicts (and probably other conflicts as well) when I try to attach the Collection.
Is there anyway around this? Or do I just need to procure a new server with a separate TFS instance?
Thanks in advance!
回答1:
General answer is NO.
But it is possible if not both collection are online/attach at the same time.
In the 2nd case do the following steps:
detach collection in TFS Admin Console
take a SQL Fullbackup
restore SQL Backup with a different database name
re-attach the original collection TFS Admin Console
attach the copied collection in TFS Admin Console and give it a different collection name
You'll get an warning that the collection conflicts Team Project ID and the collection stays offline.
if you want take the copied collection online you need to take original collection offline first than you can take the copy online.
If you want both collections work, you have to install a new server with a separate TFS instance. Then Move the team project collection to the new TFS instance.
来源:https://stackoverflow.com/questions/45551349/tfs-2017-clone-copy-a-collection-on-the-same-tfs-server