pantz.org banner
Recovering from critical windows errors
Posted on 05-25-2006 03:20:00 UTC | Updated on 03-20-2011 04:01:58 UTC
Section: /software/windows/ | Permanent Link

If you ever get messages like this:

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

Windows NT could not start because the below file is missing or corrupt:
c:\WINNT\System32\Ntoskrnl.exe

Windows NT could not start because the below file is missing or corrupt:

c:\WINNT\System32\HAL.dll

NTLDR is Missing
Press any key to restart

Invalid boot.ini
Press any key to restart 

when trying to boot Windows XP your not alone. This happens to more people than you would think and sometimes it's easy to correct when you know what to type at the Windows Recovery Console. Well, I read a great article about some commands you can use to fix these problems. I'll relist info from the article below so I don't forget this the next time some XP machine puke's it's guts.

First, you can attempt to repair the above errors by starting Windows setup using the original Windows XP CD-ROM. This is done by placing the orginal Windows XP CD into the CD-ROM drive and booting from it. You might need to go into your BIOS to make sure your boot priority is set to try booting from the CD-ROM drive first. Usually you can get into your BIOS by pushing the "Delete" key right when the computer is starting. After the CD has booted to Windows XP setup screen you'll see an option for selecting 'R' to start repair console. Push the "r" key on the keyboard and it should bring you to the Windows Recovery Console. Select "1" for the drive to fix usually there is only one selection to choose. Then if your prompted for the administrator password type that in an hit the "enter" key.

Now onto the commands. From the C:\windows prompt they are:

CD ..
CHKDSK c: /r /f
ATTRIB ?H C:\boot.ini
ATTRIB ?S C:\boot.ini
ATRIB ?R C:\boot.ini
del boot.ini

Before we execute the next command let's read about what's is going to happen.

After execution the command BOOTCFG /Rebuild will ask you some questions. The answers are as follows:

Add installation to the boot list? Y
Enter Load Identifier: Windows XP
Enter OS load Options: /FASTDETECT /NOEXECUTE=OPTIN
                                        /\
                                        ||
Set the /NOEXECUTE=OPTIN only if you have CPU featuring Intel's XD or AMD's NX buffer overflow protection.
If not then just leave it off. Any processor made after 2005 probably has this built in. Intel implemented
this feature in x86 processors beginning with the Pentium 4 processors based on the core codenamed Prescott.
If you have an AMD 64bit processor then you should have NX overflow protection. Also, no need to turn it on
unless you are installing Windows XP Service pack 2 or higher. Same for Windows Server 2003 Service Pack 1
or higher.

Now that you know what to do execute the last 2 commands.

BOOTCFG /Rebuild
FIXBOOT

After that the FIXBOOT command asks "Sure you want to write a new bootsector to the partition C:?". Answer "Y" for yes. Then at the prompt type "exit". This should reboot the computer. Take the cdrom out of the drive before the boot process starts and hopefully your back up and running.

A last note for anyone having boot loader problems (you know who you are) the command to over write another boot loader like Grub or LILO is:

fixmbr

Reddit!

Related stories


RSS Feed RSS feed logo

About


3com

3ware

alsa

alsactl

alsamixer

amd

android

apache

areca

arm

ati

auditd

awk

badblocks

bash

bind

bios

bonnie

cable

carp

cat5

cdrom

cellphone

centos

chart

chrome

chromebook

cifs

cisco

cloudera

comcast

commands

comodo

compiz-fusion

corsair

cpufreq

cpufrequtils

cpuspeed

cron

crontab

crossover

cu

cups

cvs

database

dbus

dd

dd_rescue

ddclient

debian

decimal

dhclient

dhcp

diagnostic

diskexplorer

disks

dkim

dns

dos

dovecot

drac

dsniff

dvdauthor

e-mail

echo

editor

emerald

ethernet

expect

ext3

ext4

fat32

fedora

fetchmail

fiber

filesystems

firefox

firewall

flac

flexlm

floppy

flowtools

fonts

format

freebsd

ftp

gdm

gmail

gnome

google

greasemonkey

greylisting

growisofs

grub

hacking

hadoop

harddrive

hba

hex

hfsc

html

html5

http

https

hulu

idl

ie

ilo

intel

ios

iperf

ipmi

iptables

ipv6

irix

javascript

kde

kernel

kickstart

kmail

kprinter

krecord

kubuntu

kvm

lame

ldap

linux

logfile

lp

lpq

lpr

maradns

matlab

memory

mencoder

mhdd

mkinitrd

mkisofs

moinmoin

motherboard

mouse

movemail

mplayer

multitail

mutt

myodbc

mysql

mythtv

nagios

nameserver

netflix

netflow

nginx

nic

ntfs

ntp

nvidia

odbc

openbsd

openntpd

openoffice

openssh

openssl

openvpn

opteron

parted

partimage

patch

perl

pf

pfflowd

pfsync

photorec

php

pop3

pop3s

ports

postfix

power

procmail

proftpd

proxy

pulseaudio

putty

pxe

python

qemu

r-studio

raid

recovery

redhat

router

rpc

rsync

ruby

saltstack

samba

schedule

screen

scsi

seagate

seatools

sed

sendmail

sgi

shell

siw

smtp

snort

solaris

soundcard

sox

spam

spamd

spf

spotify

sql

sqlite

squid

srs

ssh

ssh.com

ssl

su

subnet

subversion

sudo

sun

supermicro

switches

symbols

syslinux

syslog

systemd

systemrescuecd

t1

tcpip

tcpwrappers

telnet

terminal

testdisk

tftp

thttpd

thunderbird

timezone

ting

tls

tools

tr

trac

tuning

tunnel

ubuntu

unbound

vi

vpn

wget

wiki

windows

windowsxp

wireless

wpa_supplicant

x

xauth

xfree86

xfs

xinearama

xmms

youtube

zdump

zeromq

zic

zlib