Jump to content

VXD (CONFIG.SYS directive)

From Alfawiki
Adapted from the English Wikipedia article VXD (CONFIG.SYS directive), available under CC BY-SA 4.0Updated 9 August 2025
CONFIG.SYS
Company typeConfiguration file
IndustryOperating systems
Founded1983; 43 years ago (1983)
Headquarters
None
ProductsSystem configuration for DOS and OS/2

CONFIG.SYS serves as the main configuration file for DOS and OS/2 operating systems. This particular ASCII text file holds setup instructions that the operating system's DOS BIOS—usually 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 configuring DOS to manage devices, applications, and memory allocation. Once CONFIG.SYS has been processed, DOS loads the command interpreter specified by the SHELL directive; if none is provided, it defaults to COMMAND.COM. Subsequently, the shell executes the commands in AUTOEXEC.BAT.

CONFIG.SYS primarily contains name=value settings that adjust system parameters or load files such as device drivers and terminate-and-stay-resident programs (TSRs) into memory.

Within DOS, CONFIG.SYS is located in the root directory of the bootable drive.

The same filename is also utilized by (DCP), an MS-DOS variant developed by the former East-German company VEB Robotron.

Certain DOS derivatives prioritize alternative configuration filenames over CONFIG.SYS:

Earlier releases of Concurrent DOS (versions 3.2 through 4.1) did not support CONFIG.SYS; however, later editions like Concurrent DOS 386, Concurrent DOS XM, Multiuser DOS, System Manager, and REAL/32 employ CCONFIG.SYS (denoting "Concurrent"). Some Multiuser DOS distributions use CCONFIG.INI, while REAL/32 refers to MCONFIG.SYS. These platforms maintain extra configuration data in a binary file named CCONFIG.BIN, which is generally edited through CONFIG.EXE.

In environments such as DR DOS 3.31, PalmDOS 1.0, Novell DOS 7, and DR-DOS versions 7.02 and above, a file called DCONFIG.SYS ("DR DOS") takes precedence over CONFIG.SYS. Originally associated with disk compression utilities, DCONFIG.SYS also facilitates multi-boot setups. Versions like OpenDOS 7.01 and DR-OpenDOS 7.02 search for ODCONFIG.SYS, whereas some DR-DOS 7.02+ editions look for DRCONFIG.SYS.

Starting with DR DOS 6.0, the command SYS /DR:ext allows users to define custom system file extensions, enabling multiple sets of system files to coexist within a single root directory and be selected by boot loaders such as LOADER (used in Multiuser DOS and DR-DOS 7.x). The SHELL directive supports specifying alternative AUTOEXEC.BAT files using /P[:filename.ext], and COMMAND.COM can handle extensions other than ".BAT" under these conditions—a capability also available in 4DOS. The CHAIN=filespec command permits DR-DOS to continue processing another configuration file, which may reside outside the boot drive root; from version 7.02 onward, it can jump to specific labels within chained files.

With DR-DOS 7.03 and later, the SYS /A option copies corresponding CONFIG.SYS and AUTOEXEC.BAT files alongside system files.

FreeDOS employs a comparable configuration file named FDCONFIG.SYS; similarly, RxDOS version 7.24 and above uses RXCONFIG.SYS, while PTS-DOS opts for CONFIG.PTS.

Both CONFIG.SYS and AUTOEXEC.BAT exist in the root directories of boot drives on Windows 95 and Windows 98, reflecting their DOS heritage, although these files are often left empty.

Unlike its predecessors, Windows Me does not process CONFIG.SYS during startup; instead, it retrieves environment variables from the Windows Registry at:

HKLM\System\CurrentControlSet\Control\SessionManager\Environment

In contrast, under FlexOS, CONFIG.SYS is a binary file that specifies resource managers and device drivers to be 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>

:;*?!

Defines labels within CONFIG.SYS that act as jump targets for , , , and commands.
Functions similarly to , but also supports inline comments following other directives. (In MS-DOS/PC DOS, inline comments enclosed in double quotes are not ignored.)
Introduces inline comments, complementing the ; directive.
Prompts the user with a Yes/No confirmation before executing the subsequent CONFIG.SYS commands. (FreeDOS does not support custom messages but allows conditions with boot menus.) DOS version 6.0 and later provide a comparable feature by appending to directives.
Forces unconditional execution of the following CONFIG.SYS command.

ATemplate:NbndC

