5

I want Windows Updates to only be installed on Saturday night between 11pm and 2am. I do not want it to install Windows updates whenever it wants to.

I have a Powershell script that uses the PSWindowsUpdate module to install all pending updates, and I have a scheduled task that runs this script at the appropriate time. Nevertheless, just now -- Tuesday morning, 1:30 AM in Amsterdam, where the server is -- it decided on its own to install a SQL Server update. This caused a brief downtime.

How can I prevent this?

[EDIT] - My server is running Windows 2012 R2.

  • The control panel options do not seem to provide any "only install every week" option. In fact the only thing that resembles a time setting whatsoever is "Automatic Maintenance: run tasks daily at [time]".

    Screenshot

    I can't tell it to only run them once a week, or to not run them at all. However, now that you've mentioned it, perhaps I should set it to "Never check for updates", knowing that my actual update script will do the checking when I wish it to.

  • Group Policy: My previous attempt at using Group Policy also was unable to limit updates to once a week on Saturday. They ran willy-nilly whenever they wanted to.

Ross Presser
  • 453
  • 6
  • 22

1 Answers1

1

Now that we know the Operating System we can give you a more precise answer.

In Windows Server 2012 R2 you can have Windows install updates during the Automatic Maintenence period, which is the behavior you're seeing now as illustrated in the following image:

enter image description here

Or you can control Windows Updates via Group Policy as in the image below. Leaving the automatic maintenance checkbox unchecked will cause Windows Updates to be installed on the schedule you configure in this Group Policy setting.

enter image description here

joeqwerty
  • 109,901
  • 6
  • 81
  • 172
  • Is that checkbox also controlled by the same group policy? – Ross Presser Feb 21 '17 at 16:02
  • 1
    I'm not sure I understand what you're asking. If you check that box in the GPO then updates will be installed during the daily Automatic Maintenance window. If you leave that box unchecked then Windows Updates will be installed on the schedule that you configure in that GPO. – joeqwerty Feb 21 '17 at 16:26
  • @joeqwerty can you provide the path to that gpo entry within the editor? – Rowan Hawkins Feb 21 '17 at 20:45