Using Recovery Console to restore registry files

The Recovery Console allows one to copy and move files. It can be useful in the situation where the registry files have become faulty, making it impossible to boot Windows normally.

The active machine registry files are placed here:

%systemroot%\System32\Config\system
%systemroot%\System32\Config\software
%systemroot%\System32\Config\sam
%systemroot%\System32\Config\security
%systemroot%\System32\Config\default

The active user registry file is placed here:

%SystemRoot%\Profiles\<Username>\Ntuser.dat (WinNT4)
C:\Documents and Settings\<Username>\Ntuser.dat (Win2k/WinXP)

The initial registry files are placed here (Created at install):

%systemroot%\System32\Repair\system
%systemroot%\System32\Repair\software

If having used Ntbackup to create a System State backup, then a copy of the registry files will be placed in the following directory:
  • Win2k (Also happens when creating a Emergency Recovery Disk):

    %systemroot%\System32\Repair\RegBack

    More Info MS KB231777

  • WinXP:

    %systemroot%\Repair

If using WinNT4/Win2k then one can find a recent backup of the System-registry here:

%systemroot%\System32\Config\System.alt

More Info MS KB151247

Related Offline registry editing

More Info MS KB269075
More Info MS KB307545

Updated: 23 September 2007

Comments:

  1. Anonymous says:

    You know, this sort of thinking wouldn't even be needed if Microsoft just realized that the registry is an all-around bad idea. I prefer the way Linux does it. Many many many plaintext in a central directory for system-wise configuration, and dotfiles in a user's home directory.

    What are the advantages, you may ask?

    1. The user settings put in the home directory of each user means that they can be shared 100% between Linux distributions, as Linux, unlike Windows, supports a unified file system. This also means you can keep all your preferences and documents even when reinstalling the operating system. Windows does not do this.

    2. It's easier to search through for settings even if you don't have any tools beyond a text editor. And backing up JUST the settings you want is a breeze. Windows does not do this.

    3. It doesn't cause the entire system to be screwed if you mess up even an innocuous setting in one of the configuration files. It allows you to QUICKLY and ROBUSTLY restore configuration. Windows does not do this.

    4. People can help you easier in Linux because they can ask to see how your system is configured by just asking you to copy/paste /etc/file.conf so they can see. Windows does not do this.

  2. Snakefoot says:

    Anonymous wrote:

    if Microsoft just realized that the registry is an all-around bad idea

    The Windows registry is pretty much an advanced text-file, which is better at storing settings than a plain text-file (Setting hierarchy with permissions, Value types, Transactionality etc.) . This naturally requires one need to use the proper tools when needing to backup / restore / edit the registry. The problem is how the registry is used.

    Microsoft have changed their recommendation for how the registry should be used. They now recommend that 3rd party applications shouldn't mess around in the registry, but should instead work in their own configuration files.

    1) This also means you can keep all your preferences and documents even when reinstalling the operating system.

    Windows supports backing up the system state, which then can be restored after having reinstalled the operating system.

    2) It’s easier to search through for settings even if you don’t have any tools beyond a text editor

    I guess you don't have access to grep like search features without doing an export of the registry database to a text-file, but this haven't been something I have been needing. I don't see much difference between using a registry editor compared to a text-editor.

    3. It doesn’t cause the entire system to be screwed if you mess up even an innocuous setting in one of the configuration files

    I would be surprised if one cannot make a linux system unbootable if one starts adding / removing / changing settings in the configuration files without reading the documentation first.

    4. see how your system is configured by just asking you to copy/paste /etc/file.conf so they can see.

    Like all system diagnostic then one looks at the symptoms of the problem, and then request information accordingly (hardware configuration, software configuration, etc.). Never been in a situation where I wanted an export of the entire registry database. When solving an issue in Windows then many times it can be done without needing to digg into the registry database.

    I'm not saying the Windows registry is the best thing since sliced bread, but it is not a bad invention.

Leave a Reply

Your email address will not be published. Required fields are marked *