LOADFIX (CONFIG.SYS directive)
| Company type | Configuration file |
|---|---|
| Industry | Computer software |
| Founded | 1983 |
| Headquarters | N/A , N/A |
| Products | System configuration for DOS and OS/2 |
CONFIG.SYS serves as the main configuration file for DOS and OS/2 operating systems. This plain text file, written in ASCII, holds setup instructions accessible to users, which are interpreted by the operating system's DOS BIOS—commonly found in IBMBIO.COM or IO.SYS—during the boot sequence. The CONFIG.SYS file was first introduced with DOS version 2.0.
Usage
The directives within CONFIG.SYS are responsible for setting up DOS to manage devices, applications, and memory allocation. Once CONFIG.SYS has been processed, DOS launches the command interpreter specified by the SHELL command; if none is specified, it defaults to COMMAND.COM, which then executes commands from the AUTOEXEC.BAT file.
Typically, this file consists of name=value pairs that define configurable options or load device drivers and terminate-and-stay-resident (TSR) utilities into memory.
In DOS environments, CONFIG.SYS is located in the root directory of the system’s boot drive.
Certain MS-DOS variants and alternative DOS implementations check for different configuration filenames that override CONFIG.SYS:
- Systems such as Concurrent DOS 386, Concurrent DOS XM, Multiuser DOS, and REAL/32 utilize CCONFIG.SYS or CCONFIG.INI (specific to Multiuser DOS), or MCONFIG.SYS in REAL/32. These platforms support advanced configuration stored in binary files like CCONFIG.BIN, typically managed via a utility named CONFIG.EXE.
- Starting from DR DOS version 3.31 and including versions like PalmDOS 1.0, Novell DOS 7, and DR-DOS 7.02+, the DCONFIG.SYS file takes precedence over CONFIG.SYS to facilitate features such as disk compression and multi-boot setups.
- OpenDOS 7.01 and DR-OpenDOS 7.02 recognize alternative configuration files such as ODCONFIG.SYS or DRCONFIG.SYS.
From DR-DOS 6.0 onward, users can customize default system file extensions using the SYS /DR:ext command, allowing multiple system files with different extensions to coexist within a single root directory. Boot loaders like LOADER, included with Multiuser DOS and DR-DOS, enable selection between these variants during startup.
The SHELL directive offers enhanced functionality by allowing specification of alternate AUTOEXEC.BAT files through the /P[:filename.ext] parameter, supporting extensions beyond ".BAT"—a feature also available in 4DOS.
DR-DOS 6.0+ introduces the CHAIN=filespec directive to continue processing additional configuration files located anywhere on the boot drive. From DR-DOS 7.02 onward, an optional label argument (CHAIN=filespec,label) allows targeted jumps within these files.
With DR-DOS 7.03 and later versions, the SYS /A command option copies associated CONFIG.SYS and AUTOEXEC.BAT files alongside system files during setup.
Other DOS derivatives incorporate comparable mechanisms:
- FDCONFIG.SYS is used by FreeDOS - RXCONFIG.SYS appears in RxDOS version 7.24 and above - CONFIG.PTS is employed by PTS-DOS
Windows 95 and Windows 98, which are built upon DOS foundations, include CONFIG.SYS and AUTOEXEC.BAT files within their root directories but generally leave them empty.
Unlike its predecessors, Windows Me does not process CONFIG.SYS during startup; instead, it retrieves environment variables directly from the Windows Registry at HKLM\System\CurrentControlSet\Control\SessionManager\Environment.
In contrast, under the FlexOS operating system, CONFIG.SYS is a binary format file that specifies resource managers and device drivers loaded during boot time.
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 points for , , , and commands.
- Similar to , but also allows inline comments following other CONFIG.SYS instructions. (Note that in MS-DOS/PC DOS, inline comments enclosed in double quotes are not ignored.)
- Used to initiate inline comments alongside the ; directive.
- Prompts a Yes/No confirmation with an optional message before executing subsequent CONFIG.SYS commands. (FreeDOS supports conditional boot menus through and .) DOS version 6.0 and later allow similar functionality by appending after directives (e.g., ).
- Forces execution of the immediately following CONFIG.SYS command without condition.
ATemplate:NbndC
- Determines whether programs can be interrupted on errors.
- Sets which drives will record file access timestamps in FAT directory entries.
- Enables conditional execution on AT-compatible hardware.
- Boot loader utility.
- Adjusts the verbosity level of error messages.
- Changes the default serial driver assigned to the AUX: device.
- Disables character devices outside the virtual \DEV directory.
- Loads fundamental device drivers into conventional memory.
- Causes a beep sound even if system notifications are turned off.
- Defines the operating system to boot next.
- Enables or disables extended Ctrl+C checking.
- Specifies how many disk buffers to allocate.
- Similar to BUFFERS but loads buffers into High Memory Area or Upper Memory Blocks.
- , CACHETTL, CACHEFLUSH (Embedded DOS 6-XL only)
- Configure cache block lifetimes and flushing behaviors.
- Executes programs within CONFIG.SYS and pauses processing until they return control.
- (DR-DOS 7.02+)
- Sets keyboard Caps Lock state upon startup.
- , CDDBUFFERS (PTS-DOS only)
- Defines CD-ROM driver name and buffer quantity.
- (DR DOS 5.0+, Embedded DOS)
- Continues CONFIG.SYS processing from a new file or label.
- , CLS, CODEPAGE (PTS-DOS or OS/2)
- Configure system clock type, clear screen command, and OEM codepages.
- , COLOR (PTS-DOS only)
- Sets CMOS RAM address and boot menu colors.
- , COM2, COM3, COM4 (DR-DOS 7.02+)
- Configure serial port count, order, I/O addresses, and timeouts.
- , COMMENT(S) (PTS-DOS or DOS 4.0+)
- Specifies DMA buffer usage and inline comment handling.
- (DOS 3.0+, DR DOS 3.31+, OS/2)
- Activates internationalization support features.
- , CPSW (DR DOS or MS-DOS legacy)
- Cursor positioning for menus and codepage switching support.
- CPU-specific directives (PTS-DOS and DR-DOS) allow conditional execution based on processor type or speed.
This group of directives encompasses essential configuration settings for system startup behavior, device handling, and hardware compatibility, which are crucial for optimizing legacy DOS systems in professional environments.
DTemplate:NbndF
- Adjusts relocation of drive descriptor tables in memory.
- Defines memory segment address used for multi-sector disk data deblocking.
- Activates internal debugger functionality.
- Boot management utility.
- Loads device drivers into conventional memory space.
- Loads device drivers into upper memory areas (equivalent to in DRDOS 5.0).
- Sets country codes and codepage information for keyboard, screen, and printer devices.
- Configures sizes of cache memory regions.
- Defines floppy disk compatibility modes.
- Specifies font used for display output.
- Controls loading of DOS into high or upper memory blocks (similar to in DRDOS 5.0).
- Loads DOS internal tables such as BUFFERS, FCBS, FILES, LASTDRIVE, STACKS into upper memory areas.
- Specifies alternate directory paths for DOS system files.
- Defines search paths for data files.
- Describes physical parameters of disk drives.
- Sets parameters for drives not natively recognized by the system.
- See .
- Allows drive specification for PDUMP.nnn error log files.
- Enables message display on screen during processing.
- Enables message display using ANSI escape sequences.
- Activates additional program startup validation checks.
- Sets expected error or return codes for subsequent commands.
- Configures A20 gate state upon program launch.
- Terminates CONFIG.SYS processing early except for SWITCHES and SHELL directives under certain conditions.
- Defines hash table size used to speed up file opening operations, differing from MS-DOS/PC DOS FASTOPEN driver behavior.
- Specifies number of cached File Control Blocks (FCBs); shares buffer with FILES under DR-DOS implementations.
- Similar to FCBS but loads FCBs into upper memory regions.
- Boot management tool.
- Defines maximum number of simultaneously open files allowed by the system.
- Like FILES but loads file handles into upper memory blocks.
- Includes execution of specified subsections within CONFIG.SYS (refer to 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.
- Resumes nested CONFIG.SYS processing at a specified label, then returns control to the previous point.
- Refer to , , or for additional details.
- See related commands , , and .
- Consult documentation for and commands.
- Refer to or for further information.
- See also or commands.
- Refer to documentation on .
- Loads a terminate-and-stay-resident (TSR) program into memory after DOS relocates its data segment; compare with INSTCDEX.
- Consult , , or for more details.
- See additional references and .
- Review documentation on or commands.
- Activates console and command line history buffer with enhanced pattern search capabilities.
- Defines the HMA (High Memory Area) segment address.
- Configures energy-saving mode using HLT instruction.
- Enables scanning of boot sectors for viruses.
- Loads installable file system drivers.
- Prevents execution of certain CONFIG.SYS subsections.
- Grants specific programs permission to run at ring 2, allowing direct hardware I/O access.
- Includes directives from another menu block, which can be emulated by GOSUB/RETURN in DR-DOS.
- Sets the status of keyboard Insert mode.
- Loads a TSR program into memory.
- Loads a TSR program into upper memory, equivalent to HIINSTALL in DR DOS 5.0.
- Installs TSR program after relocation of DOS data segment (see also INSTCDEX).
- Adjusts PIC interrupt priorities to assign highest priority to a given IRQ number.
KTemplate:NbndM
- Defines the keyboard layout configuration.
- Specifies the location of the relocated keyboard buffer in memory.
- Sets the maximum number of accessible drives allowed by DOS.
- Functions like LASTDRIVE but loads Current Directory Structure (CDS) into upper memory regions.
- Indicates search paths for dynamic link libraries (DLLs).
- Controls compatibility handling for legacy software applications.
- Determines the number of file locks permitted simultaneously.
- Configures boot logo display when using PTS-DOS boot manager.
- Sets parameters such as count, order, I/O port address, and timeout duration for the LPT1 device.
- Similarly configures LPT2 device settings.
- Applies equivalent configuration to LPT3 device.
- Enables and configures LPT4 parallel port device functionality.
- Defines delay before elevating process priority during execution.
- Specifies memory allocation strategy preferences.
- Sets default DOS memory allocation method used by the system.
- Establishes menu option definitions within CONFIG.SYS environment.
- Specifies color schemes for menus, which can be emulated under DR-DOS systems.
- Assigns default menu block, emulatable in DR-DOS environments.
- Defines multiple menu blocks for system use, emulatable in DR-DOS as well.
- Enables multitrack disk drive operations support.
- Continues processing CONFIG.SYS directives from an external file, optionally after loading a driver and setting %NEWFILE% environment variable.
NTemplate:NbndQ
- Sets default "No" character response in Yes/No/Resume type prompts.
- Determines whether keyboard [[Num Lock|Template:Keypress]] is activated or deactivated by default.
- Enables conditional execution based on the last error code returned by previous commands (e.g., ).
- Displays text and waits for user keypress, similar to and commands in DR-DOS systems.
- Requires user confirmation when errors occur during CONFIG.SYS processing.
- Configures buffer sizes assigned to LPT parallel ports.
- Allows conditional execution based on PC-compatible hardware detection.
- Adjusts scheduler priority settings within the operating system environment.
- Sets priority levels specifically for disk input/output programs to optimize performance.
- Changes default printer device driver assignment among LPT1 through LPT4 ports.
- Specifies whether DOS applications are permitted to execute under current configuration settings.
- Loads user interface components during system startup or configuration processing.
- Enables conditional execution based on IBM PS/1-compatible hardware detection.
- Enables conditional execution based on IBM PS/2-compatible hardware detection criteria.
- Suppresses output sent to standard output (STDOUT) display device.
RTemplate:NbndT
- Activates automatic system reboot upon encountering errors.
- Permits inclusion of comments within CONFIG.SYS.
- Allocates drive letters to local block device drivers.
- Sets the default character for Resume () prompts in Yes/No/Resume dialogs.
- Facilitates returning from nested CONFIG.SYS processing to the previous GOSUB or SWITCH point, optionally with a return code.
- Specifies the size of real mode memory.
- Enables simultaneous loading of programs in CONFIG.SYS in the background, similar to CALL or INSTALL commands found in DOS variants.
- Determines whether the initial character of deleted files is stored in the FAT reserved area.
- Configures video mode (FreeDOS) or screen access methods (PTS-DOS).
- Controls the Scroll Lock keyboard state, turning it on or off.
- Assigns environment variables.
- Loads the command interpreter shell.
- Functions like SHELL but supports a SIZE parameter for pre-allocating COMMAND.COM into HMA or UMBs to minimize fragmentation.
- Defines keyboard modifier states such as Shift Lock, Num Lock, Scroll Lock, and Insert mode.
- Specifies if files should close when Ctrl+Alt+Del is pressed.
- Bypasses POST during system reboot.
- Sets the quantity of stacks allocated for hardware interrupts.
- Establishes the default stack size for newly created threads.
- Similar to STACKS but loads buffers into upper memory blocks.
- Configures boot manager settings.
- Reserved for internal system use.
- Manages the behavior of the XMS A20 gate.
- Defines submenu blocks emulated through CLS, ECHO, and SWITCH commands in DR-DOS.
- Records error details to a drive instead of displaying a popup message.
- Indicates the path for swap file storage.
- Enables conditional nested CONFIG.SYS processing based on pressed keys with return to previous location.
- Sets the default system switch character, either '/' or '-'.
- Specifies special operational options.
- Activates a correction for floating-point unit rounding errors.
- Defines an alternative DOS operating system filename for boot purposes.
- Configures memory locations for DOS components.
- { { nob old |( PTS - DOS only ) } }
- Loads system from an alternate disk region .
;{ { anchor |SYSTEMPOOL } }{ { mono |1 = SYSTEMPOOL } }{ { nob old |( Embedded DOS 6 - XL only ) } }: Size allocated to dynamic system memory pool .
;{ { anchor |SYSTOUMB } }{ { mono |1 = SYSTOUMB } }{ { nob old |( PTS - DOS only ) } }: Loads DOS data and code into upper memory blocks .
;{ { anchor |THREADS } }{ { mono |1 = THREADS } }{ { nob old |( OS/2 only ) } }: Number of threads running concurrently .
;{ { anchor |TIMEOUT } }{ { mono |1 = TIMEOUT } }{ { nob old |( DR-DOS 6.0+ and PTS-DOS only ) } }: Timeout parameters for CONFIG.SYS single-step execution, SWITCH, GETKEY, ? commands, and default responses to Yes/No queries .
;{ { anchor |TIMESLICE } }{ { mono |1 = TIMESLICE } }{ { nob old |( OS/2 only ) } }: Scheduler time slice configuration .
;{ { anchor |TMPEXT } }{ { mono |1 = TMPEXT } }{ { nob old |( PTS-DOS only ) } }: Temporary file extension designation .
;{ { anchor |TRACE } }{ { mono |1 = TRACE } }{ { nob old |( DR-DOS 7.02+, PTS-DOS, OS/2 ) } }: Enables or disables single-step execution of CONFIG.SYS (and AUTOEXEC.BAT) .
;{ { anchor |TRACEBUF } }{ { mono |1 = TRACEBUF } }{ { nob old |( OS/2 only ) } }: Size of the TRACE log buffer .
;{ { anchor |TRAPDUMP} }{ { mono |1 = TRAPDUMP} }{ { nob old |( OS/2 3.0+ )} }: Captures detailed error dump information .
UTemplate:NbndZ
- Assigns a particular segment for use as an Upper Memory Block (UMB) in DOS.
- Designates the UMB server.
- Specifies address ranges allocated for UMB RAM.
- Toggles disk write verification on or off.
- Indicates the reported DOS version.
- Configures the status of the VGA display.
- Determines the active video mode.
- Activates virtual DMA functionality.
- Manages processor Virtual Mode Extensions (VME).
- Sets parameters for the Windows VxD driver.
- Oversees Windows system support features.
- Relocates the Extended BIOS Data Area (XBDA).
- Executes conditionally on XT-compatible hardware.
- Adjusts Year 2000 compliance settings.
- Defines the default affirmative character in prompts.
- Monitors driver deletion activities.
Issues
Although the system can start without CONFIG.SYS or AUTOEXEC.BAT, these configuration files are critical for tailoring the operating system and loading necessary software components. When either file is corrupted or missing, troubleshooting becomes necessary.
If CONFIG.SYS does not contain a SHELL directive or if it is damaged or absent, DOS attempts to locate COMMAND.COM in the root directory of the boot drive. Versions of DOS prior to 6.0 will fail to boot if COMMAND.COM is unavailable. From MS-DOS 6.0/PC DOS 6.1 onwards, as well as Novell DOS 7 and similar systems, a prompt appears requesting the path to a command interpreter if COMMAND.COM is missing or terminated prematurely, enabling limited shell substitution during runtime without requiring a reboot.
COMMAND.COM from MS-DOS version 7.0 and later is incompatible with DR-DOS. In dual-boot configurations, this incompatibility prevents bypassing SHELL directives during skip, trace, or step modes (activated by Ctrl+F5/F7/F8). Some subsequent DR-DOS updates restored skip functionality (Ctrl+F6) to recover from invalid SHELL parameters. If skipping CONFIG.SYS fails to find a valid shell, users are prompted to specify one before COMMAND.COM loads.
The maximum size of CONFIG.SYS varies depending on the operating system: MS-DOS and PC DOS limit these files to a few kilobytes (up to approximately 64 KB in recent releases), whereas DR-DOS imposes no explicit size restriction beyond file system limitations. MS-DOS processes CONFIG.SYS by compiling it into a tokenized format that executes sequentially—loading device drivers before TSRs—while DR-DOS interprets its directives line-by-line, allowing fine-tuned control over load order through DEVICE and INSTALL commands. This approach facilitates resolving driver conflicts and supports conditional execution based on hardware detection, user input, or error conditions. Notably, DR-DOS permits INSTALL to launch non-resident programs within the CONFIG.SYS processing flow.
Early versions of MS-DOS restricted the SHELL command line length to 31 characters; later versions expanded this limit to 128 characters, with DR-DOS supporting up to 255 characters. None of the CONFIG.SYS directives support long filenames.
Dual booting DOS and Windows 9x
When Windows 95 is installed over an existing DOS/Windows environment, its installation renames CONFIG.SYS and AUTOEXEC.BAT to CONFIG.DOS and AUTOEXEC.DOS respectively to enable dual-boot functionality between Windows 9x and DOS. When booting into DOS mode, these files are temporarily renamed back to CONFIG.SYS and AUTOEXEC.BAT. Additionally, backups of the Windows 95 versions are stored as CONFIG.W40 and AUTOEXEC.W40.
In setups where Caldera DR-DOS versions 7.02 or 7.03 coexist with Windows 95, Windows retains its original CONFIG.SYS and AUTOEXEC.BAT filenames, while DR-DOS uses DCONFIG.SYS and AUTODOS7.BAT as its startup configuration files.
OS/2 / 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 presented to OS/2 applications, although it is actually maintained within the system registry.
There are many CONFIG.SYS commands in OS/2 that remain undocumented.
CONFIG.SYS continues to be utilized by 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 commands (archived)
- Caldera's CONFIG.SYS Command Reference (archived) – summary of DR-DOS 7 directives
- Guide to FreeDOS CONFIG.SYS commands
- PTS-DOS 2000 Pro User Manual detailing CONFIG.SYS directives (archived)
- German-language unofficial PTS-DOS FAQ (PTS/FAQD) including CONFIG.SYS directives