Set-AzureRmBackupVault
Changes the storage type of a Backup vault.
Warning
The AzureRM PowerShell module has been officially deprecated as of February 29, 2024. Users are advised to migrate from AzureRM to the Az PowerShell module to ensure continued support and updates.
Although the AzureRM module may still function, it's no longer maintained or supported, placing any continued use at the user's discretion and risk. Please refer to our migration resources for guidance on transitioning to the Az module.
Syntax
Set-AzureRmBackupVault
[[-Storage] <AzureBackupVaultStorageType>]
[-Vault] <AzureRMBackupVault>
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
Description
The Set-AzureRmBackupVault cmdlet changes the storage type of an Azure Backup vault. You cannot modify other properties of a vault.
Examples
Example 1: Change the storage for an existing vault
PS C:\>Get-AzureRmBackupVault -Name "Vault03" | Set-AzureRmBackupVault -Storage LocallyRedundant
This command gets the Azure Backup vault named Vault03 by using the Get-AzureRmBackupVault cmdlet. The command passes that vault to the current cmdlet by using the pipeline operator. The current cmdlet changes the storage type to LocallyRedundant.
Parameters
-DefaultProfile
The credentials, account, tenant, and subscription used for communication with azure
Type: | IAzureContextContainer |
Aliases: | AzureRmContext, AzureCredential |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Storage
Specifies the storage type for the backup data. The acceptable values for this parameter are: LocallyRedundant and GeoRedundant.
Type: | AzureBackupVaultStorageType |
Accepted values: | GeoRedundant, LocallyRedundant |
Position: | 1 |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Vault
Specifies a Backup vault that this cmdlet modifies. To obtain an AzureRmBackupVault object, use the Get-AzureRmBackupVault cmdlet.
Type: | AzureRMBackupVault |
Position: | 0 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
Inputs
Parameters: Vault (ByValue)
Outputs
Notes
- When you register the first server or virtual machine for a vault, the storage type is locked. Subsequently, you cannot change the storage type.