Azure

Azure: Switching Between Hot/Cool/Archive Storage Access Tiers

In this post, I’m going to provide PowerShell examples of how to switch Access Tiers of an Azure Storage Account.

First, let us provision a Storage Account with Access Tier set as Cool:

PS C:\> New-AzureRmStorageAccount -ResourceGroupName testRG1 -Name teststa112 -AccessTier Cool -Kind BlobStorage -SkuName Standard_LRS -Location WestUS

To show that the change of Access Tier is possible even when a container is present, let us create one:

PS C:\> Set-AzureRmCurrentStorageAccount -Name teststa112 -ResourceGroupName testrg1
teststa112

PS C:\> New-AzureStorageContainer -Name teststoragecontainer

Finally, let us change Access Tier to Hot (note that if you omit -Force option you’ll get a prompt to confirm price change)
PS C:\> Set-AzureRmStorageAccount -Name teststa112 -resourcegroupname testrg1 -AccessTier hot -Force -Verbose

We can change Access Tier back to Cool again as below (note that if you omit -Force option you’ll get a prompt to confirm price change)
PS C:\> Set-AzureRmStorageAccount -Name teststa112 -resourcegroupname testrg1 -AccessTier cool -Force -Verbose

Access Tier of “Archive” is in Preview as of this writing. Please refer to this blog post for details on how to enable your own Preview access. Once enabled, you can also change the tier to “Archive” in addition to Hot or Cool.

Advertisements

Categories: Azure, Storage

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s