12.2 DOS Troubleshooting Issues
12.2.1 System boot problems
Observing the steps of a boot up process can reveal a great deal about the health of the system and what is causing problems. The possible causes of errors can be eliminated or determined during the boot up procedure. If the problem lies in the boot up process, only some or possibly even none of those steps will be observed. Knowing the details of each step of the boot process will help determine what section failed if the system will not boot up past that step. For example, if the system boots up all the way to the point where it is checking the floppy drive, and the floppy drive light does not come on, then the problem exists in the floppy drive.

The Bootable Disk
One tool that every system administrator should have is a bootable disk. Often systems have issues that cannot be resolved, or the operating system has become so corrupt that despite all efforts the system will not start or boot up. A bootable disk allows administrators or service technicians to boot from a diskette instead of the hard drive. This diskette can be used to fix issues that may arise during the lifetime of the computer. If a system is unable to boot, simply insert the disk into the floppy drive and restart the computer, making sure that the BIOS is set to boot from the floppy drive. The disk possesses the necessary files that are required to boot the system and bypass the operating system files on the hard drive that are corrupted. Booting from a bootable disk will bring up a DOS prompt to allow the administrator to recopy files, inspect the hard drive partition, or reformat the drive if the bootable floppy has the fdisk executable on it. It will enable the administrator to navigate through the files on the hard drive for problem inspection.

Hidden Files
A hidden file is a file with a special hidden attribute turned on, so that the file is not normally visible to users. For example, hidden files are not listed when the DOS
dir command is executed. However, most file management utilities allow the viewing of hidden files.

DOS hides some files, such as msdos.sys and io.sys, so that users will not accidentally corrupt them. These two files are the special files in the operating system boot record. Without them, the system cannot boot up successfully. The hidden attribute for any normal file can also be turned on, making it invisible to casual snoopers. This also prevents users from corrupting those files. The attrib command is used to view and change file attributes.

The Command Interpreter
The command.com program is known as the command interpreter. It is the most important system file, since the computer cannot boot without it. command.com contains the most commonly used commands of the operating system. For example, when a DOS command is entered at the DOS prompt, the command.com program first examines it to see if it is an internal or external DOS command. Internal commands are understood by the command.com program and are executed immediately. External commands are stored in the \DOS directory and the command.com file must browse through the \DOS directory to find the command program.

When DOS runs an application, command.com finds the program and then loads it and gives it control of the system. When the program is shut down it passes control back to the command interpreter.

DOS Switches
Many of the common DOS switches were discussed in Chapter 4, "Operating System Fundamentals". In this chapter, a few more switches that are useful in troubleshooting software problems are added to the list. As a review, DOS switches are used to configure DOS commands to perform specific functions. For example, DOS switches are used in the config.sys file to configure DOS to emulate different hardware configurations. The
switches command is useful when using older applications with a new enhanced keyboard that is incompatible with the operating system. Entering the line switches=/K in the config.sys file will configure the keyboard to act like a standard keyboard.

Using these switches can be helpful when troubleshooting computer systems. They are important to remember because they can be used to manipulate the DOS commands.

The following is a list of examples of common switches:

  • /K – Causes an enhanced keyboard to act as though it were an older, standard keyboard.
  • /F – Removes the two-second delay that occurs when the "Starting MS-DOS" message is displayed on the screen (DOS Version 6 only).
  • /N – Disables the F5 and F8 keys during system start up (DOS Version 6 only).
  • /W – Tells DOS that the wina20.386 file has been moved to a directory other than the root directory.

Bootable Disk Utility Files
A DOS boot disk, as mentioned in Chapter 4, can be used to boot the system to the DOS prompt. This allows a system having boot problems to start, so troubleshooting can begin. In this regard, there are a few useful utility files that should be added to the boot disk. These are the format and fdisk utilities. The significance of these utilities is discussed next. Figure shows a list of common files associated with a boot disk.

Format
In the event that the operating system becomes so corrupted that it is beyond repair, the
format command can be used to erase the disk and start over. The boot up disk allows the administrator to boot the computer to a DOS prompt. The format utility allows the reformatting of the hard drive if needed, however, all of the information on the hard drive will be erased. The format command is also used to prepare a new disk for use with an operating system.

Fdisk
Fdisk is one of the most commonly used MS-DOS commands, even with newer operating systems such as Windows 98, 2000, and XP. Fdisk allows the technician to delete and create partitions on the hard drive. This is another useful tool that will help when troubleshooting a computer system. The boot disk will allow the technician to boot to a DOS prompt. Once this is completed, type fdisk to enter the screen. It gives access so changes can be made to the systems hard disk partitions.

Sometimes during troubleshooting calls, the computer will be unable to boot. This typically means that the Master Boot Record has been damaged or corrupted in some way. A virus can cause this or the files could have just been deleted for some reason. The Master Boot Record (MBR) is a program that is executed when a computer boots up. Typically, the MBR resides on the first sector of the hard drive. The program begins the boot process by looking up the partition table to determine which partition to use for booting. It then transfers program control to the boot sector of that partition, which continues the boot process. In DOS and Windows systems, the MBR is created with the fdisk/mbr command. This command is used to rewrite the Master Boot Record so the system will be able to boot up once again.

Bootable Configuration Files
The two main configuration files that a computer uses to boot up are config.sys and autoexec.bat. Config.sys is a special file that contains setup or configuration instructions for the computer system. The commands in this particular file configure the DOS program for use with devices and applications in the system and set up the memory managers in the system. Once the commands in config.sys have been carried out, DOS begins searching for the autoexec.bat file. This file contains a list of DOS commands that will automatically execute when DOS is loaded into the system (config.sys and autoexec.bat  are discussed more thoroughly in Chapter 4).

Without these files, or if they were corrupted, the system would still boot. However, these two files are essential for the complete boot up process to occur with the DOS operating system. They contain information that is used for things like changing the operating system for personal uses. They also contain the requirements of different software application packages. A troubleshooting call would result if either of these two files became damaged or corrupted.