Configure auto-restart reminder notifications for updates
Configurer le redémarrage automatique des notifications de rappel pour les mises à jour
Explanation
Enable this policy to specify when auto-restart reminders are displayed.
You can specify the amount of time prior to a scheduled restart to notify the user.
If you disable or do not configure this policy, the default period will be used.
Activez cette stratégie pour spécifier le moment où les rappels de redémarrage automatique doivent s'afficher.
Vous pouvez spécifier la durée avant un redémarrage planifié pour avertir l’utilisateur.
Si vous désactivez cette stratégie ou si vous ne la configurez pas, la période par défaut est utilisée.
Registry
HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\WindowsUpdate- Value name
SetAutoRestartNotificationConfig
| State | Value written |
|---|---|
| Enabled | REG_DWORD = 1 |
| Disabled | REG_DWORD = 0 |
PowerShell
PowerShell commands that write to the registry what the policy would write. Values in angle brackets (<…>) must be replaced.
Writing directly to the registry bypasses Group Policy: if a GPO manages this value, it will be rewritten at the next gpupdate; otherwise the value stays in place (the "tattooing" effect). Prefer a GPO or, locally, LGPO.exe. Run PowerShell as administrator for HKLM. Some policies need a restart or gpupdate /force.
Enable
# Enable: WindowsUpdate/AutoRestartNotificationConfig
$k = 'HKLM:\Software\Policies\Microsoft\Windows\WindowsUpdate'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
Set-ItemProperty -Path $k -Name 'SetAutoRestartNotificationConfig' -Value 1 -Type DWord
# Period (min)
# Possible options:
# 15 = 15
# 30 = 30
# 60 = 60
# 120 = 120
# 240 = 240
Set-ItemProperty -Path $k -Name 'AutoRestartNotificationSchedule' -Value 15 -Type DWordDisable
# Disable: WindowsUpdate/AutoRestartNotificationConfig
$k = 'HKLM:\Software\Policies\Microsoft\Windows\WindowsUpdate'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
Set-ItemProperty -Path $k -Name 'SetAutoRestartNotificationConfig' -Value 0 -Type DWordRevert to "Not configured"
# Revert to "Not configured": WindowsUpdate/AutoRestartNotificationConfig
$k = 'HKLM:\Software\Policies\Microsoft\Windows\WindowsUpdate'
Remove-ItemProperty -Path $k -Name 'SetAutoRestartNotificationConfig' -ErrorAction SilentlyContinue
Remove-ItemProperty -Path $k -Name 'AutoRestartNotificationSchedule' -ErrorAction SilentlyContinueOptions (1)
| Label | Control | Registry value | REG type | Constraints / details | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Period (min):Période (min) :AutoRestartNotificationSchd | Drop-down listenum | AutoRestartNotificationSchedule | REG_DWORD | Required · Default choice (UI): #0
|