BOOTNEXT (CONFIG.SYS directive)
| Company type | Configuration file |
|---|---|
| Industry | Operating system software |
| Founded | 1983 |
| Products | Configuration for DOS and OS/2 boot process |
CONFIG.SYS serves as the chief configuration file for DOS and OS/2 operating systems. This plain text file, written in ASCII, holds user-modifiable setup instructions that the operating system's DOS BIOS—usually found in IBMBIO.COM or IO.SYS—interprets during the boot process. The CONFIG.SYS file was first introduced with DOS version 2.0.
Usage
The directives within CONFIG.SYS are used to configure 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 indicated, it defaults to COMMAND.COM, which then executes AUTOEXEC.BAT.
Typically, the file contains name=value pairs that set adjustable parameters or load components such as device drivers and terminate-and-stay-resident programs (TSRs) into memory. CONFIG.SYS is located in the root directory of the system’s boot partition.
Certain MS-DOS variants and related operating systems employ alternative filenames that override CONFIG.SYS:
- Early versions of Concurrent DOS did not support CONFIG.SYS; however, subsequent editions like Concurrent DOS 386, Concurrent DOS XM, Multiuser DOS, System Manager, and REAL/32 utilize CCONFIG.SYS or CCONFIG.INI (in Multiuser DOS) and MCONFIG.SYS (in REAL/32). These platforms manage configuration data through binary files such as CCONFIG.BIN, which are controlled by the CONFIG.EXE utility.
- In DR DOS 3.31 and later releases—including PalmDOS 1.0, Novell DOS 7, OpenDOS 7.01, and DR-DOS 7.02+—the filename DCONFIG.SYS takes precedence over CONFIG.SYS. This arrangement supports multi-boot environments and disk compression scenarios where drive letters may change after loading compression drivers.
- OpenDOS 7.01 and DR-OpenDOS 7.02 additionally check for ODCONFIG.SYS, while certain DR-DOS 7.02+ versions also recognize DRCONFIG.SYS. The command SYS /DR:ext enables renaming of system files to facilitate multiple parallel configurations within a single root directory, selectable via boot loaders such as LOADER.
- Starting from DR-DOS 6.0, enhancements to the SHELL directive allow specifying alternative AUTOEXEC.BAT files. Moreover, the CHAIN=filespec[,label] directive permits continued processing of supplementary configuration files located outside the root directory.
- DR-DOS 7.03 and subsequent versions introduce a SYS /A option to copy CONFIG.SYS and AUTOEXEC.BAT alongside other system files.
Other DOS-based systems have implemented comparable features: for instance, FreeDOS uses FDCONFIG.SYS, RxDOS employs RXCONFIG.SYS, and PTS-DOS utilizes CONFIG.PTS.
In Windows 95 and Windows 98, which are built on DOS foundations, CONFIG.SYS and AUTOEXEC.BAT remain present in the root of the boot drive but are generally left empty. With Windows Me, CONFIG.SYS is no longer parsed during startup; instead, environment variables are loaded from the Windows Registry.
In contrast, under the FlexOS operating system, CONFIG.SYS exists as a binary file that specifies resource managers and device drivers to be loaded at 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 in CONFIG.SYS to serve as jump targets for , , , , and commands.
- Functions similarly to , but additionally supports in-line comments following other CONFIG.SYS instructions. (Note: In MS-DOS/PC DOS, inline comments enclosed in double quotes are not ignored.)
- Used to initiate in-line commentary alongside the ; directive.
- Prompts a Yes/No confirmation with an optional message before executing subsequent CONFIG.SYS commands. (FreeDOS extends this with conditional support via boot menus.) DOS version 6.0 and later offers a comparable feature by appending after the command (e.g., ).
- Forces unconditional execution of the next CONFIG.SYS command.
ATemplate:NbndC
- Determines whether programs can be aborted when errors occur.
- Sets which drives record file access timestamps within FAT file systems.
- Triggers conditional execution on AT-compatible computers.
- Acts as a boot manager utility.
- Adjusts verbosity level for error reporting.
- Alters the default internal serial device driver assignment (COM1: through COM4:) for the AUX device.
- Prevents character devices from being accessible outside the phantom \DEV directory.
- Loads fundamental device drivers into memory.
- Produces a brief beep even if audible alerts are disabled.
- Defines the operating system to boot next in sequence.
- Enables or disables extended Ctrl+C interrupt checking.
- Specifies the quantity of disk buffers to allocate.
- Similar to BUFFERS, but allocates buffers within HMA or UMB memory areas.
- , , (Exclusive to Embedded DOS 6-XL)
- Adjusts cache block allocation and flushing settings.
- Executes programs within CONFIG.SYS, running them in the foreground and suspending CONFIG.SYS processing until completion.
- Sets the keyboard Caps Lock state (on or off).
- , (PTS-DOS only)
- Configures CD-ROM driver name and buffer count parameters.
- Continues processing CONFIG.SYS from another file or label reference.
- , , and other directives specify system clock types or clear the screen (available in DR DOS 6.0+).
- , etc., manage OEM codepage configurations (OS/2 environments).
- , ..., COM4 (DR-DOS 7.02+) define serial device counts, order, I/O addresses, and timeouts.
- , etc., redefine inline-comment characters or instruct various DOS versions to ignore specific lines.
- , enable internationalization support (DOS 3.0+, DR DOS 3.31+, OS/2).
- CPU... directives (PTS-DOS only) allow conditional execution based on CPU architecture (8088, 286, 386, etc.).
This concise overview highlights essential directives for managing system configuration within DOS platforms, vital for optimizing legacy system functionality and ensuring compatibility across enterprise IT infrastructures.
DTemplate:NbndF
- Manages relocation of drive descriptor tables in memory.
- Defines memory segment address used for multi-sector disk data deblocking operations.
- Activates internal debugger functionality.
- Functions as a boot manager component.
- Loads device drivers into conventional memory space.
- Loads device drivers into upper memory blocks (equivalent to in DRDOS 5.0).
- Sets country-specific and codepage information applicable to keyboard, screen, and printer devices.
- Configures sizes of cache memory allocations.
- Determines floppy disk compatibility modes.
- Selects display font parameters.
- Controls loading of DOS into high or upper memory areas (similar behavior to in DRDOS 5.0).
- Loads DOS data tables such as BUFFERS, FCBS, FILES into upper memory regions.
- Specifies an alternative file search path for DOS operations.
- Defines search paths for data files used by applications.
- Establishes physical disk drive parameters for system recognition.
- Sets parameters for drives that are otherwise unrecognized by the system.
- Refer to .
- Enables error log creation with
PDUMP.nnnfiles on specified drives. - Outputs a message on-screen during processing.
- Displays messages incorporating ANSI escape sequences for enhanced formatting.
- Enforces additional validation checks when launching programs.
- Assigns assumed error or return codes for subsequent command processing logic.
- Controls A20 line gating state during program startup routines.
- Terminates CONFIG.SYS processing prematurely, except for certain SWITCHES and SHELL commands that still execute afterward.
- Configures hash table size to accelerate file open operations (distinct from MS-DOS/PC DOS FASTOPEN).
- Sets number of cached File Control Blocks allowed open simultaneously (shares buffer space with FILES under DR-DOS).
- Similar to FCBS but loads File Control Blocks into upper memory segments.
- Functions as a boot manager utility within CONFIG.SYS processing.
- Specifies maximum number of files that can be open concurrently by the system.
- Similar to FILES but loads file handles into upper memory areas for optimization purposes.
- Includes execution of designated subsections within CONFIG.SYS files (see IGNORE directive).
GTemplate:NbndI
- Waits for a key press or times out, setting the error level to the ASCII value or 1024 if timed out.
- Resumes CONFIG.SYS processing at a given label.
- Processes nested CONFIG.SYS commands at a label, allowing return with .
- Refer to , , or for details.
- See also .
- Reference .
- Consult or for more information.
- Check or for related commands.
- Additional information available in .
- Loads a TSR after relocating the DOS data segment. Compare with INSTCDEX.
- See , , or for further details.
- Refer to .
- Consult or for related functionality.
- Enables history buffers for the console and command line, including extended search capabilities.
- Defines the address of the High Memory Area (HMA) segment.
- Configures energy-saving via HLT instruction.
- Performs boot sector virus detection.
- Loads installable filesystem drivers.
- Prevents execution of specified CONFIG.SYS subsections.
- Permits programs to operate at ring 2, granting direct hardware I/O access.
- Incorporates directives from another menu block (emulated using GOSUB/RETURN in DR-DOS).
- Sets the keyboard’s Insert mode status.
- Installs a TSR program into conventional memory.
- Loads a TSR into upper memory (equivalent to HIINSTALL in DR DOS 5.0).
- Installs TSR after relocating DOS data segment. Compare with INSTCDEX.
- Adjusts PIC interrupt priority by rotating it to prioritize a specific IRQ number.
KTemplate:NbndM
- Defines the keyboard layout configuration.
- Specifies the relocated address for the keyboard buffer.
- Sets the maximum number of accessible drives.
- Similar to LASTDRIVE but loads Current Directory Structure (CDS) into upper memory.
- Specifies paths for DLL searches.
- Manages backward compatibility with legacy software.
- Determines the number of file locks allowed.
- Configures boot logo display using PTS-DOS boot manager.
- Defines count, order, I/O port, and timeout settings for LPT1 device.
- Same as LPT1 configuration but applies to LPT2 device.
- Identical to LPT1 but configured for LPT3 device.
- Enables and configures LPT4 device similarly to others.
- Sets wait duration before elevating process priority.
- Configures strategy for memory allocation.
- Specifies default DOS memory allocation parameters.
- Defines menu options available during boot or configuration.
- Specifies colors used in menus (can be emulated with ECHO commands in DR-DOS).
- Sets the default menu block (emulatable via TIMEOUT and SWITCH in DR-DOS).
- Defines individual menu blocks (can be emulated using ECHO and SWITCH commands in DR-DOS).
- Enables multitrack disk operations support.
- Continues CONFIG.SYS processing from another file, optionally loading a device driver and setting %NEWFILE% environment variable.
NTemplate:NbndQ
- Sets the default "No" character response in Yes/No/Resume prompts.
- Determines whether keyboard [[Num Lock|Template:Keypress]] is enabled or disabled by default.
- Executes conditionally based on the last error code or return status, e.g. .
- Similar to and , displays text and waits for user key press.
- Requires user confirmation of errors encountered during CONFIG.SYS processing.
- Configures buffer sizes for LPT1, LPT2, and LPT3 devices.
- Executes conditionally on PC-compatible systems only.
- Configures priority scheduling parameters.
- Sets priority levels specifically for disk I/O processes.
- Changes default printer device driver assignment among LPT1 through LPT4 ports.
- Specifies whether DOS applications are permitted to run.
- Loads a user interface component or shell extension.
- Conditional execution limited to IBM PS/1-compatible machines.
- Conditional execution limited to IBM PS/2-compatible machines.
- Silences output directed to STDOUT.
RTemplate:NbndT
- Enables automatic system reboot upon encountering errors.
- Permits inclusion of comments within CONFIG.SYS files.
- Allocates drive letters for local block device drivers.
- Sets the default response character for Yes/No/Resume prompts.
- Returns control from nested CONFIG.SYS processing back to the previous GOSUB or SWITCH command, optionally providing a return code.
- Specifies the amount of real mode memory available.
- Allows simultaneous loading of programs in CONFIG.SYS by running them in the background.
- Determines whether the first character of deleted files is stored in the FAT reserved area.
- Configures video mode settings for FreeDOS or screen access methods under PTS-DOS.
- Controls the keyboard Scroll Lock state, enabling it on or off.
- Defines environment variables for system use.
- Loads the command interpreter shell.
- Functions like SHELL but includes a SIZE parameter to pre-allocate COMMAND.COM into HMA or UMBs, preventing fragmentation with third-party shells.
- Specifies keyboard modifier keys such as Shift Lock, Num Lock, Scroll Lock, and Insert mode status.
- Controls whether files close upon pressing Ctrl+Alt+Del.
- Determines if POST (Power-On Self-Test) is bypassed during reboot.
- Sets the number of hardware interrupt stacks.
- Defines default stack size for newly created threads.
- Similar to STACKS but loads buffers into upper memory areas.
- Configures boot manager settings.
- Manages behavior of the XMS A20 gate.
- Defines submenu blocks (can be simulated using CLS, ECHO, SWITCH commands in DR-DOS).
- Redirects error logging to a file instead of displaying a popup window.
- Specifies the path for swap files.
- Enables conditional continuation of nested CONFIG.SYS processing at specified labels based on pressed keys, with RETURN returning control to the previous location.
- Sets the default system switch character (either '/' or '-').
- Defines special configuration options.
- Activates a patch addressing an FPU rounding error.
- Specifies an alternative DOS operating system filename for booting.
- Configures memory placement for DOS components.
- Loads system files from an alternate disk region.
- Defines size for dynamic allocation of system memory pools.
- Loads DOS data and code into Upper Memory Blocks (UMBs).
- TIMEOUT (DR{nbh}DOS 6.0 and later, PTS-DOS only) sets timeouts for single-stepping commands in config.sys such as SWITCH, GETKEY, and default answers for yes/no prompts. PTS-DOS supports timeout values.
- TIMESLICE (OS/2 only) configures minimum and maximum time slices used by the scheduler.
- TMPEXT (PTS-DOS only) specifies the file extension used for temporary files.
- TRACE (DR-DOS 7.02 and above, PTS-DOS, OS/2) enables or disables single-stepping globally or locally in config.sys and autoexec.bat. Functionality varies significantly between OS/2 and DOS environments.
- TRACEBUF (OS/2 only) sets the size of the trace log buffer.
- TRAPDUMP (OS/2 3.0 and later) logs detailed error information for debugging purposes.
UTemplate:NbndZ
- Directs DOS to allocate a designated segment as UMB memory.
- Sets up the UMB handler.
- Defines address intervals utilized as UMB RAM.
- Toggles disk write verification on or off.
- Determines the DOS version presented to applications.
- Adjusts VGA display status settings.
- Specifies the active video mode.
- Activates virtual DMA functionality.
- Manages the processor's Virtual Mode Extensions (VME).
- Configures VxD drivers for Windows environments.
- Sets up Windows system support parameters.
- Moves the Extended BIOS Data Area (XBDA) to a new location.
- Executes conditionally on XT-compatible hardware.
- Enables built-in Year 2000 compliance features.
- Defines the default affirmative character in prompts.
- Controls tracking of file deletions.
Issues
While the system can initiate startup without CONFIG.SYS, both this file and AUTOEXEC.BAT are critical for comprehensive DOS customization and software compatibility. Damage or absence of these files requires diagnostic intervention.
In cases where CONFIG.SYS does not contain a SHELL command or if it is corrupted or missing, 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. Conversely, MS-DOS 6.0, PC DOS 6.1, and Novell DOS 7 and later will prompt users to specify the path to a command interpreter. This prompt also appears when the main command processor terminates unexpectedly or is manually exited, providing a limited shell alternative without needing to reboot.
The COMMAND.COM from MS-DOS 7.0 and newer is incompatible with DR-DOS but is frequently found in the C: root directory on dual-boot systems. DR-DOS versions 7.02 and above prevent skipping SHELL directives during skip, trace, or step modes (Ctrl+F5/F7/F8). Later releases introduced Ctrl+F6 as a means to revert to prior skip behavior, aiding recovery from invalid SHELL parameters. If no valid SHELL directive is detected when skipping CONFIG.SYS, users are prompted to provide a valid shell before COMMAND.COM loads.
The maximum size of CONFIG.SYS varies: MS-DOS and PC DOS impose limits of several kilobytes (recently up to 64 KB), whereas DR-DOS effectively has no limit since it processes lines sequentially rather than tokenizing them. This method grants precise control over driver and TSR loading order via DEVICE and INSTALL, facilitating conflict resolution and debugging, as well as conditional execution based on hardware presence or user input.
MS-DOS/PC DOS versions from 2.0 through 4.01 restrict SHELL lines to 31 characters. Later editions permit up to 128 characters, while DR-DOS allows up to 255 characters. CONFIG.SYS commands do not support 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, enabling dual-boot functionality. During DOS startup, these files are temporarily restored as CONFIG.SYS and AUTOEXEC.BAT, whereas backups of the Windows 95 versions are saved under CONFIG.W40 and AUTOEXEC.W40.
In setups where Caldera DR-DOS 7.02 or 7.03 coexists with Windows 95, the Windows CONFIG.SYS and AUTOEXEC.BAT remain unaltered. Instead, DR-DOS uses alternative startup files named DCONFIG.SYS and AUTODOS7.BAT.
OS/2 / Windows NT
OS/2 depends extensively on CONFIG.SYS to set up drivers and the environment prior to launching its graphical user interface.
Within the OS/2 subsystem found in Windows NT, CONFIG.SYS is presented to OS/2 applications as usual, though it is actually maintained within the system registry.
OS/2 utilizes a variety of CONFIG.SYS commands that are not officially documented.
CONFIG.SYS continues to play a vital role 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) – summary of DR-DOS 7 commands
- Details on FreeDOS CONFIG.SYS directives
- PTS-DOS 2000 Pro User Guide – including CONFIG.SYS commands (archived)
- Unofficial German PTS-DOS FAQ (PTS/FAQD) covering CONFIG.SYS directives (archived)