安装 Azure 备份 MARS 代理Install the Azure Backup MARS agent

本文介绍如何安装 Azure 恢复服务 (MARS) 代理。This article explains how to install the Azure Recovery Services (MARS) agent. MARS 也称为 Azure 备份代理。MARS is also known as the Azure Backup agent.

关于 MARS 代理About the MARS agent

Azure 备份使用 MARS 代理备份本地计算机和 Azure VM 中的文件、文件夹和系统状态。Azure Backup uses the MARS agent to back up files, folders, and system state from on-premises machines and Azure VMs. 这些备份存储在 Azure 中的恢复服务保管库中。Those backups are stored in a Recovery Services vault in Azure. 可在以下位置运行代理:You can run the agent:

  • 直接在本地 Windows 计算机上。Directly on on-premises Windows machines. 这些计算机可直接备份到 Azure 中的备份恢复服务保管库。These machines can back up directly to a Recovery Services vault in Azure.
  • 在运行 Windows(与 Azure VM 备份扩展一起运行)的 Azure VM 上。On Azure VMs that run Windows side by side with the Azure VM backup extension. 代理将备份 VM 上的特定文件和文件夹。The agent backs up specific files and folders on the VM.
  • 在 Azure 备份服务器 (MABS) 实例或 System Center Data Protection Manager (DPM) 服务器上。On a Azure Backup Server (MABS) instance or a System Center Data Protection Manager (DPM) server. 在此方案中,计算机和工作负荷将备份到 MABS 或 Data Protection Manager。In this scenario, machines and workloads back up to MABS or Data Protection Manager. 然后 MABS 或 Data Protection Manager 将通过 MARS 代理备份到 Azure 中的保管库。Then MABS or Data Protection Manager uses the MARS agent to back up to a vault in Azure.

可备份的数据取决于代理的安装位置。The data that's available for backup depends on where the agent is installed.

备注

通常我们会使用 VM 上的 Azure 备份扩展来备份 Azure VM。Generally, you back up an Azure VM by using an Azure Backup extension on the VM. 此方法将备份整个 VM。This method backs up the entire VM. 若要备份 VM 上的特定文件和文件夹,请安装 MARS 代理并将其与该扩展一起使用。If you want to back up specific files and folders on the VM, install and use the MARS agent alongside the extension. 有关详细信息,请参阅内置 Azure VM 备份的体系结构For more information, see Architecture of a built-in Azure VM backup.

备份过程的步骤

开始之前Before you start

创建恢复服务保管库Create a Recovery Services vault

恢复服务保管库是用于存储在不同时间创建的备份和恢复点的实体。A Recovery Services vault is an entity that stores the backups and recovery points created over time. 恢复服务保管库还包含与受保护虚拟机关联的备份策略。The Recovery Services vault also contains the backup policies that are associated with the protected virtual machines.

若要创建恢复服务保管库,请执行以下操作:To create a Recovery Services vault:

  1. Azure 门户中登录到自己的订阅。Sign in to your subscription in the Azure portal.

  2. 在左侧菜单中,选择“所有服务”。On the left menu, select All services.

    选择“所有服务”

  3. 在“所有服务”对话框中,输入“恢复服务”。In the All services dialog box, enter Recovery Services. 资源列表根据输入进行筛选。The list of resources filters according to your input. 在资源列表中,选择“恢复服务保管库”。In the list of resources, select Recovery Services vaults.

    输入并选择“恢复服务保管库”

    此时会显示订阅中的恢复服务保管库列表。The list of Recovery Services vaults in the subscription appears.

  4. 在“恢复服务保管库”仪表板上,选择“添加”。On the Recovery Services vaults dashboard, select Add.

    添加恢复服务保管库

    此时会打开“恢复服务保管库”对话框。The Recovery Services vault dialog box opens. 提供“名称”、“订阅”、“资源组”和“位置”的值。Provide values for the Name, Subscription, Resource group, and Location.

    配置恢复服务保管库

    • 名称:输入一个友好名称以标识此保管库。Name: Enter a friendly name to identify the vault. 名称对于 Azure 订阅必须是唯一的。The name must be unique to the Azure subscription. 指定的名称应至少包含 2 个字符,最多不超过 50 个字符。Specify a name that has at least two, but not more than 50 characters. 名称必须以字母开头且只能包含字母、数字和连字符。The name must start with a letter and consist only of letters, numbers, and hyphens.

    • 订阅:选择要使用的订阅。Subscription: Choose the subscription to use. 如果你仅是一个订阅的成员,则会看到该名称。If you're a member of only one subscription, you'll see that name. 如果不确定要使用哪个订阅,请使用默认的(建议的)订阅。If you're not sure which subscription to use, use the default (suggested) subscription. 仅当工作或学校帐户与多个 Azure 订阅关联时,才会显示多个选项。There are multiple choices only if your work or school account is associated with more than one Azure subscription.

    • 资源组:使用现有资源组或创建新组。Resource group: Use an existing resource group or create a new one. 要查看订阅中可用的资源组列表,请选择“使用现有资源”,然后从下拉列表框中选择一个资源。To see the list of available resource groups in your subscription, select Use existing, and then select a resource from the drop-down list box. 若要创建新资源组,请选择“新建”,然后输入名称。To create a new resource group, select Create new and enter the name. 有关资源组的完整信息,请参阅 Azure 资源管理器概述For complete information about resource groups, see Azure Resource Manager overview.

    • 位置:选择保管库的地理区域。Location: Select the geographic region for the vault. 要创建保管库以保护虚拟机,保管库必须与虚拟机位于同一区域中。To create a vault to protect virtual machines, the vault must be in the same region as the virtual machines.

      重要

      如果不确定 VM 的位置,请关闭对话框。If you're not sure of the location of your VM, close the dialog box. 转到门户中的虚拟机列表。Go to the list of virtual machines in the portal. 如果虚拟机位于多个区域,请在每个区域中创建一个恢复服务保管库。If you have virtual machines in several regions, create a Recovery Services vault in each region. 先在第一个位置创建保管库,然后再为其他位置创建保管库。Create the vault in the first location, before you create the vault for another location. 无需指定存储帐户即可存储备份数据。There's no need to specify storage accounts to store the backup data. 恢复服务保管库和 Azure 备份服务会自动处理这种情况。The Recovery Services vault and the Azure Backup service handle that automatically.

  5. 准备好创建恢复服务保管库后,选择“创建”。When you're ready to create the Recovery Services vault, select Create.

    创建恢复服务保管库

    创建恢复服务保管库可能需要一段时间。It can take a while to create the Recovery Services vault. 可在门户右上角“通知”区域监视状态通知。Monitor the status notifications in the Notifications area at the upper-right corner of the portal. 创建保管库后,它会显示在“恢复服务保管库”的列表中。After your vault is created, it's visible in the list of Recovery Services vaults. 如果未看到创建的保管库,请选择“刷新”。If you don't see your vault, select Refresh.

    刷新备份保管库列表

