MS-DOS CONFIG.SYS File: Configuration and Device Drivers

Computer scienceUpdated on 23.04 KB

Summary

This document explains the purpose of the MS-DOS CONFIG.SYS file, the first file executed at startup, and how it configures hardware, memory and applications. It covers where the file is located, how to edit it as plain text, why changes require a restart, and how built-in and installable device drivers are loaded through commands such as DEVICE.

Key points

  • CONFIG.SYS is a plain text file that contains special commands to configure hardware and software for MS-DOS.
  • It is usually located in the root directory C:\ and is the first file run when MS-DOS starts.
  • It must be edited with a plain text editor such as Notepad, and changes take effect only after restarting the computer.
  • MS-DOS includes built-in device drivers for the keyboard, monitor, hard and floppy drives, and communication ports.
  • Installable device drivers, such as those for mice and memory cards, are loaded into memory by adding a DEVICE command to CONFIG.SYS.

Test yourself

Understanding MS-DOS CONFIG.SYS Configuration

The CONFIG.SYS file is crucial for configuring various system components, including MS-DOS, hardware, and applications, ensuring they function as intended.

System configuration information is primarily stored in the CONFIG.SYS file.

What is CONFIG.SYS?

It is a text file that contains special commands that configure computer components such as hardware (memory, keyboard, mouse, printer) for use by MS-DOS and applications.

It is the first file that runs when you start MS-DOS.

Location of CONFIG.SYS

It is usually located in the root directory, C:\.

CONFIG.SYS Runtime

MS-DOS executes this file each time you start your computer. However, if needed, you can instruct the system to skip it.

Why Modify CONFIG.SYS?

You can modify the system configuration to:

  • Customize how MS-DOS utilizes hardware, memory, and files.
  • Add new hardware or reconfigure existing components.
  • Specify commands for MS-DOS to execute upon PC startup.
  • Define multiple system configurations. For example, different users on the same computer can have distinct configurations.

This represents an advanced use of CONFIG.SYS commands.

Editing CONFIG.SYS

CONFIG.SYS can be edited to add or modify commands that configure the system.

To edit the file, you must use a text editor that saves files as plain text (ASCII), such as Notepad.

MS-DOS reads the CONFIG.SYS file only when the computer starts. Therefore, after making changes, the computer must be restarted for them to take effect.

CONFIG.SYS Syntax

Image

Image

Image

Hardware Device Settings

Each hardware device (mouse, monitor, printer, keyboard, disk drives, and memory cards) has unique characteristics that can be customized.

MS-DOS uses a special program called a device driver to control each device.

For instance, MS-DOS uses a built-in device driver to monitor how information is read to or from a floppy drive.

MS-DOS includes built-in device drivers for the keyboard, monitor, hard drives, floppy drives, and communication ports.

While these built-in device drivers generally require no special action to use, you can customize certain characteristics of them using commands within CONFIG.SYS.

Other devices, such as memory cards and mice, come with their own device drivers. These are called installable device drivers because you install them by adding a command to your CONFIG.SYS file. Several installable device drivers are included with MS-DOS.

To use an installable device driver, add a DEVICE command for each controller to CONFIG.SYS.

When MS-DOS starts, it loads the device driver into memory. For example, to load the MOUSE.SYS device driver located in C:\MOUSE, you would add a command like the following to CONFIG.SYS:

Image

When MS-DOS reads this command, the MOUSE.SYS driver loads into memory, where it remains and provides access to the mouse.

Generally, hardware device drivers are included in installation programs that automatically add the necessary commands to CONFIG.SYS.

Download

PDF Word HTML

FAQ

Where is the CONFIG.SYS file located?

It is usually located in the root directory, C:\. It is the first file that runs when MS-DOS starts.

Why must the computer be restarted after editing CONFIG.SYS?

MS-DOS reads the CONFIG.SYS file only when the computer starts, so changes must be applied with a restart.

How do you load a device driver through CONFIG.SYS?

Add a DEVICE command for each controller to CONFIG.SYS. When MS-DOS starts, it loads the driver into memory, for example MOUSE.SYS from C:\MOUSE.

Test yourself

Flashcards

Click a card to see the answer.

Quiz

1. What is CONFIG.SYS in MS-DOS?
2. Where is CONFIG.SYS usually located?
3. What text editor is recommended for editing CONFIG.SYS?
4. When does MS-DOS read the CONFIG.SYS file?
5. Which command is used to load an installable device driver?
6. Which device uses an installable driver such as MOUSE.SYS?

Questions generated by AI from the document: check the answers against the text.