Vault registration fails with "already registered" error in Azure Site Recovery

Applies to: Azure Backup

Symptoms


The Microsoft Azure Site Recovery Registration Wizard may fail on the Vault Settings page, and you receive an error message that resembles the following:
---------------------------
Microsoft Azure Site Recovery Provider Setup
---------------------------
The DRA server is already registered in vault . Either select the registration key associated with this vault, or unregister the server from and then register it with a different vault.
---------------------------
OK
---------------------------
Note the space after the word "vault." In some cases, you may see the name of a previously registered vault. For example, you may see the following: 
The DRA server is already registered in vault contosovault01.

Cause


This error may occur if you are reinstalling the Azure Site Recovery (ASR) provider and agent on a Hyper-V server that was previously registered to another vault.

Resolution


To fix this error and enable the ASR Provider and agent setup to complete successfully, follow these steps:
  1. Cancel the current installation.
  2. Make a backup of the following registry key:
    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Azure Site Recovery\Registration
  3. Delete the registry key that you backed up in step 2.
  4. Restart the Provider and agent setup.