I cannot delete a vault in Azure

Waddell, Joshua J 0 Reputation points
2024-04-18T18:40:19.0166667+00:00

I am receiving the error below when attempting to delete a vault. I removed any dependencies that I saw but I still receive the error. Any help would be appreciated.

Vault Deletion Error

Recovery Services Vault cannot be deleted as there are existing resources within the vault. : josh1235. Please ensure all containers have been unregistered from the vault and all private endpoints associated with the vault have been deleted, and retry operation. For more details, see https://aka.ms/AB-AA4ecq5

Azure Key Vault
Azure Key Vault
An Azure service that is used to manage and protect cryptographic keys and other secrets used by cloud apps and services.
1,120 questions
Azure
Azure
A cloud computing platform and infrastructure for building, deploying and managing applications and services through a worldwide network of Microsoft-managed datacenters.
958 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Marilee Turscak-MSFT 33,951 Reputation points Microsoft Employee
    2024-04-18T23:49:41.42+00:00

    Hi @Waddell, Joshua J ,

    If you already removed the dependencies, it's possible that some are still in the "soft deleted" state. Typically you would receive this error if there is a Backup item for the Azure VM that is attached to this Recovery Services vault. You need to confirm that there is no backup listed under "Backup items" or "Replicated items" and that they have been permanently deleted. To confirm this, click the Backup items link under Protected items on the Recovery Services vault page. If you see anything other than "0" listed next to the Azure Virtual Machine under "Backup Item Count", you will need to delete the backup item to resolve the error.

    First you need to select the "..." next to the backup instance and select "Stop backup." Then, once the backup is stopped, you can select the "..." and select "Delete backup instance."

    After this, since the backup goes into a soft-deleted state for 14 days before it is permanently deleted, you will still receive the error. You have two options then to resolve it:

    1. You can wait 14 days and delete the vault again.
    2. You can disable the Azure Portal's soft delete option under Properties > Security Settings. Then you will need to undelete the backup, re-delete it, and delete the vault. Note that disabling soft delete though will also apply to all other items in the portal.

    If this doesn't work, let me know and we can further troubleshoot or get a support case opened to look into your configuration. You can reach out to me at AzCommunity@microsoft.com ("Attn: Marilee Turscak") and include your subscription ID and a link to this thread.

    If the information helped you, please Accept the answer. This will help us as well as others in the community who may be researching similar questions.

    0 comments No comments