Determines whether programs can be interrupted on error conditions.
Sets drives to record file access timestamps within FAT directory entries.
Enables conditional execution on AT-compatible systems.
Boot manager utility.
Controls the verbosity level of error messages.
Changes the default serial device driver associated with the AUX device.
Prevents character devices from being accessible outside the virtual \DEV directory.
Loads a base device driver into memory.
Produces a brief beep sound even if audible alerts are disabled.
Defines which operating system to boot next.
Enables or disables extended Ctrl+C checking functionality.
Specifies how many disk buffers to allocate.
Similar to BUFFERS but loads buffers into High Memory Area (HMA) or Upper Memory Blocks (UMB).
, CACHETTL, CACHEFLUSH (Embedded DOS 6-XL only)
Manage cache block lifetimes and flushing intervals.
Loads and executes programs within CONFIG.SYS, pausing processing until they return.
(DR-DOS 7.02+)
Controls Caps Lock keyboard status on or off.
, CDDBUFFERS (PTS-DOS only)
Defines CD-ROM driver designation and buffer quantity.
(DR DOS 5.0+, Embedded DOS)
Continues processing CONFIG.SYS from a new file or label.
, CLS, CODEPAGE (PTS-DOS or OS/2)
Configure system clock type, clear the screen, and specify OEM code pages.
, COLOR (PTS-DOS only)
Specifies CMOS RAM address and color settings for boot menus.
, COM2, COM3, COM4 (DR-DOS 7.02+)
Configure serial COM ports including I/O addresses and timeouts.
, COMMENT(S), COUNTRY, CPOS, CPSW (various DOS versions)
Manage DMA buffers, inline comments, internationalization support, cursor position display, and codepage switching capabilities respectively.
, CPU88, CPU86, CPU286, CPU386, CPU486 (PTS-DOS or DR-DOS)
Conditional execution based on CPU model or clock speed.

DTemplate:NbndF

Adjusts relocation of drive descriptor tables in memory.
Defines memory segment address for multi-sector disk data deblocking operations.
Enables support for an internal debugger.
Boot manager utility.
Loads a device driver into system memory.
Loads device drivers into upper memory areas (equivalent to in DRDOS 5.0).
Configures country-specific and codepage information for keyboard, screen, and printer devices.
Sets sizes for cache memory allocation.
Specifies compatibility modes for floppy disk drives.
Selects display font used by the system.
Controls loading of DOS into high memory and/or usage of upper memory blocks.
Loads DOS internal tables (BUFFERS, FCBS, FILES, LASTDRIVE, STACKS) into upper memory areas.
Specifies an alternative directory path for locating DOS system files.
Defines search paths for data files used by the system.
Sets physical parameters for disk drives connected to the system.
Establishes parameters for drives that are not recognized automatically.
See .
Enables logging of error reports to PDUMP.nnn files on specified drives.
Displays a message on the screen during boot or configuration processing.
Displays messages that include ANSI escape sequences for formatting purposes.
Determines whether additional verification checks occur when launching programs.
Defines expected error or return codes for subsequent operations in CONFIG.SYS processing.
Controls A20 gate status when starting new programs to manage memory addressing modes.
Terminates CONFIG.SYS processing prematurely except under certain conditions involving SWITCHES and SHELL directives.
Sets hash table size used for accelerating file open operations, differing from MS-DOS/PC DOS FASTOPEN driver behavior.
Specifies how many File Control Blocks (FCBs) can be simultaneously opened (shares buffer space with FILES under DR-DOS).
Similar to FCBS but explicitly loads FCBs into upper memory segments.
Boot manager utility command.
Defines the maximum number of files that can be opened concurrently by the system.
Similar to FILES but explicitly loads file handles into upper memory areas for improved performance.
Allows execution of designated CONFIG.SYS subsections (refer to IGNORE directive).

GTemplate:NbndI

Waits for a key press or timeout, setting the error level to the ASCII code 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 previous location.
Refer to , , or for additional information.
See also .
Consult for related details.
Refer to or for further guidance.
See or for more information.
Additional details available in .
Loads a TSR program after relocating the DOS data segment. Compare with INSTCDEX.
Refer to , , or for related commands.
See also .
Consult or for further explanation.
Activates console and command line history buffers with enhanced pattern searching capabilities.
Defines the address for the High Memory Area (HMA) segment.
Configures the HLT instruction for power-saving mode.
Performs boot sector virus scanning during startup.
Loads installable file system drivers.
Prevents execution of selected CONFIG.SYS subsections.
Permits specific programs to operate at ring 2, enabling direct hardware I/O access.
Incorporates directives from another menu block (emulated via GOSUB/RETURN in DR-DOS).
Sets the status of keyboard Insert mode.
Installs TSR programs into conventional memory.
Loads TSR programs into upper memory, equivalent to HIINSTALL in DR DOS 5.0.
Installs TSR after relocation of DOS data segment, similar to INSTALL.
Adjusts PIC interrupt priorities to prioritize a specified IRQ number.

