Windows 7 Forums
Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.


Windows 7: Registry - Backup and Restore


20 Feb 2009   #19
Brink
Microsoft MVP

64-bit Windows 8.1 Enterprise
 
 
Registry - Backup and Restore

How to Backup and Restore the Registry in Windows 7 and Vista

...


My System SpecsSystem Spec
30 Jan 2012   #20
Infinite

Windows 7 Ultimate SP1 - 64 Bit
 
 

The Registry worked perfectly.


My System SpecsSystem Spec
30 Jan 2012   #21
Brink
Microsoft MVP

64-bit Windows 8.1 Enterprise
 
 

You're welcome.
My System SpecsSystem Spec
19 Nov 2012   #22
Injust

Windows 7 Home Premium 64-bit SP1
 
 

Something the ERUNT readme file says:
"Note: The "Export registry" function in Regedit is USELESS (!) for making a complete backup of the registry. Neither does it export the whole registry (for example, no information from the "SECURITY" hive is saved), nor can the exported file be used later to replace the current registry with the old one. Instead, if you re-import the file, it is merged with the current registry without deleting anything that has been added since the export, leaving you with an absolute mess of old and new entries."
My System SpecsSystem Spec
19 Nov 2012   #23
Brink
Microsoft MVP

64-bit Windows 8.1 Enterprise
 
 

Quote   Quote: Originally Posted by Injust View Post
Something the ERUNT readme file says:
"Note: The "Export registry" function in Regedit is USELESS (!) for making a complete backup of the registry. Neither does it export the whole registry (for example, no information from the "SECURITY" hive is saved), nor can the exported file be used later to replace the current registry with the old one. Instead, if you re-import the file, it is merged with the current registry without deleting anything that has been added since the export, leaving you with an absolute mess of old and new entries."
Hello Injust,

I agree with that for the complete registry. That's one of the main reasons why I recommended using System Restore for the complete registry instead.

Of course, nothing can beat creating a system image.
My System SpecsSystem Spec
.


19 Nov 2012   #24
Injust

Windows 7 Home Premium 64-bit SP1
 
 

Yup, but many members here have recommended me to export the registry instead of creating an image or using a third-part tool like ERUNT
My System SpecsSystem Spec
19 Nov 2012   #25
Brink
Microsoft MVP

64-bit Windows 8.1 Enterprise
 
 

Ooof, that's not good. Exporting parts of the registry is fine, but not the whole thing.
My System SpecsSystem Spec
21 Nov 2012   #26
Neophile

Windows 7 Ultimate 64-bit SP1
 
 

Hello,
How would be the command to backup a sub-key like at command prompt to use in a batch file or other simple script, please?
My System SpecsSystem Spec
21 Nov 2012   #27
Brink
Microsoft MVP

64-bit Windows 8.1 Enterprise
 
 

Hello Neophile,

You can type reg export /? in a command prompt and press Enter to get more details about it like below.



For example, if you want to export the Software registry key below, ....
HKEY_CURRENT_USER\Software
.... you would type this into the command prompt below to export it with any filename.reg you like. The Y switch is to copy over if that filename already exists.
REG Export "HKCU\Software" filename.reg /Y
It will export the filename.reg file to wherever you have the command prompt open to. In my screenshot below, this would into the C:\Users\Brink folder.

Registry - Backup and Restore-reg.jpg

Hope this helps,
Shawn


My System SpecsSystem Spec
21 Nov 2012   #28
Neophile

Windows 7 Ultimate 64-bit SP1
 
 

Thank you Brink. I had already tried regedit /?, but this was wrong and just opened the registry editor. I had not found the correct help command. Now I tried, but it does not always work . It works when I export a full key, like
reg export HKEY_CURRENT_USER trial.reg
The operation completed successfully.
But not when I try to export a deeper subkey, and get an error as
reg export HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion trial.reg
ERROR: Invalid syntax.
Type "REG EXPORT /?" for usage.
I wonder what I am missing or if it does not actually export subkeys as I understand from the results of "reg export /?".

It would be very useful for many usages. An example is the Outlook profile for e-mail accounts settings, because it saves all accounts, passwords, etc. The usage is not limited to this, but with this I could make periodic auto-savings.
My System SpecsSystem Spec
21 Nov 2012   #29
Brink
Microsoft MVP

64-bit Windows 8.1 Enterprise
 
 

Since the key path has a space in it, you'll just need to have it wrapped in quotes like below instead.

reg export "HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion" trial.reg
My System SpecsSystem Spec
Comment

 Registry - Backup and Restore




Tutorial Tools




Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 06:18 AM.
Twitter Facebook Google+



Windows 7 Forums

Seven Forums Android App Seven Forums IOS App
  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33