Share via

Unable to delete Azure Resource Group due to PendingTransactionAlreadyExists on Storage

Shubham kumar Singh 0 Reputation points
2026-03-19T10:43:55.04+00:00

Title: Unable to delete Azure Resource Group due to PendingTransactionAlreadyExists on Storage Account

Question:

Hi Team,

I’m facing an issue while trying to delete a resource group in Azure.

I attempted to delete my resource group RG12, but the deletion failed with the following error:

Failed to delete resource group 'RG12' as resources could not be deleted.
Error Code: ResourceGroupDeletionBlocked

Details:
Pending transaction for geo change already exists.
Error Code: PendingTransactionAlreadyExists

The issue is related to a storage account inside the resource group.

What I did:

  • I deployed resources using an ARM template

During testing, I changed the storage account redundancy from LRS to GRS

After that, I attempted to delete the resource group

Current situation:

The storage account shows that initial data synchronization is in progress

I am unable to delete the storage account or the resource group

It seems like the operation is locked due to an ongoing geo-replication process

My questions:

Is there any way to cancel or override this pending geo-replication operation?

How can I force delete the resource group in this situation?

Is waiting for the replication to complete the only option?

Any guidance would be greatly appreciated.

Azure Storage
Azure Storage

Globally unique resources that provide access to data management services and serve as the parent namespace for the services.


3 answers

Sort by: Most helpful
  1. Praveen Bandaru 11,310 Reputation points Microsoft External Staff Moderator
    2026-03-26T00:52:50.0266667+00:00

    Hello Shubham kumar Singh

    I understand that you're trying to delete the resource group, but you're unable to because the storage account is still present within it.

    The RG deletion is currently on hold because the storage account within it is in the process of changing from LRS to GRS geo-replication. Azure does not provide an API to cancel geo-replication or a force-delete option while this operation is ongoing.

    Check the any replication action is ongoing with the below CLI commands:

    az storage account show --name <storageAccountName> --resource-group RG12 --query “{status:geoReplicationStats.status, lastSync:geoReplicationStats.lastSyncTime}”
    

    If the action is still processing, you cannot delete it or stop it midway. You will need to wait until the action is completed. After completing the action, you can proceed to delete the storage account and then delete your resource group.

    And below are the CLI command to delete:
    Command for delete Storage account

    az storage account delete -n -g RG12 --yes
    

    Command for to delete Resource Group

    az group delete -n RG12 --yes
    

    Check the below documents for more understanding:
    https://dotnet.territoriali.olinfo.it/en-us/troubleshoot/azure/virtual-machines/windows/storage-resource-deletion-errors

    https://dotnet.territoriali.olinfo.it/en-us/azure/azure-resource-manager/management/manage-resources-cli#delete-resources


    I hope the above answer helps you! Please let us know if you have any further questions.

    Please don't forget to "upvote" where the information provided will help you, this can be beneficial to other members of the community.

    0 comments No comments

  2. Venkatesan S 6,350 Reputation points Microsoft External Staff Moderator
    2026-03-19T17:09:47.5033333+00:00

    Hi Shubham kumar Singh,

    Thanks for reaching out in Microsoft Q&A forum,

    It looks like the storage account geo-replication change (LRS>GRS) you kicked off is still in its “initial data synchronization” phase, and Azure won’t let you delete the account (or its RG) until that background copy finishes. The “PendingTransactionAlreadyExists” error is exactly that your storage account is mid-replication and locked for deletes.

    Here’s what you can do:

    1. Monitor the geo-replication progress
      • In the Azure portal, go to your storage account > Geo-replication. You’ll see “Initial data synchronization in progress” and an estimate of completion.
      • Or use Azure CLI/PowerShell: • CLI:
         az storage account show --name <storageAccountName> --resource-group RG12 --query “{status:geoReplicationStats.status, lastSync:geoReplicationStats.lastSyncTime}”
      
      • PowerShell:
         Get-AzStorageAccount –ResourceGroupName RG12 –Name <storageAccountName> | Select-Object –ExpandProperty GeoReplicationStats
      
    2. Wait for the sync to complete
      Unfortunately, there’s no supported “cancel” or “force delete” for a pending geo-replication change. You’ll need to let that replication finish. Once the status goes to “live,” you can delete the storage account normally.
    3. Delete in correct order
      Once the replication state is “live”:
      • Delete the storage account
      • Then retry deleting RG12
        If you hit any locks or permission errors, make sure you’re Owner (or have Lock-management permissions) and that there are no management locks on RG12 or its child resources.

    Reference docs to help you troubleshoot locks, permissions, and deletion errors:

    Kindly let us know if the above helps or you need further assistance on this issue.

    Please do not forget to 210246-screenshot-2021-12-10-121802.pngand “up-vote” wherever the information provided helps you, this can be beneficial to other community members.

    0 comments No comments

  3. Q&A Assist
    2026-03-19T10:44:11.19+00:00
    AI generated content. This question contains an answer created with AI from Q&A Assist. Learn more

    The resource group delete is being blocked because the storage account is in the middle of a long‑running platform operation (geo‑redundancy change). While that operation is in progress, the storage account cannot be deleted, and therefore the resource group delete also fails.

    Azure Resource Manager deletes a resource group by issuing DELETE on each resource in dependency order and waiting for each to complete. If any resource cannot be deleted (for example, because the platform reports a blocking condition), the whole resource group delete fails with ResourceGroupDeletionBlocked.

    There is no supported way in the provided guidance to cancel or override such a pending platform operation on a storage account, and no documented “force delete” that bypasses the storage account’s own constraints. The only safe and supported path described is:

    1. Ensure there are no other blockers on the storage account (locks, attached VM disks, etc.). If the storage account is associated with VMs, follow the documented steps to detach/delete those VM disks first, then retry the delete.
    2. Retry deletion of the storage account directly (via portal, PowerShell Remove-AzStorageAccount, or CLI az storage account delete).
    3. Once the storage account can be deleted successfully, retry deleting the resource group (via portal, PowerShell Remove-AzResourceGroup, or CLI az group delete).

    If the platform operation (geo change / initial data sync) is still in progress, waiting for it to complete and then retrying the delete is the only behavior covered by the documentation. After the operation finishes and the storage account is in a stable state, the normal delete paths will work and the resource group delete will succeed.

    If the storage account remains stuck in this state for an unusually long time and still blocks deletion after repeated retries, the next step is to open an Azure Support request so the service team can inspect and clear the stuck backend operation.


    References:

    0 comments No comments

Your answer

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