SHELLHIGH (CONFIG.SYS directive)
| Company type | Configuration file |
|---|---|
| Industry | Computer software |
| Founded | 1983 |
| Headquarters | N/A , N/A |
| Products | DOS and OS/2 configuration |
CONFIG.SYS serves as the main configuration file for DOS and OS/2 operating systems. This specialized ASCII text file contains setup instructions accessible to users, which are interpreted by the operating system's DOS BIOS—usually found in IBMBIO.COM or IO.SYS—during the boot process. CONFIG.SYS was first introduced with DOS version 2.0.
Usage
The directives within CONFIG.SYS configure DOS for hardware devices, software applications, and memory management utilities. Once CONFIG.SYS has been processed, DOS launches the command interpreter specified on the SHELL line; if this line is missing, it defaults to COMMAND.COM, which subsequently executes AUTOEXEC.BAT.
Typically, the file consists of name=value instructions that adjust configurable parameters or load components such as device drivers and terminate-and-stay-resident programs (TSRs) into memory.
In DOS systems, CONFIG.SYS is located in the root directory of the bootable drive.
The same filename is also utilized by (DCP), a variant of MS-DOS developed by East-German manufacturer VEB Robotron.
Certain DOS variants check for alternative configuration filenames that override CONFIG.SYS:
Early versions of Concurrent DOS did not support CONFIG.SYS; however, later iterations including Concurrent DOS 386, Concurrent DOS XM, Multiuser DOS, and REAL/32 use CCONFIG.SYS instead (with "C" denoting "Concurrent"). Some Multiuser DOS editions employ CCONFIG.INI, while REAL/32 looks for MCONFIG.SYS. These platforms also accommodate additional configuration data stored in a binary file named CCONFIG.BIN, usually managed through CONFIG.EXE.
Under DR DOS 3.31, PalmDOS 1.0, Novell DOS 7, and DR-DOS versions 7.02 and later, DCONFIG.SYS (where "D" stands for "DR DOS") supersedes CONFIG.SYS. This arrangement supports cases such as disk compression that alter boot drive letters and facilitates multi-boot environments.
OpenDOS 7.01 and DR-OpenDOS 7.02 prioritize ODCONFIG.SYS, while some DR-DOS 7.02+ variants also seek DRCONFIG.SYS. Since DR DOS 6.0, the SYS /DR:ext command enables renaming system and configuration files to allow multiple concurrent setups within a single root directory, selectable through boot loaders like LOADER. The SHELL directive permits specifying alternative AUTOEXEC.BAT files using /P[:filename.ext], a feature supported by enhanced shells such as 4DOS. Additionally, the CHAIN=filespec command allows continuation of processing in another file, optionally targeting a particular label.
Starting with DR-DOS 7.03, the SYS /A command copies both CONFIG.SYS and AUTOEXEC.BAT alongside system files.
FreeDOS uses FDCONFIG.SYS, whereas RxDOS employs RXCONFIG.SYS. The operating system PTS-DOS utilizes CONFIG.PTS.
While both CONFIG.SYS and AUTOEXEC.BAT are present in the root directory of Windows 95 and 98 boot drives, they are typically empty. In contrast, Windows Me does not process CONFIG.SYS during startup; instead, environment variables are loaded from the Windows Registry at:
- HKLM\System\CurrentControlSet\Control\SessionManager\Environment
Within the FlexOS operating system, CONFIG.SYS is a binary file responsible for defining 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 destinations for , , , and commands.
- Functions like , but also allows inline comments following other CONFIG.SYS commands. (In MS-DOS/PC DOS, inline comments inside double quotes are not ignored.)
- Used to initiate inline comments alongside the ; directive.
- Presents a Yes/No prompt to confirm execution of subsequent CONFIG.SYS commands.[1] (FreeDOS does not support optional messages but allows conditional execution with boot menus using and .) DOS 6.0 and later versions offer similar functionality by appending after commands, e.g., , also supported by DR DOS.
- Executes the following CONFIG.SYS command unconditionally.
ATemplate:NbndC
- Determines whether programs can be interrupted on errors.
- Enables drives to record file access timestamps in reserved FAT directory entries.
- Executes conditionally on AT-compatible hardware.
- Boot manager utility.
- Adjusts verbosity level of error messages.
- Changes default serial device driver (COM1: through COM4:) for the AUX device.
- Disables character devices located outside the phantom \DEV directory.
- Loads a base device driver into memory.
- Produces a beep sound even if audible alerts are disabled.
- Specifies the operating system to boot next.
- Enables or disables extended Ctrl+C checking.
- Sets the quantity of disk buffers to allocate.
- Similar to BUFFERS but loads buffers into HMA or UMB areas (akin to HIBUFFERS in DR DOS).
- , CACHETTL, CACHEFLUSH (Embedded DOS 6-XL only)
- Manage cache block allocation and flushing behavior.
- Loads programs within CONFIG.SYS, running them in the foreground and pausing processing until they return.
- (DR-DOS 7.02+)
- Defines Caps Lock keyboard status on or off.
- , CDDBUFFERS (PTS-DOS only)
- Sets CD-ROM driver name and buffer count.
- (DR DOS 5.0+, Embedded DOS)
- Continues processing CONFIG.SYS from a new file or label.
- , CLS, CODEPAGE, CMOSADDR, COLOR (PTS-DOS or OS/2)
- Configure screen clearing, OEM codepages, CMOS RAM address, system clock type, and boot menu colors respectively.
- (DR-DOS 7.02+)
- Specifies count, order, I/O addresses, and timeouts for COM ports.
- , COMMENT(s), COUNTRY
- Define DMA buffer settings, override comment characters or ignore lines, enable international features respectively.
- , CPSW
- Sets cursor position for menus and supports codepage switching (various DOS versions).
- , CPU88-CPU486+
- Conditional execution based on CPU model or speed (PTS-DOS and DR-DOS variants).
DTemplate:NbndF
- Configures relocation settings for drive descriptor tables.
- Sets segment address limits in memory for multi-sector disk data deblocking.
- Activates internal debugger support.
- Boot manager utility.
- Loads device drivers into conventional memory.
- Loads device drivers into upper memory blocks (equivalent to in DRDOS 5.0).
- Sets country and codepage parameters for keyboard, screen, and printer devices.
- Configures cache memory sizes and parameters.
- Defines floppy disk compatibility modes.
- Specifies display font settings.
- Controls loading of DOS into high memory area and usage of upper memory blocks.
- Places DOS tables (BUFFERS, FCBS, FILES, LASTDRIVE, STACKS) into upper memory regions.
- Defines alternative search path for DOS system files.
- Specifies search paths for data files used by DOS utilities.
- Describes physical characteristics of disk drives.
- Sets parameters for drives that are not recognized automatically.
- See .
- Enables error log creation with PDUMP.nnn files on specified drives.
- Displays messages on the screen during processing.
- Shows messages including ANSI escape sequences for formatting.
- Controls additional validation checks when launching programs.
- Assigns error or return codes to assume after execution steps.
- Manages A20 gate state upon program startup.
- Terminates CONFIG.SYS processing early except for SWITCHES and SHELL commands.
- Adjusts hash table size to speed up file open operations (distinct from MS-DOS/PC DOS FASTOPEN driver).
- Defines maximum cached File Control Blocks (FCBs) allowed open simultaneously (shares buffer with FILES under DR-DOS).
- Similar to FCBS but loads FCBs into upper memory space.
- Boot manager utility command.
- Sets maximum number of files that can be open simultaneously.
- Same as FILES but loads file handles into upper memory areas.
- Executes specified subsections of CONFIG.SYS (see IGNORE).
GTemplate:NbndI
- Awaits a keypress 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 execution at a specified label, then returns to the prior point.
- Refer to , , or for additional information.
- See also .
- Consult for related details.
- Refer to or for further guidance.
- See or for more information.
- Consult .
- Loads a TSR program into memory after relocating the DOS data segment. Compare with INSTCDEX.
- Refer to , , or for related commands.
- See .
- Refer to or for additional context.
- Activates console and command line history buffer, including enhanced pattern search capabilities.
- Defines the address of the HMA segment.
- Sets up HLT mode for power saving.
- Enables scanning for boot sector viruses.
- Loads installable file system drivers.
- Prevents execution of specified CONFIG.SYS subsections.
- Grants certain programs permission to operate at CPU ring 2, allowing direct hardware I/O access.
- Incorporates directives from another menu block (emulated via GOSUB/RETURN in DR-DOS).
- Configures Insert mode status on the keyboard.
- Installs a TSR program into memory.
- Loads a TSR program into upper memory, equivalent to HIINSTALL in DR DOS 5.0.
- Installs TSR after relocating DOS data segment (compare INSTCDEX).
- Adjusts PIC interrupt priorities to prioritize a specified IRQ number.
KTemplate:NbndM
- Defines the keyboard layout configuration.
- Specifies the relocated address of the keyboard buffer.
- Sets the maximum number of accessible drives.
- Similar to LASTDRIVE but loads Current Directory Structure into upper memory.
- Establishes paths for DLL searches.
- Manages compatibility settings for legacy applications.
- Determines the number of file locks allowed.
- Controls display of boot logos and startup messages.
- Configures count, order, I/O address, and timeout parameters for LPT1 device.
- Applies similar settings as LPT1 but for LPT2 device.
- Mirrors LPT1 settings for LPT3 device configuration.
- Enables and configures LPT4 device similarly to others.
- Sets delay before elevating process priority.
- Defines memory allocation methods and strategies.
- Specifies default DOS memory allocation approach.
- Establishes menu options available during boot or operation.
- Sets color schemes for menus (can be emulated under DR-DOS).
- Determines default menu block (emulatable under DR-DOS).
- Defines individual menu blocks (emulatable under DR-DOS).
- Activates multitrack disk support functionality.
- Continues CONFIG.SYS processing from another file, optionally loading a driver and setting %NEWFILE% environment variable.
NTemplate:NbndQ
- Sets default No () response character in Yes/No/Resume prompts.
- Specifies whether keyboard [[Num Lock|Template:Keypress]] is enabled or disabled by default.
- Enables conditional execution based on previous return code or error status, e.g., .
- Displays text and waits for a key press, comparable to and in DR-DOS environments.
- Determines if user confirmation is required upon errors in CONFIG.SYS processing.
- Configures buffer sizes for LPT1, LPT2, and LPT3 devices.
- Enables conditional execution restricted to PC-compatible hardware only.
- Sets parameters for priority-based scheduling of processes.
- Adjusts priority settings specifically for disk I/O operations.
- ; Changes internal default printer driver assignment (for example, switching from LPT1 to LPT3 or LPT4).
- Specifies whether DOS programs are permitted to execute.
- Loads user interface components during startup or operation.
- ; Enables conditional execution limited to IBM PS/1-compatible systems.
- ; Enables conditional execution limited to IBM PS/2-compatible systems.
- ; Suppresses output sent to STDOUT display.
RTemplate:NbndT
- Determines whether the system should perform an automatic reboot upon encountering errors.
- Permits inclusion of comments within CONFIG.SYS.
- Reserves a specific drive letter from local block device drivers.
- Establishes the default Resume () character used in Yes/No/Resume prompts.
- Returns control from nested CONFIG.SYS processing to the prior GOSUB or SWITCH directive location, optionally passing back a return code.
- Sets the size of real mode memory.
- Functions like CALL but initiates programs in CONFIG.SYS to run simultaneously in the background.
- Indicates if the first character of deleted file names is saved in the FAT reserved area.
- Specifies video mode under FreeDOS and screen access methods under PTS-DOS.
- Defines the status of the keyboard Scroll Lock key, either on or off.
- Assigns environment variables.
- Loads the command interpreter shell.
- Similar to SHELL but supports a SIZE parameter for pre-allocating COMMAND.COM into HMA or UMBs to minimize fragmentation.
- Specifies keyboard modifier keys such as Shift Lock, Num Lock, Scroll Lock, and Insert mode states.
- Determines whether files are closed upon pressing Ctrl+Alt+Del.
- Indicates if POST (Power-On Self-Test) should be bypassed during reboot sequences.
- Sets the quantity of stacks allocated for hardware interrupts.
- Defines default stack size for newly created threads.
- Comparable to STACKS but explicitly loads buffers into upper memory areas.
- Configuration settings for the boot manager.
- Manages behavior of the XMS A20 gate.
- (DOS 6.0+)
- Defines submenu blocks, a feature not supported by DR-DOS or FreeDOS.
- Redirects error logging to a drive instead of displaying popup error screens.
- (OS/2)
- Specifies the path location for the swap file.
- (DR DOS 6.0+)
- Enables conditional continuation of nested CONFIG.SYS processing at designated labels based on key presses, with RETURN resuming previous execution points.
- (DOS variants)
- Sets the system’s default SwitChar character, typically '/' or '-'.
- (DOS 4.0, Novell DOS 7+)
- Defines special options which are ignored under PTS-DOS environments.
- (OS/2 Warp 4 FixPak+)
- Activates a fix addressing an FPU rounding issue.
- (PTS-DOS)
- Designates alternative DOS system files to boot from.
- (PTS-DOS)
- Configures memory locations for DOS components.
- (PTS-DOS)
- Loads the system from an alternative disk area.
- (Embedded DOS 6-XL)
- Specifies size of system memory pool for dynamic allocations.
- (PTS-DOS)
- Indicates whether DOS data and code should be loaded into UMBs (Upper Memory Blocks).
- (OS/2)
- Defines the number of concurrent threads permitted.
- (DR-DOS 6.0+, PTS-DOS)
- Sets timeout values for CONFIG.SYS single-step execution and default responses for queries and selections. PTS-DOS supports only timeout values.
- (OS/2)
- Configures minimum and maximum scheduler time slices.
- (PTS-DOS)
- Specifies file extensions used for temporary files.
- (DR-DOS 7.02+, PTS-DOS, OS/2)
- Enables or disables global or local single-step execution of CONFIG.SYS and AUTOEXEC.BAT. This functionality varies considerably between OS/2 and DOS platforms.
- (OS/2)
- Configures size of TRACE log buffer.
- (OS/2 3.0+)
- Logs detailed error information to assist with diagnostics.
UTemplate:NbndZ
- Configures DOS to utilize a designated segment as an Upper Memory Block (UMB).
- Defines the UMB server settings.
- Specifies address ranges allocated as UMB RAM areas.
- Enables or disables verification of disk writes.
- Sets the DOS version reported to applications.
- Manages VGA display status parameters.
- Defines current video mode, similar in function to FreeDOS's SCREEN command.
- Enables use of virtual DMA channels.
- Controls processor Virtual Mode Extensions (VME).
- Configures VxD drivers used by Windows operating systems.
- Sets Windows system support parameters.
- Relocates the Extended BIOS Data Area (XBDA).
- Executes commands conditionally on XT-compatible machines only.
- Configures Year 2000 compatibility support features.
- Sets the default 'Yes' character used in prompt responses.
- Tracks file deletions for system management purposes.
Issues
Although the system is capable of booting without CONFIG.SYS or AUTOEXEC.BAT, these files are crucial for complete operating system customization and meeting software dependencies. Any corruption or loss of these files requires diagnostic efforts.
In cases where CONFIG.SYS does not contain a SHELL command or is damaged or missing, DOS attempts to locate COMMAND.COM in the root directory of the boot drive. Earlier 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, and Novell DOS 7 and later, the system prompts the user to specify the command interpreter’s path and offers recovery options if the shell terminates unexpectedly. This functionality permits a limited runtime substitution of the shell without needing to reboot.
Because of incompatibilities between MS-DOS 7.0+ COMMAND.COM and DR-DOS, versions 7.02 and newer of DR-DOS prevent bypassing SHELL directives when using skip or trace modes, thereby enhancing stability in dual-boot scenarios. Furthermore, additional keybindings were implemented to allow recovery from invalid SHELL parameters by requesting a valid shell path before loading COMMAND.COM.
CONFIG.SYS file size restrictions differ depending on the operating system: MS-DOS and PC DOS impose limits measured in kilobytes (up to 64 KB in later releases), whereas DR-DOS effectively has no fixed size limit aside from filesystem constraints. MS-DOS processes CONFIG.SYS by tokenizing its contents and organizing directives so that device drivers load prior to TSR programs. Conversely, DR-DOS interprets directives sequentially, providing fine-grained control over the order in which drivers and TSRs load through DEVICE and INSTALL commands. This approach aids in resolving conflicts during loading and supports conditional execution based on hardware detection or user input, thereby improving customization and troubleshooting options.
The maximum length for SHELL lines varies by version: MS-DOS/PC DOS from 2.0 through 4.01 limits this to 31 characters; subsequent versions extend this limit up to 128 characters, while DR-DOS allows lines up to 255 characters long. It is important to note that CONFIG.SYS directives do not support long filenames.
Dual booting DOS and Windows 9x
When installing Windows 95 over a pre-existing DOS or Windows installation, the original CONFIG.SYS and AUTOEXEC.BAT files are renamed to CONFIG.DOS and AUTOEXEC.DOS respectively. This renaming facilitates dual-booting between Windows 9x and DOS by temporarily restoring these files under their original names when booting into DOS mode. Additionally, backup copies for Windows 95 versions are saved as CONFIG.W40 and AUTOEXEC.W40.
If Caldera DR-DOS versions 7.02 or 7.03 are installed alongside Windows 95, the Windows CONFIG.SYS and AUTOEXEC.BAT remain intact without modification. Instead, DR-DOS uses its own startup files named DCONFIG.SYS and AUTODOS7.BAT.
OS/2 / Windows NT
OS/2 relies heavily on CONFIG.SYS for setting up device drivers and environment variables prior to launching its graphical interface.
Within the OS/2 subsystem of Windows NT, CONFIG.SYS is presented to OS/2 applications but is actually stored within the Windows registry rather than as a physical file.
There exists a variety of undocumented CONFIG.SYS commands specific to OS/2.
CONFIG.SYS continues to be utilized by 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
- AUTOEXEC.BAT and CONFIG.SYS details at Computer Hope
- Overview of Windows 98 / MS-DOS 7.10 CONFIG.SYS commands (archived)
- Caldera’s CONFIG.SYS Command Reference (archived) – summary of DR-DOS 7 directives
- Documentation on FreeDOS CONFIG.SYS commands
- PTS-DOS 2000 Pro User Guide – includes PTS-DOS CONFIG.SYS instructions (archived)
- German-language unofficial PTS-DOS FAQ (2004) – extended CONFIG.SYS commands (archived)
- ↑ Cite error: Invalid
<ref>tag; no text was provided for refs namedPaul_2000_CONFIG