TMPEXT (CONFIG.SYS directive)
| Company type | Configuration file |
|---|---|
| Industry | Computer software |
| Founded | 1983 (with DOS version 2.0) |
| Products | System configuration directives for DOS and OS/2 |
CONFIG.SYS serves as the central configuration file for DOS and OS/2 operating systems. This plain text file contains configuration commands that the operating system’s DOS BIOS interprets during the boot sequence. The CONFIG.SYS file was first introduced with DOS version 2.0.
Usage
The directives within CONFIG.SYS are used to set up DOS for hardware devices, software applications, and memory management. Once CONFIG.SYS has been processed, DOS initiates the command interpreter specified by the SHELL directive; if none is defined, it defaults to COMMAND.COM, which subsequently executes AUTOEXEC.BAT.
Typically, the file includes name=value pairs that configure adjustable settings or load device drivers and terminate-and-stay-resident (TSR) programs. In DOS environments, CONFIG.SYS is located in the root directory of the bootable drive.
The same filename is also employed by (DCP), an MS-DOS variant developed by East-German manufacturer VEB Robotron.
Certain DOS versions check for alternative filenames that override CONFIG.SYS:
- Advanced editions of Concurrent DOS 386, Concurrent DOS XM, Multiuser DOS, System Manager, and REAL/32 utilize CCONFIG.SYS or CCONFIG.INI instead. These configurations are stored in a binary file named CCONFIG.BIN. These operating systems offer extended configuration capabilities beyond MS-DOS/PC DOS and modify these files using CONFIG.EXE.
- In DR DOS 3.31, PalmDOS 1.0, Novell DOS 7, OpenDOS 7.01, and DR-DOS 7.02 or later releases, DCONFIG.SYS takes precedence over CONFIG.SYS to support multi-boot environments and disk compression setups where drive letters may change after booting.
- OpenDOS 7.01 and DR-OpenDOS 7.02 additionally search for ODCONFIG.SYS, while certain DR-DOS 7.02+ builds also look for DRCONFIG.SYS.
- Starting with DR DOS 6.0, users can alter default system file extensions using the SYS /DR:ext command. This permits multiple system files to coexist within a single root directory and be selected through boot loaders such as LOADER provided with Multiuser DOS and DR-DOS.
- The SHELL command supports specifying alternative AUTOEXEC.BAT files via the /P[:filename.ext] option; in this mode, COMMAND.COM accepts extensions other than .BAT, a capability also available in 4DOS.
- DR-DOS versions 6.0 and above introduce CHAIN=filespec, enabling continuation of configuration processing from another file anywhere on the boot disk; DR-DOS 7.02+ enhances this with optional label parameters to jump to specific sections within files.
- From DR-DOS 7.03 onward, the SYS /A command copies corresponding CONFIG.SYS and AUTOEXEC.BAT files alongside system files during installation.
Similar functionality exists in other DOS derivatives: FreeDOS employs FDCONFIG.SYS, RxDOS uses RXCONFIG.SYS, and PTS-DOS relies on CONFIG.PTS.
In Windows 95 and Windows 98—both built upon a DOS foundation—CONFIG.SYS and AUTOEXEC.BAT are present but generally left empty. Windows Me does not process CONFIG.SYS during startup; instead, it retrieves environment settings from the Windows Registry at:
- HKLM\System\CurrentControlSet\Control\SessionManager\Environment
For FlexOS, CONFIG.SYS is a binary configuration file that specifies resource managers and device drivers loaded during system initialization.
Example
A sample CONFIG.SYS file for MS-DOS 5 might appear as follows: <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 to define labels within CONFIG.SYS, acting as jump points for directives like , , , and .
- Functions similarly to , also allowing in-line comments following other commands. (Note: In MS-DOS/PC DOS, inline comments within double quotes are not disregarded.)
- Used at the start of in-line comments alongside the ; directive.
- Prompts a Yes/No confirmation before executing subsequent CONFIG.SYS commands. (FreeDOS does not support custom messages but allows conditional execution with boot menus.) DOS 6.0 and later versions support comparable syntax using a trailing after directives.
- Ensures unconditional execution of the next CONFIG.SYS command.
ATemplate:NbndC
- Determines whether programs can be aborted upon encountering errors.
- Defines which drives record file access timestamps in FAT file systems.
- Applies conditional execution on AT-compatible hardware.
- Acts as a boot manager.
- Configures verbosity level of error messages.
- Changes the default serial device driver linked to the AUX: device.
- Prevents character devices from being accessible outside the phantom \DEV directory.
- Loads a base device driver into memory.
- Triggers a beep sound even when audible alerts are disabled.
- Indicates the next operating system to boot.
- Enables or disables extended Ctrl+C checking.
- Sets the number of disk buffers to allocate.
- Explicitly loads buffers into HMA or UMB memory areas.
- , , (Embedded DOS 6-XL only)
- Controls cache block allocation and flushing timing parameters.
- Loads programs within CONFIG.SYS and pauses processing until they return.
- Sets the keyboard’s Caps Lock state.
- , (PTS-DOS only)
- Defines CD-ROM driver name and buffer quantity.
- Continues processing CONFIG.SYS from a new file or label.
- , , and other PTS-DOS-specific directives manage system clock type and screen clearing behaviors.
- (OS/2 only)
- Specifies OEM codepage(s).
- , ..., (DR-DOS 7.02+)
- Configures serial port count, order, I/O addresses, and timeouts.
- , (DOS 4.0+, RxDOS)
- Redefines inline-comment characters or ignores subsequent lines (ignored by some DOS variants).
- , (DOS 3.0+, DR DOS, OS/2)
- Enables internationalization support.
- CPU-related directives (PTS-DOS and DR-DOS) allow conditional execution based on processor type and speed.
This collection of directives facilitates detailed system tuning across diverse DOS platforms, covering device handling, memory management, localization, and boot sequencing—critical for enterprises maintaining legacy environments or embedded systems.
DTemplate:NbndF
- Adjusts relocation settings for drive descriptor tables.
- Defines memory segment address for multi-sector disk data deblocking operations.
- Activates internal debugger functionality.
- Functions as a boot manager.
- Loads device drivers into conventional memory.
- Loads device drivers into upper memory areas (analogous to in DRDOS 5.0).
- Sets country and codepage parameters for keyboard, screen, and printer devices.
- Configures sizes for cache memory allocation.
- Specifies compatibility mode for floppy disk drives.
- Determines display font selection.
- Controls loading of DOS into high memory and usage of upper memory blocks.
- Loads DOS tables such as BUFFERS, FCBS, FILES, LASTDRIVE, and STACKS into upper memory segments.
- Indicates an alternative directory path for DOS files.
- Defines search paths for data files used by DOS utilities.
- Establishes physical parameters for disk drives.
- Sets parameters for unrecognized or unknown drives.
- See .
- Enables drive support for PDUMP.nnn error logging files.
- Displays messages on-screen during processing.
- Displays messages including ANSI escape sequences for enhanced formatting.
- Specifies additional checks before program execution begins.
- Assigns an assumed error or return code for following commands.
- Controls A20 gate state when launching programs.
- Terminates CONFIG.SYS processing prematurely except in some cases involving SWITCHES and SHELL directives.
- Defines hash table size used to accelerate file open operations, differing from MS-DOS/PC DOS FASTOPEN driver functionality.
- Sets the maximum number of cached File Control Blocks (FCBs) that can be opened simultaneously (shares buffer with FILES under DR-DOS).
- Similar to FCBS but explicitly loads FCBs into upper memory areas.
- Acts as a boot manager component.
- Specifies the maximum number of files that can be open concurrently.
- Similar to FILES but explicitly loads file handles into upper memory blocks.
- Includes execution of specified CONFIG.SYS subsections (refer to IGNORE).
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 CONFIG.SYS execution at a designated label.
- Continues nested CONFIG.SYS processing at a specified label, then returns to the previous location.
- Refer to , , or for additional details.
- See also .
- Consult .
- Refer to or for more information.
- See or as applicable.
- Consult .
- Loads a terminate-and-stay-resident (TSR) program into memory following DOS data segment relocation. Compare with INSTCDEX.
- Refer to , , or for further information.
- See .
- Consult or for additional context.
- Activates console and command line history buffer with advanced pattern search capability.
- Defines the address of the High Memory Area (HMA) segment.
- Configures energy-saving settings related to the HLT instruction.
- Specifies whether to perform a virus check on the system boot sector.
- Loads installable file system drivers.
- Prevents execution of designated CONFIG.SYS subsections.
- Grants certain programs permission to execute at CPU ring 2, enabling direct hardware I/O access.
- Includes commands from another menu block, emulated via GOSUB/RETURN in DR-DOS environments.
- Sets the status of the keyboard Insert mode.
- Installs TSR programs into memory.
- Loads TSR programs into upper memory areas, equivalent to HIINSTALL in DR DOS 5.0.
- Installs TSR programs after relocating the DOS data segment. See also INSTCDEX for comparison.
- Adjusts PIC interrupt priority levels to assign highest priority to a specified IRQ.
KTemplate:NbndM
- Defines the keyboard layout configuration.
- Specifies the relocated keyboard buffer's memory address.
- Determines the maximum number of accessible drives.
- Similar to LASTDRIVE but additionally loads Current Directory Structure (CDS) into upper memory regions.
- Lists directories used for dynamic link library (DLL) searches.
- Manages compatibility settings for legacy applications.
- Sets the quantity of file locks allowed.
- Controls display of boot logos and startup messages during system initialization.
- Configures device parameters including count, logical order, I/O port address, and timeout for LPT1 printer port.
- Applies similar settings as LPT1 for LPT2 device configuration.
- Mirrors LPT1 configuration for LPT3 device setup.
- Enables and configures LPT4 device functionality similarly to other LPT ports.
- Defines delay time before elevating process priority levels.
- Sets strategies for memory allocation management.
- Determines default method for DOS memory allocation handling.
- Defines options available within system menus.
- Specifies color schemes for menus, which can be simulated in DR-DOS using ECHO commands.
- Indicates default menu block selection, emulatable in DR-DOS through TIMEOUT and SWITCH directives.
- Defines individual menu blocks, with emulation possible in DR-DOS via ECHO and SWITCH commands.
- Enables or disables multitrack disk operations support.
- Continues processing CONFIG.SYS from a new file after loading a device driver, setting the %NEWFILE% environment variable accordingly.
NTemplate:NbndQ
- Sets the default character used for No () responses in Yes/No/Resume prompts.
- Configures initial status of the keyboard's Num Lock key.
- Executes commands conditionally based on the last error code encountered, such as .
- Displays specified text and pauses waiting for a key press from the user.
- Requires user confirmation when errors occur during CONFIG.SYS processing.
- Configures buffer sizes assigned to LPT printer ports.
- Executes commands only on PC-compatible systems when conditions are met.
- Sets scheduler priority levels for processes or tasks.
- Assigns priority levels specifically for disk I/O-related programs.
- ; Changes the default printer device driver assignment among LPT1 through LPT4 ports.
- Specifies whether DOS applications are permitted to execute in the environment.
- Loads a user interface shell program during system startup or operation.
- Executes conditionally on IBM PS/1-compatible hardware platforms only.
- Executes conditionally on IBM PS/2-compatible systems exclusively.
- Suppresses output directed to standard output (STDOUT).
RTemplate:NbndT
- Activates automatic reboot upon encountering errors.
- Permits inclusion of comments within CONFIG.SYS.
- Reserves a drive letter to prevent allocation by block device drivers.
- Defines the default Resume () character used in prompts.
- Returns control from nested CONFIG.SYS processing to the prior GOSUB or SWITCH point, optionally with a return code.
- Specifies the amount of real mode memory available.
- Enables simultaneous loading of programs during CONFIG.SYS processing in the background.
- Saves the initial character of deleted files in the FAT reserved area.
- Sets video mode for FreeDOS or determines screen access methods for PTS-DOS.
- Controls the Scroll Lock key status on the keyboard.
- Establishes environment variables.
- Loads the command interpreter shell.
- Similar to SHELL but supports a size parameter to relocate COMMAND.COM into HMA or UMBs, reducing fragmentation.
- Specifies states for keyboard modifiers 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 system reboots.
- , STACKSIZE, STACKSHIGH
- Set stack parameters across various DOS platforms and versions, with some ignored in newer releases to maintain compatibility.
- , SYSBOOT, SYSGEN, SYSLOAD
- Directives unique to PTS-DOS that manage boot processes and system memory configuration.
- , SWITCH
- Handles nested CONFIG.SYS processing and conditional branching exclusive to DR DOS.
- , SWAPPATH, THREADS, TIMESLICE
- OS/2-specific commands that control error logging, swap file locations, threading behavior, and scheduler time slice durations.
- , TRACE
- Configures timeouts and enables single-step execution within CONFIG.SYS and AUTOEXEC.BAT under DR DOS and PTS-DOS systems.
- Additional directives govern system functions such as temporary file handling (TMPEXT), A20 gate management (STUBA20), switch character definitions (SWITCHAR), and hardware-specific fixes (SXFAKEHWFPU).
UTemplate:NbndZ
- Assigns a designated segment as an Upper Memory Block (UMB) for DOS usage.
- Defines the UMB server component.
- Specifies memory address ranges allocated as UMB RAM.
- Enables or disables verification of disk writes.
- Sets the DOS version reported to applications.
- Configures VGA display status indicators.
- Determines the current video mode configuration.
- Activates virtual DMA capabilities.
- Controls processor Virtual Mode Extensions (VME) settings.
- Manages VxD driver configurations for Windows environments.
- Sets Windows system support parameters.
- Adjusts relocation of the Extended BIOS Data Area (XBDA).
- Enables conditional execution on XT-compatible hardware platforms.
- Configures built-in Year 2000 compliance features.
- Establishes the default 'Yes' response character in prompts.
- Manages deletion tracking functionality.
Issues
While it is possible for a system to boot without a CONFIG.SYS file, both this file and AUTOEXEC.BAT are critical for fully customizing DOS startup and meeting software requirements. Troubleshooting becomes necessary if these files are missing or corrupted.
If CONFIG.SYS does not include a SHELL directive or is absent or damaged, DOS attempts to locate COMMAND.COM in the root directory of the boot drive. Early DOS versions prior to 6.0 will fail to boot if COMMAND.COM is unavailable. In contrast, MS-DOS 6.0, PC DOS 6.1, and Novell DOS 7 or later will prompt users to specify a command interpreter path. This prompt also appears if the command processor terminates unexpectedly or exits by design, enabling limited shell replacement during runtime without requiring a reboot.
Due to incompatibilities between MS-DOS 7.x's COMMAND.COM and DR-DOS, versions of DR-DOS from 7.02 onward enforce SHELL directives when operating in skip/trace/step modes to prevent conflicts in dual-boot environments. Recovery options include prompting for a valid shell filename before loading COMMAND.COM.
The maximum size allowed for CONFIG.SYS varies depending on the operating system: MS-DOS and PC DOS limit configuration files to several kilobytes—up to approximately 64 KB in later versions—whereas DR-DOS imposes no size restriction beyond file system limits. This difference arises because MS-DOS compiles CONFIG.SYS into an internal tokenized structure for sequential processing, while DR-DOS parses directives line-by-line. This approach grants precise control over driver and TSR loading order through DEVICE and INSTALL commands, facilitating resolution of load conflicts and inclusion of temporary external programs within CONFIG.SYS.
Limits on line length also vary: MS-DOS/PC DOS versions from 2.0 through 4.01 restrict SHELL lines to 31 characters, later editions allow up to 128 characters, and DR-DOS accepts lines up to 255 characters long. 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 pre-existing DOS/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 mode, these files are temporarily reverted to their original names, CONFIG.SYS and AUTOEXEC.BAT. Additionally, backup copies of the Windows 95 versions are saved as CONFIG.W40 and AUTOEXEC.W40.
In cases where Caldera DR-DOS 7.02 or 7.03 is installed alongside Windows 95, the Windows CONFIG.SYS and AUTOEXEC.BAT files retain their standard names, while DR-DOS employs DCONFIG.SYS and AUTODOS7.BAT as its startup configuration files.
OS/2 / Windows NT
OS/2 extensively utilizes CONFIG.SYS for loading drivers and setting up the environment prior to launching its graphical user interface. Within the OS/2 subsystem on Windows NT, what OS/2 applications recognize as CONFIG.SYS is actually maintained within the system registry.
OS/2 contains a variety of undocumented CONFIG.SYS commands, indicative of its intricate configuration requirements.
The use of CONFIG.SYS continues in 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
- 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; DR-DOS 7 directives)
- Details on FreeDOS CONFIG.SYS directives
- PTS-DOS 2000 Pro User Guide with CONFIG.SYS directive summaries
- Unofficial German FAQ for PTS-DOS including CONFIG.SYS directives (archived)