IDLEHALT (CONFIG.SYS directive)
| Company type | Configuration file |
|---|---|
| Industry | Operating systems |
| Founded | 1983 |
| Products | System configuration for DOS and OS/2 |
CONFIG.SYS serves as the main configuration file for DOS and OS/2 operating systems. This plain text file, written in ASCII, contains initialization commands that the OS's DOS BIOS—typically found in IBMBIO.COM or IO.SYS—interprets during the boot sequence. CONFIG.SYS was first introduced with DOS version 2.0.
Usage
The directives within CONFIG.SYS are responsible for setting up DOS to handle devices, applications, and memory allocation. Once CONFIG.SYS has been processed, DOS launches the command interpreter specified in the SHELL directive; if none is specified, it defaults to COMMAND.COM, which then executes AUTOEXEC.BAT.
This file primarily consists of name=value pairs that adjust system parameters or load components such as device drivers and terminate-and-stay-resident programs (TSRs). CONFIG.SYS is located in the boot drive’s root directory.
The same filename is also utilized by (DCP), a variant of MS-DOS developed by East-German company VEB Robotron.
Certain DOS variants prioritize alternative filenames over CONFIG.SYS:
Systems like Concurrent DOS 386, Concurrent DOS XM, Multiuser DOS, System Manager, and REAL/32 use CCONFIG.SYS (short for "Concurrent") instead of CONFIG.SYS. Some Multiuser DOS releases rely on CCONFIG.INI, while REAL/32 looks for MCONFIG.SYS. These platforms support extra configuration options stored in a binary file named CCONFIG.BIN, typically modified through CONFIG.EXE.
In DR DOS 3.31, PalmDOS 1.0, Novell DOS 7, OpenDOS 7.01, and DR-DOS 7.02 and later versions, DCONFIG.SYS (derived from "DR DOS") takes precedence over CONFIG.SYS. This setup facilitates disk compression and multi-boot configurations by allowing multiple configuration files. OpenDOS 7.01 and DR-OpenDOS 7.02 also check for ODCONFIG.SYS, while certain DR-DOS 7.02+ versions search for DRCONFIG.SYS.
Starting with DR DOS 6.0, the command SYS /DR:ext enables users to modify default system file extensions to maintain several sets of system files within a single root directory, selectable through boot loaders such as LOADER included with Multiuser DOS and DR-DOS 7.x releases. The SHELL command supports specifying alternative AUTOEXEC.BAT files using /P[:filename.ext], a feature also recognized by enhanced shells like 4DOS. The CHAIN=filespec directive allows continuation of configuration processing from another file, which may reside outside the root directory; DR-DOS 7.02+ further permits jumping to specific labels inside chained files.
From DR-DOS 7.03 onward, the SYS /A option copies corresponding CONFIG.SYS and AUTOEXEC.BAT files alongside system files during setup.
FreeDOS employs a comparable configuration file named FDCONFIG.SYS; RxDOS version 7.24 and above uses RXCONFIG.SYS; while PTS-DOS utilizes CONFIG.PTS.
Both CONFIG.SYS and AUTOEXEC.BAT are present in the root directory of Windows 95 and Windows 98 boot drives but generally remain unpopulated. Windows Me does not process CONFIG.SYS at startup; instead, it retrieves environment variables from the Windows Registry (HKLM\System\CurrentControlSet\Control\SessionManager\Environment).
In the case of FlexOS, CONFIG.SYS is a binary configuration file that specifies resource managers and device drivers loaded during system initialization.
Example
An example CONFIG.SYS configuration for MS-DOS 5: <syntaxhighlight lang="ini" line="1"> DOS=HIGH,UMB DEVICE=C:\DOS\HIMEM.SYS DEVICE=C:\DOS\EMM386.EXE RAM DEVICEHIGH=C:\DOS\ANSI.SYS FILES=30 SHELL=C:\DOS\COMMAND.COM C:\DOS /E:512 /P </syntaxhighlight>
:;*?!
- Marks labels within CONFIG.SYS to serve as targets for , , , and commands.
- Functions similarly to , also used for inline comments following other directives. (Note: In MS-DOS/PC DOS, inline comments enclosed in double quotes are not ignored.)
- Used at the start of inline comments along with the ; directive.
- Prompts a Yes/No confirmation before executing subsequent CONFIG.SYS commands. (FreeDOS lacks support for custom messages but allows conditional execution through boot menus.) DOS version 6.0 and later offers comparable functionality via appending to the directive (e.g., ).
- Forces immediate execution of the next CONFIG.SYS command without conditions.
ATemplate:NbndC
- Determines whether programs can be interrupted upon encountering errors.
- Sets drives to record file access timestamps on FAT filesystems.
- Executes commands conditionally on AT-compatible hardware.
- Manages boot menu functionality.
- Adjusts the verbosity level of error messages.
- Changes the default serial port driver (COM1 through COM4) used for the AUX device.
- Disables access to character devices outside of the virtual \DEV directory.
- Loads fundamental device drivers into conventional memory.
- Produces a beep sound even if notification sounds are disabled.
- Specifies which operating system to boot next.
- Enables or disables extended Ctrl+C signal checking.
- Defines the quantity of disk buffers allocated.
- Similar to BUFFERS but allocates buffers in High Memory Area or Upper Memory Blocks.
- Sets the maximum number of cache blocks allocated dynamically.
- Defines maximum idle time before unused cache blocks are returned to system memory.
- Sets maximum time before dirty cache blocks are written back to disk.
- Loads external programs during CONFIG.SYS processing and pauses until they return control.
- Controls the Caps Lock key status on the keyboard.
- Specifies the driver name for CD-ROM hardware support.
- Determines the number of buffers allocated for CD-ROM operations.
- Continues processing CONFIG.SYS from another file or label.
- Specifies the type of system clock used.
- Clears the display screen.
- Defines OEM codepage(s) in use.
- Indicates CMOS RAM address settings.
- Configures colors utilized in boot menus.
- , ;, ;, ;
Each sets count, logical order, I/O port address, and timeout parameters for corresponding COM ports (available from DR-DOS 7.02 onwards).
- (PTS-DOS) specifies DMA buffer settings.
Defines characters that introduce inline comments or causes lines to be ignored (behavior varies by DOS version).
Enables internationalization features and configures related settings (dependent on DOS version).
Sets cursor position for configuration menus (introduced in DR DOS 6.0 and later).
Supports codepage switching functionality (available in MS-DOS versions 4.00-4.01). Conditional CPU directives control execution based on CPU model and speed (e.g., CPU88, CPU386).
DTemplate:NbndF
- Adjusts relocation settings for drive descriptor tables.
- Specifies segment address in memory for multi-sector disk data deblocking processes.
- Activates internal debugger support features.
- Manages boot menu operations.
- Loads device drivers into conventional memory space.
- Loads device drivers into upper memory areas (equivalent to in DRDOS 5.0).
- Configures country codes and codepage information for keyboard, screen, and printer devices.
- Sets sizes for cache memory allocations.
- Defines floppy disk compatibility modes.
- Specifies fonts used for display output.
- Controls loading of DOS into high memory and use of upper memory blocks (similar to in DRDOS 5.0).
- Loads DOS system tables such as BUFFERS, FCBS, FILES into upper memory areas.
- Designates an alternative directory path for DOS system files.
- Specifies search paths for data files used by DOS utilities.
- ; Defines parameters related to physical disk drives.
- ; Sets parameters for unrecognized or unknown drives.
- ; See .
- ; Enables error log creation and designates drive location for
PDUMP.nnnfiles. - ; Displays a text message on screen during boot or processing.
- ; Outputs messages containing ANSI escape sequences for formatting purposes.
- ; Adds additional verification steps when launching programs.
- ; Defines assumed error or return codes following specific commands.
- ; Controls A20 gate state upon program startup.
- ; Terminates CONFIG.SYS processing prematurely except for certain SWITCHES and SHELL commands.
- ; Sets hash table size utilized in accelerating file opening operations—differs from MS-DOS/PC DOS FASTOPEN driver behavior.
- ; Determines number of cached File Control Blocks (FCBs) that can be opened simultaneously (shares buffer with FILES under DR-DOS).
- ; Similar to FCBS but loads FCBs into upper memory areas instead of conventional memory.
- ; Manages boot menu features within CONFIG.SYS processing flow.
- ; Specifies maximum number of files that can be opened at once by DOS system calls.
- ; Same as FILES but loads file handles into upper memory regions rather than conventional memory space.
- ; Includes execution of specified subsections within CONFIG.SYS files (see IGNORE directive).
GTemplate:NbndI
- Waits for a key press or timeout, then assigns the error level to the ASCII value of the key or 1024 if timed out.
- Resumes processing of CONFIG.SYS at the indicated label.
- Continues nested CONFIG.SYS processing at a given label and then returns to the prior point.
- Refer to , , or for additional details.
- See related commands , , and .
- Consult for further information.
- Refer to or for context.
- See also or commands.
- Consult for more details.
- Loads a TSR program into memory following relocation of the DOS data segment. Compare with INSTCDEX.
- Refer to , , or for related functions.
- See also .
- Consult or for additional context.
- Activates a console and command line history buffer with advanced pattern search capabilities.
- Defines the address of the HMA segment.
- Configures energy-saving behavior for the HLT instruction.
- Enables scanning for boot sector viruses.
- Loads file systems that can be installed dynamically.
- Prevents execution of specified CONFIG.SYS subsections.
- Permits certain applications to operate at ring 2 for direct hardware I/O access.
- Incorporates directives from another menu block, emulated via GOSUB/RETURN in DR-DOS environments.
- Sets the status of keyboard Insert mode.
- Installs a TSR program into memory.
- Installs a TSR program into upper memory, equivalent to HIINSTALL in DR DOS 5.0.
- Installs a TSR program after relocating the DOS data segment, similar to INSTALL.
- Adjusts PIC interrupt priorities by rotating them so that a specified interrupt receives highest priority.
KTemplate:NbndM
- Defines the keyboard layout configuration.
- Specifies the relocated address of the keyboard buffer.
- Sets the maximum number of drives accessible by DOS.
- Similar to LASTDRIVE but additionally loads Current Directory Structure into upper memory.
- Lists directories where DLLs are searched for.
- Manages support for legacy programs.
- Determines the number of file locks allowed concurrently.
- Configures support for displaying boot logos.
- Sets parameters such as count, order, I/O address, and timeout for the LPT1 parallel port device.
- Applies identical settings as LPT1 but for LPT2 device configuration.
- Mirrors LPT1 settings for LPT3 device configuration.
- Enables and configures settings for the LPT4 parallel port device.
- Defines wait duration before increasing process priority levels.
- Sets strategy for memory allocation management.
- Specifies default allocation parameters for DOS memory usage.
- Defines options available within system menus.
- Configures menu color schemes, which can be emulated under DR-DOS systems.
- Sets a default menu block, also emulatable in DR-DOS environments.
- Defines multiple menu blocks, with emulation support under DR-DOS platforms.
- Enables operations involving multiple disk tracks simultaneously.
- Continues processing CONFIG.SYS from a new file, optionally after loading a device driver and setting the %NEWFILE% environment variable.
NTemplate:NbndQ
- Defines the default character used for No () responses in Yes/No/Resume prompts.
- Sets keyboard Num Lock on or off during startup or configuration.
- Enables conditional execution based on the last error code returned, similar to .
- Displays text on screen and waits for a key press, comparable to DR-DOS commands and .
- Requires user confirmation when errors occur during CONFIG.SYS processing.
- Configures buffer sizes allocated to LPT (parallel) ports.
- Enables conditional command execution only on PC-compatible machines.
- Sets scheduler priority levels for processes or tasks.
- Assigns priority specifically for disk I/O-bound programs.
- Changes default printer device driver assignment from LPT1 to either LPT3 or LPT4 ports.
- Controls whether DOS applications are permitted to run on the system.
- Loads an alternative user interface shell environment during startup.
- Enables conditional execution exclusively on IBM PS/1-compatible machines.
- Restricts conditional execution to IBM PS/2-compatible hardware platforms.
- Suppresses output directed to STDOUT.
RTemplate:NbndT
- Activates automatic system restart upon encountering errors.
- Permits inclusion of comments within CONFIG.SYS files (ignored in PTS-DOS).
- Reserves a drive letter, preventing its use by local block devices.
- Defines the default character for Resume () prompts.
- Enables returning from nested CONFIG.SYS processing to the previous GOSUB or SWITCH point, optionally supplying a return code.
- Sets the size of real mode memory available.
- Allows parallel loading of programs specified in CONFIG.SYS, functioning similarly to CALL or INSTALL commands in DOS.
- Determines whether the first character of deleted files is stored in FAT directory entries.
- Configures video mode (in FreeDOS) or screen access methods (in PTS-DOS).
- Controls the Scroll Lock key status on the keyboard (on or off).
- Assigns environment variables.
- Loads the command interpreter shell.
- Similar to SHELL but includes a size parameter to pre-allocate COMMAND.COM in HMA or UMBs, reducing fragmentation when using third-party shells.
- Sets keyboard modifier states such as Shift Lock, Num Lock, Scroll Lock, and Insert mode.
- Determines whether files are closed upon pressing Ctrl+Alt+Del.
- Skips the Power-On Self Test (POST) during reboot sequences.
- A compatibility placeholder ignored by most DR DOS versions.
- Specifies the number of hardware interrupt stacks (applicable to DOS 3.2 and Novell DOS 7 and later).
- Defines default stack size for newly created threads (Embedded DOS 6-XL).
UTemplate:NbndZ
- Configures DOS to allocate a specified segment for Upper Memory Block (UMB) usage.
- Designates the UMB management server.
- Defines address ranges allocated for UMB RAM areas.
- Enables or disables disk write verification processes.
- Sets the DOS version string reported to applications.
- Manages VGA display status settings.
- Specifies the current video mode configuration.
- Activates virtual DMA capabilities.
- Controls processor Virtual Mode Extensions (VME) functionality.
- Configures VxD drivers utilized by Windows environments.
- Sets system parameters supporting Windows operation.
- Manages relocation of the Extended BIOS Data Area (EBDA).
- Allows conditional execution on XT-compatible machines.
- Configures integrated Year 2000 compliance support.
- Defines the default character used for Yes responses in prompts.
- Enables deletion tracking features.
Issues
Although the system can start without CONFIG.SYS or AUTOEXEC.BAT files, these are crucial for comprehensive OS customization and meeting software prerequisites. Corruption or loss of these files necessitates troubleshooting efforts.
When CONFIG.SYS lacks a SHELL directive—or if it is missing or damaged—DOS attempts to locate COMMAND.COM in the root directory of the boot drive. Versions prior to 6.0 will fail to boot if COMMAND.COM is not found. Starting with MS-DOS 6.0, PC DOS 6.1, Novell DOS 7, and subsequent releases, users are prompted to specify a command processor path if COMMAND.COM is absent or fails to load.[1] This mechanism also facilitates limited runtime shell replacement without requiring a reboot.
COMMAND.COM from MS-DOS 7.0 and later versions is incompatible with DR-DOS,[2] impacting dual-boot configurations. DR-DOS versions 7.02 and beyond enforce SHELL directives when operating in skip, trace, or step modes, prompting users to input valid shell filenames before loading COMMAND.COM.[3][2] Pressing defaults back to the previously used shell.
CONFIG.SYS file size limitations differ across systems: MS-DOS and PC DOS restrict file size to a few kilobytes (up to 64 KB in newer iterations), whereas DR-DOS imposes no practical limit due to its line-by-line parsing approach.[1] MS-DOS compiles CONFIG.SYS into an internal tokenized format sorted by directive type—loading device drivers before TSRs—while DR-DOS processes directives sequentially, allowing precise control over load order and conditional execution based on hardware or software conditions.[3][4] This capability supports integration of temporary programs via INSTALL, enhancing system flexibility.
Limits on SHELL command line length vary: MS-DOS/PC DOS versions 2.0 through 4.01 accepted up to 31 characters, with later editions allowing up to 128 characters.[1] DR-DOS supports command lines up to 255 characters.[1] It should be noted that CONFIG.SYS directives do not accommodate long filenames.
Dual Booting DOS and Windows 9x
When Windows 95 is installed over a pre-existing DOS or Windows system, the files CONFIG.SYS and AUTOEXEC.BAT are renamed to CONFIG.DOS and AUTOEXEC.DOS respectively, enabling dual boot functionality between Windows 9x and DOS. During a DOS boot, these files are temporarily reverted to their original names, CONFIG.SYS and AUTOEXEC.BAT. Additionally, Windows 95 versions of these files are saved as CONFIG.W40 and AUTOEXEC.W40.
In setups where Caldera DR-DOS 7.02 or 7.03 coexists with Windows 95, the Windows CONFIG.SYS and AUTOEXEC.BAT files remain intact. Instead, DR-DOS relies on startup files named DCONFIG.SYS (a traditional filename) and AUTODOS7.BAT.
OS/2 / Windows NT
OS/2 makes extensive use of CONFIG.SYS to load drivers and set environment variables prior to launching its graphical user interface.
Within the OS/2 subsystem of Windows NT, CONFIG.SYS was presented to OS/2 applications as a file but was actually maintained within the system registry.
There are numerous undocumented CONFIG.SYS commands specific to OS/2.
CONFIG.SYS continues to be utilized by OS/2-based systems such as eComStation and ArcaOS.
See also
- IBMBIO.COM / IO.SYS
- IBMDOS.COM / MSDOS.SYS
- CONFIG (environment variable)
- AUTOEXEC.BAT
- COMMAND.COM
- List of DOS commands
External links
- Detailed information on AUTOEXEC.BAT and CONFIG.SYS at Computer Hope
- Overview of Windows 98 / MS-DOS 7.10 CONFIG.SYS directives (archived)
- Caldera’s CONFIG.SYS Command Reference (archived) – summary of DR-DOS 7 directives
- Guide to FreeDOS CONFIG.SYS directives
- User Manual for PTS-DOS 2000 Pro including CONFIG.SYS directives (archived)
- Unofficial German FAQ for PTS-DOS covering CONFIG.SYS directives (archived)
- ↑ 1.0 1.1 1.2 1.3 Cite error: Invalid
<ref>tag; no text was provided for refs namedPaul_1997_NWDOSTIP - ↑ 2.0 2.1 Cite error: Invalid
<ref>tag; no text was provided for refs namedPaul_2004_COMMAND - ↑ 3.0 3.1 Cite error: Invalid
<ref>tag; no text was provided for refs namedPaul_1997_OD-A3 - ↑ Cite error: Invalid
<ref>tag; no text was provided for refs namedPaul_2004_YESCHAR