I want to do the following: create a VHD, copy a filetree there, then upload the VHD file to Azure blob storage, then when my Azure role starts I will download the VHD and mount it and use it as read-only. I know the filetree in advance so I can choose between a fixed-size VHD and an expandable VHD.

Expandable looks more convenient, but I suspect it might have some overhead and then I'll maybe get a bigger file compared to fixed one.

Will using an expandable VHD yield a bigger file? Are there any catches with expandable VHDs in this scenario?

1 Answer 1


The "catch" isn't increased file size, in fact the very purpose of a Thin Provisioned/Dynamically Expandable disk is that you decrease their size on disk.

The [major] tradeoffs are performance in all cases, and the risk of over commitment (running out of space as the volumes grow) in most cases. If you monitor your disk usage and are careful to avoid letting your expandable VHDs grow past the size of your storage, you can avoid the over-commitment issue relatively easily (but that depends on how many you have and the complexity of your virtual environment), and you can mitigate the performance issue somewhat with certain disk settings.

(MS article on VHD architecture which may be useful.)

Read performance is slower for dynamically sized VHDs, and you may need to consider other performance factors as well - like what happens on your host and/or storage if you have a bunch of your VHDs growing at the same time, because you'll take a performance hit there as well. Add to that other storage-related considerations, like your dynamically sized VHDs becoming fragmented/non-contiguous, and interactions with deduplication and snapshotting, your environmental constraints may dictate whether or not they're a good idea at all.

As a general rule, if you know what size you need, and have the space to allocate it all now, the fixed-size/thick provisioned disk is a better choice. At a minimum, you get slightly better performance and one less thing to worry about. But if you're pressed for space, and keep those few things in mind, there's nothing wrong with going the Dynamic/Thin route either. And in fact, one could make the argument that dynamic disks are not a horrible default choice, because expandable virtual disks allow you a lot more flexibility when the requirements change and someone needs to cram a couple dozen gigs of extra stuff onto your disk. As with everything else, it depends on your environment.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.