Jump to content

RESERVEDRIVELETTER (CONFIG.SYS directive)

From Alfawiki
Adapted from the English Wikipedia article RESERVEDRIVELETTER (CONFIG.SYS directive), available under CC BY-SA 4.0Updated 9 August 2025
CONFIG.SYS
Company typeConfiguration file
IndustryComputer software
Founded1983
Headquarters
N/A
ProductsConfiguration commands for DOS and OS/2 boot process

CONFIG.SYS serves as the main configuration file for DOS and OS/2 operating systems. This file, written in ASCII text format, contains configuration commands that the operating system's DOS BIOS—commonly found in IBMBIO.COM or IO.SYS—interprets during the boot process. CONFIG.SYS made its debut with DOS version 2.0.

Usage

The directives within CONFIG.SYS are utilized to set up DOS for hardware devices, software applications, and memory handling. Once CONFIG.SYS has been processed, DOS initiates the command interpreter specified by the SHELL directive; if none is provided, it defaults to COMMAND.COM, which then executes the AUTOEXEC.BAT script.

Typically, this file includes name=value pairs that define parameters or load essential 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 employed by (DCP), an MS-DOS variant developed by East-German company VEB Robotron.

Certain DOS distributions check for alternative filenames that override the standard CONFIG.SYS:

- Advanced editions of Concurrent DOS 386, Concurrent DOS XM, Multiuser DOS, and REAL/32 replace CONFIG.SYS with CCONFIG.SYS. Some Multiuser DOS releases utilize CCONFIG.INI, while REAL/32 looks for MCONFIG.SYS. These platforms support extended configuration through binary files like CCONFIG.BIN, which are typically edited using a utility called CONFIG.EXE.

- In DR DOS version 3.31 and later (including PalmDOS 1.0 and Novell DOS 7), DCONFIG.SYS takes precedence over CONFIG.SYS. Originally associated with disk compression tools, this file also enables multi-boot setups.

- OpenDOS 7.01 and DR-OpenDOS 7.02 prioritize ODCONFIG.SYS, whereas some DR-DOS versions from 7.02 onward search for DRCONFIG.SYS.

- Starting with DR DOS 6.0, the SYS /DR:ext command permits renaming of system files to maintain multiple boot file sets within a single root directory, selectable via boot loaders such as LOADER included with Multiuser DOS and DR-DOS 7.x.

- The SHELL command supports specifying alternative AUTOEXEC.BAT files through /P[:filename.ext], with COMMAND.COM accepting extensions beyond ".BAT" (a feature also supported by 4DOS).

- From DR-DOS 6.0 onward, the CHAIN=filespec directive allows continuation of processing from another configuration file, which can be located outside the root directory; version 7.02+ adds an optional label parameter to jump to specific sections within files.

- DR-DOS 7.03+ introduces a SYS /A option that copies CONFIG.SYS and AUTOEXEC.BAT alongside other system files.

Other DOS variants implement comparable capabilities: FreeDOS uses FDCONFIG.SYS, RxDOS relies on RXCONFIG.SYS, and PTS-DOS employs CONFIG.PTS.

Windows 95 and Windows 98, which are built on top of DOS, include CONFIG.SYS and AUTOEXEC.BAT on their boot drives but typically leave them empty. Unlike its predecessors, 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 file specifying resource managers and device drivers loaded during system initialization.

Example

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>

:;*?!

Marks labels within CONFIG.SYS to serve as jump targets for , , , and commands.
Functions similarly to , also utilized for inline comments following other CONFIG.SYS instructions. (In MS-DOS/PC DOS, inline comments inside double quotes are not ignored.)
Used to begin inline comments alongside the ; directive.
Prompts a Yes/No confirmation with an optional message before executing subsequent CONFIG.SYS commands. (FreeDOS supports conditional execution with boot menus via and .) DOS 6.0 and later versions offer a comparable feature by appending after directives (e.g., ).
Forces unconditional execution of the next CONFIG.SYS command.

ATemplate:NbndC

