Forum Discussion
Dave Thomas
Nov 27, 2017Copper Contributor
Cannot delete Server from Recovery Services
I'm trying to delete a server from a Recovery Vault that no longer exists. When I put in the server name to delete the exclamation point still stays there. I'm attaching a screen shot of what I'm s...
Kent Gaardmand
Nov 28, 2017Iron Contributor
Do not run the following with out testing and modifying the result of targetVM
$vault = Get-AzureRmRecoveryServicesVault
Set-AzureRmRecoveryServicesVaultContext -Vault $vault
$container = get-AzureRmRecoveryServicesBackupContainer -ContainerType AzureVM
$targetvm = Get-AzureRmRecoveryServicesBackupItem -Container $container -WorkloadType AzureVM
Disable-AzureRmRecoveryServicesBackupProtection -Item $targetvm -RemoveRecoveryPoints -force
The result will look like this