You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/virtual-machines/capacity-reservation-create.md
+45Lines changed: 45 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -33,6 +33,51 @@ The Capacity Reservation must meet the following rules:
33
33
- For a Capacity Reservation group that supports zones, each reservation type is defined by the combination of **VM size** and **zone**. For example, one Capacity Reservation for `Standard_D2s_v3` in `Zone 1`, another Capacity Reservation for `Standard_D2s_v3` in `Zone 2`, and a third Capacity Reservation for `Standard_D2s_v3` in `Zone 3` is supported.
34
34
35
35
36
+
## Checking VM sizes available for Capacity Reservation in a region
37
+
38
+
Before creating capacity reservation, VM sizes available for reservation can be checked for a particular region.
39
+
40
+
41
+
### [Portal](#tab/portal1)
42
+
43
+
<!-- no images necessary if steps are straightforward -->
44
+
45
+
1. Open [Azure portal](https://portal.azure.com)
46
+
1. In the search bar, type **Capacity Reservation groups**
47
+
1. Select **Capacity Reservation groups** from the options
48
+
1. Select **Create**
49
+
1. Under the *Basics* tab, create a Capacity Reservation group:
50
+
1. Select a **Subscription**
51
+
1. Select or create a **Resource group**
52
+
1.**Name** your group
53
+
1. Select a **Region**
54
+
1. Optionally select **Availability zones** or opt not to specify any zones and allow Azure to choose for you
55
+
1. Select **Next**
56
+
1. On VM size, click on **See all sizes** to check what VM sizes are available for Capacity Reservation
57
+
58
+
59
+
### [PowerShell](#tab/powershell1)
60
+
61
+
1. Before you create a capacity reservation, you can check the reservation available VM sizes for the region selected using Get-AzComputeResourceSku for Capability property for Resource type Virtual Machines. The following example lists the capacity reservation available VM sizes in East US location:
62
+
63
+
64
+
65
+
```powershell-interactive
66
+
$vmsizes = Get-AzComputeResourceSku -Location eastus | where {$_.ResourceType -eq "virtualMachines"}
67
+
foreach($vmsize in $vmsizes) { foreach($capability in $vmsize.capabilities) { if($capability.Name -eq 'CapacityReservationSupported' -and $capability.Value -eq 'true'){ $vmsize.name } } }
68
+
```
69
+
70
+
71
+
### [CLI](#tab/cli1)
72
+
73
+
1. The following example lists the capacity reservation available VM sizes in East US location using Azure CLI:
74
+
75
+
```azurecli-interactive
76
+
az vm list-skus -l eastus --resource-type virtualMachines --query "[?contains(capabilities[?name == 'CapacityReservationSupported' && value == 'True'].name,'CapacityReservationSupported')].name"
77
+
```
78
+
---
79
+
<!-- The three dashes above show that your section of tabbed content is complete. Do not remove them :) -->
0 commit comments