Share via

Setting BlobAccessTier while generating upload SAS Url

Janani 20 Reputation points
2024-03-14T18:33:16.48+00:00

We are uploading data to azure storage account using SAS URL having write permissions. We would like to upload these blob with AccessTier as Cold, though the default Storage Account one is Hot. Is there a way to specify the AccessTier while generating upload SAS Url.

Many thanks in advance.

Azure Blob Storage
Azure Blob Storage

An Azure service that stores unstructured data in the cloud as blobs.

0 comments No comments

Answer accepted by question author

Amrinder Singh 5,875 Reputation points Microsoft Employee Volunteer Moderator
2024-03-15T09:45:36.7+00:00

Hi @Janani - Thanks for reaching out on Q&A Forum.

SAS doesn't provide option to set the access tier rather it is being considered as the auth mechanism.

When you will be uploading the blob to storage, you will be mainly calling the PUT BLOB operation and let's consider you are making use of SAS as the auth scheme in here.

https://learn.microsoft.com/en-us/rest/api/storageservices/put-blob?tabs=microsoft-entra-id

In PutBlob Tier, you can pass the access tier value as COLD for header x-ms-access-tier which will create the Blob in Cold Tier irrespective of the default access tier on the account level.

Note: Cold tier is supported for version 2021-12-02 and later.If you are making use of any 3rd party tool which doesn't allow setting these headers, you can also explore for option of moving the tier from Hot to Cold tier post uploading via LCM as well.

https://learn.microsoft.com/en-us/azure/storage/blobs/lifecycle-management-overview#rule-actions

Please let me know for any further queries and will be glad to assist.

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.

Was this answer helpful?

1 person found this answer helpful.
0 comments No comments

1 additional answer

Sort by: Most helpful
  1. Marcin Policht 92,380 Reputation points MVP Volunteer Moderator
    2024-03-14T19:06:16.3633333+00:00

    In short no - access tier is not supported as part of the SAS token properties


    hth

    Marcin

    Was this answer helpful?


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.