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/maintenance-control-cli.md
+27-10Lines changed: 27 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -28,13 +28,13 @@ With maintenance control, you can:
28
28
> Maintenance Control is currently in public preview.
29
29
> This preview version is provided without a service level agreement, and it's not recommended for production workloads. Certain features might not be supported or might have constrained capabilities.
30
30
> For more information, see [Supplemental Terms of Use for Microsoft Azure Previews](https://azure.microsoft.com/support/legal/preview-supplemental-terms/).
31
-
>
31
+
>
32
32
33
33
## Limitations
34
34
35
35
- VMs must be on a [dedicated host](./linux/dedicated-hosts.md), or be created using an [isolated VM size](./linux/isolation.md).
36
36
- After 35 days, an update will automatically be applied.
37
-
- User must have **Resource Owner** access.
37
+
- User must have **Resource Contributor** access.
38
38
39
39
40
40
## Install the maintenance extension
@@ -148,6 +148,23 @@ az maintenance assignment list \
148
148
149
149
Use `az maintenance update list` to see if there are pending updates. Update --subscription to be the ID for the subscription that contains the VM.
150
150
151
+
If there are no updates, the command will return an error message, which will contain the text: `Resource not found...StatusCode: 404`.
152
+
153
+
If there are updates, only one will be returned, even if there are multiple updates pending. The data for this update will be returned in an object:
Check for pending updates for an isolated VM. In this example, the output is formatted as a table for readability.
@@ -163,7 +180,7 @@ az maintenance update list \
163
180
164
181
### Dedicated host
165
182
166
-
To check for pending updates for a dedicated host. In this example, the output is formatted as a table for readability. Replace the values for the resources with your own.
183
+
To check for pending updates for a dedicated host (ADH). In this example, the output is formatted as a table for readability. Replace the values for the resources with your own.
167
184
168
185
```azurecli-interactive
169
186
az maintenance update list \
@@ -179,7 +196,7 @@ az maintenance update list \
179
196
180
197
## Apply updates
181
198
182
-
Use `az maintenance apply update` to apply pending updates.
199
+
Use `az maintenance apply update` to apply pending updates. On success, this command will return JSON containing the details of the update.
183
200
184
201
### Isolated VM
185
202
@@ -188,7 +205,7 @@ Create a request to apply updates to an isolated VM.
@@ -214,17 +231,17 @@ az maintenance applyupdate create \
214
231
215
232
You can check on the progress of the updates using `az maintenance applyupdate get`.
216
233
217
-
### Isolated VM
234
+
You can use `default` as the update name to see results for the last update, or replace `myUpdateName` with the name of the update that was returned when you ran `az maintenance applyupdate create`.
218
235
219
-
Replace `myUpdateName` with the name of the update that was returned when you ran `az maintenance applyupdate create`.
236
+
### Isolated VM
220
237
221
238
```azurecli-interactive
222
239
az maintenance applyupdate get \
223
240
--resource-group myMaintenanceRG \
224
241
--resource-name myVM \
225
242
--resource-type virtualMachines \
226
243
--provider-name Microsoft.Compute \
227
-
--apply-update-name myUpdateName
244
+
--apply-update-name default
228
245
```
229
246
230
247
### Dedicated host
@@ -238,7 +255,7 @@ az maintenance applyupdate get \
0 commit comments