Thursday, June 17, 2010

Migrating TFS 2008 from SQL 2005 to SQL 2008 (R2)

I have been tasked with upgrading our TFS 2008 instance to TFS 2010.  However, our current environment is a TFS 2008 dual-server deployment running on a SQL 2005 database server, and TFS 2010 requires SQL Server 2008.  In order to upgrade to TFS 2010, our current TFS 2008 instance must be migrated over to run against a SQL 2008 database server.

After quite a bit of searching and reading a variety documentation, I came to the conclusion that there doesn’t seem to be an official Microsoft document that describes this process.  The closest thing to this was the endorsement of this article by several of the TFS folks.  I highly recommend reading this article, as it is about 99% of what you’ll need to do in order to have a successful migration.

There is one gotcha that is very important or the process will fail when you try to move the TFS databases.  You must install a TFS 2008 with SP1 integrated on a separate (or same) server configured to point to the new SQL 2008 database server to “prep” the database server and make sure all the necessary TFS components, jobs, and security roles are set up correctly.

Thus, before starting the process as described in the article, first create a new TFS 2008 instance with the database on the SQL 2008 instance you will be migrating too.  Then you can begin following the instructions in the referenced article.

In addition, I unprovisioned WSS from the application tier server and re-provisioned it (by running the Sharepoint Products and Technologies Configuration Wizard), and then created a new web application on port 80, and then restored the content database and configured it to use the restored content database.  I wanted to move all WSS databases (Admin, Config, and Content) and simply moving the Content was not sufficient.  Note if you do this, you’ll probably need to reinstall the WSS extensions for TFS as the last step.

One final comment – we used SQL Server 2008 R2 and the migration worked fine.  Just make sure your TFS install has SP1 integrated.

Other links I found helpful: