Automatic Restart of Windows Server 2012R2 after Windows Update

9,371

Off-topic: To check the group policies, you should use rsop.msc. I think what you're showing is the output of gpedit.msc.

Firstly, let's dive into the 2 points mentioned in the question:

AlwaysAutoRebootAtScheduledTime: When this registry value is set to 1, you are still notified of the upcoming automatic restart on the sign-in screen. However, at the end of the two-day period, the 15-minute counter begins even if the computer is locked. The restart also occurs even if the computer is locked.

NoAutoRebootWithLoggedOnUsers: To prevent Automatic Updates from restarting a computer while users are logged on, the administrator can create a NoAutoRebootWithLoggedOnUsers registry value.

This setting is complicated to explain in few words and so I'd suggest you to better go through the shared link. A sample comparison taken from MSDN is shared below:

enter image description here

Now, Coming to the main questions:

  1. Does AlwaysAutoRebootAtScheduledTime only work if no administrator sessions are active?

In the settings of AU shared by you, the AlwaysAutoRebootAtScheduledTime is enabled (set to 1). When this registry value is set to 1, you (any user) are still notified of the upcoming automatic restart on the sign-in screen. However, at the end of the two-day period, the 15-minute counter begins even if the computer is locked. The restart also occurs even if the computer is locked.

  1. There were some disconnected administrator sessions at the time of the update. Could this be the cause?

Here, NoAutoRebootWithLoggedOnUsers is disabled OR not configured in your server. So, please go through the shared cases of this setting not enabled as per the image shared above in the answer.

But, when you'll check the always auto reboot setting to be enabled, and then the NoAutoRebootWithLoggedOnUsers setting disabled (or not configured), both settings imply that anyway, at the maximum, after 2 days notification expiry, the system could have been expected to restart automatically even when the administrator session was disconnected (locked or signed out).

I suspect this is what might have happened*. After the administrator session disconnected (and / or other users not logged on), the system restarted automatically. At max, the setting would have restarted the server at the 2nd day of disconnect of session.

* NOTE: For exact event schedule, you need to confirm it with the event viewer logs. I hope this answers your question and solves the query.

Share:
9,371

Related videos on Youtube

jussinen
Author by

jussinen

Updated on September 18, 2022

Comments

  • jussinen
    jussinen almost 2 years

    I have a Windows Server 2012R2 which is set to have the Windows Updates Scheduled at a certain time.

    However, this week, I received a 15 minute countdown from the moment I signed in instead of straight after the Windows Update. This therefore happened during office hours which is not ideal.

    I can't see any Group Policies configured in Computer Configuration / Administrative Templates / Windows Components / Windows Update: They all show at Not Configured. enter image description here

    The registry setting AlwaysAutoRebootAtScheduledTime in HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU is set to 1 and AUOptions is set to 4. enter image description here

    There were some disconnected administrator sessions at the time of the update:

    1. Could this be the cause?
    2. Does AlwaysAutoRebootAtScheduledTime only work if no administrator sessions are active?
  • jussinen
    jussinen over 6 years
    I have AlwaysAutoRebootAtScheduledTime set to 1 and NoAutoRebootWithLoggedOnUsers to 0 which to me suggests that the server should have restarted within five minutes of the installation of the Windows Updates, which didn't happen, but instead it waited for two days and then showed the 15 minute countdown. I want the server to restart at the time of the installation and not 2 days later. Isn't this supposed to be the case with NoAutoRebootWithLoggedOnUsers set to 0?
  • jussinen
    jussinen over 6 years
    In fact looking at the article where the image is from, this applies to Windows Server Update Services, Windows Small Business Server 2011 Standard, Windows Server 2008 R2, Windows Server 2003 with SP2, Windows Server 2008 R2 with SP1. As far as I have been able to determine, the Automatic Restart process was changed in Windows Server 2012+ so I guess the above doesn't apply