Muokkaa

Jaa


Control updates with Maintenance Configurations and the Azure portal

Applies to: ✔️ Linux VMs ✔️ Windows VMs ✔️ Flexible scale sets ✔️ Uniform scale sets

With the Maintenance Configurations feature, you can control when to apply updates to various Azure resources. This article covers the Azure portal options for using this feature. For more information about the benefits of using Maintenance Configurations, its limitations, and other management options, see Managing platform updates with Maintenance Configurations.

Create a maintenance configuration

  1. Sign in to the Azure portal.

  2. Search for maintenance configurations, and then open the Maintenance Configurations result.

    Screenshot that shows how to find the Maintenance Configurations service in the Azure portal.

  3. Select Create.

    Screenshot that shows the location of the command for creating a maintenance configuration.

  4. On the Basics tab, choose a subscription and resource group, provide a name for the configuration, choose a region, and select one of the scopes that you want to apply updates for. Then select Add a schedule to add or modify the schedule for your configuration.

    Important

    Certain virtual machine types and schedules require a specific kind of scope. To find the right scope for your virtual machine, see Scopes.

    Screenshot that shows basic information for a maintenance configuration.

  5. On the Add/Modify schedule pane, declare a scheduled window when Azure will apply the updates on your resources. Set a start date, maintenance window, and recurrence if your resource requires it. After you create a scheduled window, you no longer have to apply the updates manually. When you finish, select Next.

    Important

    The duration of the maintenance window must be 2 hours or longer.

    Screenshot that shows schedule options for applying updates.

  6. On the Machines tab, assign resources now or skip this step and assign resources later (after you deploy the maintenance configuration). Then select Next.

  7. On the Tags tab, add tags and values. Then select Next.

    Screenshot that shows name and value boxes for adding tags to a maintenance configuration.

  8. On the Review + create tab, review the summary. Then select Create.

  9. After the deployment is complete, select Go to resource.

Assign the configuration

  1. On the details page of the maintenance configuration, select Machines, and then select Add machine.

    Screenshot that shows the button for adding a machine.

  2. On the Select resources pane, select the resources that you want the maintenance configuration assigned to. The VMs that you select need to be running. If you try to assign a configuration to a VM that's stopped, an error occurs. When you finish, select Ok.

    Screenshot that shows the selection of resources.

Check the configuration and status

You can verify that the configuration was applied correctly, or check which machines are assigned to a maintenance configuration, by going to Maintenance Configurations > Machines.

Screenshot that shows where to check a maintenance configuration in the Azure portal.

The Maintenance status column shows whether any updates are pending for a maintenance configuration.

Screenshot that shows a pending status for an update.

Delete a maintenance configuration

To delete a maintenance configuration, open the configuration details and select Delete.

Screenshot that shows the button for deleting a configuration.

Next steps

To learn more, see Maintenance for virtual machines in Azure.