A Hyper-V replica installation provides a great opportunity for providing rapid disaster-recovery by asynchronously replicating a VM running at a primary site to a replica site across LAN or WAN to maintain a hot standby VM.
When it comes to high-availability in Hyper-V Server 2012, Quick & Live Migration two options are available:
Both options are intended to improve availability for Hyper-V but there still is no rapid Disaster Recovery with either of them. To make good this omission, Windows Server 2012 brings a rapid Disaster Recovery solution by means of Hyper-V Replica.
A Hyper-V Replica installation consists of a primary site where all Hyper-V hosts and the respective Virtual Machines are running. Besides the primary site there’s also a replica site. Hyper-V hosts are also located in this replica site but they contain replicas of virtual machines that are running in the primary site. Every five minutes, the primary site sends information regarding these last five minutes to the replica site where this information is replayed into the Hyper-V Replica.
When disaster strikes in the primary site, the virtual machines are still available in the replica site. Part of the disaster recovery process is taken up with firing up these virtual machines. Since the replication is an asynchronous mechanism, you will always face some data loss, though it should be very minimal.
It is a manual disaster recovery process so there’s always intervention from the sysadmin. This is in contrast to an automated high-availability solution such as the live migration that we discussed earlier, which has no downtime, unless an unscheduled outage occurs.
It is not really a disaster recovery solution for a high-end enterprise. These will need a fast and reliable solution that performs well and is capable of replicating large amounts of data to other datacenters. In these environments you typically see large SAN infrastructures that replicate their data to other locations.
Terms used in Hyper-V Replica:
Primary Server | A Windows Server 2012 server running with Hyper-V Role enabled is called a Primary Server which hosts Virtual Machines participating in the replication. The Primary Servers run on primary or production site. |
Replica Server | A Windows Server 2012 server running with Hyper-V Role enabled is called a Replica Server which accepts replication from Hyper-V Primary Servers. The Replica Servers run on replica or disaster recovery site. |
Primary Site | A site on which Primary Servers are located. |
Replica Site | A site on which Replica Servers are located. |
Primary Virtual Machine | A Virtual Machine that is enabled for replication and is running on Primary Server. |
Replica Virtual Machine | A copy of Primary Virtual Machine that is running on a Replica Server in a Replica Site. |
Hyper-V Replica API | Application Programming Interface (API) available with Hyper-V Replica. Vendors can use APIs provided with Hyper-V Replica to build a customized disaster recovery environment. |
VSS Snapshots | A process associated with Volume Shadow Copy Service to take point-in-time snapshots of volumes on the Operating System. |
Replication Engine | A component of Hyper-V Replica which is responsible for replicating the replicas to Replica Server. |
Network Module | A component of Hyper-V Replica which improves the network traffic over slow WAN links. |
Change Tracking | A component of Hyper-V Replica responsible for tracking changes to the Primary Virtual Machines. |
Standard Replicas | A ‘point-in-time’ copy of the Virtual Machine VHD file which is generated by the Primary Server and available to use with Replica Server at disaster recovery site when recovering a Virtual Machine. |
Test Failover | A mechanism implemented by Hyper-V Replica to perform tests on Replica Virtual Machine. |
Planned Failover | Planned Failover is initiated from Primary site to Replica site in case of any planned events or maintenance of Primary Site. |
Failover | Failover, sometimes called unplanned failover, is initiated on Replica Virtual Machine. |
Reverse Replication | A process in which the virtualized workload is reverse-replicated from Replica to Primary Server. |
Cancel Failover | A process in which the virtual machine’s state is returned to what it was before a failover was started. |