|
| 1 | +--- |
| 2 | +title: Back up Azure NetApp Files datastores and VMs using Cloud Backup |
| 3 | +description: Learn how to back up datastores and Virtual Machines to the cloud. |
| 4 | +ms.topic: how-to |
| 5 | +ms.service: azure-vmware |
| 6 | +ms.date: 08/10/2022 |
| 7 | +--- |
| 8 | + |
| 9 | +# Back up Azure NetApp Files datastores and VMs using Cloud Backup for Virtual Machines |
| 10 | + |
| 11 | +From the VMware vSphere client, you can back up datastores and Virtual Machines (VMs) to the cloud. |
| 12 | + |
| 13 | +## Configure subscriptions |
| 14 | + |
| 15 | +Before you back up your Azure NetApp Files datastores, you must add your Azure and Azure NetApp Files cloud subscriptions. |
| 16 | + |
| 17 | +### Add Azure cloud subscription |
| 18 | + |
| 19 | +1. Sign in to the VMware vSphere client. |
| 20 | +2. From the left navigation, select **Cloud Backup for Virtual Machines**. |
| 21 | +3. Select the **Settings** page and then select the **Cloud Subscription** tab. |
| 22 | +4. Select **Add** and then provide the required values from your Azure subscription. |
| 23 | + |
| 24 | +### Add Azure NetApp Files cloud subscription account |
| 25 | + |
| 26 | +1. From the left navigation, select **Cloud Backup for Virtual Machines**. |
| 27 | +2. Select **Storage Systems**. |
| 28 | +3. Select **Add** to add the Azure NetApp Files cloud subscription account details. |
| 29 | +4. Provide the required values and then select **Add** to save your settings. |
| 30 | + |
| 31 | +## Create a backup policy |
| 32 | + |
| 33 | +You must create backup policies before you can use Cloud Backup for Virtual Machines to back up Azure NetApp Files datastores and VMs. |
| 34 | + |
| 35 | +1. In the left navigation of the vCenter web client page, select **Cloud Backup for Virtual Machines** > **Policies**. |
| 36 | +2. On the **Policies** page, select **Create** to initiate the wizard. |
| 37 | +3. On the **New Backup Policy** page, select the vCenter Server that will use the policy, then enter the policy name and a description. |
| 38 | +* **Only alphanumeric characters and underscores (_) are supported in VM, datastore, cluster, policy, backup, or resource group names.** Other special characters are not supported. |
| 39 | +4. Specify the retention settings. |
| 40 | + The maximum retention value is 255 backups. If the **"Backups to keep"** option is selected during the backup operation, Cloud Backup for Virtual Machines will retain backups with the specified retention count and delete the backups that exceed the retention count. |
| 41 | +5. Specify the frequency settings. |
| 42 | + The policy specifies the backup frequency only. The specific protection schedule for backing up is defined in the resource group. Therefore, two or more resource groups can share the same policy and backup frequency but have different backup schedules. |
| 43 | +6. **Optional:** In the **Advanced** fields, select the fields that are needed. The Advanced field details are listed in the following table. |
| 44 | + |
| 45 | + | Field | Action | |
| 46 | + | ---- | ---- | |
| 47 | + | VM consistency | Check this box to pause the VMs and create a VMware snapshot each time the backup job runs. <br> When you check the VM consistency box, backup operations might take longer and require more storage space. In this scenario, the VMs are first paused, then VMware performs a VM consistent snapshot. Cloud Backup for Virtual Machines then performs its backup operation, and then VM operations are resumed. <br> VM guest memory is not included in VM consistency snapshots. | |
| 48 | + | Include datastores with independent disks | Check this box to include any datastores with independent disks that contain temporary data in your backup. | |
| 49 | + | Scripts | Enter the fully qualified path of the prescript or postscript that you want the Cloud Backup for Virtual Machines to run before or after backup operations. For example, you can run a script to update Simple Network Management Protocol (SNMP) traps, automate alerts, and send logs. The script path is validated at the time the script is executed. <br> **NOTE**: Prescripts and postscripts must be located on the virtual appliance VM. To enter multiple scripts, press **Enter** after each script path to list each script on a separate line. The semicolon (;) character is not allowed. | |
| 50 | +7. Select **Add** to save your policy. |
| 51 | + You can verify that the policy has been created successfully and review the policy configuration by selecting the policy in the **Policies** page. |
| 52 | + |
| 53 | +## Resource groups |
| 54 | + |
| 55 | +A resource group is the container for VMs and datastores that you want to protect. |
| 56 | + |
| 57 | +Do not add VMs in an inaccessible state to a resource group. Although a resource group can contain a VM in an inaccessible state, the inaccessible state will cause backups for the resource group to fail. |
| 58 | + |
| 59 | +### Considerations for resource groups |
| 60 | + |
| 61 | +You can add or remove resources from a resource group at any time. |
| 62 | +* Back up a single resource |
| 63 | + To back up a single resource (for example, a single VM), you must create a resource group that contains that single resource. |
| 64 | +* Back up multiple resources |
| 65 | + To back up multiple resources, you must create a resource group that contains multiple resources. |
| 66 | +* Optimize snapshot copies |
| 67 | + To optimize snapshot copies, group the VMs and datastores that are associated with the same volume into one resource group. |
| 68 | +* Backup policies |
| 69 | + Although it's possible to create a resource group without a backup policy, you can only perform scheduled data protection operations when at least one policy is attached to the resource group. You can use an existing policy, or you can create a new policy while creating a resource group. |
| 70 | +* Compatibility checks |
| 71 | + Cloud Backup for VMs performs compatibility checks when you create a resource group. Reasons for incompatibility might be: |
| 72 | + * Virtual machine disks (VMDKs) are on unsupported storage. |
| 73 | + * A shared PCI device is attached to a VM. |
| 74 | + * You have not added the Azure subscription account. |
| 75 | + |
| 76 | +### Create a resource group using the wizard |
| 77 | + |
| 78 | +1. In the left navigation of the vCenter web client page, select **Cloud Backup** for **Virtual Machines** > **Resource Groups**. Then select **+ Create** to start the wizard |
| 79 | + |
| 80 | + :::image type="content" source="./media/cloud-backup/vsphere-create-resource-group.png" alt-text="Screenshot of the vSphere Client Resource Group interface shows a red box highlights a button with a green plus sign that reads Create, instructing you to select this button." lightbox="./media/cloud-backup/vsphere-create-resource-group.png"::: |
| 81 | + |
| 82 | +1. On the **General Info & Notification** page in the wizard, enter the required values. |
| 83 | +1. On the **Resource** page, do the following: |
| 84 | + |
| 85 | + | Field | Action | |
| 86 | + | -- | ----- | |
| 87 | + | Scope | Select the type of resource you want to protect: <ul><li>Datastores</li><li>Virtual Machines</li></ul> | |
| 88 | + | Datacenter | Navigate to the VMs or datastores | |
| 89 | + | Available entities | Select the resources you want to protect. Then select **>** to move your selections to the Selected entities list. | |
| 90 | + |
| 91 | + When you select **Next**, the system first checks that Cloud Backup for Virtual Machines manages and is compatible with the storage on which the selected resources are located. |
| 92 | + |
| 93 | + >[!IMPORTANT] |
| 94 | + >If you receive the message `selected <resource-name> is not Cloud Backup for Virtual Machines compatible` then a selected resource is not compatible with Cloud Backup for Virtual Machines. |
| 95 | +
|
| 96 | +1. On the **Spanning disks** page, select an option for VMs with multiple VMDKs across multiple datastores: |
| 97 | + * Always exclude all spanning datastores |
| 98 | + (This is the default option for datastores) |
| 99 | + * Always include all spanning datastores |
| 100 | + (This is the default for VMs) |
| 101 | + * Manually select the spanning datastores to be included |
| 102 | +1. On the **Policies** page, select or create one or more backup policies. |
| 103 | + * To use **an existing policy**, select one or more policies from the list. |
| 104 | + * To **create a new policy**: |
| 105 | + 1. Select **+ Create**. |
| 106 | + 1. Complete the New Backup Policy wizard to return to the Create Resource Group wizard. |
| 107 | +1. On the **Schedules** page, configure the backup schedule for each selected policy. |
| 108 | + In the **Starting** field, enter a date and time other than zero. The date must be in the format day/month/year. You must fill in each field. The Cloud Backup for Virtual Machines creates schedules in the time zone in which the Cloud Backup for Virtual Machines is deployed. You can modify the time zone by using the Cloud Backup for Virtual Machines GUI. |
| 109 | + |
| 110 | + :::image type="content" source="./media/cloud-backup/backup-schedules.png" alt-text="A screenshot of the Backup schedules interface showing an hourly backup beginning at 10:22 a.m. on April 26, 2022." lightbox="./media/cloud-backup/backup-schedules.png"::: |
| 111 | +1. Review the summary. If you need to change any information, you can return to any page in the wizard to do so. Select **Finish** to save your settings. |
| 112 | + |
| 113 | + After you select **Finish**, the new resource group will be added to the resource group list. |
| 114 | + |
| 115 | + If the pause operation fails for any of the VMs in the backup, then the backup is marked as not VM-consistent even if the policy selected has VM consistency selected. In this case, it's possible that some of the VMs were successfully paused. |
| 116 | + |
| 117 | +### Other ways to create a resource group |
| 118 | + |
| 119 | +In addition to using the wizard, you can: |
| 120 | +* **Create a resource group for a single VM:** |
| 121 | + 1. Select **Menu** > **Hosts and Clusters**. |
| 122 | + 1. Right-click the Virtual Machine you want to create a resource group for and select **Cloud Backup for Virtual Machines**. Select **+ Create**. |
| 123 | +* **Create a resource group for a single datastore:** |
| 124 | + 1. Select **Menu** > **Hosts and Clusters**. |
| 125 | + 1. Right-click a datastore, then select **Cloud Backup for Virtual Machines**. Select **+ Create**. |
| 126 | + |
| 127 | +## Back up resource groups |
| 128 | + |
| 129 | +Backup operations are performed on all the resources defined in a resource group. If a resource group has a policy attached and a schedule configured, backups occur automatically according to the schedule. |
| 130 | + |
| 131 | +### Prerequisites |
| 132 | + |
| 133 | +* You must have created a resource group with a policy attached. |
| 134 | + Do not start an on-demand backup job when a job to back up the Cloud Backup for Virtual Machines MySQL database is already running. Use the maintenance console to see the configured backup schedule for the MySQL database. |
| 135 | + |
| 136 | +### Back up resource groups on demand |
| 137 | + |
| 138 | +1. In the left navigation of the vCenter web client page, select **Cloud Backup for Virtual Machines** > **Resource Groups**, then select a resource group. Select **Run Now** to start the backup. |
| 139 | + |
| 140 | + :::image type="content" source="./media/cloud-backup/resource-groups-run-now.png" alt-text="Image of the vSphere Client Resource Group interface. At the top left, a red box highlights a green circular button with a white arrow inside next to text reading Run Now, instructing you to select this button." lightbox="./media/cloud-backup/resource-groups-run-now.png"::: |
| 141 | + |
| 142 | + 1.1 If the resource group has multiple policies configured, then in the **Backup Now** dialog box, select the policy you want to use for this backup operation. |
| 143 | +1. Select **OK** to initiate the backup. |
| 144 | + >[!NOTE] |
| 145 | + >You can't rename a backup once it is created. |
| 146 | +1. **Optional:** Monitor the operation progress by selecting **Recent Tasks** at the bottom of the window or on the dashboard Job Monitor for more details. |
| 147 | + If the pause operation fails for any of the VMs in the backup, then the backup completes with a warning and is marked as not VM-consistent even if the selected policy has VM consistency selected. In this case, it is possible that some of the VMs were successfully paused. In the job monitor, the failed VM details will show the paused as failed. |
| 148 | + |
| 149 | +## Next steps |
| 150 | + |
| 151 | +* [Restore VMs using Cloud Backup for Virtual Machines](restore-azure-netapp-files-vms.md) |
0 commit comments