What are the required RBAC permission required to restore and fetch deleted storage accounts?

Nagendrra C 61 Reputation points
2022-12-13T05:46:06.883+00:00

I was trying to restore a deleted storage account, on clicking on restore its displaying a message stating "We could not fetch the deleted storage accounts for the subscription". I have given Microsoft.Storage/storageAccounts/write and Microsoft.Storage/storageAccounts/read permission to the user, still the same error.

269827-image.png

Azure Storage
Azure Storage
Globally unique resources that provide access to data management services and serve as the parent namespace for the services.
3,548 questions
0 comments No comments
{count} votes

Accepted answer
  1. TP 126.7K Reputation points Volunteer Moderator
    2022-12-13T07:10:25.943+00:00

    Hi,

    To Restore deleted storage account the user needs:

    Microsoft.Storage/deletedAccounts/read at Subscription level. You can create custom role for this. Please refer to this article if you are unfamiliar with creating custom role:

    https://learn.microsoft.com/en-us/azure/active-directory/roles/custom-create

    Storage Account Contributor on the resource group that the storage account was deleted from. If the resource group itself was deleted, you need to create a new one with the same name before attempting to restore. Perhaps you could grant a subset of the permissions of Storage Account Contributor, however, I know Storage Account Contributor works so if you want to be more granular you will need to research and test.

    Thanks.

    -TP


1 additional answer

Sort by: Most helpful
  1. JimmySalian-2011 42,611 Reputation points
    2022-12-13T06:34:09.41+00:00

    Hi,

    To recover a deleted storage account there are some pre-conditions that needs to be met, so kindly check below list items and see if you fulfil these:

    269955-image.png

    Also you can check this page for the detailed information on the recovery as it is not guranteed from Microsoft. The error doesnt seem to be RBAC or permissions issue. However you can check the permissions here.
    storage-account-recover

    Hope this helps.
    JS

    ==
    Please Accept the answer if the information helped you. This will help us and others in the community as well.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.