How to prevent Windows 10 from restarting the computer after installing updates

79

50

This questions has been answered previously, e.g. here, but all the answers I've seen require using a dropdown in Settings> Update & Security> Advanced Options.

On my version of Windows 10 Pro, there is no such dropdown:

Windows update advanced options

How can I prevent automatic restarts?

Laurent

Posted 2016-08-05T15:46:16.720

Reputation: 1 059

1Windows 10 version 1607 (OS build 14393.10) – Laurent – 2016-08-06T00:48:01.890

You can also set your activity information. So Windows will only install updates, during those times, you are not active. – Ramhound – 2016-08-08T14:36:57.577

19Yes but the problem with setting the "active" hours is that if I forget to close Excel and leave it open overnight, Windows might reboot during the night, causing me to lose unsaved data. Also, the maximum active timespan is 12 hours, which assumes everybody sleeps at least 12 hours a day... – Laurent – 2016-08-08T23:06:58.977

1

@Laurent, when the Creators Update is released next month, one of the changes will increase the maximum Active Hours setting you can configure to 18 hours. Hopefully, you are typically getting at least six hours of sleep!

– Run5k – 2017-03-08T21:12:17.280

1This is just one of the many things that Windows does that slows us down and gets in the way of our work. Although we still use Windows a little here in our business (mostly in WINE or VirtualBox), we've switched to Linux (RHEL, LM MATE 18.1, and Xubuntu 16.04). Linux updates don't slow us down, and there's seldom a need to reboot. – Mike Waters – 2017-03-08T21:59:16.257

3

Possible duplicate of How to stop Windows 10 from automatic restarts

– Tomas – 2018-07-23T13:17:30.287

@Tomas, this thread is a far better one than the other. I've voted to make the other a dupe of this one. – fixer1234 – 2018-07-26T20:55:38.200

The older question cannot be a duplicate, because it is older. It is the original one. – Tomas – 2018-07-28T17:02:13.633

@Tomas, age isn't the determining factor unless there are two threads that are equally good. If one thread has more and better solutions, or the question is applicable to a wider audience, or is otherwise a better canonical reference, it is better to make that one the one others are linked to. That's a more effective way to help people find the most potential solutions. – fixer1234 – 2018-07-28T19:50:50.673

Answers

5

The two other solutions don't seem to be working for me as those registry settings were already set on my computer.

Here is an indirect solution, which is to tell Windows Update not to install updates automatically, just download them, and then prompt for installation. The user can then choose when to install them, and restart then.

Go to the following Registry key: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update
Set the AUOptions value to one of the following values:

1 = Never check for updates
2 = Check for updates but let me choose whether to download and install them
3 = Download updates but let me choose whether to install them
4 = Install updates automatically

I set it to 3.

Source: Microsoft Technet Forums: How to stop Windows 10 from automatically restarting, answer by MaxBak83

Laurent

Posted 2016-08-05T15:46:16.720

Reputation: 1 059

yes, I use this tool to manually search for Updates: http://superuser.com/a/948069/174557

– magicandre1981 – 2016-08-08T14:46:03.903

4Nope, this doesn't work either. My Windows 10 Pro (with this setting set to 2, (after I deleted the Windows/SoftwareDistribution folder, actually downloaded updates, installed them, and then rebooted, in the middle of my office hours, on Wednesday, 13PM, with several apps open, including an unsaved Word document. Then it proceeded installing the "Aniversary edition" for the next 30 minutes, failed, and then restored my previous version automatically. Cool, now I can wait for the next attempt. Must remember to save anytime I go get grab a cup of coffee. – Groo – 2016-09-28T13:08:33.000

1It did work for me; now I receive a message saying Restart required and then a more ominous We will restart your device outside office hours. But it doesn't restart by itself. There is a button to Restart now. – jmgonet – 2016-10-01T05:28:23.687

1Does not work. (Windows 10 Version 1607 Build 14393.187) – user643011 – 2016-10-03T02:28:27.093

isn't it HKLM\SOFTWARE\ Policies \Microsoft...? Also, this seems to confirm my comment that you have to activate both policies "Configure Automatic Updates" and "No auto-restart with logged on users for scheduled automatic updates installations"

– Tobias Kienzler – 2017-01-04T20:29:37.790

89

Setting the "No auto-restart with logged on users for scheduled automatic updates installations" GPO didn't work for me. I woke up this morning and my machine had been rebooted. (I was using the computer last night and didn't even get a warning.)

This suggestion from techjourney.net looks more promising.

  • Open Task Scheduler and navigate to Task Scheduler Library > Microsoft > Windows > UpdateOrchestrator
  • Right click the Reboot task and Disable it.

Windows will attempt to re-enable the task automatically, so you also need to modify permissions on the task file.

  • Go to C:\Windows\System32\Tasks\Microsoft\Windows\UpdateOrchestrator
  • Open the properties of the Reboot file, open the Security tab and open Advanced Permissions.
  • Take ownership of the file by clicking the "Change" link next to the owner and typing in your name. Disable inheritance via the button at the bottom.

  • Change all permissions to read or read & execute only.

