Windows Registry | DigitalRise

Digital Rise Homepage

Windows Registry

Ever wondered where all your personalization settings were stored on your computer. The most likely place the windows operating system stores its settings, both system and user, is the ‘Registry’. It is a database for all information settings and options for hardware, operating system and most non operating system software, user settings. The registry was introduced in Windows 3.1 and is one of the key components of the Microsoft Windows operating system. Its main components are ‘Keys’ and ‘Values’. Keys are containers which hold values or keys (sub keys). The key value hierarchy is comparable with the folder and file hierarchy in the windows OS where keys are the folders and values are the files. The values contain actual data like the path to a folder where software is installed, its associated settings and any customizations made by the user.

If the registry is viewed with a UI editor, under the root(My computer) the following keys are found.

HKEY_CLASSES_ROOT – Under this key we can find file associations and OLE object class information. The entries here are a union of HKEY_LOCAL_MACHINESoftwareClasses and HKEY_CURRENT_USERSoftwareClasses. HKEY_CURRENT_USER – As the name suggests the settings of the currently logged in user is stored in this hive.It contains the colors, fonts and attributes for the desktop environment as well as any network connections HKEY_USERS – This hive contains the settings of all the users in the system. HKEY_LOCAL_MACHINE – Under this we see the settings for the hardware, system software and applications. HKEY_CURRENT_CONFIG – Contains temporary settings that are generated at boot time and not stored permanently like the current display resolution and printers.

The registry is constantly been written and over written, every time a new software/hardware is installed/uninstalled, or the user/OS changes a setting, and for many more reasons. Not always values that are supposed to be deleted get deleted or get updated to the correct values. So values might end up having paths to already removed or moved software, and values with corrupt data that make no sense to the application or to the OS. Over a period of time as a side effect of all the updating the registry accumulates a lot of residue causing the system to slow down or hang. The common symptoms of corrupted registry is large boot time, increase in the instances of unresponsiveness (system freezes), increase in time taken by a software to begin its work, inability to modify or delete a program or the most dreaded of the blue screen.

There is no way to prevent the registry corruption, the only way out is to regularly clean the registry. One can manually edit or delete any key or value in the registry using the registry editor (regedit.exe) bundled with the OS, this tool has a user interface which shows all the keys and values in their hierarchy. Another tool available with the OS is the reg.exe, with no UI, this is a command line tool which can be used to edit the registry. Manually changing the registry entries can be very risky, and cause the system to fail completely. Hence it is better to take a backup of the existing registry in a ‘.reg’ file using either of the tools mentioned, and use it to restore to the previous state if need be.

Manual editing can be time consuming and not all registry errors are obvious, so one would need to take the help of a registry cleaner tool here. There is a multitude of registry cleaners available in the market. Though these expedite the registry cleaning, care needs to be taken not to give these a free run and they have to be monitored in order to not loose valuable information.