Skip navigation
Microsoft Azure Logo

Guidance on disk size for disks in Azure

Q. With the switch to managed disks has the guidance on always creating the maximum size possible disk changed?

A. Yes. This is best understood by taking a step back to the original Azure Storage paged Blob offering which is how the VHDs for VMs were (are for unmanaged standard storage) stored. Paged Blobs use sparse storage. This means that even if you create a 1 TB VHD file, if you only write 100 MB of data within the VHD then only 100 MB of data is actually written to Azure storage which is all you were charged for. TRIM was also supported which means if data was deleted then the data stored was also reduced leading to reduced storage costs. Because of this and the difficulty of increasing the size of disks post creation the guidance was to always create disks the maximum possible size since you only paid for data actually written anyway.

With the introduction of premium storage this change as premium storage was based on disk sizes which corresponded to certain IOPS. You paid based on the size of the disk/IOPS and not based on the amount of data actually written. Therefore you would not always pick the biggest disk size available but rather the size of the disk that matched the storage/performance needs.

Next with the introduction of managed disks which abstracts storage accounts from the usage of disks, the billing is based on disk size/performance for standard and premium and no longer billed based on the amount of data actually written even for standard. Therefore even for standard you should now pick a disk that closest matches the projected storage needs of the disk when using managed storage to avoid paying more than you need to. Also you should create disks aligned with the SKU sizes as creating a disk smaller than a SKU size would be rounded up in price to the nearest SKU size anyway, for example creating a standard managed disk of 400 GB would be billed at a P20 (512 GB per https://azure.microsoft.com/en-us/pricing/details/managed-disks/)

To summarize:

  • Unmanaged standard storage - Pay for data written so can create maximum size disks
  • Everything else (managed standard storage, unmanaged/managed premium storage) - Pay for size of the disk so create disk size that matches need

Note you can resize disks if required, it just means a reboot of the VM. Also remember the difference in pricing if you ever switch an unmanaged standard disk to a managed disk!

Hide comments

Comments

  • Allowed HTML tags: <em> <strong> <blockquote> <br> <p>

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.
Publish