JaredE

Posted 2016-08-05T15:46:16.720

Reputation: 999

3You should also set the group policy "Enabling Windows UPM to automatically wake up the system to install scheduled updates" to DISABLED. If you don't, Windows will sometimes start your computer when it's off (hibernating), install updates, and turn off again, causing you to lose your hibernation state. This causes you to lose all of your open windows, which is a huge pain. – Steve – 2016-10-18T22:12:29.287

Looks like advanced security settings have been disabled in the latest Win 10 Pro 64 bit – veryRandomMe – 2016-10-19T02:10:06.023

1Beware that the task must be disabled first, then the file permissions set. If you do the file permissions first, the task may give an error when trying to set the state to disabled. – Mike Simpson – 2016-11-15T02:58:38.330

7As far as I can tell, this no longer works. Windows now ignores the permissions on the file and switches "reboot" back to enabled. I do not think there is currently a way to stop Windows from restarting itself, which is absolutely ridiculous. – dallin – 2016-11-17T01:56:05.677

1I also had to do this process for the "C:\Windows\System32\Tasks\Microsoft\Windows\rempl" folder for the auto-restarts to be blocked (disabling the tasks in task-scheduler, then removing all write permissions). At least, I think they are now since it's past the scheduled time now and hasn't restarted. We'll see if MS creates yet another task trying to get past our blocks... -_- – Venryx – 2018-04-20T10:06:18.157

2Not working, no permission to disable the reboot task, even for admin! I get this message: "The user account you are operating under does not have permission to disable this task" – Tomas – 2018-07-23T13:35:47.810

This used to work for me, but May 2019 update rebooted my PC even though I had this hack in place. :-( Maybe Reboot_AC and Reboot_Battery have to be hacked the same way, now. – Palec – 2019-07-15T05:35:56.380

9

All the suggested hacks workarounds seems not to work with the anniversary update. But there is still an option: You can periodically update the "active hours" in the settings. However, this is no fun to do manually, but there is a small windows service that can do it for you: https://www.udse.de/en/windows-10-reboot-blocker

audioxp

Posted 2016-08-05T15:46:16.720

Reputation: 91

The accepted answer seems to still work for me... As the updates don't install automatically, it doesn't reboot. However if I do click to install the updates, it will reboot later without asking, so I make sure to reboot right after manually installing the updates. – Laurent – 2016-12-04T06:11:52.577

3This is ridiculous! I can't believe we need to install this to "fix" something that shouldn't have been "broken" in the first place! So much for being a "pro" version.... – tftd – 2016-12-26T21:25:44.070

1

For those who prefer to review the code before running it, there's also a PowerShell version by someone else on Github.

– Peter Taylor – 2018-12-21T08:31:10.383

8

Edit:

Microsoft are going to release a way to snooze updates. The Verge - Microsoft is making it easy to stop Windows 10 rebooting your PC randomly for updates

I'm not sure if the settings app allows you to do this anymore. I have had a look but I cannot find anything. This solution below will work regardless if you have Windows 10 Pro.

In the run dialog box (winkey + R) type "gpedit.msc" (without quotations), hit enter Navigate to Computer Configuration/Administrative Templates/Windows Components/Windows Update Double click on "No auto-restart with logged on users for scheduled automatic updates installations" Enable it and click apply

Ref: Windows 10: Disable automatic reboot for updates

Gpedit

mt025

Posted 2016-08-05T15:46:16.720

Reputation: 2 392

7gpedit is only for Pro and higher versions, Home or lower does not have gpedit – Moab – 2016-08-05T18:22:39.393

2I have Pro so I was able to do this. But it was already enabled (I enabled it a long time ago when I was still on Windows 8). Last night it rebooted again even with this setting enabled. – Laurent – 2016-08-06T00:49:22.693

21This doesn't work. I have this enabled, but it still reboots. The most annoying thing is that it reboots during the week, during office hours, while many apps are open, and just forcefully closes them and I lose my work. Every single time. I've been using Windows since 3.1 and didn't mind any of their dubious UI decisions, including the 8 Modern UI. But just let me do my damn job without interruptions. Ironically, they name it Windows 10 "Pro". – Groo – 2016-09-28T12:48:56.157

1Does not work. (Windows 10 Version 1607 Build 14393.187) – user643011 – 2016-10-03T02:28:40.943

2Did anyone read that option's last paragraph "this does not work if the policy Configure Automatic Updates is not active"? I guess (but could not yet verify) this only works if one also activates said policy as well. – Tobias Kienzler – 2017-01-04T20:26:14.090

@TobiasKienzler, I have enabled that policy too, and this policy still doesn't prevent reboot (v1607 build 14393.693). – Vanav – 2017-03-07T19:44:48.373

@Vanav And did you choose one of options 2/3, i.e. one where installation does not happen automatically? – Tobias Kienzler – 2017-03-08T06:58:11.507

Your first link (The Verge) is broken due to misspelling. – Evgeni Nabokov – 2018-03-14T19:41:58.863

1

Winaero.com has provided a way to do it:

  • Open Registry Editor.
  • Go to the following Registry key: HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU
  • Create a new DWORD value here named NoAutoRebootWithLoggedOnUsers and set it to 1 and reboot the device.

enter image description here

magicandre1981

Posted 2016-08-05T15:46:16.720

Reputation: 86 560

1I just went there in regedit and on my PC that key was already set to 1. – Laurent – 2016-08-08T14:07:15.263

My computer doesn't have WindowsUpdate – Richard – 2016-08-23T16:39:49.810

@Richard create a key with that name if you can't find it – magicandre1981 – 2016-08-24T04:39:58.837

3Does not work. (Windows 10 Version 1607 Build 14393.187) – user643011 – 2016-10-03T02:28:14.277

Continuing in the trend of tech blogs not doing proper research and not cross-checking their answers thoroughly enough, the guide doesn't list bitness information properly. The key you posted is only applicable to 32-bit machines. I've added the information for 64-bit machines as well. – seagull – 2016-10-07T18:13:50.913

1

Here's a .zip containing a .reg file which SHOULD work even in Windows 10 (though I won't know for sure until the next time M$ pushes a Win10 update which requires rebooting):

