I like to clean up things after I’m done with my testing and this morning I decided to clean up my VM’s, Databases which were created under Windows Azure.
Everything went smooth till I tried to delete my storage account. As soon as I tried a delete there was an exception.
The ‘Details’ section gave me more details on why this action cant be completed.
The error message is quite self explanatory. This was telling me that the storage account which I was trying to delete was having a container which was holding an active image.
Then I decided to go ahead and check the blobs under the container, and there was indeed a blob available. As a matter of fact even the container itself is a blob.
I decided to delete this blob, and then successfully deleted the storage account from the portal.
To sum up, the right way to delete a storage account from windows azure is to check if you have any active blobs under the container and remove that blob well before you try and remove the storage account.
Hope this short explanation helps you understand how storage is handled within Azure and how things are categorized with respect to Accounts, Container Blobs and Blobs within the containers.