Performing site-to-site recovery via Azure Site Recovery

Azure Site Recovery is intended to be used as part of an organization’s disaster recovery or business continuity plans, which it does by ensuring applications and workloads are accessible during outages. A simple example of Site Recovery would be to replicate a VM from the primary region to the secondary region. If the primary region goes offline, you can failover to the secondary region without issue.

Note

Azure Site Recovery can also be used to migrate on-premises VMs to Azure.

Let’s go ahead and perform a site recovery:

  1. Navigate to the Azure portal by opening a web browser and going to https:// portal.azure.com. Select the Recovery Services vault we created in the Creating a Recovery Services vault section:
  2. Click on Enable Site Recovery:

Figure 21.18 – Enable Site Recovery

  1. Next, select Enable replication under Azure virtual machines. Here, set Source location to East US, Azure virtual machine deployment model to Resource Manager, Source subscription to Demo (select your subscription here), Source resource group to Az-104, and Disaster recovery between availability zones to No. Click Next:

Figure 21.19 – Site recovery replication settings

  1. Select your VM and make sure it has been started. In my case, this will be prod-vm1. Click Next:

Figure 21.20 – Selecting the VM resource

  1. Next, set Target location to West US and click Enable replication:

Figure 21.21 – Enabling site-to-site replication

  1. Once you’ve done this, you will notice that a new resource group has been created with the suffix -asr. In my case, it is Az-104-asr, which has a virtual network and the OS disk of the VM we configured as part of the site recovery options.
  2. To confirm that site recovery has been completed successfully, browse to Az104RecoveryServicesVault and select Site Recovery Dashboard. Here, you should see charts for Replication health and Failover health:

Figure 21.22 – Site-to-site recovery health status

  1. Once the resources have been replicated, you can click on the Failover or Test Failover button to simulate or initiate an actual failover, respectively:

Figure 21.23 – Failover options

With that, we have configured Azure site recovery and know how to initiate a failover.

We encourage you to read up on Azure site recovery by going to the following links:

In this section, we learned how to perform failover operations via the Azure portal.