http://www.geeksalive.com/NoAutoReboot_Win10.zip

Here's the contents of the NoAutoReboot.reg file, but be sure to read the 00ReadMe.txt, too.

REGEDIT4

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update]
"NoAutoRebootWithLoggedOnUsers"=dword:00000001

[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU]
"NoAutoRebootWithLoggedOnUsers"=dword:00000001
"NoAutoUpdate"=dword:00000000
"AUOptions"=dword:00000004
"AutomaticMaintenanceEnabled"=dword:00000001
"ScheduledInstallDay"=dword:00000000
"ScheduledInstallTime"=dword:00000003
"AllowMUUpdateService"=dword:00000001

Note that for this to be effective you'll need to either restart the Windows Update Service, or just reboot the computer, after installing the registry update.

Dave Burton

Posted 2016-08-05T15:46:16.720

Reputation: 261

0

For computers with Group Policy, applying the policy User Configuration\Administrative Templates\Windows Components\Windows Update\Remove access to use all Windows Update features with the option Do not show any notifications will completely prevent forced reboots. Windows update on Windows 10 will still remain fully functional.

The registry entries for this policy is HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\WindowsUpdate Create the keys: DisableWindowsUpdateAccess with value 1 DisableWindowsUpdateAccessMode with value 0

This will prevent the task scheduler task in the JaredE's answer from forcing a reboot as well. Even manually running this task will not cause a reboot.

ayao1337

Posted 2016-08-05T15:46:16.720

Reputation: 478

-1

Possible answer, still testing but seems to be working until MS changes these settings in the Task Scheduler.

On another post, "How to disable automatic reboots in Windows 10?", jakethedog references using the Task Scheduler. I expanded on the settings per items in the UpdateOchestrator.

Goto Start and enter Task Scheduler. Goto Task Scheduler Library >> Microsoft >> Windows >> UpdateOrchestrator.

Here you will find items that can be adjusted to cause Updates to behave differently. You can change different properties in each item by right clicking and selecting Properties.

You should see six tabs. Most have parameters that can be set, disabled, or deleted. Use the History tab on each item to see when and what these are processing. Then per tab make the desired changes.

So far, I've only Disabled and not Deleted any parameters. MS may re-add a deleted parameter when the update scans run, whether manually or automatically and replace missing items.

On each item I've adjusted, I've changed the following tabs.

General Tab >> Security options. Changed the user account controlling the item from System to my account. This should help the system account stop overriding changes.

Triggers >> Edit >> Advanced settings. Begin the task: On a schedule. Set Delay task for up to (random delay): to 1 day. Set Stop task if it runs longer than: 30 Minutes. Set Expire: the day you make a change to the item, 15 minutes later than when the change is made and to Sync across time zones. Unchecked Enable.

Actions >> Edit. Rename the Program/script entry. Here, I just changed MusNotification.exe to MNcation.exe and removed the Add arguments option of Reboot. This may be adding to the Event Viewer, I've not checked to see.

Conditions >> Power. Uncheck both entries.

Settings. Set to the following.

enter image description here

Then select OK to close the Properties window and then Right click and Disable the item per item you adjust. Then reboot.

AndyA

Posted 2016-08-05T15:46:16.720

Reputation: 1

1

You should edit this answer after you have verified it is an actual answer. Review. Why are you submitting identical answers to questions instead of flagging one of the questions as a duplicate?

– Ramhound – 2016-12-15T19:53:04.503