Windows update _only_ once a week

windows-update

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.

Best Answer

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

Related Topic