Sign up for the ITPro Today newsletter
Stay on top of the IT universe with commentary, news analysis, how-to's, and tips delivered to your inbox daily.
Learn how to resize disks used by ARM VMs.
June 7, 2016
Q. How can I resize an Azure Resource Manager disk?
A. The regular cmdlets to resize OS and data disks in a ASM storage account do not work for ARM storage accounts. Instead they are resized via the VM.
$vm = Get-AzureRmVM -Name testvm -ResourceGroupName RG-SCUSA$vm.StorageProfile.OsDisk.DiskSizeGB = 1023$vm.StorageProfile.OsDisk.Caching = 'None' # or ReadOnly ReadWriteUpdate-AzureRmVM -VM $VM -ResourceGroupName RG-SCUSA
To resize data disks they are accessed via an array of the VMs storage profile, for example:
$vm.StorageProfile.DataDisks[0].DiskSizeGB = 1023
You May Also Like