SYSTEMPOOL (CONFIG.SYS directive)
| Company type | Configuration file |
|---|---|
| Industry | Operating systems |
| Founded | 1983 |
| Products | System configuration directives for DOS and OS/2 |
CONFIG.SYS serves as the chief configuration file for DOS and OS/2 operating systems. This plain text file, written in ASCII, holds user-defined setup instructions that the operating system's DOS BIOS (commonly found in IBMBIO.COM or IO.SYS) evaluates during the system boot process. CONFIG.SYS made its debut with DOS version 2.0.
Usage
The directives within CONFIG.SYS tailor DOS to manage devices, applications, and memory allocation. Once CONFIG.SYS processing concludes, DOS initiates the command interpreter specified by the SHELL directive or defaults to COMMAND.COM, which subsequently runs AUTOEXEC.BAT.
Primarily, this file consists of name=value pairs that configure parameters or load components such as device drivers and terminate-and-stay-resident programs (TSRs) into memory.
In DOS environments, CONFIG.SYS is located in the root directory of the system's boot drive.
The same filename is also utilized by (DCP), an MS-DOS variant developed by East-German manufacturer VEB Robotron.
Certain DOS editions check for alternative filenames that override CONFIG.SYS:
- Advanced releases of Concurrent DOS 386, Concurrent DOS XM, Multiuser DOS, and REAL/32 prefer CCONFIG.SYS or CCONFIG.INI, storing configuration data within a binary file called CCONFIG.BIN. These are commonly edited using a configuration tool named CONFIG.EXE.
- In DR DOS 3.31, PalmDOS 1.0, Novell DOS 7, and DR-DOS versions 7.02 and later, DCONFIG.SYS takes precedence over CONFIG.SYS. Originating from disk compression software setups, it also facilitates multi-boot arrangements.
- OpenDOS 7.01 and DR-OpenDOS 7.02 seek out ODCONFIG.SYS, while some DR-DOS 7.02+ variants look for DRCONFIG.SYS.
From DR-DOS 6.0 onward, users can alter default system file extensions with the SYS /DR:ext command. This allows multiple sets of system files to coexist and be selected by boot loaders like LOADER included in Multiuser DOS and DR-DOS 7.x releases.
The SHELL command supports specifying alternate AUTOEXEC.BAT files using the /P[:filename.ext] option; in this mode, COMMAND.COM accepts extensions other than .BAT—a feature also available in 4DOS.
Starting with DR-DOS 6.0+, a CHAIN=filespec directive enables continuation of configuration loading from another file, which can reside outside the boot drive's root directory. Versions 7.02 and above extend this with CHAIN=filespec,label, allowing jumps to designated labels inside configuration files.
DR-DOS 7.03+ introduces a SYS /A switch that copies matching CONFIG.SYS and AUTOEXEC.BAT files alongside system files during setup.
FreeDOS uses FDCONFIG.SYS, while RxDOS 7.24 and newer employ RXCONFIG.SYS. Similarly, PTS-DOS utilizes CONFIG.PTS for equivalent purposes.
Although both CONFIG.SYS and AUTOEXEC.BAT exist in the root directories of Windows 95 and Windows 98 boot drives, they are generally left empty.
Windows Me does not process CONFIG.SYS during startup; instead, it loads environment variables directly from the Windows Registry at:
- HKLM\System\CurrentControlSet\Control\SessionManager\Environment
In contrast, under FlexOS, CONFIG.SYS is a binary configuration file that specifies resource managers and device drivers to be loaded at boot time.
Example
Here is a sample 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>
:;*?!
- Serves as labels within CONFIG.SYS to mark jump destinations for commands such as , , , , and .
- Functions similarly to , allowing inline comments after other directives. (Note that MS-DOS/PC DOS handles inline comments differently when enclosed in quotes.)
- Initiates inline comments, used alongside the ; directive.
- Requests user confirmation with Yes/No prompts before executing subsequent commands. (FreeDOS supports conditional boot menus but lacks customizable messages.) DOS version 6.0 and later offer a comparable feature by appending to a directive.
- Forces the immediate execution of the following CONFIG.SYS command regardless of conditions.
ATemplate:NbndC
- Determines whether programs can be aborted upon encountering errors.
- Controls whether file access date stamps are recorded on drives formatted with FAT file systems.
- Enables conditional execution exclusively on AT-compatible computers.
- Boot management utility.
- Adjusts verbosity level of error messages displayed.
- Alters the default serial device driver assigned to the AUX device.
- Prevents character devices from being accessible outside the virtual \DEV directory.
- Loads a fundamental device driver into memory.
- Produces a brief beep sound even when audible alerts are disabled.
- Specifies which operating system to boot next.
- Enables or disables extended Ctrl+C interrupt checking.
- Sets the quantity of disk buffers allocated.
- Similar to BUFFERS but loads buffers into High Memory Area (HMA) or Upper Memory Blocks (UMB).
- , , (Embedded DOS 6-XL only)
- Manages cache size and timing parameters.
- Loads executable programs within CONFIG.SYS, pausing processing until they return control.
- (DR-DOS 7.02+)
- Defines Caps Lock state during system startup.
- , (PTS-DOS only)
- Configures CD-ROM driver names and buffer quantities.
- (DR DOS 5.0+)
- Continues processing CONFIG.SYS from another file or label.
- , , and other PTS-DOS commands
- Manage system clock, clear screen, among others.
- , (OS/2 only)
- Specifies OEM codepage(s).
- , ..., (DR-DOS 7.02+)
- Configures COM port device settings.
- , (DOS 4.0+)
- Redefines characters used for inline comments or causes lines to be ignored.
Additional directives such as COUNTRY (for internationalization), CPOS (cursor position display), CPSW (codepage switching), and CPU-specific conditionals like CPU88, CPU386, CPU486 tailor system behavior according to hardware or locale requirements.
This comprehensive set of directives allows organizations to efficiently customize system configurations across various DOS versions and hardware platforms, enhancing both compatibility and operational performance in professional environments.
DTemplate:NbndF
- Adjusts relocation settings for drive descriptor tables.
- Defines memory segment address used for multi-sector disk data deblocking operations.
- Activates internal debugger capabilities.
- Boot management tool.
- Loads device drivers into conventional memory.
- Loads device drivers into upper memory areas (equivalent to in DRDOS 5.0).
- Sets country and codepage information for keyboard, screen, and printer devices.
- Configures sizes of cache memory segments.
- Specifies compatibility mode for floppy disk drives.
- Selects display font used by the system.
- Controls loading of DOS into high memory and utilization of upper memory blocks.
- Loads DOS internal tables (, , etc.) into upper memory regions.
- Defines an alternative path for locating DOS files.
- Specifies search paths for data files required by the system.
- Establishes physical parameters for disk drives.
- Defines settings for unrecognized or unknown drives.
- See .
- Enables error logging to
PDUMP.nnnfiles on specified drives. - Enables display of messages on screen during boot or operation.
- Allows display of messages including ANSI escape sequences for enhanced formatting.
- Adds extra verification procedures when launching programs.
- Sets expected error or return codes for subsequent commands.
- Controls A20 line gate state during program startup sequences.
- Terminates CONFIG.SYS processing prematurely under certain conditions (exceptions apply).
- Sets hash table size to optimize file open operations, differing from MS-DOS/PC DOS external FASTOPEN driver behavior.
- Defines number of cached File Control Blocks that can be open simultaneously (shares buffer space with FILES under DR-DOS).
- Similar to FCBS but explicitly loads File Control Blocks into upper memory areas.
- Boot management utility.
- Specifies maximum number of files that can be open concurrently.
- Similar to FILES but loads file handles explicitly into upper memory blocks.
- Includes execution of specified CONFIG.SYS subsections (see also IGNORE).
GTemplate:NbndI
- Waits for a key press or timeout, setting the error level to the ASCII value of the key or 1024 if timed out.
- Resumes processing of CONFIG.SYS at a designated label.
- Continues nested CONFIG.SYS processing at a specified label, then returns to the prior location.
- Refer to , , or for additional details.
- Consult for further information.
- See for related instructions.
- Refer to or for more context.
- See or for related commands.
- Consult for additional guidance.
- Loads a TSR program following relocation of the DOS data segment. Compare with INSTCDEX.
- Review , , or for more information.
- See for additional details.
- Refer to or for further explanation.
- Activates and configures the console and command line history buffer along with extended pattern searching capabilities.
- Specifies the address of the High Memory Area (HMA) segment.
- Configures HLT instruction-based power saving features.
- Determines system boot sector virus scanning options.
- Loads installable file system drivers.
- Prevents execution of selected CONFIG.SYS subsections.
- Defines programs permitted to operate at ring 2 level with direct hardware I/O access.
- Incorporates directives from another menu block, emulated via GOSUB/RETURN in DR-DOS environments.
- Sets the Insert mode status of the keyboard.
- Loads a TSR program into conventional memory.
- Installs a TSR into upper memory, equivalent to HIINSTALL in DR-DOS version 5.0.
- Installs TSR after relocating DOS data segment, similar to INSTCDEX.
- Adjusts PIC interrupt priorities to prioritize a specified IRQ number.
KTemplate:NbndM
- Defines keyboard layout configuration.
- Specifies the relocated address of the keyboard buffer.
- Sets the maximum number of accessible drive letters.
- Similar to LASTDRIVE but also loads Current Directory Structure into upper memory areas.
- Lists search paths used by DLLs.
- Manages loading procedures for legacy applications.
- Configures the number of allowed file locks.
- Controls display of boot logos when using PTS-DOS boot manager.
- Sets count, order, I/O port address, and timeout values for LPT1 device configuration.
- Applies the same settings as LPT1 to LPT2 device configuration.
- Mirrors LPT1 settings for LPT3 device setup.
- Enables and configures LPT4 device similarly to other parallel ports.
- Defines delay time before increasing process priority levels.
- Configures memory allocation policies and strategies.
- Establishes default DOS memory allocation parameters.
- Specifies menu option entries within CONFIG.SYS menus.
- Defines menu color schemes, which can be emulated under DR-DOS systems.
- Sets the default menu block, also emulatable in DR-DOS environments.
- Defines individual menu blocks, compatible with DR-DOS emulation methods.
- Enables support for multitrack disk operations during boot or runtime.
- Continues processing CONFIG.SYS from a new file after loading a device driver and setting the %NEWFILE% environment variable.
NTemplate:NbndQ
- Sets default character used as "No" response in Yes/No/Resume prompts (commonly ).
- Controls the state of the keyboard's Num Lock key on startup or during operation.
- Executes commands conditionally based on the last error code encountered, e.g., .
- Displays a message and waits for key input, functioning similarly to and commands in DR-DOS systems.
- Requires user confirmation to acknowledge errors encountered during CONFIG.SYS processing.
- Configures buffer sizes allocated for LPT (parallel) ports to optimize performance.
- Enables conditional execution based on detection of PC-compatible hardware platforms.
- Adjusts scheduler priority settings for task management optimization.
- Sets priority levels specifically for disk I/O related programs to improve throughput.
- Changes default printer device driver assignment from LPT1 to either LPT3 or LPT4.[1]
- Restricts execution permissions for DOS applications, enhancing system security control.
- Loads a user interface shell environment upon system startup or command prompt initiation.
- Allows conditional execution of commands on IBM PS/1-compatible machines only.
- Allows conditional execution of commands on IBM PS/2-compatible machines only.
- Suppresses output sent to standard output (STDOUT), muting displayed messages.
RTemplate:NbndT
- Activates automatic system reboot upon encountering errors.
- Permits inclusion of comments within CONFIG.SYS (ignored by PTS-DOS).
- Allocates a reserved drive letter for local block device drivers.
- Sets the default character for Resume () prompts in Yes/No/Resume queries.
- Returns control from nested CONFIG.SYS processing to the prior GOSUB or SWITCH point, optionally passing a return code.
- Specifies the size of real mode memory available.
- Allows programs to load concurrently in the background during CONFIG.SYS execution, similar to CALL or INSTALL commands in DOS.
- Saves the initial character of deleted files within the FAT reserved region.
- Defines video mode settings for FreeDOS or screen access methods under PTS-DOS.
- Manages keyboard Scroll Lock status behavior.
- Assigns environment variables.
- Loads the command interpreter shell.
- Functions like SHELL but permits pre-allocation of COMMAND.COM size for loading into HMA or UMBs, reducing fragmentation when using third-party shells.
- Specifies keyboard modifier states such as Shift Lock, Num Lock, Scroll Lock, and Insert mode.
- Controls file closure behavior upon pressing Ctrl+Alt+Del.
- Bypasses POST during system reboot sequences.
- , STACKSIZE, STACKSHIGH
- Configure hardware interrupt stack sizes and buffer locations across different DOS variants and derivatives.
- , SYSBOOT, SYSGEN, SYSLOAD
- PTS-DOS instructions that manage boot manager configurations, alternate OS boot files, memory layout, and system loading regions.
- , SWITCH
- Defines submenu blocks (DOS 6.0+) or enables conditional nested CONFIG.SYS processing with RETURN support (DR DOS 6.0+).
- , SWAPPATH
- OS/2 directives specifying drives for error logging and paths for swap file storage.
- , SWITCHES
- Establish default switch characters ('/' or '-') and special options for DOS versions excluding PTS-DOS.
- , THREADS, TIMESLICE
- OS/2 parameters controlling FPU bug fixes, maximum concurrent threads, and scheduler time slice durations.
- , TRACE, TRACEBUF
- Manage CONFIG.SYS timeouts, enable single-step execution tracing (DOS variants), and set buffer sizes for logging (OS/2).
- , TRAPDUMP
- Directive in PTS-DOS for temporary file extensions and OS/2 setting for detailed error log generation.
UTemplate:NbndZ
- Configures DOS to use a specified segment as Upper Memory Block (UMB) space.
- Determines which UMB server is utilized.
- Defines address ranges designated as UMB RAM areas.
- Enables or disables verification of disk writes.
- Sets the DOS version reported to software applications.
- Controls VGA display status settings.
- Specifies the current video mode in use.
- Dictates whether virtual DMA is permitted.
- Determines if the processor’s Virtual Mode Extensions (VME) are disabled.
- Configures VxD driver parameters for Windows environments.
- Sets system support options related to Windows operation.
- Manages relocation of the Extended BIOS Data Area (XBDA).
- Enables conditional execution on XT-compatible hardware platforms.
- Activates built-in Year 2000 compliance features.
- Defines the default character used for affirmative responses in prompts.
- Controls tracking of file deletions.
Issues
While the system is capable of booting without CONFIG.SYS or AUTOEXEC.BAT present, these files are critical for tailoring the operating system and loading necessary software components. If CONFIG.SYS is missing a SHELL directive or is absent altogether, DOS attempts to locate COMMAND.COM in the root directory. Versions prior to DOS 6.0 will fail to boot if COMMAND.COM is not found, whereas MS-DOS 6.0/PC DOS 6.1 and Novell DOS 7 and later prompt users to specify a command processor path.
In dual-boot configurations involving MS-DOS 7.0+ and DR-DOS, incompatibilities with COMMAND.COM prevent circumventing SHELL directives in certain debugging modes. Subsequent updates introduced recovery mechanisms that detect invalid SHELL parameters and prompt users to provide a valid shell before loading COMMAND.COM.
The maximum size allowed for CONFIG.SYS varies depending on the operating system version—MS-DOS/PC DOS restricts these files to a few kilobytes (up to 64 KB in later releases), while DR-DOS imposes no practical limit due to its line-by-line interpretation method. This flexibility grants DR-DOS users enhanced control over the sequence of driver and TSR loading as well as conditional processing based on hardware detection or error conditions, improving troubleshooting capabilities and customization options.
For MS-DOS/PC DOS versions from 2.0 through 4.01, the SHELL command line is limited to a maximum of 31 characters. Later editions extend this limit up to 128 characters, with DR-DOS supporting up to 255 characters. It should be noted that CONFIG.SYS directives do not support long filenames.
Dual booting DOS and Windows 9x
During the installation of Windows 95 over a preexisting DOS or Windows environment, the system renames CONFIG.SYS and AUTOEXEC.BAT to CONFIG.DOS and AUTOEXEC.DOS to enable dual boot functionality between Windows 9x and DOS. When the system boots into DOS, these files are temporarily reverted to their original filenames. Backup copies of Windows 95's configuration files are saved as CONFIG.W40 and AUTOEXEC.W40.
When Caldera DR-DOS versions 7.02 or 7.03 are installed alongside Windows 95, the default Windows CONFIG.SYS and AUTOEXEC.BAT filenames remain unchanged, whereas DR-DOS utilizes its own startup files named DCONFIG.SYS and AUTODOS7.BAT.
OS/2 / Windows NT
OS/2 relies heavily on CONFIG.SYS for setting up drivers and environment variables prior to launching its graphical user interface. In the Windows NT environment, specifically within the OS/2 subsystem, the contents of CONFIG.SYS are maintained in the system registry rather than as a separate file.
OS/2 contains many undocumented CONFIG.SYS commands, highlighting the complexity of its configuration system.
CONFIG.SYS continues to be a fundamental component in OS/2-based operating 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
- Information on AUTOEXEC.BAT and CONFIG.SYS at Computer Hope
- Archived details on Windows 98 / MS-DOS 7.10 CONFIG.SYS directives
- Caldera’s archived CONFIG.SYS Command Reference – overview of DR-DOS 7 directives
- FreeDOS CONFIG.SYS directives description
- PTS-DOS 2000 Pro User Manual including CONFIG.SYS directives
- Unofficial German-language PTS-DOS FAQ (PTS/FAQD) covering CONFIG.SYS directives
- ↑ Cite error: Invalid
<ref>tag; no text was provided for refs namedPaul_1997_OD-A3