Restore the Windows registry and system defaults without reinstalling Windows

Discussion in 'Windows OS's' started by RHochstenbach, Sep 6, 2010.

  1. RHochstenbach

    RHochstenbach Administrator Staff Member

    Likes Received:
    24
    Trophy Points:
    38
    Reinstalling Windows can be quite time consuming, but sometimes it’s required if your system doesn’t boot anymore. This can be caused if the system configuration is broken, the registry has been corrupted, or when you’ve replaced your motherboard.

    Luckily there’s a solution that saves the hassle of reinstalling, yet being able to properly boot into Windows, and even without losing any data at all.

    Step 1: Launch recovery console
    Insert your Windows installation disc and reboot your system. When it asks to press a key if you want to launch Setup, do so.

    When loading has been completed, there are 3 options: ENTER to Install Windows, R to perform a repair and F3 to quit setup. Press the ‘R’ key to launch the recovery console.

    It will now ask to choose an existing installation. This is usually option 1. So press 1 and then the ENTER key. Enter your Administrator password when asked. If there isn't any, just leave it blank. You’re now inside the recovery console.

    Note:
    The system configuration, the Windows Registry and the user accounts database are located in the folder WINDOWS\system32\config. An original copy exists since the installation of your Windows copy inside the folder WINDOWS\repair.

    Here’s a list of the important files in that folder:

    • system: This is the system configuration (including hardware configuration).
    • SAM: This is the database containing all local user accounts.
    • Software: This file contains the data of all your installed software, and all Windows settings.
    • default: This file contains all default user account settings.
    • security: This file contains the local security policy

    -- I've updated this guide to include instructions for Windows Vista and Windows 7. You can find instructions for these versions all the way down in the last section of this post --

    Step 2: Restore the file(s)
    I’m now going to show the required steps to restore the file(s) using the Recovery Console. In this example I’ve upgraded my motherboard, so I need to restore the system configuration (system-file) to the Windows defaults, disabling any additional drivers.

    Remember that the original file is located in WINDOWS\repair, while the active file (the one that needs to be replaced by the original) resides in WINDOWS\system32\config.

    (optional) Make a backup of your active file before proceeding. Enter these two commands:
    Code:
    cd system32\config
    ren system system.old
    
    The file has now been renamed to system.old. If you ever need it again (not likely), you can rename it back if you need to.

    Now restore the original file using this command (change C: if you’ve installed Windows on a different partition):
    Code:
    copy C:\WINDOWS\repair\system C:\WINDOWS\system32\config\system
    Step 3: Boot into Windows
    You can now boot into windows by entering the EXIT command. If you restored the system configuration, you now need to install all hardware drivers.

    Side notes
    • By restoring these files, you can restore your registry to the Windows defaults. However, it won’t fix missing files and folders.
    • Also don’t use this method if your system has been infected with malware, because chances are that your system becomes infected again when rebooting. Instead, copy your files to an external drive using the Recovery Console and then scan these with anti-virus software on a different system.
    • If you've replaced your motherboard, you might need to re-activate Windows. You can use the Windows Activation wizard to either activate it online or by calling to the provided phone number if activation would fail for some reason.

    You can find more information in this thread: http://www.hardwareforums.com/when-windows-xp-really-its-knees-1088/

    Note for Windows Vista and Windows 7
    The original registry files in Windows Vista and Windows 7 are located in a different folder: WINDOWS\system32\config\RegBack

    Instead of using the Recovery Console, insert your Windows disc and launch Setup. Choose Repair your Computer instead of Install Now.
    View attachment 2206

    Choose your current Windows installation and then choose Command Prompt.
    View attachment 2207

    In this example I'll restore the Registry file 'system'.

    1. Backup your original file.
    Code:
    cd C:\Windows\system32\config
    ren system system.old
    2. Restore the original file.
    Code:
    cd C:\windows\system32\config\RegBack
    copy system ..\system
    
    You can now reboot your system.

    Attached Files:

  2. daz

    daz Geek

    Likes Received:
    0
    Trophy Points:
    16
    Restoring option in Windows 7 is very good. It helped me more then once.
  3. salvagetug

    salvagetug Geek Trainee

    Likes Received:
    0
    Trophy Points:
    0
    One big question I have about this fix, will you be able to recover your documents? My System crashed due to a virus I believe. I cannot get into any of the safe modes, nor can I reboot. when going into the safe mode, it gets as far as multi(0)disk(0)rdisk(0)partition(2)\WINDOWS\system32\drivers\mup.sys then freezes.
    Appreciate any assistance here. I am running a Vostro 1400 (Dell) with Windows XP
    I would be happy to get my files off of the computer.
    Thanks and Happy New Year.
  4. RHochstenbach

    RHochstenbach Administrator Staff Member

    Likes Received:
    24
    Trophy Points:
    38
    This fix won't be able to restore damaged system files. In that case, you have to use the Recovery Console to restore the file. Use the steps in my 1st post to get into the console.

    After entering your Administrator password, you need to figure out which drive letter is used for your cd/dvd drive. If you have the partitions C: and D:, the cd drive should be E:. I'll use E: as an example.
    Enter this command:
    Code:
    expand d:\i386\mup.sy_ C:\windows\system32\drivers
    
    Now reboot your system into Safe Mode. if it still hangs, disconnect all USB devices at the moment when it hangs. It should boot up properly now. Then reboot and start the system normally.
  5. salvagetug

    salvagetug Geek Trainee

    Likes Received:
    0
    Trophy Points:
    0
    Thank you very much. I will give this a shot. I am not so worried about the computer as I am the files, (lots of pictures, music ect). I spoke to Dell Tech Help earlier and was told if I used the recovery disk that I loose everything on the computer, (all files programs ect)>
    Good to know there is another option.

    Thanks for the assistance
  6. Bobby_pro

    Bobby_pro Geek Trainee

    Likes Received:
    0
    Trophy Points:
    1
    Oh.. Finally I have one relevant guide. Except for this, windows repair is pretty useless. The automatic startup repair is good for nothing.

Share This Page