Sunday, August 17, 2008

Registry

The Registry
Windows configuration information is stored in a special configuration database known as
the Registry. This centralized database contains environmental settings for various Windows
programs. It also contains registration information that details which types of file extensions
are associated with which applications. So, when you double-click a file in Windows Explorer,
the associated application runs and opens the file you double-clicked.
The Registry was introduced with Windows 95. Most OSs up until Windows 95 were configured
through text files, which can be edited with almost any text editor. However, the Registry
database is contained in a special binary file that can be edited only with the special
Registry Editor provided with Windows.
Windows 2000 and XP have two applications that can be used to edit the Registry,
REGEDIT and REGEDT32 (with no I). In Windows XP, regedt32 opens regedit. They work
similarly, but each has slightly different options for navigation and browsing. In addition,
REGEDT32 allows you to configure security-related settings for Registry keys,, such as assigning
permissions.
The Registry is broken down into a series of separate areas called hives. These keys are
divided into two basic sections—user settings and computer settings. In Windows 2000 and
XP, a number of files are created corresponding to each of the different hives. Most of these
files do not have extensions, and their names are system, software, security, sam, and
default. One additional file that does have an extension is NTUSER.DAT.
The basic hives of the Registry are these:
HKEY_CLASSES_ROOT Includes information about which file extensions map to particular
applications.
HKEY_CURRENT_USER Holds all configuration information specific to a particular user, such
as their Desktop settings and history information.
HKEY_LOCAL_MACHINE Includes nearly all configuration information concerning the actual
computer hardware and software.
HKEY_USERS Includes information about all users who have logged on to the system. The
HKEY_CURRENT_USER hive is actually a subkey of this hive.
HKEY_CURRENT_CONFIG Provides quick access to a number of commonly needed keys that
are otherwise buried deep in the HKEY_LOCAL_MACHINE structure.

Modifying a Registry Entry
If you need to modify the Registry, you can modify the values in the database or create new
entries or keys. You will find the options for adding a new element to the Registry under the
Edit menu. To edit an existing value, double-click the entry and modify it as needed. On Windows
2000 and XP systems, you need administrative-level access to modify the Registry.

Restoring the Registry in Windows 2000 and XP
Windows 2000 and XP store Registry information in files on the hard drive. You can restore
this information using the Last Known Good Configuration option, which restores the Registry
from a backup of its last functional state. To use this option:
 In Windows 2000/XP, press F8 during startup and then select Last Known Good Configuration
from the menu that appears. You can also back up the Registry files to the systemroot\
repair directory by using the Windows 2000/XP Backup program, or you can save them to
tape during a normal backup. To repair the Registry from a backup, overwrite the Registry
files in systemroot\system32\config.
 In Windows 2000, creating an Emergency Repair Disk (ERD) also backs up the Registry
files (to floppy disk, in this case). To create an ERD, in Windows 2000, use the Backup
utility.
 In Windows XP, the ERD has been replaced with Automatic System Recovery (ASR),
which is accessible through the Backup utility.

No comments: