Hello Passkey-Noah,
Oof, this is a tough one. Once an immutability policy is locked on a blob container, Azure is pretty serious about enforcing it - that's kind of the whole point of immutability (think compliance requirements like WORM for financial/legal data).
Here's the bad news: You can't delete or override a locked immutability policy. That's by design. Even Microsoft support can't do it for you - it's a security feature.
But here's what you CAN do:
Wait it out
If the policy has a retention period (like "retain for 7 years"), you have to wait until that period expires for each blob before you can delete them. Once all the blobs expire and are deleted, the container can be removed.
Check what type of policy it is:
- Go to your container in Azure Portal
- Look at the immutability policy settings
- See if there's an expiration date
If you absolutely need the storage space back now:
Since you only have basic support, your options are limited, but try:
- Stop writing new data to that container immediately
- Create a NEW container for your ongoing work
- Let the old container sit there until the retention expires
- Mark it clearly so no one tries to use it (rename it to something like "locked-do-not-use-expires-2030")
The nuclear option (if you're desperate):
You could potentially delete the entire storage account, but that's obviously extreme and would take down everything else in it too. Only consider this if:
- The container is the only thing in the storage account
- You absolutely can't wait
- You've backed up anything you need
How did this happen?
If this was locked "inadvertently during testing" as you mentioned, someone probably set a time-based retention policy and then locked it thinking they could unlock it later. Unfortunately, once it's locked, it's locked for good.
Going forward: Never lock an immutability policy unless you're 100% sure. Use unlocked policies for testing.
Sorry I don't have better news - this is one of those "designed to be painful" features for compliance reasons.
Best Regards,
Jerald Felix