The A+ Exams Guide: (Exam 220-301), (Exam 220-302) (TestTakers Guides)

 < Day Day Up > 


Three files make up the core of DOS: IO.SYS, MSDOS.SYS (which are hidden system files), and COMMAND.COM (which is a visible file). All three of these files are located on the primary active boot partition and are stored at the root of drive C:. All three files are required to successfully boot a system into DOS. They are also the minimum files required for booting Windows 9.x to a DOS prompt. If one of these files is corrupt or missing, the message “Missing or unknown operating system” will be displayed.

Although these three system files meet the minimum requirements to boot to DOS on a Windows 9.x OS, the complete DOS boot order is as follows.

  1. IO.SYS—Interacts with the BIOS to determine the hardware environment.

  2. MSDOS.SYS—Houses the DOS kernel and interacts with programs and devices.

  3. CONFIG.SYS—Used primarily to load device drivers.

  4. COMMAND.COM—Translator or interpreter of commands entered.

  5. AUTOEXEC.BAT—Used to configure specific user settings.

    Note 

    The exam may ask for the overall system starting order, regardless of what operating system you are running. The overall system start order is POST, BIOS, Boot Sector, and GUI. See The Windows 9.x Start-Up Process in Chapter 11 for further details.

The major functions of the DOS system and configurations files, as well as their relationships with newer operating systems, are explained next.

IO.SYS

IO.SYS is a binary (uneditable) executable hidden file that is loaded first when a computer system is booted. IO.SYS works with the systems BIOS to determine what hardware is to be used by the operating system. IO.SYS is like a scout that discovers the physical layout of a system by looking at the CONFIG.SYS file, which is used to load hardware drivers and control DOS memory. Keep in mind that Windows 9.x comes with a newer version of IO.SYS that replaces the old IO.SYS and MSDOS.SYS utilized in ‘pure DOS.’ The new version of IO.SYS eliminates the need for use of the AUTOEXEC.BAT and CONFIG.SYS files in newer operating systems. Newer operating systems still allow the use of AUTOEXEC.BAT and CONFIG.SYS to maintain backward compatibility with legacy programs and hardware.

Note 

Binary files consist of 0s and 1s, and are basically unreadable without being interpreted. Text files contain readable characters that can be understood by the average human being.

MSDOS.SYS

MSDOS.SYS is a hidden system text file that contains the DOS kernel. The kernel is the core software code of an OS that is retained in memory to control all processes.

Note 

The kernel that resides in the MSDOS.SYS file and the kernel used in newer operating systems are two totally separate things.

MSDOS.SYS is loaded after IO.SYS and is responsible for the interaction of software applications and hardware settings. MSDOS.SYS controls whether the computer will be booted into a DOS, Windows 3.x, Windows 9.x, or Windows Me GUI environment. If you want to set up Windows 9.x or Windows Me for dual booting purposes, you can modify the BootGUI=0 to BootGUI=1 entry under [Options] in the MSDOS.SYS file.

Note 

The BOOT.INI file is modified in Windows NT 4.0, Windows 2000, and Windows XP for dual booting purposes.

CONFIG.SYS

The CONFIG.SYS file is the first editable DOS configuration text file that you can modify at system start-up. Its primary function is to load 16-bit real mode device and memory management drivers for a DOS environment. At system start-up, MSDOS.SYS loads the device drivers and instructions specified in the CONFIG.SYS file before continuing on to AUTOEXEC.BAT.

In DOS, typing “EDIT CONFIG.SYS” or “EDIT AUTOEXEC.BAT” and pressing Enter at the DOS command prompt opens the DOS utility editor known as EDIT.COM. You can use EDIT.COM to view and make changes to the CONFIG.SYS and AUTOEXEC.BAT files. This can be very useful for troubleshooting if you encounter errors on start-up with settings in either of these files.

The CONFIG.SYS is available in Windows 9.x and Windows Me for backward compatibility with legacy devices. It can be edited by running the SYSEDIT program at the Start > Run line in Windows 9.x. Simply click Start > Run, then type in “SYSEDIT”, and press Enter. Windows NT 4.0, Windows 2000, and Windows XP have basically replaced the CONFIG.SYS file with the file CONFIG.NT. You can also edit either of these files by using any available text editor in Windows, such as Notepad.

Next, we look at a typical CONFIG.SYS file that is used to configure hardware- and memory-related settings for a DOS Windows environment. Each of the lines in the following CONFIG.SYS file are described.

DEVICE=C:\WINDOWS\HIMEM.SYS DEVICE=C:\WINDOWS\EMM386.EXE NOEMS DEVICE=C:\DOS\SETVER.EXE FILES=40 STACKS=9,256 BUFFERS=10 FCBS=16,0 DOS=HIGH,UMB SHELL=C:\DOS\COMMAND.COM C:\DOS /P /E:1024 DEVICE=C:\WINDOWS\IFSHLP.SYS DEVICEHIGH=C:\WINDOWS\COMMAND\ANSI.SYS DEVICEHIGH=C:\MTMCDAI.SYS /D:MSCD0001 LASTDRIVE=Z

COMMAND.COM

As previously mentioned in this chapter, COMMAND.COM is responsible for translating what you input into the computer into information that the OS can understand. COMMAND.COM processes information entered and passes it back to MSDOS.SYS, where the operating system’s kernel resides.

In DOS, COMMAND.COM is responsible for providing a user interface, such as the DOSSHELL or command prompt. With a default installation of DOS, Windows 3.x, Windows 9.x, or Windows Me, COMMAND.COM is stored in the root directory of the C: drive. Windows 9.x and Windows Me also store a backup copy of COMMAND.COM in the C:\Windows directory. The AUTOEXEC.BAT file uses the SET COMSPEC= command to place COMMAND.COM in a location other than the root directory of C:. With Windows NT, Windows 2000, and Windows XP, COMMAND.COM is stored in the C:\WINNT\SYSTEM32 directory.

It is important to note that the DOS COMMAND.COM file should be from the same version of DOS installation as the IO.SYS and MSDOS.SYS files. If it is not, you may receive the error message “Incorrect DOS version” at system start-up.

AUTOEXEC.BAT

The AUTOEXEC.BAT (automatically executed batch) file is the second editable DOS batch file that is used at start-up to create an environment for the operating system. The AUTOEXEC.BAT file sets the stage for programs to run. It holds Terminate and Stay Resident (TSR) programs, such as DOSKEY and MOUSE.COM, which are held in RAM, and can be quickly accessed and easily loaded by the system. The AUTOEXEC.BAT sets environment variables with the PATH= statement, which is used to tell the system where to look for files and executable programs. The AUTOEXEC.BAT file is the last program that is run in the DOS boot sequence. It is important to remember that any command that is in the AUTOEXEC.BAT file can be run from the command prompt.

Now we will look at a typical AUTOEXEC.BAT file that is used to configure user-related and environment settings for a DOS Windows environment.

Each of the lines in the following AUTOEXEC.BAT file is described following the file listing.

@ECHO OFF SET COMSPEC=C:\DOS\COMMAND.COM SET TEMP=C:\TEMP PROMPT $P$G PATH=C:\;C:\WINDOWS;C:\DOS REM LH C:\WINDOWS\COMMAND\MSCDEX.EXE /D:MSCD0001 DOSKEY CLS LH C:\MOUSE\MOUSE.EXE WIN


 < Day Day Up > 

Категории