There will come a time when you are faced with a computer that won’t boot for one reason or another. One of the many reasons for this is a corrupted operating system. When dealing with a Windows-based computer, there are a few things that you can try to fix the corrupt OS before a complete reinstall becomes your only option.
As long as you are able to boot into a device which gives you access to a command prompt, you can run some commands to attempt to fix the corruption. The BootRec.exe program which is used via the command prompt has a few different commands within itself that are useful for cases such as this. Affixing “/fixmbr” to the end of BootRec.exe will force BootRec to attempt to rebuild the Master Boot Record for the OS in question. You can replace “/fixmbr” with “/fixboot”, “/scanos” or “/rebuildbcd” for different functionality.
Each of these commands attempts to recover the portions of Windows which are involved in the booting process. Things like the Master Boot Record, the Boot Sector of the hard drive and the Boot Configuration Data store can become corrupt and any of them can prevent Windows from booting correctly. These can be run one after another to attempt to completely fix a corrupt operating system, but only if it is a minor corruption. Many of the causes of a non-booting system cannot be fixed by simply running these commands.
Note: These commands can only be run in a Preinstall Environment or from a Recovery CD after choosing the Repair option.