KTemplate:NbndM

Defines the keyboard layout configuration.
Specifies the relocated keyboard buffer’s memory address.
Determines the maximum number of accessible drives.
Functions like LASTDRIVE but loads Current Directory Structure into upper memory.
Sets paths for DLL searches.
Controls execution of legacy software applications.
Configures quantity of file locks permitted.
Manages boot logo display using PTS-DOS boot manager.
Specifies count, sequence, I/O address, and timeout parameters for LPT1 device.
Equivalent settings for LPT2 device as LPT1.
Same configuration as LPT1 but applied to LPT3 device.
Enables and configures LPT4 printer port device.
Defines wait duration before elevating process priority level.
Sets strategy for memory allocation management.
Establishes default DOS memory allocation method.
Specifies menu configuration options.
Defines color schemes for menus (can be emulated using ECHO in DR-DOS).
Sets default menu block (emulatable with TIMEOUT and SWITCH commands in DR-DOS).
Defines multiple menu blocks (emulatable via ECHO and SWITCH in DR-DOS).
Enables multitrack operations on disk drives.
Continues processing CONFIG.SYS from a new file, optionally loading a device driver and setting the %NEWFILE% environment variable.

NTemplate:NbndQ

Sets default "No" character response in Yes/No/Resume prompt dialogs.
Defines keyboard [[Num Lock|Template:Keypress]] state at startup.
Executes conditionally based on the last error code, e.g., .
Displays text and waits for key input, similar to DR-DOS prompt commands.
Requires user confirmation upon encountering errors in CONFIG.SYS processing.
Configures buffer size settings for LPT port operations.
Conditional execution targeting PC-compatible systems only.
Sets parameters for priority-based task scheduling.
Configures priority settings for disk I/O operations.
Changes default printer device driver assignment (from LPT1 to LPT3 or LPT4).
Specifies whether DOS applications are permitted to execute.
Loads the user interface shell environment.
Conditional execution on IBM PS/1-compatible hardware platforms.
Conditional execution on IBM PS/2-compatible systems.
Suppresses output display on STDOUT.

RTemplate:NbndT

Activates automatic system reboot upon encountering errors.
Permits inclusion of comments within CONFIG.SYS files.
Allocates a drive letter for local block device drivers.
Defines the default character used for Resume () prompts.
Returns control in nested CONFIG.SYS processing to the preceding GOSUB or SWITCH command, optionally passing a return code.
Sets the size of real mode memory.
Allows simultaneous loading of programs in CONFIG.SYS, functioning similarly to CALL or INSTALL commands under DOS/OS2.
Saves the first character of deleted files within the FAT reserved area.
Determines video mode settings for FreeDOS or screen access methods under PTS-DOS.
Controls the keyboard Scroll Lock status.
Establishes environment variables.
Loads the command interpreter shell.
Functions like SHELL but includes a SIZE parameter to pre-allocate COMMAND.COM in HMA or UMBs, enhancing memory efficiency with third-party shells.
Defines keyboard modifier states such as Shift Lock, Num Lock, Scroll Lock, and Insert mode.
Specifies file closure behavior triggered by Ctrl+Alt+Del.
Skips the Power-On Self-Test (POST) during reboot sequences.
, STACKSIZE, STACKSHIGH
Manage stack size parameters across multiple DOS variants and derivatives for hardware interrupts or thread stacks, with some parameters disregarded in newer or specific systems.
, SYSBOOT, SYSGEN, SYSLOAD, SYSTOUMB
Commands unique to PTS-DOS that handle boot configuration, system memory allocation, and loading DOS components into upper memory blocks (UMBs).
, STUBA20
Internal or PTS-DOS-specific settings related to system controls such as A20 gate management.
, SUPPRESSPOPUPS
Defines submenu blocks (DOS 6.0 and later) or designates error logging drives to replace pop-up messages (OS/2).
, THREADS, TIMESLICE
OS/2 directives that set swap file locations, configure concurrent thread counts, and adjust scheduler time slices respectively.
, SWITCHES, SWITCHAR
Commands that enable conditional processing in CONFIG.SYS (DR DOS), set special options (Novell DOS), and determine default switch characters ('/' or '-') across various DOS platforms.
, TRACE, TRACEBUF, TRAPDUMP
OS/2 commands addressing hardware floating-point unit bug fixes, enabling/disabling single-step tracing with buffer size settings, and detailed trap logging.

