为 Azure VM 设置到 Azure 次要区域的灾难恢复Set up disaster recovery to a secondary Azure region for an Azure VM

Azure Site Recovery 服务通过在计划内和计划外中断期间使商业应用程序保持启动和运行状态,有助于实施业务连续性和灾难恢复 (BCDR) 策略。The Azure Site Recovery service contributes to your business continuity and disaster recovery (BCDR) strategy by keeping your business apps up and running, during planned and unplanned outages. Site Recovery 管理并安排本地计算机和 Azure 虚拟机 (VM) 的灾难恢复,包括复制、故障转移和恢复。Site Recovery manages and orchestrates disaster recovery of on-premises machines and Azure virtual machines (VMs), including replication, failover, and recovery.

本快速入门介绍了如何通过将 Azure VM 复制到不同的 Azure 区域来为其设置灾难恢复。This quickstart describes how to set up disaster recovery for an Azure VM by replicating it to a different Azure region.

如果没有 Azure 订阅,可在开始前创建一个 试用帐户If you don't have an Azure subscription, create a trial account before you begin.

备注

本文是针对新用户的快速演练。This article is a quick walkthrough for new users. 它使用带有默认选项和最小自定义的最简单路径。It uses the simplest path, with default options and minimum customization. 有关完整演练,请参阅教程启用复制For a full walkthrough, review the tutorial Enable replication.

登录 AzureLog in to Azure

登录到 Azure 门户Log in to the Azure portal.

为 Azure VM 启用复制Enable replication for the Azure VM

  1. 在“Azure 门户”菜单中,选择“虚拟机”,或在任何页面上搜索并选择“虚拟机” 。On the Azure portal menu, select Virtual machines, or search for and select Virtual machines on any page. 选择要复制的 VM。Select the VM you want to replicate.

  2. 在“操作”中,选择“灾难恢复” 。In Operations, select Disaster recovery.

  3. 在“配置灾难恢复” > “目标区域” 中,选择要复制到的目标区域。In Configure disaster recovery > Target region select the target region to which you'll replicate.

  4. 在本快速入门中,接受其他默认设置。For this Quickstart, accept the other default settings.

  5. 选择“查看 + 开始复制” 。Select Review + Start replication. 选择“开始复制”,启动为 VM 启用复制的作业 。Then select Start replication to start a job to enable replication for the VM.

    启用复制

验证设置Verify settings

复制作业完成后,可以检查复制状态、修改复制设置和测试部署。After the replication job has finished, you can check the replication status, modify replication settings, and test the deployment.

  1. 在“Azure 门户”菜单中,选择“虚拟机”,或在任何页面上搜索并选择“虚拟机” 。On the Azure portal menu, select Virtual machines, or search for and select Virtual machines on any page. 选择要验证的 VM。Select the VM you want to verify.

  2. 在“操作”中,选择“灾难恢复” 。In Operations, select Disaster recovery.

    可以验证复制运行状况、已创建的恢复点以及映射中的源和目标区域。You can verify replication health, the recovery points that have been created, and source, target regions on the map.

    复制状态

清理资源Clean up resources

对主要区域中的 VM 禁用复制时,该 VM 会停止复制:The VM in the primary region stops replicating when you disable replication for it:

  • 将自动清除源复制设置。The source replication settings are cleaned up automatically. 在复制过程中安装在 VM 上的 Site Recovery 扩展不会被删除,必须手动删除。The Site Recovery extension installed on the VM as part of the replication isn't removed, and must be removed manually.
  • 对 VM 的 Site Recovery 计费会停止。Site Recovery billing for the VM stops.

请按如下所述停止复制:Stop replication as follows:

  1. 在“Azure 门户”菜单中,选择“虚拟机”,或在任何页面上搜索并选择“虚拟机” 。On the Azure portal menu, select Virtual machines, or search for and select Virtual machines on any page. 选择要修改的 VM。Select the VM you want to modify.

  2. 在“灾难恢复”中,选择“禁用复制” 。In Disaster recovery, select Disable Replication.

    禁用复制

后续步骤Next steps

在本快速入门中,将单个 VM 复制到了次要区域。In this quickstart, you replicated a single VM to a secondary region. 现在,请尝试使用恢复计划复制多个 Azure VM。Now, try replicating multiple Azure VMs using a recovery plan.