修复存储复制Modify storage replication

默认情况下,保管库使用异地冗余存储 (GRS)By default, vaults use geo-redundant storage (GRS).

  • 如果保管库是主要备份机制,建议使用 GRS。If the vault is your primary backup mechanism, we recommend that you use GRS.
  • 可以使用本地冗余存储 (LRS) 来降低 Azure 存储成本。You can use locally redundant storage (LRS) to reduce Azure storage costs.

若要修改存储复制类型,请执行以下操作:To modify the storage replication type:

  1. 在新保管库的“设置”部分选择“属性”。In the new vault, select Properties under the Settings section.

  2. 在“属性”页的“备份配置”下选择“更新”。 On the Properties page, under Backup Configuration, select Update.

  3. 选择存储复制类型,然后选择“保存”。Select the storage replication type, and select Save.

    更新备份配置

备注

在保管库经过设置并且包含备份项之后,无法修改存储复制类型。You can't modify the storage replication type after the vault is set up and contains backup items. 若要修改,需要重新创建保管库。If you want to do this, you need to re-create the vault.

验证 Internet 访问Verify internet access

如果计算机的 Internet 访问状态受限,请确保计算机或代理上的防火墙设置允许以下 URL 和 IP 地址:If your machine has limited internet access, ensure that firewall settings on the machine or proxy allow the following URLs and IP addresses:

  • URLURLs
    • www.msftncsi.com
    • *.Microsoft.com
    • *.WindowsAzure.cn
    • *.partner.microsoftonline.cn
    • *.chinacloudapi.cn
    • www.msftconnecttest.com
  • IP 地址IP addresses
    • 20.190.128.0/1820.190.128.0/18
    • 40.126.0.0/1840.126.0.0/18

使用 Azure ExpressRouteUse Azure ExpressRoute

可以使用公共对等互连(适用于旧线路)和 Microsoft 对等互连通过 Azure ExpressRoute 备份数据。You can back up your data over Azure ExpressRoute by using public peering (available for old circuits) and Microsoft peering. 不支持通过专用对等互连进行备份。Backup over private peering isn't supported.

若要使用公共对等互连,请首先确保能够访问以下域和地址:To use public peering, first ensure access to the following domains and addresses:

  • http://www.msftncsi.com/ncsi.txt
  • http://www.msftconnecttest.com/connecttest.txt
  • microsoft.com
  • .WindowsAzure.cn
  • .partner.microsoftonline.cn
  • .chinacloudapi.cn

若要使用 Microsoft 对等互连,请选择以下服务、区域和相关社区值:To use Microsoft peering, select the following services, regions, and relevant community values:

  • Azure Active Directory (12076:5060)Azure Active Directory (12076:5060)
  • Azure 区域(取决于你的恢复服务保管库的位置)Azure region, according to the location of your Recovery Services vault
  • Azure 存储(取决于你的恢复服务保管库的位置)Azure Storage, according to the location of your Recovery Services vault

有关详细信息,请参阅 ExpressRoute 路由要求For more information, see ExpressRoute routing requirements.

备注

对于新线路,公共对等互连已弃用。Public peering is deprecated for new circuits.

