TFS 2012 with Update 2 - Done

At SSW, we make sure we keep ourselves up to date with the latest version of everything, we were one of the first to upgrade our TFS 2010 instance to TFS 2012 RC, then to the RTM when that became available, and finally to Update 1 earlier this year.  Today, I'm happy to announce we have upgraded to TFS 2012.2 (or TFS 2012 Update 2).

Summary

One of the major changes with this version is the installation story.  Microsoft has done a lot of work to help ease your upgrade path, so you'll notice the upgrade is much more straightforward than previous ones.

This update remembered the vast majority of our settings, so there was less need to reconfigure everything after the install.  I like to err on the side of safety though, so I followed our standard steps:

  1. Screenshot our existing configuration
  2. Back up the databases and snapshot the servers
  3. Stop the TFS services
  4. Install TFS 2012 Update 2
  5. Configure TFS 2012 Update 2
  6. Test, test, test!

Before you start

Just as we did last time, the first step was to send an email letting everyone know there would be a TFS outage.  See our Rules to Better Networking for an example of how to do it.

If you’re doing the upgrade, you’ll also need administrator access to the servers. Just as last time, I got promoted temporarily so I could do my work.

Preparation Steps – save your existing configuration

The release notes for TFS 2012.2 claim that all your settings will persist, but just in case, I opened the TFS Administration Console and took a screenshot of each summary page and ended up with 4 images.  This ensures I don’t forget any of the settings if I need them.

Once I’d saved everything I need, I could get going on the install.

Preparation Steps – stopping the servers and backing up

  1. Review the Rules to Better TFS 2012 Migration to make sure what you need to do.  In line with these rules, I took the TFS server offline. This is important because we don’t want any checkins or work item changes to come through while we’re halfway through the process.  They may miss the upgrade!
    1. Use TFSServiceControl quiesce to stop all the agents. Note: Once again  I got a number of exceptions, but the process automatically retries and succeeds.  The important parts are highlighted in yellow. TFS Quiesce
    2. Stop the relevant network services TFS Net Stop WAS
    3. Verify that you can’t connect to the TFS server by trying to connect in Visual Studio TFS unavailable in VS And that you can’t visit TFS Web Access TFS Web - 404


  2. As per our rules,  it’s a good idea to run the DogFood Stats queries from Grant Holliday. Document the numbers so you can compare them after the upgrade to make sure you haven’t lost anything.  If you have more than one Project Collection, make sure you do this over every Project Collection you care about.
  3. Back up the TFS and Reporting Server databases as per our rules. We have a few relevant databases because we have a number of Project Collections.
    TFS Backup Collections

Installing TFS 2012.2

  1. Because we’re installing from an ISO rather than a physical CD, we mount the ISO using SlySoft’s Virtual CloneDrive (or your favourite alternative).
  2. Run tfs_server.exe from the installation disk or ISO.
  3. Accept the license terms and click Install Now. TFS 2012.2 Install
  4. Watch the progress with excitement and trepidation (and coffee) TFS 2012.2 Installingssw-coffee

Configuring TFS 2012.2

  1. The Upgrade Wizard should start automatically this time (previously you had to choose it) and it will collect your settings for you! Upgrade Wizard collecting settings
  2. When it's done, you can click Next.
  3. We’re now asked to upgrade an existing database.  Because of the work done with upgrades, the tool should have these details already filled out. Upgrading the Database
  4. Confirm you have a current backup, then click Next.
  5. Next, we’re asked for the service account for our Application Tier.  Again, this should already be filled out. Once you've provided the password again, check it by clicking Test, then click Next. Application Tier settings
  6. Next up, we’re asked if we want to configure SQL Reporting Services.  Make sure the checkbox is checked, then click Next.
  7. Again checking your screenshots, make sure the instance and URLs for your Reporting Services instance are correct (they should be), and click Next. TFS Reporting Services config
  8. Next up is the TFS Warehouse database.
  9. The wizard should have already filled this out for you.  If everything is correct, click Next. Warehouse Database settings
  10. Next, you’re asked for your Analysis Services instance.  Check the instance name before clicking Next.
  11. Next, we’re asked to provide an account that the Reports will run as.  Again, this should already be filled out by the wizard, but you'll have to provide a password. Do so, then click Next.
  12. Next we’re asked if we want to configure SharePoint for TFS, we do, so we’ll make sure the checkbox is checked and click Next.
  13. Once again, the wizard should have kept all our existing settings.  We'll check they're correct by clicking Test, then click Next. SharePoint settings
  14. On the next screen, we’ll get a summary of all the options we've chosen.
  15. Go through them carefully to make sure everything is correct, and click Verify to check. TFS config confirmation
  16. Your Verify step may highlight issues such as restarts required.  I once again got this issue and had to reboot the server before continuing. As per our upgrade to the RTM, I got stuck in a reboot loop and had to follow Steve Wiseman's advice to break out of it. Once fixed, I had to click Configure Installed Features on the Application Tier node then choose Upgrade to start the wizard again.
  17. Once the readiness checks pass, click Configure Readiness Checks
  18. Wait patiently (again with coffee) while the upgrade goes through its steps.  When finished, click Next. Final Configuration
  19. Once the TFS upgrade has finished, the Upgrade Wizard will upgrade each of the Project Collections. Be patient while it does this. Project Collection Upgrades ssw-coffee
  20. At this point I ran the Dog Food Stats again (as per step 9) and checked that nothing had changed too much.  This time, all the numbers were exactly the same which is reassuring

Additional steps

  1. I also upgraded Team Foundation Server on our Build Servers by installing the upgrade and checking the settings were the same.
  2. I had to reconfigure our Build Agent to get it working again - it was running under the wrong account.

Testing

After the final steps were completed, we went through the following tests to make sure everything was up and running again.

  1. Open Visual Studio and connect to TFS
  2. Do a Get Latest
  3. Make a change and check in
  4. Trigger a build and wait for it to succeed
  5. Check TFS Web Access is working by navigating to the TFS URL
  6. Check the Reporting Services are still working by navigating to the reporting URL

All the tests passed without a problem, so we’re up and live on TFS 2012 Update 2!

There is a lot of goodness in this update for everyone - have a look at the blo

Damian Brady

I'm an Australian developer, speaker, and author specialising in DevOps, developer process, and software architecture. I love Octopus Deploy, Visual Studio Team Services, and reducing process waste.