Sunday, May 13, 2012

Procedure to bring your hard disk to Factory Setup

Recently I faced a situation where my OS was not booting. Also when I tried to install a fresh Windows 7 in it,  my hard disk was not getting formatted.
I followed the following Debug script to bring my hard disk to factory setup & after that I could install the Windows 7, in the way I wanted.

NB : 1. We should not go for more than 3 partition, else system might slow up.
        2. Make all partition as primary (by Win 7 DVD). Avoid creating Dynamic drives, else going further they cant be modified.

Procedure for reverting to  Factory Setup :

Insert any boot able Floppy / CD / DVD & navigate to RAM Disk (By default the prompt goes there).
Then type below commands in command prompt (With CAPS lock ON) :

DEBUG
-F 200 L1000 0
-A CS:100
xxxx:0100 MOV AX,301  (NB: XXXX could be anything, just ignore & type rest command)
xxxx:0103 MOV BX,200
xxxx:0106 MOV CX,1
xxxx:0109 MOV DX,80


 NOTE:  Type 80 for the Main hard drive - HD 0, or type 81 for the Second hard drive - HD 1.


xxxx:010C INT 13
xxxx:010E INT 20
xxxx:0110 (Leave this line blank and press the key)
-G
The message, Program terminated normally, appears. Turn off the computer by pressing the power button. On the next startup the hard drive must be partitioned and formatted.



If anyone tried this procedure & found helpful, requesting him / her to leave a message here as comment / feedback.


Thanks,
Bikash Patra

No comments: