Registry Backups

  1. Posts : 190
    Windows 10, 22H2 10.0.19045

    Registry Backups

    Based on a lot of Googling and information from this forum I created the below batch file to backup my Windows 10 registry from an elevated cmd prompt. Everything is working perfectly but I have a question on what I'm backing up. Are there other registry hives/locations that I should include?

    set curr_date=%DATE:~10,4%-%DATE:~4,2%-%DATE:~7,2%
    echo %curr_date%"

    mkdir "D:\Registry Backups\Backup %curr_date%"

    REG SAVE HKLM\Software "D:\Registry Backups\Backup %curr_date%\SOFTWARE"
    REG SAVE HKLM\Security "D:\Registry Backups\Backup %curr_date%\SECURITY"
    REG SAVE HKLM\System "D:\Registry Backups\Backup %curr_date%\SYSTEM"
    REG SAVE HKU\.Default "D:\Registry Backups\Backup %curr_date%\DEFAULT"
    REG SAVE HKLM\SAM "D:\Registry Backups\Backup %curr_date%\SAM"
    REG SAVE HKCU "D:\Registry Backups\Backup %curr_date%\NTUSER.DAT"
    REG SAVE HKCU\Software\Classes "D:\Registry Backups\Backup %curr_date%\USRCLASS.DAT"
    REG SAVE HKLM\BCD00000000 "D:\Registry Backups\Backup %curr_date%\BCD"
      My Computer

  2. Posts : 42,467
    Win 10 Pro (22H2) (2nd PC is 22H2)

    Hi, backing up the registry is at best of very very limited value. Restoring the registry alone is likely to lead to inconsistencies with files on your system.

    If you want a regular registry backup then there are two ways I'd suggest of doing it.
    a. Re-enable an existing feature built into Windows.
    Enable Automatic Backup of System Registry when Restart in Windows 10

    Note the introductory text is misleading- read on to Starting in Windows 10 version 1803, to see why.

    But you can re-enable that feature.

    b. Use a 3rd party registry backup utility (free).

    Finally, you can set System Restore to create a restore point (which includes the registry) on a daily schedule if you like. Tutorial available.

    No need at all to reinvent the wheel.
      My Computers

  3. Posts : 190
    Windows 10, 22H2 10.0.19045
    Thread Starter

    @dalchina Thanks for the reply. I think building that batch file was more of a way to fill some time than anything else. I put it together after trying the Acelogix software which hasn't been updated since mid 2015 and searching the forums where the latest version of their registry backup software has reported issues going back to mid 2020. Don't know if these issues impact the actual backup or if the issues are cosmetic. Either way I passed on both.

    And, I use Macrium Reflect to do a full image backup every Sunday, and differential backups all days in between. So I'm covered.
    Last edited by Homer712; 07 Mar 2021 at 15:38.
      My Computer

  4. Posts : 16,560
    Windows 10 Home x64 Version 22H2 Build 19045.3930

    I agree with dalchina that Registry backups are of limited use. I back mine up within my weekly-ish full backups routines.

    1 I export each section to a .reg file [HKLM, HKCU, HKCR, HKU, HKCC] using Reg Export commands.
    - This gives me a running set of readable files for use in investigating Registry changes that I might become interested in.

    2 I save the major hives [HKLM - SAM, SECURITY, SOFTWARE, SYSTEM; HKU - .DEFAULT; HKCU] using Reg Save commands.
    - This could be useful in manually creating a 'restore to last known good configuration'.
    - I would have to boot from my InstallUSB then use its command prompt to copy the files back into place.
    - MS recommend using a Restore point instead.
    - I think I would always choose to restore my last system image instead.

    3 I always use the same user account when backing up the Registry. So I take the opportunity of backing up the C:\Users\....\ntuser.dat files [which are their HKCU sections] for the other user accounts.
    - They can be loaded and examined by RegEdit - my example of using an offline Registry hive in RegEdit - TenForums

    I put this together a couple of years ago after there had been lots of discussions in TenForums on the subject.
    - I do not believe that I will ever use any of these backups in anger. If anything, I might one day use the #1 backup to investigate strange behaviour.
    - My batch file drafting notes include, "review the hives nobody seems to bother with - BCD-Template, COMPONENTS, DRIVERS, ELAM, BBI" but I have not progressed that at all.

    The system registry is no longer backed up to the RegBack folder - KB4509719
    Microsoft explains the lack of Registry backups - TenForums
    Microsoft explains the lack of Registry backups - gHacks Tech News
    Enable Automatic Backup of System Registry to RegBack folder - TenForumsTutorials
    batch script Enable Automatic Backs up of System Registry - TenForums
    Backup Registry Hives - TenForums

    my consolidated ditty about new Regbackup routines - TenForums
    My Registry backup plan - TenForums
    my list of general Registry guides [post #10] - TenForums
    my ditty on backing up and restoring Registry entries using a reg file [post #37] - TenForums

    All the best,

    By the way, by misspelling the username you thanked a user called del instead of dalchina.
    Last edited by Try3; 07 Mar 2021 at 16:03.
      My Computer

  5. Posts : 190
    Windows 10, 22H2 10.0.19045
    Thread Starter

    @Try3 Thanks, and the original "Thanks" has been corrected. You provided a lot of interesting reading.
      My Computer

  6. Posts : 16,560
    Windows 10 Home x64 Version 22H2 Build 19045.3930

    Homer712 said:
    @Try3 Thanks, and the original "Thanks" has been corrected. You provided a lot of interesting reading.
    And I have just added another link to the list.
    Backup Registry Hives - TenForums

    And I've added HKCU to my group #2 Reg Save list. I have no idea why I left it out in the first place. I might as well have another bit in my never-to-be-used backups. The whole set of Reg Export & Reg Save outputs zip up to only 100MB each time.

    Last edited by Try3; 07 Mar 2021 at 16:16.
      My Computer

  7. Posts : 6,660
    22H2 64 Bit Pro

    Just to add that I've restored registry from backup after some tweak resulted in minute (tiny) system tray icons. I couldn't undo the tweak so restored registry in seconds.
    Reason for lots of tweaking today: Just clean installed 20H2.

    Registry Backups-hdcleaner-version_-64-bit-.jpg
      My Computer


  Related Discussions
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 05:03.
Find Us

Windows 10 Forums