Choosing and Changing VM Sizes
A VM's size decides its resources and cost. This lesson explains size families and the constraints on resizing.
Learning outcomes
After completing this lesson, you will be able to:
- Identify the VM size families and the workloads they suit.
- Explain when a VM must be deallocated before resizing.
- Identify other constraints on resizing, such as quotas.
Size families and names
Azure groups VM sizes into families for different workloads. The following table lists the families most likely to appear in exam scenarios.
| Family | Optimized for | Example workloads |
|---|---|---|
| B | Burstable CPU (earns credits when idle) | Development, small web servers, low-traffic apps |
| D | General purpose, balanced CPU and memory | Most enterprise applications, application servers |
| E | Memory optimized (high memory per vCPU) | Relational databases, in-memory caches |
| F | Compute optimized (high CPU per GB) | Batch processing, web front ends, gaming servers |
| L | Storage optimized with local NVMe disks | Big data, NoSQL databases, data warehousing |
| M | Very large memory | SAP HANA, very large databases |
| N | GPU | AI training and inference, visualization |
Size names encode their properties: in Standard_D4as_v5, D is the family, 4 the number of vCPUs, a an AMD processor, s support for premium storage, and v5 the version. Each size also sets the maximum number of data disks and NICs, uncached and cached disk IOPS and throughput, and expected network bandwidth, so a disk's performance can be capped by the VM size.
Which size family?
Resizing a VM
A VM is resized on its Size page, with az vm resize --size or Update-AzVM. Resizing restarts the VM. The Size page lists sizes available on the hardware cluster that currently hosts the VM; if the required size is not available there, the VM must be deallocated first so that it can start on a different cluster, after which every size in the region is available. VMs in an availability set share clusters, so changing to a size not on the cluster requires deallocating all VMs in the set.
Other constraints: the subscription needs enough vCPU quota for the target family in the region; some sizes are not offered in every region or zone; moving between sizes with and without a temporary disk, or between generations, may require recreating the VM; and a size must support the VM's features, such as premium storage, encryption at host or Trusted launch.
The following diagram shows the sequence for resizing a running VM to a size that is missing from its Size page.

Resizing
A resize that is not listed
A database VM of size Standard_D4s_v5 runs out of memory. The administrator wants Standard_E8s_v5, but it does not appear on the Size page, although the region offers it and the subscription has enough quota. What should the administrator do?
The E-series size is not available on the current hardware cluster. Deallocate the VM (Stop in the portal), then resize it to Standard_E8s_v5 and start it. Requesting more quota is unnecessary because quota is sufficient, and recreating the VM is not required. The E-series is the right family because the problem is memory.
What does the s mean in a size name such as Standard_D4s_v5?
Show answer
The size supports premium storage (Premium SSD disks).
Exam Tips
Remember for the exam
- Resizing restarts the VM; deallocate first if the size is not listed.
- Choose the family by bottleneck: memory E, compute F, storage L, GPU N, burstable B.
- VM size limits disk IOPS, throughput and the number of data disks.
- Check vCPU quota for the target family before resizing.