Lesson 1 of 2 Azure Site Recovery

Replicating Azure VMs with Site Recovery

This lesson explains how Site Recovery differs from Azure Backup, how replication is enabled, and how networking and recovery plans are configured.

Learning outcomes

After completing this lesson, you will be able to:

  • Distinguish between Azure Backup and Azure Site Recovery.
  • Describe the steps and settings for enabling replication.
  • Explain network mapping and recovery plans.

Site Recovery compared with Azure Backup

Azure Backup keeps recovery points so data can be restored after deletion, corruption or ransomware, with a recovery point objective (RPO) of hours. Azure Site Recovery replicates disk writes continuously to another region, with an RPO of minutes and a short recovery time objective (RTO), so that whole applications can run in the secondary region during a regional outage. Most production workloads use both.

Azure Backup
PurposeRestore data and VMs to a point in time
Recovery pointsDays to years of retention
Typical RPOHours (scheduled backups)
Choose when Accidental deletion, corruption, long retention
Azure Site Recovery
PurposeRun workloads in another region after a disaster
Recovery pointsUp to 15 days, crash- and app-consistent
Typical RPOMinutes (continuous replication)
Choose when Regional outage, business continuity
Sort into groups

Backup or Site Recovery?

Exam skills 5.2.5

Choose the service that meets each requirement.

Log in to try this activity Interactive activities are free with an account.

Enabling replication

Replication is enabled from the VM's Disaster recovery page or from a Recovery Services vault, which must be in a different region from the source, normally the target region. The steps are summarized below.

  1. Choose the target region

    Select the region to replicate to, often the paired region.

  2. Review target settings

    Site Recovery proposes or uses a target resource group, VNet and subnet, availability set or zone, and a cache storage account in the source region; customize as needed.

  3. Choose a replication policy

    Set recovery point retention (up to 15 days) and app-consistent snapshot frequency.

  4. Enable replication

    Site Recovery installs the Mobility service extension, performs initial replication of the disks, then replicates changes continuously.

Crash-consistent recovery points are created every few minutes; app-consistent recovery points are created at the policy's frequency (for example every 4 hours) with VSS on Windows. Multi-VM consistency creates shared recovery points across a replication group of VMs that must be consistent with each other.

The following diagram shows a Recovery Services vault and the groups of a recovery plan for a three-tier application replicated between two regions.

Site Recovery for a three-tier application from West Europe to North Europe. The Recovery Services vault sits in North Europe; all five VMs replicate continuously to a target VNet with network mapping, meeting the 15-minute RPO; and a recovery plan starts the groups in order: SQL Server, then the application VMs, then the web VMs.
The scenario is illustrative.
Put in order

Enabling replication

Exam skills 5.2.5

Arrange the steps to enable Site Recovery for an Azure VM.

Log in to try this activity Interactive activities are free with an account.

Networking and recovery plans

Network mapping maps each source VNet to a target VNet, so failed-over VMs land in the right network; target IP addresses can be set per NIC, and Site Recovery keeps the same IP if it is free in a target subnet with the same address range. Source VMs need outbound access to Site Recovery and Storage endpoints, allowed with NSG rules using service tags (AzureSiteRecovery, Storage, AzureActiveDirectory, EventHub, GuestAndHybridManagement). Public IPs, load balancers and NSGs in the target must be planned too.

A recovery plan groups replicated VMs into ordered groups that fail over and start in sequence, with scripts (Automation runbooks) and manual actions before or after each group, for example database servers first, then application servers, then web servers and a script that updates DNS. Replication health, RPO and errors are monitored on the vault's Replicated items page, and Azure Monitor alerts can notify of problems.

Scenario questions

Planning the failover

Exam skills 5.2.5

Configure networking and recovery plans for a replicated application.

Log in to try this activity Interactive activities are free with an account.
Worked example

Protecting a three-tier application

An application in West Europe has two web VMs, two application VMs and a SQL Server VM. It must be recoverable in North Europe with an RPO under 15 minutes, the SQL Server VM must start before the application tier, and the web tier last. What should you configure?

Create a Recovery Services vault in North Europe, enable replication for all five VMs to North Europe with a target VNet and network mapping, and create a recovery plan with three groups in order: SQL Server, application VMs, web VMs. Continuous replication meets the 15-minute RPO; daily Azure Backup would not, and a vault in West Europe cannot be used for replication from West Europe.

Check yourself

In which region should the Recovery Services vault for Site Recovery be created?

Show answer

In a region other than the source, normally the target region.

Exam Tips

Remember for the exam

  • Site Recovery replicates continuously; Azure Backup restores to points in time.
  • Put the Recovery Services vault in the target region, not the source region.
  • Recovery plans order failover in groups with scripts and manual actions.
  • Source VMs need outbound access to Site Recovery service tags.