This segment outlines essential configuration directives that govern system behavior customization across DOS variants and OS/2 platforms, demonstrating strategic adaptability for enterprise-level deployment and legacy system maintenance.

UTemplate:NbndZ

Designates a specific segment for DOS management as UMB memory.
Specifies which UMB server to utilize.
Defines address ranges allocated as UMB RAM.
Enables or disables verification of disk writes.
Sets the DOS version reported to applications.
Configures VGA display status parameters.
Indicates the current video mode setting.
Determines whether virtual DMA is permitted.
Controls deactivation of Virtual Mode Extensions.
Configures VxD driver settings for Windows environments.
Adjusts system support parameters for Windows operation.
Manages relocation of the Extended BIOS data area (XBDA).
Enables conditional execution on XT-compatible hardware.
Configures built-in support for Year 2000 compliance.
Specifies the default 'Yes' response character in prompts.
Controls tracking of file deletions.

Issues

Although the system can start without CONFIG.SYS or AUTOEXEC.BAT, these files are crucial for comprehensive customization and meeting software prerequisites. Any corruption or damage to them requires diagnostic efforts.

When CONFIG.SYS is missing a SHELL command—or if the file itself is absent or corrupted—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, whereas MS-DOS 6.0, PC DOS 6.1, and Novell DOS 7 and later will display a prompt requesting the path to the command processor. This prompt also appears if the main shell terminates unexpectedly or is exited intentionally, offering a limited shell replacement without needing to restart.

COMMAND.COM from MS-DOS 7.0 and later is not compatible with DR-DOS, although it is frequently stored on drive C: in dual-boot environments. From DR-DOS 7.02 onward, bypassing SHELL directives during skip, trace, or step modes is restricted; valid shell input must be provided before COMMAND.COM loads from the root directory. This behavior improves system reliability during boot recovery procedures.

The size of CONFIG.SYS under MS-DOS and PC DOS is confined to a few kilobytes (up to 64 KB in later releases), whereas DR-DOS imposes no practical upper limit aside from file system constraints. MS-DOS processes CONFIG.SYS by tokenizing it into memory and executing directives in a predetermined sequence, typically loading drivers before TSRs. Conversely, DR-DOS parses CONFIG.SYS line-by-line, enabling fine-tuned control over the order in which drivers and TSRs load using DEVICE and INSTALL commands. This approach resolves conflicts in loading sequences and allows conditional execution based on hardware detection, key presses, error states, or software return codes.

The INSTALL directive in DR-DOS can initiate non-resident programs integrated within the CONFIG.SYS processing flow, thereby enhancing customization options and facilitating debugging.

Early MS-DOS versions limited the length of the SHELL command line to 31 characters; subsequent versions extended this limit to 128 characters, while DR-DOS supports up to 255 characters. 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 an existing DOS/Windows environment, it renames CONFIG.SYS and AUTOEXEC.BAT to CONFIG.DOS and AUTOEXEC.DOS respectively. This allows dual booting between Windows 9x and DOS by temporarily restoring these files to their original names when booting DOS. Additionally, Windows 95 creates backup copies named CONFIG.W40 and AUTOEXEC.W40.

In setups where Caldera DR-DOS 7.02 or 7.03 coexists with Windows 95, Windows’ CONFIG.SYS and AUTOEXEC.BAT remain intact, while DR-DOS utilizes separate startup files named DCONFIG.SYS and AUTODOS7.BAT.

OS/2 / Windows NT

OS/2 relies heavily on CONFIG.SYS for driver configuration and environment setup prior to launching its graphical user interface.

Within the OS/2 subsystem of Windows NT, CONFIG.SYS exists as a configuration stored in the registry for OS/2 applications.

Numerous CONFIG.SYS commands in OS/2 are undocumented.

CONFIG.SYS continues to be used by OS/2 derivatives such as eComStation and ArcaOS.

See also

External links

  • Information on AUTOEXEC.BAT and CONFIG.SYS available at Computer Hope
  • Overview of Windows 98 / MS-DOS 7.10 CONFIG.SYS commands (archived)
  • Caldera's CONFIG.SYS Command Reference (archived) – partial list of DR-DOS 7 directives
  • Details on CONFIG.SYS commands for FreeDOS
  • User Manual for PTS-DOS 2000 Pro featuring CONFIG.SYS commands (partial)
  • Unofficial German PTS-DOS FAQ (2004) containing extra CONFIG.SYS commands