Determines whether programs can be interrupted upon errors.
Sets which drives record file access dates in FAT file systems.
Executes conditionally on AT-compatible hardware.
Boot management utility.
Configures verbosity level of error messages.
Changes the default serial device driver linked to the AUX device.
Restricts access to character devices outside the phantom \DEV directory.
Loads a base device driver into memory.
Triggers a beep sound even if notifications are disabled.
Specifies the operating system to boot next.
Enables or disables extended Ctrl+C checking.
Defines how many disk buffers are allocated.
Similar to BUFFERS, but loads buffers into HMA or UMB areas.
, , (Exclusive to Embedded DOS 6-XL)
Manages cache block allocation and flushing intervals.
Loads programs within CONFIG.SYS and pauses processing until they return.
(Available in DR-DOS 7.02+)
Sets keyboard Caps Lock status.
, , (PTS-DOS only)
Designates CD-ROM driver name and buffer quantity.
(Supported by DR DOS 5.0+ and Embedded DOS)
Continues CONFIG.SYS processing from a new file or label.
, , (DR DOS, PTS-DOS)
Configures clock type and screen clearing commands.
, (OS/2)
Specifies OEM codepages.
, (PTS-DOS)
Defines CMOS RAM address.
, (PTS-DOS)
Sets colors for boot menus.
, ..., , (DR-DOS 7.02+)
Configures serial COM devices, including count, order, I/O addresses, and timeouts.
, (PTS-DOS)
Specifies DMA buffer parameters.
, (DOS 4.0+, RxDOS)
Redefines inline comment lead characters or causes the following line to be ignored.
, (DOS 3.0+, DR DOS 3.31+, OS/2)
Enables international support settings.
, (DR DOS 6.0+)
Positions display cursor for configuration menus.
, (MS-DOS 4.x only)
Supports codepage switching functionality.
CPU-specific conditional directives (PTS-DOS and DR-DOS) allow execution based on CPU type or generation such as 8088, 8086, 286, 386, or 486.

DTemplate:NbndF

Adjusts relocation of drive descriptor tables in memory.
Defines memory segment address used for multi-sector disk data deblocking.
Enables support for internal debugging features.
Boot management utility.
Loads device drivers into conventional memory.
Loads device drivers into upper memory blocks (equivalent to in DRDOS 5.0).
Configures country and codepage information for keyboard, screen, and printer devices.
Sets cache memory sizes for improved performance.
Defines compatibility mode for floppy disk drives.
Specifies font used for display output.
Controls loading of DOS into high memory and use of upper memory areas.
Loads DOS internal tables such as BUFFERS, FCBS, FILES, LASTDRIVE, STACKS into upper memory regions.
Specifies an alternative path location for DOS system files.
Sets search paths for data files used by DOS utilities.
Defines physical parameters related to disk drives for proper operation.
Establishes parameters for drives that are not natively recognized by the system.
See .
Enables error logging to PDUMP.nnn files on specified drives in case of system faults.
Controls whether messages are displayed on the screen during boot or operation.
Enables display of messages with ANSI escape sequences formatting support.
Adds extra verification steps when launching programs to ensure stability or compatibility.
Specifies expected error or return codes from executed programs or commands.
Sets the state of the A20 gate line when starting applications to manage memory addressing modes.
Terminates processing of CONFIG.SYS before reaching the end of the file, with some exceptions allowed.
Defines hash table size used by fast file open operations, differing from MS-DOS/PC DOS FASTOPEN driver implementations.
Indicates how many File Control Blocks can be cached simultaneously (shares buffer space with FILES under DR-DOS).
Similar to FCBS but explicitly loads these into upper memory areas for efficiency gains.
Boot management utility functions again referenced here.
Specifies maximum number of files that can be open simultaneously by the system or applications.
Like FILES but loads file handle structures into upper memory explicitly to conserve conventional memory space.
Allows inclusion and execution of specified subsections within CONFIG.SYS files (see IGNORE directive).

GTemplate:NbndI

Waits for a key press or timeout, then sets the error level to the corresponding ASCII value or 1024 if timed out.
Resumes CONFIG.SYS processing at a designated label.
Continues nested CONFIG.SYS processing at a given label and returns to the original point afterward.
Refer to , , or for additional information.
See also .
Consult .
Refer to or for details.
See or for further context.
Consult .
Loads a TSR program into memory after relocating the DOS data segment. Compare with INSTCDEX.
Refer to , , or for related commands.
See .
Check or for more details.
Enables command line and console history buffer with enhanced pattern search capabilities.
Specifies the memory address of the HMA segment.
Configures the HLT power-saving mode.
Indicates whether the system performs boot sector virus checks.
Loads installable file systems into memory.
Prevents execution of certain CONFIG.SYS subsections.
Permits specified programs to operate at ring 2, allowing direct hardware I/O access.
Includes directives from another menu block, emulated via GOSUB/RETURN in DR-DOS.
Sets the Insert mode status for the keyboard.
Installs a TSR program into memory.
Installs TSR into upper memory area, equivalent to HIINSTALL in DR DOS 5.0.
Installs TSR after DOS data segment relocation, similar in function to INSTALL.
Rotates PIC interrupt priorities, elevating a specified IRQ to highest priority.

