Change the planned maintenance time for Azure SQL and MI

Change the planned maintenance time for Azure SQL and MI

As you’re aware one of the adventures of PaaS is the user doesn’t need to do anything for maintenance. Cloud service provider in our case Azure will do all patching and maintenance for you!

Planned maintenance event keeps Azure SQL Database and Azure SQL Managed Instance services secure, compliant, stable, and performant as also here mentions Maintenance event can produce single or multiple reconfigurations, depending on the constellation of the primary and secondary replicas at the beginning of the maintenance event. On average, 1.7 reconfigurations occur per planned maintenance event.

By default, Azure SQL maintenance policy blocks most impactful updates during the period 8AM to 5PM local time every day to avoid any disruptions during typical peak business hours.

The question is can we change the planned maintenance time for Azure SQL Database and Managed Instance?

The maintenance window feature allows you to configure maintenance schedule for Azure SQL Database and Azure SQL Managed Instance resources making impactful maintenance events predictable and less disruptive for your workload.

By default, Azure SQL maintenance policy blocks most impactful updates during the period 8AM to 5PM local time every day to avoid any disruptions during typical peak business hours.

You can further adjust the maintenance updates to a time suitable to your Azure SQL resources by choosing from two additional maintenance window slots:

· Weekday window: 10:00 PM to 6:00 AM local time, Monday - Thursday

· Weekend window: 10:00 PM to 6:00 AM local time, Friday – Sunday

Maintenance window days listed indicate the starting day of each eight-hour maintenance window. For example, "10:00 PM to 6:00 AM local time, Monday – Thursday" means that the maintenance windows start at 10:00 PM local time on each day (Monday through Thursday) and complete at 6:00 AM local time the following day (Tuesday through Friday).

Once the maintenance window selection is made and service configuration completed, planned maintenance will occur only during the window of your choice. While maintenance events typically complete within a single window, some of them may span two or more adjacent windows.

you’re not able to customize the timing however the System default maintenance window is 5PM to 8AM daily (local time of the Azure region the resource is located) to avoid peak business hours interruptions. If the System default maintenance window is not the best time, select one of the other available maintenance windows.

Be aware based on the referral link Maintenance Window - Azure SQL Database | Microsoft Learn

As it explains choosing a maintenance window other than the default is available on all SLOs except for:

· Instance pools

· Legacy Gen4 vCore

· Basic, S0 and S1

· DC, Fsv2, M-series

Change available maintenance windows for Azure SQL Database or Managed Instance.

Go to database page in Azure Portal and from the left blade search for “Maintenance” and from “Maintenance windows” choose one of the time which works for you.

Change the planned maintenance time for Azure SQL and MI