The Windows Registry

Document Sample
The Windows Registry Powered By Docstoc
					          The Windows Registry

                           Adapted from
• Working with the registry can be
  dangerous even if you know what you are
• Making a wrong change can cause
  problems severe enough that they cannot
  be solved short of a reinstall.
• The Windows XP Registry is a database
  repository that is stored on your hard drive.
• This database stores different settings for your
  software, hardware, users, and preferences for
  Windows itself.
• Ever wonder how Windows remembers your
  screen resolution even after you restart your
  – Or how about the size and position of your windows?
  – All that is stored in the Registry, and more.
        Opening the registry
• This is easy, just click on the start button
  and then on run. Once run is open, type in
  regedit and click OK.
                         Hives and Keys
Now you see the "folders"
   HKEY_USERS, and

Some basic terminology

   The five main "folders" are
   called hives
   Their subfolders are called

   Once you open the Registry Editor, you'll notice that it is divided into two
   panes. The left pane contains the hives, keys, and sub-keys. The right pane
   contains various data types.
The Hives
        Backup the entire registry
Click Start
Mouse over All Programs
Mouse over Accessories
Mouse over System Tools
Click Backup
Click Next
Select the Back up files and
       settings radio button
Click Next
Select the Let me choose
       what to back up radio
In the left pane, highlight My
       Computer (but don't
       check it)
Now in the right pane, check
       System State

Restore Entire Registry If You Can't
         Boot Windows
• To restore the Registry when you are unable to boot into
  Windows, you will have to use the Last Known Good
  configuration by doing the following:
• Press the F8 key while your computer first begins
  loading Windows
• In the Windows Advanced Options menu, select Last
  Known Good Configuration and press Enter
• Your computer will now boot into Windows with your
  most recent settings that worked
      Restore the Entire Registry
•   Click Next
•   Select the Restore files and
    settings radio button
•   In the left pane, highlight File
•   Now, in the right pane, you
    should see your backup;
    double-click it
    If you don't see your backup,
    click the Browse... button
•   System State should now be
    displayed in the right pane;
    check it
•   Click Next
•   Click Finish
•   Accept the Warning by
    clicking OK
•   You should now see a
    Restore Progress window
•   Once the restoration is
    complete, click Close
•   Click Yes to restart your
    computer so the changes will
    take effect
    Windows XP Home edition
• Windows XP Home edition does not include the
  Backup utility by default.
  To install it:
• Insert your Windows XP cd
• Open up Windows explorer
  (replace ? with appropriate cd-rom drive letter)
• Double-click NTBACKUP.MSI and follow the on-
  screen instructions
                  Keys and values
•   if you wanted to open HKEY_CURRENT_USER\Software\Microsoft, click
    the + next to Software, then the + next to Microsoft.
•   Some keys contain other keys and some contain keys and values and some
    just contain values
                 Value Types
• String Values (REG_SZ), which are capable of storing
  text or any type of characters (including numbers).
• Binary Values (REG_BINARY) stores information in
  binary format but is displayed in hexadecimal format.
• DWORD Values (REG_DWORD), which are used to
  store number values. Although displayed in hexadecimal
  format, you may enter in data in either hexadecimal or
  plain decimal
• Multi-String Values (REG_MULTI_SZ) usually hold
  data that contain lists or multiple values in a form.
• EXPandable String Values (REG_EXPAND_SZ)
  usually contains variable-length data strings.
                     “Exporting” keys
•   This should be done to any and all registry keys before changing them.
    It will give you an easy way of changing back any changes that you make
    editing the registry. Right click the key that you want to eXPort, and select
              Exporting /2
• Then give it a
  name so you
  what it is.
• Now that you have eXPorted keys to
  change back your changes,
  you need to know how to import them
  into the registry.

  Usually a double-click on a registry
  file will merge it for you unless you
  have changed the default action.

  Then you have to right-click the file
  and select Merge.
                Edit a registry value
                      Strings /1
• There are three main types of
  registry values that you will
  deal with: STRINGS,

• There are others, but these are
  99% of what you will deal with
  doing normal editing.

• To change an existing
  STRING value, just double
  click it and enter in the new
  value data.
                  Hex or Decimal
                    Dword /2
• To change an existing
  DWORD value you have
  two options, hexadecimal
  and decimal.

• Be sure you know what
  type the value should be,
   – 200 hexadecimal is 256
   – c8 is hexadecimal for 200
                  Binary /3

• Binary values are
  written in hex.
• The applicable
  values are entered
  the format 00 01 A2
• Changing anything
  other than 00 to 01
  or 01 to 00 is rare
      Adding new registry entries
• Adding values is
  very similar to
  changing them with
  the exception that
  you have to name
  the value.
• Right click in the left-
  hand-side of the
  registry editor and
• New > String
    – (or whatever value
      type you want to
                       Adding a new Key
•   You need to add a key under

•   Just right-click on
    oftware\Policies\Microsoft in
    the folder tree,
    and then New > Key
Doing it with Text
Manually /2
Manually /3
Manually /4
Manually /5

Shared By: