Saturday, January 16, 2010

My System Is Not Booting How To Recover From A Corrupted Registry

In this article, we have given the steps to recover a Windows XP System that is corrupted in the Registry settings. However, you can recover the data when you use this procedure but Microsoft doesn’t guarantee full recovery of the system to a previous state using this method.

Important Warning:

If your Computer has an OEM installed Operating System, you don’t need to use this procedure as the system hive on OEM installation creates passwords and user accounts that did not exist previously. If you use this procedure, you will not be able to log back into the recovery console to restore the original registry hives. Moreover, this article assumes that typical recovery methods have failed and access to the System is not available except by using Recovery Console.

Important Note:
You should replace all five of the registry hives. If you fail to replace a single hive or two, it may cause potential issues as the Software and Hardware may have settings in multiple locations in the registry. If you try to start or restart the Windows XP Computer, you may receive the following error messages.
Windows XP could not start because the following file is missing or corrupt: \WINDOWS\SYSTEM32\CONFIG\SYSTEM

Windows XP could not start because the following file is missing or corrupt: \WINDOWS\SYSTEM32\CONFIG\SOFTWARE

Stop: c0000218 {Registry File Failure} The registry cannot load the hive (file): \SystemRoot\System32\Config\SOFTWARE or its log or alternate

System error: Lsass.exe
When trying to update a password the return status indicates that the value provided as the current password is not correct.

How to recover registry files manually
This procedure describes Recovery Console, System Restore and lists all the required steps in specific order to ensure that the process is fully completed. Moreover, if you finish the procedure, the system will return to a closer state before the problem occurred. At the same time, if you have ever run NTBackup and completed a system state backup, you don’t need to follow the procedures given in the parts two and three. You can directly go to the part four.
Part one

You have to start the Recovery Console in the part one. Create a temporary folder, back up the existing registry files to a new location and delete the registry files from the existing locations. Then you can copy the Registry files from the repair folder to the System32\Config folder. If you finish the procedure, a registry will be created that can be used to start Windows XP. Moreover, this registry is created and saved during the initial setup of Windows XP.
If you want to complete part one, follow the following steps:
• First, insert the Windows XP Startup disk into the floppy disk drive.
• Or else, insert the Windows XP CD-ROM into the CD-ROM Drive and then restart the Computer.
• Now, click to select any options used to start the Computer from the CD-ROM Drive if you are prompted to do so.
• After that, if the system shows the “Welcome to Setup” screen appears, press R to start the Recovery Console.
• Whereas, if you have a dual-boot or multiple-boot Computer, select the installation which you want to be accessed from the Recovery Console.
• If you are asked to enter the Administrator password enter the password, otherwise press Enter.
• After this, you have to type the following lines in the Console Command Prompt. You have to press Enter after each line.
md tmp
copy c:\windows\system32\config\system c:\windows\tmp\system.bak
copy c:\windows\system32\config\software c:\windows\tmp\software.bak
copy c:\windows\system32\config\sam c:\windows\tmp\sam.bak
copy c:\windows\system32\config\security c:\windows\tmp\security.bak
copy c:\windows\system32\config\default c:\windows\tmp\default.bak

delete c:\windows\system32\config\system
delete c:\windows\system32\config\software
delete c:\windows\system32\config\sam
delete c:\windows\system32\config\security
delete c:\windows\system32\config\default

copy c:\windows\repair\system c:\windows\system32\config\system
copy c:\windows\repair\software c:\windows\system32\config\software
copy c:\windows\repair\sam c:\windows\system32\config\sam
copy c:\windows\repair\security c:\windows\system32\config\security
copy c:\windows\repair\default c:\windows\system32\config\default

• Now, you can type exit to quit the Recovery Console.
• Now, your Computer will restart.
Important Note
This procedure is suitable only if Windows XP is installed in the C:\Windows folder. Otherwise, you have to change the c:\Windows to the appropriate Windows Folder.
At the same time, if you can access another Computer and you want to save time you can copy the text in step five and then create a text file called ‘Regcopy1.txt”. Then if you want to use this file, run the following command when you start in Recovery Console.
batch regcopy1.txt

This command will save your time and let you free from typing each and every command.

