Share via

Set Azure Server Reboot Window

Cathy in Maine 36 Reputation points
2025-10-24T18:52:07.1033333+00:00

Azure Server 2022 File server rebooted while users were accessing files. It was an Azure reboot and they did get a message, but had no time to save. How can I set the server to not reboot during a certain window?

Azure Virtual Machines
Azure Virtual Machines

An Azure service that is used to provision Windows and Linux virtual machines.

0 comments No comments

Answer accepted by question author

Hemalatha 14,525 Reputation points Microsoft External Staff Moderator
2025-10-24T20:28:16.1566667+00:00

Hi Cathy in Maine,

Thanks for reaching out Q/A. To control Azure-initiated reboots and avoid downtime during working hours, please review the following recommendations:

  1. Use Azure Update Manager or Maintenance Configurations:

Azure allows you to define maintenance windows, so updates and reboots happen outside of critical usage times.

  • In the Azure Portal, go to Update Manager >> Machines >> Schedule updates.
  • Create a maintenance configuration with (A time window outside business hours and Reboot settings: Never reboot or Reboot if required)

Reference: https://learn.microsoft.com/en-us/azure/update-manager/configure-wu-agent

2.You’ll need to configure your VM's Windows Update settings. You can set "ActiveHoursStart" and "ActiveHoursEnd" in the Windows Registry to specify the time window in which reboots should not occur.

Adjust the following registry entries:

HKLM\Software\Policies\Microsoft\Windows\WindowsUpdate

ActiveHoursStart and ActiveHoursEnd: Define the start and end of your active hours.

SetActiveHours: Set this to 1 to enable active hours.

HKLM\Software\Policies\Microsoft\Windows\WindowsUpdate\AU

NoAutoRebootWithLoggedOnUsers: Set to 1 to prevent reboots when users are logged in.

  1. Azure may perform planned maintenance which could require a reboot. You can check the Scheduled Maintenance Notifications and be informed in advance of any scheduled maintenance that affects your VM.

In some cases, Azure performs host-level (platform) maintenance that can restart your VM. While it is not possible to completely prevent these updates, you can control their timing if your VM type supports Maintenance Control.

To configure Maintenance Control:

  1. Navigate to Azure Portal >> Maintenance configurations >> Create configuration.
  2. Select the scope (Host).
  3. Assign supported resources, such as Dedicated Hosts, Isolated VMs, or supported VM scale sets.
  4. Define your preferred maintenance window for Azure to apply updates.

Reference: https://learn.microsoft.com/en-us/azure/virtual-machines/maintenance-configurations

If your VM does not appear in the Select resources list, it is likely running on shared infrastructure, which does not support Maintenance Control. In such cases, you will still receive advance Scheduled Maintenance Notifications in the Azure Portal whenever host maintenance is planned.

Please let me know if you have any questions or need further assistance

Was this answer helpful?

1 person found this answer helpful.

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.