Hi rr-4098,
Welcome to Microsoft Q&A, thanks for posting your query.
Yes, you're right. SQL Server Maintenance Plans do not support accessing or interacting with URL-based locations like Azure Blob Storage. They are designed to work with local disk locations.
To clean up old SQL backups stored in Azure Blob storage, you can use Azure Blob storage lifecycle management. Lifecycle management policies are supported for block blobs and append blobs in general-purpose v2, premium block blob, and Blob Storage accounts.
A lifecycle management policy is composed of one or more rules that define a set of actions to take based on a condition being met. For a base blob, you can choose to check one of the following conditions:
- The number of days since the blob was created.
- The number of days since the blob was last modified.
- The number of days since the blob was last accessed. To use this condition in an action, you should first optionally enable last access time tracking.
To set up lifecycle management for your Azure Blob storage account, you can use the Azure portal, Azure CLI, or Azure PowerShell.
Reference: Configure a lifecycle management policy - Azure Blob Storage | Microsoft Learn
These pages provide detailed information on how to set up and manage lifecycle management rules for Azure Blob storage using the Azure portal, Azure CLI, or Azure PowerShell.
Azure Blob storage lifecycle management can be used to delete blobs based on their age or other criteria.
If you want to delete files in a file share, you can use Azure File Sync to replicate the files to an Azure file share and then use Azure Blob storage lifecycle management to delete the blobs.
Lifecycle management policy will not delete the current version of a blob until any previous versions or snapshots associated with that blob have been deleted.
If blobs in your storage account have previous versions or snapshots, then you must include previous versions and snapshots when you specify a delete action as part of the policy.
Please let us know if you have any further queries. I’m happy to assist you further.
Please do not forget to "Accept the answer” and “up-vote” wherever the information provided helps you, this can be beneficial to other community members.