az backup restore
Restore backed up items from recovery points in a Recovery Services vault.
Commands
az backup restore files |
Gives access to all files of a recovery point. |
az backup restore files mount-rp |
Download a script which mounts files of a recovery point. |
az backup restore files unmount-rp |
Close access to the recovery point. |
az backup restore restore-azurefiles |
Restore backed up Azure files within a file-share to the same file-share or another file-share in registered storage accounts. |
az backup restore restore-azurefileshare |
Restore backed up Azure file shares to the same file-share or another file-share in registered storage accounts. |
az backup restore restore-azurewl |
Restore backed up Azure Workloads in a Recovery services vault to another registered container or to the same container. |
az backup restore restore-disks |
Restore disks of the backed VM from the specified recovery point. |
az backup restore restore-azurefiles
Restore backed up Azure files within a file-share to the same file-share or another file-share in registered storage accounts.
az backup restore restore-azurefiles --container-name
--item-name
--resolve-conflict {Overwrite, Skip}
--restore-mode {AlternateLocation, OriginalLocation}
--rp-name
[--ids]
[--resource-group]
[--source-file-path]
[--source-file-type {Directory, File}]
[--subscription]
[--target-file-share]
[--target-folder]
[--target-storage-account]
[--vault-name]
Examples
Restore backed up Azure files within a file-share to the same file-share or another file-share in registered storage accounts.
az backup restore restore-azurefiles --resource-group MyResourceGroup --vault-name MyVault --container-name MyContainer --item-name MyItem --rp-name recoverypoint --resolve-conflict Overwrite --restore-mode OriginalLocation --source-file-type File --source-file-path Filepath1 Filepath2
Required Parameters
Name of the backup container. Accepts 'Name' or 'FriendlyName' from the output of az backup container list command. If 'FriendlyName' is passed then BackupManagementType is required.
Name of the backed up item.
Instruction if there's a conflict with the restored data.
Specify the restore mode.
Name of the recovery point.
Optional Parameters
One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
The absolute path of the file, to be restored within the file share, as a string. This path is the same path used in the 'az storage file download' or 'az storage file show' CLI commands.
Specify the source file type to be selected.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Destination file share to which content will be restored.
Destination folder to which content will be restored. To restore content to root , leave the folder name empty.
Destination storage account to which content will be restored.
Name of the Recovery services vault.
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Increase logging verbosity. Use --debug for full debug logs.
az backup restore restore-azurefileshare
Restore backed up Azure file shares to the same file-share or another file-share in registered storage accounts.
az backup restore restore-azurefileshare --container-name
--item-name
--resolve-conflict {Overwrite, Skip}
--restore-mode {AlternateLocation, OriginalLocation}
--rp-name
[--ids]
[--resource-group]
[--subscription]
[--target-file-share]
[--target-folder]
[--target-storage-account]
[--vault-name]
Examples
Restore backed up Azure file shares to the same file-share or another file-share in registered storage accounts.
az backup restore restore-azurefileshare --resource-group MyResourceGroup --vault-name MyVault --container-name MyContainer --item-name MyItem --rp-name recoverypoint --resolve-conflict Overwrite --restore-mode OriginalLocation
Required Parameters
Name of the backup container. Accepts 'Name' or 'FriendlyName' from the output of az backup container list command. If 'FriendlyName' is passed then BackupManagementType is required.
Name of the backed up item.
Instruction if there's a conflict with the restored data.
Specify the restore mode.
Name of the recovery point.
Optional Parameters
One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Destination file share to which content will be restored.
Destination folder to which content will be restored. To restore content to root , leave the folder name empty.
Destination storage account to which content will be restored.
Name of the Recovery services vault.
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Increase logging verbosity. Use --debug for full debug logs.
az backup restore restore-azurewl
Restore backed up Azure Workloads in a Recovery services vault to another registered container or to the same container.
az backup restore restore-azurewl --recovery-config
[--ids]
[--resource-group]
[--subscription]
[--vault-name]
Examples
Restore backed up Azure Workloads in a Recovery services vault to another registered container or to the same container.
az backup restore restore-azurewl --resource-group MyResourceGroup --vault-name MyVault --recovery-config MyRecoveryConfig
Required Parameters
Specify the recovery configuration of a backed up item. The configuration object can be obtained from 'backup recoveryconfig show' command.
Optional Parameters
One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Name of the Recovery services vault.
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Increase logging verbosity. Use --debug for full debug logs.
az backup restore restore-disks
Restore disks of the backed VM from the specified recovery point.
az backup restore restore-disks --container-name
--item-name
--rp-name
--storage-account
[--diskslist]
[--ids]
[--resource-group]
[--restore-as-unmanaged-disks {false, true}]
[--restore-only-osdisk {false, true}]
[--restore-to-staging-storage-account {false, true}]
[--subscription]
[--target-resource-group]
[--vault-name]
Examples
Restore disks of the backed VM from the specified recovery point. (autogenerated)
az backup restore restore-disks --container-name MyContainer --item-name MyItem --resource-group MyResourceGroup --rp-name MyRp --storage-account mystorageaccount --vault-name MyVault
Required Parameters
Name of the backup container. Accepts 'Name' or 'FriendlyName' from the output of az backup container list command. If 'FriendlyName' is passed then BackupManagementType is required.
Name of the backed up item.
Name of the recovery point.
Name or ID of the staging storage account. The VM configuration will be restored to this storage account. See the help for --restore-to-staging-storage-account parameter for more info.
Optional Parameters
List of disks to be excluded or included.
One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Use this flag to specify to restore as unmanaged disks.
Use this flag to restore only OS disks of a backed up VM.
Use this flag when you want disks to be restored to the staging storage account using the --storage-account parameter. When not specified, disks will be restored to their original storage accounts. Default: false.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Use this to specify the target resource group in which the restored disks will be saved.
Name of the Recovery services vault.
Increase logging verbosity to show all debug logs.
Show this help message and exit.
Only show errors, suppressing warnings.
Output format.
JMESPath query string. See http://jmespath.org/ for more information and examples.
Increase logging verbosity. Use --debug for full debug logs.