@Andrei Muresan
Currently the only way to retrieve the data from an archived snapshot or version is to copy that to a new blob. If you attempt to set the tier of archived version to cool or hot you will receive an error. Instructions for rehydrating a blob via copying can be found here. Once you have copied the blob you could proceed to replace the existing blob with this restored version.
Here is my test for restoring a blob via CLI:
az storage blob copy start -u https://storageaccount.blob.core.windows.net/test1/blob.txt?versionId=2021-09-21T21:50:52.7602500Z --destination-container test2 --destination-blob blob1.txt --account-name storageaccount --tier hot --rehydrate-priority standard
There are no credentials provided in your command and environment, we will query for account key for your storage account.
It is recommended to provide --connection-string, --account-key or --sas-token in your command as credentials.
You also can add `--auth-mode login` in your command to use Azure Active Directory (Azure AD) for authorization if your login account is assigned required RBAC roles.
For more information about RBAC roles in storage, visit https://learn.microsoft.com/en-us/azure/storage/common/storage-auth-aad-rbac-cli.
In addition, setting the corresponding environment variables can avoid inputting credentials in your command. Please use --help to get more information about environment variable usage.
{
"client_request_id": "11d491ce-1bc4-11ec-be4c-0a580af407e7",
"copy_id": "514e41a1-ad0b-484c-907d-54a765d00718",
"copy_status": "success",
"date": "2021-09-22T16:42:26+00:00",
"etag": "\"0x8D97DE7F6327C09\"",
"last_modified": "2021-09-22T16:42:27+00:00",
"request_id": "1570842b-501e-0031-78d0-af8fb5000000",
"version": "2020-04-08",
"version_id": "2021-09-22T16:42:27.1056905Z"
}
Hope this helps! Let me know if you have further questions or run into any issues.
-------------------------------
Please don’t forget to "Accept the answer" and “up-vote” wherever the information provided helps you, this can be beneficial to other community members.