24

I like Windows to keep itself up to date via the automatic updates, but sometimes it does that when I'm not at the computer and it's doing something critical, like downloading the latest stack overflow podcast.

How do I prevent Windows from doing the automatic reboot if I'm not there?

17

The comment by Johannes Rössel to the answer InSciTek Jeff is quite a valid point. The use of group policy settings he mentioned was actually blogged about by Jeff Atwood a long time ago. The synopsis goes like this:

Press Windows+r and run gpedit.msc, you should get a window like this:

gpedit.msc

Now, Windows 7 has changed the order and added a couple of newer options I've italicized:

  1. Do not display 'Install Updates and Shut Down' in Shut Down Windows dialog box
  2. Do not adjust default option to 'Install Updates and Shut Down' in Shut Down Windows dialog box
  3. Enabling Windows Power Management to automatically wake up the system to install scheduled updates
  4. Configure Automatic Updates
  5. Specify intranet Microsoft update service location
  6. Automatic Updates detection frequency
  7. Allow non-administrators to receive update notifications
  8. Turn on Software Notifications
  9. Allow Automatic Updates immediate installation
  10. Turn on recommended updates via Automatic Updates
  11. No auto-restart with logged-on users for scheduled Automatic Updates
  12. Re-prompt for restart with scheduled installations.
  13. Delay Restart for scheduled installations
  14. Reschedule Automatic Updates scheduled installations
  15. Enable Client Side targeting
  16. Allow signed updates from an intranet Microsoft update service

Personally I chose to enable 9, 11, 12, and 13. 9 enables only those updates that do not have to restart Windows nor stop a service. Enabling 11 actually disables the auto-restart, if and only if there is at least one logged user. 12 and 13 were enabled and set to their max values with the scroll wheel. 16 sounds good but won't affect users lacking their own update server. I took this from my own question.

Addendum

It's been pointed out that Home editions of Windows don't come with gpedit.msc, and you must therefore set things directly in the registry. There's probably more settings you could add besides NoAutoRebootWithLoggedOnUsers ... In fact I'm going to check that now. Okay in HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU add:

  • AutoInstallMinorUpdates = 1
  • NoRebootWithLoggedOnUsers = 1
  • RebootRelaunchTimeout = 1440 (decimal)
  • RebootRelaunchTimeoutEnabled = 1 [I'm actually curious if that's what I wanted]
  • RebootWarningTimeout = 30 (decimal)
  • RebootWarningTimeoutEnabled = 1 [I think the above four don't happen due to #2]
8
  1. Right click on the "Computer" icon on the desktop and select "Properties..."
  2. Click on "Windows Update" and then select "Change Settings"
  3. Now select "Download updates but let me choose whether to install them"
  4. Finally, click "Apply" button.

In this mode of operation, Windows checks for new updates and downloads them, but won't apply them and reboot until you tell it. In the interim, it will remind you that you have new updated available via the system tray icon.

  • 4
    This unfortunately has the nasty side-effect of preventing updates from installing that don't need a reboot, such as signature updates for Windows Defender or updates for Office, VS, etc. I recently read about a method that involved using group policies to prevent automatic restarts and you'd then set automatic updates to automatically install. So updates will be installed and reboot-needing ones will only take effect on reboot. Best of both worlds, I'd say. I just can't remember right now where I read it :/ – Joey Jul 16 '09 at 2:16
  • Oh interesting. Please let us know if you get that info. – Stevo Jul 16 '09 at 6:09
  • In Windows 7 (and Vista I think) you get a notification asking you to restart now, ask again in 10 minutes, 1 hour or 4 hours I think. It's only one click and you probably won't get bothered. I never noticed it automatically rebooting :-S – Ivo Flipse Jul 16 '09 at 7:30
1

start->run->cmd ...

net stop "Automatic Updates"

That will turn off the service. It won't download or updates until you turn it back on tho. that's also handy for getting rid of the "hey do you want to restart" notices over and over again.

  • You should mention that this will keep you from automatically downloading important security updates too. – Sampson Jul 16 '09 at 1:52
  • I don't think you're answering the question that was asked. You're stopping Automatic Updates from running. The question is looking for ways to prevent it from rebooting. Congratulations... you just swatted a fly with a sledgehammer – Jeff Fritz Jul 16 '09 at 1:53
  • Thanks, but yeah I do still want it to download. – Stevo Jul 16 '09 at 1:58
1

Install Vista or Windows 7? Has only happend to me in XP if I remember correctly... In vista at least you get a nice question asking you if you want to or if you would like to postpone it a few hours, upon which it will ask again. Or you can just leave the message open.

  • It happened to me in Vista :-\ I was away from the computer so didn't get chance to delay it. – Stevo Jul 16 '09 at 1:58
1

On Windows 7 and 8(.1) the following works (put in .reg file and run):

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU]
"NoAutoRebootWithLoggedOnUsers"=dword:00000001

For Windows 10, see How to *disable* automatic reboots in Windows 10?

0

After a shutdown has been initiated, you can stop it by running a shutdown -a command

Win+R   
shutdown -a
0

Once you get the scheduled restart message after update you can disable it as follows:

  1. Open Control Panel

  2. Go to Control Panel\System and Security\Administrative Tools. Click the Task Scheduler icon.

  3. In Task Scheduler, open the following folder Task Scheduler Library \ Microsoft \ Windows \ UpdateOrchestrator.

  4. There you will see a task called "Reboot". Disable it using the appropriate command in the right click menu

  5. Open this folder in File Explorer: %systemroot%\System32\Tasks\Microsoft\Windows\UpdateOrchestrator

  6. Rename the file name Reboot without an extension to Reboot.bak

  7. Create an empty folder here instead and name it Reboot

This will prevent Windows 10 from re-creating the Reboot task and restarting the computer whenever it wants.

Reference: Sergey Tkachenko This is the only what that worked with me after searching for other different alternatives like editing Group Policy that didn't work for Windows 10

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.