KTemplate:NbndM

Defines the keyboard layout configuration.
Specifies the relocated address of the keyboard buffer.
Sets the maximum number of accessible drives.
Functions like LASTDRIVE but loads Current Directory Structure into upper memory.
Lists directories for DLL search paths.
Manages legacy program compatibility settings.
Configures the number of file locks allowed.
Enables boot logo support and startup message using PTS-DOS boot manager.
Defines count, sequence, I/O port, and timeout values for LPT1 device.
Defines count, sequence, I/O port, and timeout values for LPT2 device.
Defines count, sequence, I/O port, and timeout values for LPT3 device.
Enables and configures LPT4 device similarly to others.
Sets delay before increasing process priority level.
Configures memory allocation methods and strategies.
Specifies default memory allocation strategy for DOS operations.
Defines available menu options within CONFIG.SYS environment.
Sets color schemes for menus (can be emulated under DR-DOS).
Establishes default menu block (emulatable under DR-DOS).
Defines specific menu blocks (emulatable under DR-DOS).
Enables multitrack disk operation support.
Continues CONFIG.SYS processing from a new file after loading specified drivers and setting %NEWFILE% environment variable.

NTemplate:NbndQ

Specifies default response character for No () in Yes/No/Resume prompts.
Sets keyboard [[Num Lock|Template:Keypress]] status either on or off.
Executes conditionally based on last error code, e.g., .
Displays text and waits for a key press, similar to and commands under DR-DOS.
Requires user confirmation upon encountering errors in CONFIG.SYS processing.
Configures buffer sizes for LPT1 through LPT3 devices.
Executes conditionally on PC-compatible hardware platforms.
Adjusts scheduler priority settings within DOS environment.
Sets priority level for disk input/output operations.
; Changes default printer device assignment (for example, from LPT1 to LPT4).
; Controls whether DOS applications are permitted to run.
; Loads the user interface shell program during startup.
; Executes conditionally on IBM PS/1-compatible machines only.
; Executes conditionally on IBM PS/2-compatible machines only.
; Suppresses standard output display (STDOUT) during execution.

RTemplate:NbndT

Activates automatic system reboot upon encountering errors.
Permits the inclusion of comments within CONFIG.SYS files.
Allocates a drive letter for local block device drivers.
Sets the default Resume () prompt character.
Returns control from nested CONFIG.SYS processing to the previous GOSUB or SWITCH command, optionally passing a return code.
Specifies the size of real mode memory.
Allows simultaneous loading of programs in CONFIG.SYS in the background, functioning similarly to CALL or INSTALL commands in DOS.
Determines whether the first character of deleted filenames is preserved in the FAT reserved area.
Selects the video mode under FreeDOS or defines screen access methods for PTS-DOS.
Controls the state of the keyboard Scroll Lock key, turning it on or off.
Sets environment variables within the system.
Loads the command interpreter shell.
Functions like SHELL but includes a SIZE parameter to relocate COMMAND.COM into HMA or UMBs, thereby minimizing memory fragmentation.
Defines keyboard modifier key states such as Shift Lock, Num Lock, Scroll Lock, and Insert mode.
Specifies whether files are closed automatically when Ctrl+Alt+Del is pressed.
Skips the Power-On Self-Test (POST) during reboot sequences.
, STACKSIZE, STACKSHIGH, STACK
Various stack configuration parameters across DOS versions, now largely obsolete due to advances in modern memory management.
, SYSBOOT, SYSGEN, SYSLOAD, SYSTOUMB
Commands specific to PTS-DOS that handle boot procedures and memory allocation for system components.
, SUPPRESSPOPUPS, SWAPPATH
OS/2 directives managing menu block behavior, error log locations, and swap file directory paths respectively.
, SWITCHES
Conditional processing instructions in CONFIG.SYS that enable dynamic system configuration based on user inputs or options.
Defines the default command-line switch character, either '/' or '-'.
, THREADS, TIMESLICE
OS/2 parameters controlling hardware floating-point unit fixes, concurrent thread management, and scheduler time slice durations.
, TRACE, TRACEBUF
Settings that regulate execution timeouts and tracing capabilities within CONFIG.SYS to improve diagnostic processes on DR-DOS, PTS-DOS, and OS/2 platforms.
, TRAPDUMP
Defines temporary file extensions for error dumps (PTS-DOS) and detailed error logging features (OS/2).