Part Two
If you want to complete this procedure, you should log in as an administrator or a user with administrative privileges. Remember, if you’re running Windows XP Home Edition, you can log in as administrative user. If you want to log on as an administrator, you must first start Windows XP Home Edition in Safe Mode.
If you restart the Computer, you can’t view the instructions. Therefore, take a printout of this instruction to log in to Safe Mode.
• Click Start and choose Shut Down or choose Turn Off Computer.
• Then choose Restart and then click Ok or click Restart.
• Now, keep tapping the F8 key.
• You can use the arrows keys to swap appropriate Safe Mode option. Choose the Safe Mode and press Enter.
• If you have multiple Operating System in the Computer, the Computer will prompt you to choose Operating System. Choose the appropriate one.

Before you start this procedure, you should change several setting to make the copied folder visible because the registry files you copied from their backed up location by using System Restore will not available in Recovery Console and generally they won’t be visible.
1. Start Windows Explorer by pressing Windows Key and E Key.
2. Then on the Tools menu, choose Folder Options.
3. Now, click the View tab.
4. Under Hidden File and Folders, click to select Show Hidden Files and Folders and uncheck the Hide Protected Operating System files (Recommended) check box.
5. Now, click Yes, if the dialog box confirms that you want to display these files appear.
6. Now, double click on the drive in which you installed Windows XP to display a list of the folders. Choose the correct drive.
7. After that, open the System Volume Information folder. This will be unavailable and appear dimmed as it is set as a hidden folder.

Note This folder contains one or more _restore {GUID} folders such as

Note You may receive the following error message:
C:\System Volume Information is not accessible. Access is denied.

8. If you receive the above error message, you have to refer to the Microsoft for troubleshooting.
9. Now, you can open folder that wasn’t created at present. Therefore, you will have to click Details on the View menu to see when these folders were created. You can see one or more folders that start with “RPx under this folder. These are the Restore points of your Computer.
10. Now, you can open one of these folders in order to locate a Snapshot subfolder. The path given below is an example of a folder path of a Snapshot folder. Refer to it.
C:\System Volume Information\_restore{D86480E3-73EF-47BC-A0EB-A81BE6EE3ED8}\RP1\Snapshot

11. Now, you have to copy the following files to the C:\Windows\Tmp folder: from the Snapshot folder,

12. After that, rename the files in the C:\Windows\Tmp folder as follows:

The files given above are backed up registry files from System Restore. It is because, you have used the registry files that the Setup program created, the registry doesn’t know that these Restore Points exist and are available.

At the same time, you should have the previous copy of the registry from a previous restore point to make the previous restore points available again.
At this point of time, the registry files that are copied to the TMP folder in C:\Windows folder will be moved to ensure that the files are available under Recovery Console. You can use these files to replace the registry files currently in the C:\Windows\System32\Config folder because, by default Recovery Console has limited folder access and can’t copy the files from the System Volume folder.

Part Three
In this part, you can delete the existing registry files and then copy the System Restore Registry files to the C;\Windows\System32\Config folder.
Start Recovery Console.
1. Open the command prompt and type the following lines. Remember, you have to press Enter after you type each line:
del c:\windows\system32\config\sam

del c:\windows\system32\config\security

del c:\windows\system32\config\software

del c:\windows\system32\config\default

del c:\windows\system32\config\system

copy c:\windows\tmp\software c:\windows\system32\config\software

copy c:\windows\tmp\system c:\windows\system32\config\system

copy c:\windows\tmp\sam c:\windows\system32\config\sam

copy c:\windows\tmp\security c:\windows\system32\config\security

copy c:\windows\tmp\default c:\windows\system32\config\default

Some of these command lines may be wrapped for readability.
2. Once you finish entering all of the above lines, type exit to quit Recovery Console. Now, your computer restarts.
Important Note
This procedure is suitable only if Windows XP is installed in the C:\Windows folder. Otherwise, you have to change the c:\Windows to the appropriate Windows Folder.
At the same time, if you can access another Computer and you want to save time you can copy the text in step five and then create a text file called ‘Regcopy2.txt”. Then if you want to use this file, run the following command when you start in Recovery Console.
batch regcopy2.txt

Part Four
This is the simplest procedure to perform System Restore.
1. Click on Start Button, choose All Programs.
2. Now, choose Accessories and then click System Tools.
3. After that, click System Restore and then choose Restore to a pervious Restore Point.
The article given above applies to
• Microsoft Windows XP Home Edition
• Microsoft Windows XP Professional
• Microsoft Windows XP Tablet PC Edition
• Microsoft Windows XP Media Center Edition