Tuesday, 4 February 2014

SQL Server AlwaysOn with Team Foundation Server – a great team!

High Availability and Disaster Recovery are the first two items on the list for a TFS Administrator, as Team Foundation Server hosts a critical service for almost every company with a linked development team.

Frankly in the past delegating the HA story to someone else in the organization was a very common practice, as it is not something related to TFS – which is pretty agonostic about the SQL Server deployment topology or about the number of Application Tiers.

If you want to use SQL Server AlwaysOn in your deployment – apart from all the other technologies which can be involved (Windows Failover Clustering, SQL Server Clustering, VMs redundancy, etc.) – the only configuration needed is to create a SQL Server AlwaysOn Availability Group. You are going to get a replication between up to four different SQL Server instances so you can failover at anytime.

Given a Windows Failover Cluster and two different SQL Server instances, one on each node, you just need to do as it follows:


You launch the wizard, and you specify a name and, for now, no databases are going to be contained inside the Availability Group.

Then you can select the replica mode (synchronous or asynchronous) and you must specify a Listener, which is going to become the instance name you are going to use to configure Team Foundation Server.

Then – while configuring Team Foundation Server using the Advanced mode - you are going to need to specify the Listener and tick the box saying that it is a SQL AlwaysOn Availability Group. TFS will then configure some specific settings for it in the process.

Select AlwaysOn checkbox

It is extremely important to add all the databases, and each database must be backed up, otherwise you won’t be able to add them to the AG.

Eventually, do not forget it is not the only HA solution, and a good HA solution is composed by several technologies working together on a minded plan :)

Here you can find the MSDN page for the topic.


  1. This blog is really helpful for my database. It enhanced the area of my thoughts and pushed me beyond the boundaries. Work ethic of every point is different and represent a new way to improve myself.HPE LTO Ultrium 6250 Tape Drive

  2. Thanks for this nice post regarding, Image Clinic offers best cosmetic & plastic surgery clinic in Delhi, India. Aesthetic or cosmetic & plastic surgery by best surgeon and specialist with your cost. Find more information for best cosmetic surgery clinic of India at Image Clinic.