UTemplate:NbndZ

Configures DOS to utilize a specified segment as Upper Memory Block (UMB) memory.
Sets which UMB server is employed by the system.
Defines address ranges designated as UMB RAM areas.
Enables or disables verification of disk write operations.
Specifies the DOS version number presented to running applications.
Controls VGA display status settings.
Indicates the current video mode in use.
Determines whether virtual DMA functionality is permitted.
Enables disabling of the processor's Virtual Mode Extensions feature.
Configures VxD drivers for Windows environments.
Adjusts system support parameters for Windows operating systems.
Manages relocation settings for the Extended BIOS Data Area (XBDA).
Enables conditional execution tailored for XT-compatible machines.
Configures built-in Year 2000 compliance features.
Sets the default 'Yes' response character for system queries.
Controls deletion tracking behavior.

Issues

Although the system can start without CONFIG.SYS present or if it is corrupted, this file together with AUTOEXEC.BAT remains critical for comprehensive operating system customization and loading necessary programs. When these files are damaged, troubleshooting becomes essential.

If CONFIG.SYS lacks a SHELL directive—or if it is missing or corrupted—DOS attempts to locate COMMAND.COM in the root directory. Earlier MS-DOS versions before 6.0 will fail to boot if COMMAND.COM is not found. From MS-DOS 6.0/PC DOS 6.1 onward and Novell DOS 7+, users are prompted to provide a command processor path when COMMAND.COM is absent. This prompt also appears if the main command processor terminates unexpectedly or exits intentionally, enabling runtime replacement of the shell without rebooting.

COMMAND.COM versions from MS-DOS 7.0 onwards are incompatible with DR-DOS shells commonly installed on drive C:, often seen in dual-boot configurations. DR-DOS 7.02 and later prevent bypassing SHELL directives during various skip or trace modes to avoid conflicts with incompatible shells. However, some subsequent updates reintroduced limited skip functionality to facilitate recovery scenarios.

CONFIG.SYS size limitations differ by platform: MS-DOS/PC DOS restricts file size to a few kilobytes (up to 64 KB in later versions), whereas DR-DOS imposes no inherent limit beyond filesystem constraints. MS-DOS preprocesses CONFIG.SYS by tokenizing its contents before sequentially processing directives—loading device drivers prior to TSRs. In contrast, DR-DOS processes directives line-by-line, allowing precise control over load order through DEVICE and INSTALL commands. This granularity assists in resolving driver conflicts and debugging.

Additionally, DR-DOS supports conditional execution based on hardware detection or error states and permits running non-resident programs via INSTALL, integrating temporary software into CONFIG.SYS sequences.

Early releases of MS-DOS/PC DOS limited SHELL command lines to 31 characters, expanding to 128 characters in later editions. DR-DOS allows up to 255 characters for this directive. It should be noted that CONFIG.SYS does not support long filenames within its directives.

Dual Booting DOS with Windows 9x

During the installation of Windows 95 over an existing DOS/Windows environment, the system renames CONFIG.SYS and AUTOEXEC.BAT to CONFIG.DOS and AUTOEXEC.DOS, enabling a dual-boot setup between Windows 9x and DOS. When switching to DOS mode, these files are temporarily reverted to their original filenames. Meanwhile, backup copies of the Windows 95 versions are stored as CONFIG.W40 and AUTOEXEC.W40.

In scenarios where Caldera DR-DOS 7.02 or 7.03 is installed alongside Windows 95, the original Windows CONFIG.SYS and AUTOEXEC.BAT files remain intact. DR-DOS instead utilizes DCONFIG.SYS and AUTODOS7.BAT for its boot-time configuration.

OS/2 and Windows NT

OS/2 depends extensively on CONFIG.SYS to set up drivers and environment variables prior to launching its graphical user interface.

Within the OS/2 subsystem of Windows NT, CONFIG.SYS is simulated through registry entries rather than existing as a conventional file.

There are numerous undocumented CONFIG.SYS commands specific to OS/2, highlighting its intricate configuration options.

CONFIG.SYS continues to play a critical role in OS/2-based operating systems such as eComStation and ArcaOS.

See also

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) – details on DR-DOS 7 directives
  • Documentation for FreeDOS CONFIG.SYS directives
  • PTS-DOS 2000 Pro User Manual covering CONFIG.SYS directives (archived)
  • Unofficial German PTS-DOS FAQ including CONFIG.SYS directives (archived)