
Windows 98 Professional Reference


- 36 -
The Windows 98 Boot Process and Emergency Recovery
Sometimes you find yourself in a jam--a real jam, where your system won't start.
What's the problem? What to do? How to handle it? That's part of the subject of this
chapter: Emergency Recovery. Chapter 37, "Tools and Strategies for Troubleshooting
Windows 98" covers dealing with individual hardware devices, software that isn't
working correctly, or other aberrant behavior on your system. But Chapter 37 assumes
that your system is starting (more or less). Not here, though: This chapter will
get you on the road to recovery when you can't even get the darn thing booted. And
because emergency recovery is closely related to how Windows 98 boots, you'll also
learn about the Windows 98 boot process in this chapter.
In this chapter you learn about the following:
- How Windows 98 boots
- Different kinds of startup problems
- How to deal with the different types of startup problems
- How to use the Windows 98 Startup menu to attempt recovery
- Understanding, preparing, and using a Windows 98 Emergency Boot Disk (EBD)
Startup problems can be among the most frustrating because you have so little
information with which to work. There are no friendly little trouble icons in Device
Manager to show you where the trouble is, usually. As you will see, however, solving
startup problems is more a matter of working through the different possibilities,
one by one.
Understanding the Windows 98 Boot Process
Windows 98 goes through a series of steps as it boots the computer. If everything's
working well, you won't care about the details about how Windows 98 gets the computer
from an off state to when it displays the opening desktop. However, when troubleshooting
boot problems, it's helpful to understand how booting works.
When a computer is powered up, the first thing that happens is that a program
built into the computer's Basic Input/Output System (BIOS) runs and performs a Power-On
Self Test (POST). The POST tests all the key system components to make sure that
they're all there and that they're minimally functioning. Also, the RAM in the computer
is briefly tested during the POST.
After the POST completes, the BIOS automatically loads a small program from the
primary hard disk on the system (or from a disk drive, or in rare cases a CD-ROM).
This small program is called a bootstrap because it helps the computer "pull
itself up by its bootstraps." The bootstrap loads the operating system's own
bootstrap program from special startup sectors on the hard disk and transfers control
to the operating system. The operating system programs then proceed to initialize
the hard disk's file system, and control is transferred to other programs, on down
the line until the system is completely booted.
The first phase of Windows 98's startup process involves scanning the installed
hardware in the system and selecting the appropriate Hardware Profile from the Registry.
After the Hardware Profile is activated, Windows 98 processes any commands found
first in the CONFIG.SYS file, and then the AUTOEXEC.BAT file, both located in the
root directory of the primary boot device. that although CONFIG.SYS and AUTOEXEC.BAT
are not required for Windows 98, they are still processed in case they are needed
for compatibility with older software or hardware on the system. Any drivers loaded
by CONFIG.SYS and AUTOEXEC.BAT are real-mode drivers; the operating system has not
yet switched the system into protected mode.
Windows 98 then proceeds to load WIN.COM and any VxD device drivers needed for
the system. There are both static VxDs that are loaded during each boot and dynamically
loaded VxDs that may or may not be loaded, depending on the selected Hardware Profile.
The individual VxD device drivers are all contained in a file called VMM32.VXD.
The VxDs that are part of VMM32.VXD are loaded based on entries found in the Registry
at HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\VxD. If there are conflicting
entries in the SYSTEM.INI file, the entries in SYSTEM.INI will take precedence over
the Registry entries.
After the VxDs are loaded, Windows 98 switches the computer into protected mode
to proceed. The first thing that happens during this phase is that the Configuration
Manager is loaded and started, which then queries all Plug and Play devices in the
system; if the system's BIOS doesn't support Plug and Play, then the various buses
in the system are scanned for installed devices. Based on the information gleaned
from the Plug and Play queries or the bus scanning, dynamic protected-mode drivers
are loaded for the installed devices. After the device drivers are loaded, any resource
conflicts between the devices (such as IRQ assignments) are resolved by the Configuration
Manager.
Next, a variety of files are loaded: KERNEL32.DLL and KRNL386.EXE (contain the
basic components of Windows and the Windows device drivers, respectively), GDI.EXE
and GDI32.EXE (handle the graphical interface duties for the operating system), and
USER.EXE and USER32.EXE (provide the user-interface programming for Windows 98).
Any related resources, such as icons, images, and fonts, are then loaded. Next, WIN.INI
is processed and the desktop software is loaded and started. When User Profiles are
active on the system, a logon prompt for the system then displays. After the user
logs on, any settings specified for the User Profile are processed. Finally, any
programs listed in the Startup folder are loaded for the user while the desktop initializes.
Windows 98 Startup Files
There are seven key files that form the base of Windows 98's startup behavior.
They are all (except for WIN.INI and SYSTEM.INI) located in the root directory of
the primary boot device, usually C:.
- IO.SYS--This is the bootstrap program for Windows 98.
- MSDOS.SYS--This file is actually an ASCII text file that can be edited and contains
a few startup settings for the system. Table 36.1 describes all the settings you
can use in MSDOS.SYS.
- CONFIG.SYS and AUTOEXEC.BAT--These files contain any device drivers and commands
required for backward compatibility.
- SYSTEM.INI and WIN.INI--These files are for compatibility for older Windows 3.x
programs.
- BOOTLOG.TXT--This is a detailed account of the system's most recent logged startup.
Understanding Startup Problems
If a Windows 98 computer won't boot, the trouble is most likely due to one of
the following reasons:
- Something has caused the boot partition on the primary hard disk to stop functioning
properly.
- Some other hardware device has failed and is keeping Windows 98 from completing
its boot process.
- One or more key files that Windows 98 depends on has become corrupted and no
longer works.
You'll take different paths for resolving each of these errors. The following
sections discuss each type of problem in more detail.
WARNING: This author can't count the number of times he's worked
through a failure with someone, only to determine that the failure required a restoration
of data from a backup, and then discovering from a panicked user that there are no
backups--or only very old backups--available. The very best emergency recovery tool
anyone can ever have is a current, reliable backup of the system. Computers can and
do fail, and sometimes spectacularly. A good backup system in place will prevent
you from losing thousands of hours of accumulated work that is irreplaceable. If
you're in an environment that relies on users to perform their own backups, you owe
it to them to hammer this point home as forcefully as you can. Even better, find
a way to take backups out of their hands and set up a reliable system to take care
of this necessary chore.
Resolving Hard Disk Problems
Hard disk drives are much more reliable than in years past. It used to be that
they had a Mean Time Between Failure (MTBF) of about five to seven years. Now, most
drives quote MTBFs of 20 years or more. Still, even with this increased reliability
(or more optimistic marketing--we're not sure), hard drives can still fail. Sometimes
they fail slowly, accumulating bad sectors at a gradual rate, which then accelerate
over time, and sometimes fail suddenly, going dead for no apparent reason. The first
order of business is to ascertain whether the hard disk has failed. Afterward, if
you determine that the primary boot drive has indeed failed, you can take these steps
to replace it and rebuild your system:
- When the computer boots, you should see the hard disk drive light (the actual
light on the drive itself, if possible, rather than the "echoed" light
on most cases) illuminate as the system goes through its Power On Self Test (POST)
and the drive receives power from the system. If this isn't happening, check the
drive's data and power cables to ensure that they haven't become loose.
- If the drive still isn't showing even rudimentary signs of life (no spin-up noises,
no drive lights, and so on), try disconnecting any other hard drives in the system,
particularly those on the same EIDE or SCSI bus; sometimes a drive (hard drive or
CD-ROM) further down the chain can fail and can keep the primary drive from operating.
You may have to reconfigure the drive to make this work; for instance, on EIDE drives
you might have to reset jumpers on the primary drive to indicate that there are no
longer any slave drives connected. Also, don't forget to reseat the drive controller
board, if the system uses one. You can also relocate the drive controller board to
another slot; sometimes slots go bad.
- If the drive in question is a SCSI drive, check the drive's SCSI address and
the termination settings, as well as the terminator itself if there is one.
- If you're still not getting normal POST lights (and maybe not even startup noises)
try replacing the disk controller with an identical model set with the same settings
and try to boot again. Some failed drives will spin up, emit some loud "clicking"
noises, and then stop spinning. If this happens, recovering the drive is a lost cause
and it should be replaced.
- Don't forget to double-check the computer's CMOS settings to ensure they haven't
been cleared or changed; if the CMOS doesn't show the drives properly, you'll have
to re-detect them using whatever procedure is appropriate for the system.
- Boot the system with its Emergency Boot Disk (discussed in detail later in this
chapter). See if you can find the drive with FDISK, or even with the DIR command.
- Sometimes hard disks, particularly when they get old, experience problems starting
when they're cold. What happens is that the lubricant has a higher viscosity when
cold, and some of the metals in the drive shrink as a result of the colder temperature;
the result is increased friction and sometimes the drive motor can't overcome it
until the drive or the ambient temperature in the case warms up. If all the preceding
has failed and the drive still isn't starting or responding, try these last-ditch
attempts:
- 1. Leave the system powered on for an extended period (at least an hour) and
then try to restart the system with a warm boot. If you can do this in a warm environment,
it may help.
- 2. If the drive still isn't starting after going through this warm-up phase,
try a cool-down phase and leave the system powered off overnight, and try it again
first thing in the morning.
- 3. This is really a desperate move, but the author has seen it work before: Warm
up the system for an hour by leaving it on, and then give the hard drive a couple
of sturdy whacks with the heel of your hand, then do a warm boot. (Make sure you've
tried everything else first, because this can damage the drive!)
- These last-ditch attempts might at least get the drive to spin up and let you
recover any valuable data that you might otherwise lose. If you're lucky and recover
some data, immediately replace the drive because any drive that requires these extreme
measures shouldn't be trusted!
If all the preceding steps fail, you've most likely got a failed primary drive
on your hands. You'll need to replace it, reinstall Windows 98, reinstall all of
your applications, and then restore your data from backup.
TIP: Most hard disk drives have at least a one-year warranty. If
the drive has failed, you might be able to get a free replacement from the drive's
manufacturer or your computer's manufacturer.
Assuming you are getting normal POST behavior from the drive (the hard disk lights
flash normally during startup and normal sounds emanate from the drive), then you
start to get into other configuration problem possibilities. Check the following:
- Do you see the message Loading Windows 98 or the Windows 98 splash screen when
the computer boots? If so, then the drive itself is working (although it may contain
a lot of bad sectors); jump to the later section "Resolving System File Problems"
for instructions on dealing with your problem.
- Can you start Windows 98 in Safe Mode? If so, you probably don't have a hard
drive problem at all; continue troubleshooting the problem first according to the
later section "Resolving System File Problems" and then to Chapter 37,
"Tools and Strategies for Troubleshooting Windows 98."
- If the drive seems to be succeeding at POST, but the system never displays Loading
Windows 98, your hard disk configuration may have been changed, or your boot sector
on the drive may have become damaged. There are two things to check here:
- 1. Start the system with the EBD and see if you can do a DIR of your C: drive.
If so, perform a SCANDISK on the C: drive, and then use the SYS command that is part
of the EBD to reinstall the system files on the drive. Continue with the "Resolving
System File Problems" section.
- 2. Start the system with the EBD and use FDISK to see if the disk partition data
has been lost for some reason. You may be able to repartition the disk and have it
start functioning again, with your data mostly intact. However, this requires that
the partition be created exactly as it was when the system was last working, and
this is a chancy proposition at best. Chances are you'll have to repartition the
drive and reinstall Windows 98 and your applications.
Resolving Other Hardware Problems
Sometimes a system won't boot and the problem isn't due to the hard disk drive.
It might be due to another device in the system that's failing in some way and preventing
a startup, or it may be a number of different possible file problems. This section
deals with the former possibility, while the next two deal with the latter.
If the system starts to boot, displays the message Loading Windows 98 and possibly
the Windows 98 splash screen, but then stops booting, try these steps to find out
if there's other hardware in the system preventing startup:
- Try to start the system in Safe Mode. Hold down the left Ctrl key while the system
starts. This should display the Windows Startup menu, from which you can choose Safe
Mode. Safe Mode starts Windows 98 and loads as few drivers as possible. If you can
get into Safe Mode, use the Device Manager tab in the System Control Panel to search
for any reported hardware errors.
- If the startup fails when the Windows 98 splash screen is displayed, press the
Esc key. This should display the DOS startup screen and show you the status of any
non-Windows drivers that the system is loading. When diagnosing boot problems, you
should press Esc as soon as the splash screen appears, and once again when it reappears,
and then watch the messages as the drivers load; you might see one that's causing
the system to fail its boot. It's also possible that some command or driver was added
to the system's CONFIG.SYS or AUTOEXEC.BAT file and is preventing startup. If this
is the case, restart the system using the Windows Startup menu (hold down the left
Ctrl key while the system starts) and then choose Command Prompt Only from the menu.
Edit (the EDIT program is in C:\Windows\Command) the CONFIG.SYS and AUTOEXEC.BAT
files to remove any unneeded commands. You might want to remove all of the commands
in those fi