Skip to content

Commit 1063fd7

Browse files
committed
updated CLI section
1 parent 5c7bb6f commit 1063fd7

File tree

1 file changed

+17
-6
lines changed

1 file changed

+17
-6
lines changed

articles/azure-monitor/autoscale/autoscale-multiprofile.md

Lines changed: 17 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -325,12 +325,6 @@ To create a recurring profile
325325

326326
The example below shows the addition of a recurring profile, recurring on Thursdays between 06:00 and 22:50.
327327

328-
> [!NOTE]
329-
> The JSON for your autoscale default profile will be modified by adding a recurring profile.
330-
> The `name` of the default profile will be an object in the format: `"name": "{\"name\":\"Auto created default scale condition\",\"for\":\"recurring profile\"}"` where *recurring profile* is the profile name from the `az monitor autoscale profile create` command.
331-
> The default profile will also have a recurrence clause added to it that starts at the end time specified for the new recurring profile
332-
> A new default profile is created for each recurring profile.
333-
334328
``` azurecli
335329
336330
az monitor autoscale profile create --autoscale-name VMSS1-Autoscale-607 --count 2 --max-count 10 --min-count 1 --name Thursdays --recurrence week thu --resource-group rg-vmss1 --start 06:00 --end 22:50 --timezone "Pacific Standard Time"
@@ -340,4 +334,21 @@ az monitor autoscale rule create -g rg-vmss1 --autoscale-name VMSS1-Autoscale-60
340334
az monitor autoscale rule create -g rg-vmss1 --autoscale-name VMSS1-Autoscale-607 --scale out 2 --condition "Percentage CPU > 50 avg 5m" --profile-name Thursdays
341335
```
342336

337+
> [!NOTE]
338+
> The JSON for your autoscale default profile is modified by adding a recurring profile.
339+
> The `name` of the default profile is changed to an object in the format: `"name": "{\"name\":\"Auto created default scale condition\",\"for\":\"recurring profile\"}"` where *recurring profile* is the profile name from the `az monitor autoscale profile create` command.
340+
> The default profile also has a recurrence clause added to it that starts at the end time specified for the new recurring profile.
341+
> A new default profile is created for each recurring profile.
342+
343+
After adding recurring profiles, your default profile is renamed. If you have multiple recurring profiles and want to update your default profile the update mast be made to each default profile that corresponds to a recurring profile.
344+
345+
For example, if you have two recurring profiles called *Wednesdays* and *Thursdays*, you need two commands to add a rule to the default profile.
346+
347+
```azurecli
348+
az monitor autoscale rule create -g rg-vmss1--autoscale-name VMSS1-Autoscale-607 --scale out 8 --condition "Percentage CPU > 52 avg 5m" --profile-name "{\"name\": \"Auto created default scale condition\", \"for\": \"Wednesdays\"}"
349+
350+
az monitor autoscale rule create -g rg-vmss1--autoscale-name VMSS1-Autoscale-607 --scale out 8 --condition "Percentage CPU > 52 avg 5m" --profile-name "{\"name\": \"Auto created default scale condition\", \"for\": \"Thursdays\"}"
351+
```
352+
353+
343354
---

0 commit comments

Comments
 (0)