前面的所有 URL 和 IP 地址在端口 443 上使用 HTTPS 协议。All of the preceding URLs and IP addresses use the HTTPS protocol on port 443.

下载 MARS 代理Download the MARS agent

下载 MARS 代理,以便可将其安装到所要备份的计算机上。Download the MARS agent so that you can install it on the machines that you want to back up.

如果已在任何计算机上安装该代理,请确保运行该代理的最新版本。If you've already installed the agent on any machines, make sure that you're running the latest version of the agent. 在门户中找到最新版本,或直接转到下载Find the latest version in the portal, or go directly to the download.

  1. 在保管库中的“开始使用”下,选择“备份”。 In the vault, under Getting Started, select Backup.

    打开备份代理

  2. 在“工作负荷的运行位置?”下,选择“本地”。 Under Where is your workload running?, select On-premises. 即使你要在 Azure VM 上安装 MARS 代理,也应选择此选项。Select this option even if you want to install the MARS agent on an Azure VM.

  3. 在“要备份哪些内容?”下,选择“文件和文件夹”。 Under What do you want to back up?, select Files and folders. 还可以选择“系统状态”。You can also select System State. 还有其他一些可用选项,但仅当运行的是辅助备份服务器时,这些选项才受支持。Many other options are available, but these options are supported only if you're running a secondary backup server. 选择“准备基础结构”。Select Prepare Infrastructure.

    配置文件和文件夹

  4. 对于“准备基础结构”,请在“安装恢复服务代理”下,下载 MARS 代理。 For Prepare infrastructure, under Install Recovery Services agent, download the MARS agent.

    准备基础结构

  5. 在下载菜单中选择“保存”。In the download menu, select Save. 默认情况下,MARSagentinstaller.exe 文件将保存到 Downloads 文件夹。By default, the MARSagentinstaller.exe file is saved to your Downloads folder.

  6. 选择“已下载或使用最新的恢复服务代理”,然后下载保管库凭据。Select Already download or using the latest Recovery Services Agent, and then download the vault credentials.

    下载保管库凭据

  7. 选择“保存” 。Select Save. 文件将下载到“下载”文件夹。The file is downloaded to your Downloads folder. 无法打开保管库凭据文件。You can't open the vault credentials file.

安装并注册代理Install and register the agent

  1. 在要备份的计算机上运行 MARSagentinstaller.exe 文件。Run the MARSagentinstaller.exe file on the machines that you want to back up.

  2. 在 MARS 代理安装向导中选择“安装设置”。In the MARS Agent Setup Wizard, select Installation Settings. 在此处选择代理的安装位置以及缓存位置。There, choose where to install the agent, and choose a location for the cache. 然后,选择“下一步”。Then select Next.

    • Azure 备份在将数据快照发送到 Azure 之前,会使用缓存来存储这些快照。Azure Backup uses the cache to store data snapshots before sending them to Azure.
    • 缓存位置的可用空间应该至少为所要备份的数据大小的 5%。The cache location should have free space equal to at least 5 percent of the size of the data you'll back up.

    在 MARS 代理安装向导中选择安装设置

  3. 对于“代理配置”中,请指定 Windows 计算机上运行的代理如何连接到 Internet。For Proxy Configuration, specify how the agent that runs on the Windows machine will connect to the internet. 然后,选择“下一步”。Then select Next.

    • 如果使用自定义代理,请指定任何所需的代理设置和凭据。If you use a custom proxy, specify any necessary proxy settings and credentials.
    • 请记住,代理需要有权访问特定的 URLRemember that the agent needs access to specific URLs.

    在 MARS 向导中设置 Internet 访问

  4. 对于“安装”,请复查先决条件,然后选择“安装”。 For Installation, review the prerequisites, and select Install.

  5. 安装代理后,选择“继续注册”。After the agent is installed, select Proceed to Registration.

  6. 在“注册服务器向导” > “保管库标识”中,浏览并选择已下载的凭据文件。 In Register Server Wizard > Vault Identification, browse to and select the credentials file that you downloaded. 然后,选择“下一步”。Then select Next.

    使用注册服务器向导添加保管库凭据

  7. 在“加密设置”页上,指定用于加密和解密计算机备份的通行短语。On the Encryption Setting page, specify a passphrase that will be used to encrypt and decrypt backups for the machine. 有关允许的通行短语字符的详细信息,请参阅此处See here for more information on allowed passphrase characters.

    • 将通行短语保存在安全位置。Save the passphrase in a secure location. 还原备份时需要用到它。You need it to restore a backup.
    • 如果你丢失或忘记了该通行短语,Microsoft 将无法帮助你恢复备份数据。If you lose or forget the passphrase, Microsoft can't help you recover the backup data.
  8. 选择“完成”。Select Finish. 现已安装代理,且已向保管库注册计算机。The agent is now installed, and your machine is registered to the vault. 接下来可以配置和计划备份。You're ready to configure and schedule your backup.

后续步骤Next steps

了解如何使用 Azure 备份 MARS 代理备份 Windows 计算机Learn how to Back up Windows machines by using the Azure Backup MARS agent