SQL Server 2012 has very nice HADR technology built-in, AlwaysOn Availability Groups. It allows to have multiple replicas of selected databases across multiple servers, which can be even located across multiple sites. AlwaysOn itself provides mechanism to keep all replicas of database synchronized and up-to-date, as some of them might serve data for read-only purposes (for example reporting).
MSDN article: AlwaysOn Availability Groups (SQL Server) describes AlwaysOn technology in details. In this article I will focus on practical side of this HADR technology and how to get this up and running fast without any issues.
To test and demonstrate SQL Server 2012 AlwaysOn capabilities I built simple Lab environment on VMware Workstation as shown below. Lab contains 2 servers with Windows Server 2012 R2 Datacenter and SQL Server 2012 Enterprise.
Lab environment also contains Active Directory domain and Domain Controller, which is not shown on the diagram.
In order to get SQL Server AlwaysOn up and running we will complete following activities:
- Install Failover Clustering Role
- Configure Windows Server Failover Clustering
- SQL Server installation
- Demo database preparation
- Enable Availability Groups on SQL Server
- Creating AlwaysOn Availability Group
So, let’s get started…