Microsoft has disabled the automatic system registry backup task starting with Windows 10 1803. In previous Windows versions, the Automatic Maintenance job ran a scheduler task that copied all the registry hives in the \Windows\System32\config\RegBack
folder.
You can still enable automatic registry backups in modern Windows 10 and 11 builds. Just create the EnablePeriodicBackup registry parameter (REG_DWORD) with a value of 1 in the HKLM\System\CurrentControlSet\Control\Session Manager\Configuration Manager
reg key. You can create this registry option manually or by using a PowerShell command:
New-ItemProperty -Path "HKLM:\System\CurrentControlSet\Control\Session Manager\Configuration Manager" -Name EnablePeriodicBackup -Type DWORD -Value 1
Then restart the computer.
The automatic registry backup will be started as part of the automatic system maintenance by calling the RegIdleBackup scheduler task. To run this task manually, open taskschd.msc
and run the RegIdleBackup task in the Microsoft\Windows\Registry folder.
Or you can manually start the Automatic Maintenance in Windows with the command
MSchedExe.exe Start
Among other things, this runs the RegIdleBackup task. The task copies the system registry files (DEFAULT, SAM, SECURITY, SOFTWARE, and SYSTEM) from the %windir%\System32\config
to the %windir%\System32\config\RegBack
folder.
Check the task execution status:
Get-ScheduledTask regidlebackup | Get-ScheduledTaskInfo
Now, if Windows does not boot properly and none of the standard recovery methods work (including boot to the last known good configuration and rollback to a previous restore point), you can try replacing the registry files with the versions from the backup. To do this, boot into the WinRE recovery environment, open a command prompt, and run:
xcopy c:\Windows\System32\config\regback c:\Windows\System32\config
In a domain environment, it is possible to enable automatic registry backup on all computers by using a Group Policy that creates a registry parameter with the name EnablePeriodicBackup and the value 1.