|
| 1 | +# Azure CLI quota Extension # |
| 2 | +This is the extension for quota |
| 3 | + |
| 4 | +### How to use ### |
| 5 | +Install this extension using the below CLI command |
| 6 | +``` |
| 7 | +az extension add --name quota |
| 8 | +``` |
| 9 | + |
| 10 | +### Included Features ### |
| 11 | +#### quota reservation #### |
| 12 | +##### List ##### |
| 13 | +``` |
| 14 | +az quota reservation list --reservation-order-id "276e7ae4-84d0-4da6-ab4b-d6b94f3557da" |
| 15 | +``` |
| 16 | +##### Show ##### |
| 17 | +``` |
| 18 | +az quota reservation show --expand "renewProperties" --reservation-id "6ef59113-3482-40da-8d79-787f823e34bc" \ |
| 19 | + --reservation-order-id "276e7ae4-84d0-4da6-ab4b-d6b94f3557da" |
| 20 | +``` |
| 21 | +##### Update ##### |
| 22 | +``` |
| 23 | +az quota reservation update --applied-scope-type "Shared" --instance-flexibility "Off" \ |
| 24 | + --reservation-id "6ef59113-3482-40da-8d79-787f823e34bc" \ |
| 25 | + --reservation-order-id "276e7ae4-84d0-4da6-ab4b-d6b94f3557da" |
| 26 | +``` |
| 27 | +##### Available-scope ##### |
| 28 | +``` |
| 29 | +az quota reservation available-scope --properties scopes="/subscriptions/efc7c997-7700-4a74-b731-55aec16c15e9" \ |
| 30 | + --reservation-id "356e7ae4-84d0-4da6-ab4b-d6b94f3557da" \ |
| 31 | + --reservation-order-id "276e7ae4-84d0-4da6-ab4b-d6b94f3557da" |
| 32 | +``` |
| 33 | +##### List-all ##### |
| 34 | +``` |
| 35 | +az quota reservation list-all --filter "(properties%2farchived+eq+false)" --orderby "properties/displayName asc" \ |
| 36 | + --skiptoken "50" --refresh-summary "true" --take "1" |
| 37 | +``` |
| 38 | +##### List-revision ##### |
| 39 | +``` |
| 40 | +az quota reservation list-revision --reservation-id "6ef59113-3482-40da-8d79-787f823e34bc" \ |
| 41 | + --reservation-order-id "276e7ae4-84d0-4da6-ab4b-d6b94f3557da" |
| 42 | +``` |
| 43 | +##### Merge ##### |
| 44 | +``` |
| 45 | +az quota reservation merge \ |
| 46 | + --sources "/providers/Microsoft.Capacity/reservationOrders/c0565a8a-4491-4e77-b07b-5e6d66718e1c/reservations/cea04232-932e-47db-acb5-e29a945ecc73" "/providers/Microsoft.Capacity/reservationOrders/c0565a8a-4491-4e77-b07b-5e6d66718e1c/reservations/5bf54dc7-dacd-4f46-a16b-7b78f4a59799" \ |
| 47 | + --reservation-order-id "276e7ae4-84d0-4da6-ab4b-d6b94f3557da" |
| 48 | +``` |
| 49 | +##### Split ##### |
| 50 | +``` |
| 51 | +az quota reservation split --quantities 1 2 \ |
| 52 | + --reservation-id "/providers/Microsoft.Capacity/reservationOrders/276e7ae4-84d0-4da6-ab4b-d6b94f3557da/reservations/bcae77cd-3119-4766-919f-b50d36c75c7a" \ |
| 53 | + --reservation-order-id "276e7ae4-84d0-4da6-ab4b-d6b94f3557da" |
| 54 | +``` |
| 55 | +#### quota #### |
| 56 | +##### Show-applied-reservation-list ##### |
| 57 | +``` |
| 58 | +az quota show-applied-reservation-list --subscription-id "23bc208b-083f-4901-ae85-4f98c0c3b4b6" |
| 59 | +``` |
| 60 | +##### Show-catalog ##### |
| 61 | +``` |
| 62 | +az quota show-catalog --location "eastus" --reserved-resource-type "VirtualMachines" \ |
| 63 | + --subscription-id "23bc208b-083f-4901-ae85-4f98c0c3b4b6" |
| 64 | +``` |
| 65 | +#### quota reservation-order #### |
| 66 | +##### Purchase ##### |
| 67 | +``` |
| 68 | +az quota reservation-order purchase --location "westus" --applied-scope-type "Shared" --billing-plan "Monthly" \ |
| 69 | + --billing-scope-id "/subscriptions/ed3a1871-612d-abcd-a849-c2542a68be83" --display-name "TestReservationOrder" \ |
| 70 | + --quantity 1 --renew false --instance-flexibility "On" --reserved-resource-type "VirtualMachines" --term "P1Y" \ |
| 71 | + --name "standard_D1" --reservation-order-id "a075419f-44cc-497f-b68a-14ee811d48b9" |
| 72 | +``` |
| 73 | +##### Show ##### |
| 74 | +``` |
| 75 | +az quota reservation-order show --reservation-order-id "a075419f-44cc-497f-b68a-14ee811d48b9" |
| 76 | +``` |
| 77 | +##### Show ##### |
| 78 | +``` |
| 79 | +az quota reservation-order show --expand "schedule" --reservation-order-id "a075419f-44cc-497f-b68a-14ee811d48b9" |
| 80 | +``` |
| 81 | +##### Calculate ##### |
| 82 | +``` |
| 83 | +az quota reservation-order calculate --location "westus" --applied-scope-type "Shared" --billing-plan "Monthly" \ |
| 84 | + --billing-scope-id "/subscriptions/ed3a1871-612d-abcd-a849-c2542a68be83" --display-name "TestReservationOrder" \ |
| 85 | + --quantity 1 --instance-flexibility "On" --reserved-resource-type "VirtualMachines" --term "P1Y" \ |
| 86 | + --name "standard_D1" |
| 87 | +``` |
| 88 | +##### Change-directory ##### |
| 89 | +``` |
| 90 | +az quota reservation-order change-directory --destination-tenant-id "906655ea-30be-4587-9d12-b50e077b0f32" \ |
| 91 | + --reservation-order-id "a075419f-44cc-497f-b68a-14ee811d48b9" |
| 92 | +``` |
| 93 | +##### List ##### |
| 94 | +``` |
| 95 | +az quota reservation-order list |
| 96 | +``` |
| 97 | +#### quota operation #### |
| 98 | +##### List ##### |
| 99 | +``` |
| 100 | +az quota operation list |
| 101 | +``` |
| 102 | +#### quota calculate-exchange #### |
| 103 | +##### Post ##### |
| 104 | +``` |
| 105 | +az quota calculate-exchange post \ |
| 106 | + --reservations-to-exchange quantity=1 reservation-id="/providers/microsoft.capacity/reservationOrders/1f14354c-dc12-4c8d-8090-6f295a3a34aa/reservations/c8c926bd-fc5d-4e29-9d43-b68340ac23a6" \ |
| 107 | + --reservations-to-purchase location="westus" reserved-resource-type="VirtualMachines" billing-scope-id="/subscriptions/ed3a1871-612d-abcd-a849-c2542a68be83" term="P1Y" billing-plan="Upfront" quantity=1 display-name="testDisplayName" applied-scope-type="Shared" applied-scopes=null renew=false instance-flexibility="On" name="Standard_B1ls" |
| 108 | +``` |
| 109 | +#### quota exchange #### |
| 110 | +##### Post ##### |
| 111 | +``` |
| 112 | +az quota exchange post --session-id "66e2ac8f-439e-4345-8235-6fef07608081" |
| 113 | +``` |
| 114 | +#### quota #### |
| 115 | +##### Create ##### |
| 116 | +``` |
| 117 | +az quota create \ |
| 118 | + --properties "{\\"name\\":{\\"value\\":\\"standardFSv2Family\\"},\\"limit\\":200,\\"unit\\":\\"Count\\"}" \ |
| 119 | + --location "eastus" --provider-id "Microsoft.Compute" --resource-name "standardFSv2Family" \ |
| 120 | + --subscription-id "D7EC67B3-7657-4966-BFFC-41EFD36BAAB3" |
| 121 | +``` |
| 122 | +##### Create ##### |
| 123 | +``` |
| 124 | +az quota create \ |
| 125 | + --properties "{\\"name\\":{\\"value\\":\\"StandardDv2Family\\"},\\"limit\\":200,\\"resourceType\\":\\"dedicated\\",\\"unit\\":\\"Count\\"}" \ |
| 126 | + --location "eastus" --provider-id "Microsoft.MachineLearningServices" --resource-name "StandardDv2Family" \ |
| 127 | + --subscription-id "D7EC67B3-7657-4966-BFFC-41EFD36BAAB3" |
| 128 | +``` |
| 129 | +##### Create ##### |
| 130 | +``` |
| 131 | +az quota create \ |
| 132 | + --properties "{\\"name\\":{\\"value\\":\\"TotalLowPriorityCores\\"},\\"limit\\":200,\\"resourceType\\":\\"lowPriority\\",\\"unit\\":\\"Count\\"}" \ |
| 133 | + --location "eastus" --provider-id "Microsoft.MachineLearningServices" --resource-name "TotalLowPriorityCores" \ |
| 134 | + --subscription-id "D7EC67B3-7657-4966-BFFC-41EFD36BAAB3" |
| 135 | +``` |
| 136 | +##### List ##### |
| 137 | +``` |
| 138 | +az quota list --location "eastus" --provider-id "Microsoft.Compute" \ |
| 139 | + --subscription-id "00000000-0000-0000-0000-000000000000" |
| 140 | +``` |
| 141 | +##### List ##### |
| 142 | +``` |
| 143 | +az quota list --location "eastus" --provider-id "Microsoft.MachineLearningServices" \ |
| 144 | + --subscription-id "00000000-0000-0000-0000-000000000000" |
| 145 | +``` |
| 146 | +##### Show ##### |
| 147 | +``` |
| 148 | +az quota show --location "eastus" --provider-id "Microsoft.Compute" --resource-name "standardNDSFamily" \ |
| 149 | + --subscription-id "00000000-0000-0000-0000-000000000000" |
| 150 | +``` |
| 151 | +##### Update ##### |
| 152 | +``` |
| 153 | +az quota update \ |
| 154 | + --properties "{\\"name\\":{\\"value\\":\\"standardFSv2Family\\"},\\"limit\\":200,\\"unit\\":\\"Count\\"}" \ |
| 155 | + --location "eastus" --provider-id "Microsoft.Compute" --resource-name "standardFSv2Family" \ |
| 156 | + --subscription-id "D7EC67B3-7657-4966-BFFC-41EFD36BAAB3" |
| 157 | +``` |
| 158 | +#### quota quota-request-status #### |
| 159 | +##### List ##### |
| 160 | +``` |
| 161 | +az quota quota-request-status list --location "eastus" --provider-id "Microsoft.Compute" \ |
| 162 | + --subscription-id "3f75fdf7-977e-44ad-990d-99f14f0f299f" |
| 163 | +``` |
| 164 | +##### Show ##### |
| 165 | +``` |
| 166 | +az quota quota-request-status show --id "2B5C8515-37D8-4B6A-879B-CD641A2CF605" --location "eastus" \ |
| 167 | + --provider-id "Microsoft.Compute" --subscription-id "00000000-0000-0000-0000-000000000000" |
| 168 | +``` |
| 169 | +##### Show ##### |
| 170 | +``` |
| 171 | +az quota quota-request-status show --id "2B5C8515-37D8-4B6A-879B-CD641A2CF605" --location "eastus" \ |
| 172 | + --provider-id "Microsoft.Compute" --subscription-id "00000000-0000-0000-0000-000000000000" |
| 173 | +``` |
| 174 | +##### Show ##### |
| 175 | +``` |
| 176 | +az quota quota-request-status show --id "2B5C8515-37D8-4B6A-879B-CD641A2CF605" --location "eastus" \ |
| 177 | + --provider-id "Microsoft.Compute" --subscription-id "00000000-0000-0000-0000-000000000000" |
| 178 | +``` |
0 commit comments