Jump to content

SCROLLOCK (CONFIG.SYS directive)

From Alfawiki
CONFIG.SYS
Company typeConfiguration file
IndustryComputer software
Founded1983
Headquarters
N/A
ProductsConfiguration commands for DOS and OS/2 startup

CONFIG.SYS serves as the essential configuration file for DOS and OS/2 operating systems. This plain text file, written in ASCII, holds configuration commands interpreted by the operating system's DOS BIOS—commonly found in IBMBIO.COM or IO.SYS—during the startup process. CONFIG.SYS was first introduced with DOS version 2.0.

Usage

The directives within CONFIG.SYS are utilized to set up DOS for hardware devices, software applications, and memory allocation. Once CONFIG.SYS is processed, DOS launches the command interpreter designated in the SHELL line; if none is specified, it defaults to COMMAND.COM, which subsequently executes AUTOEXEC.BAT.

Typically, the file includes name=value pairs that define system parameters or load components such as device drivers and terminate-and-stay-resident programs (TSRs). In DOS environments, CONFIG.SYS is located in the root directory of the bootable drive.

Certain DOS variants employ alternative filenames that override CONFIG.SYS. For instance, advanced iterations of Concurrent DOS 386, Concurrent DOS XM, Multiuser DOS, and REAL/32 utilize CCONFIG.SYS or CCONFIG.INI (in Multiuser DOS) and MCONFIG.SYS (in REAL/32). These platforms support extra configuration details stored in binary files like CCONFIG.BIN, which are usually edited via CONFIG.EXE.

In versions of DR DOS starting from 3.31—including distributions like PalmDOS, Novell DOS, and OpenDOS—a file named DCONFIG.SYS, if present, takes precedence over CONFIG.SYS. This functionality aids multi-boot configurations and accommodates disk compression scenarios where drive letter assignments change after loading compression drivers. Additionally, OpenDOS 7.01 and DR-DOS 7.02+ recognize ODCONFIG.SYS or DRCONFIG.SYS. The command SYS /DR:ext enables customization of default file extensions, facilitating multiple simultaneous boot setups managed by loaders such as LOADER in Multiuser DOS and DR-DOS.

DR-DOS extends the capabilities of the SHELL directive by allowing specification of alternative AUTOEXEC.BAT files and supports the CHAIN=filespec[,label] command to continue processing configuration files located outside the root directory.

FreeDOS uses a configuration file named FDCONFIG.SYS, while RxDOS relies on RXCONFIG.SYS, and CONFIG.PTS is used by PTS-DOS.

In Windows 95 and 98—which are based on DOS—both CONFIG.SYS and AUTOEXEC.BAT exist but are generally left empty. Windows Me does not process CONFIG.SYS during startup; instead, it depends on environment variables stored in the registry at HKLM\System\CurrentControlSet\Control\SessionManager\Environment.

For the FlexOS operating system, CONFIG.SYS is a binary format file that specifies 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 that serve as jump destinations for , , , , and commands.
Functions similarly to , also used for inline comments after other directives. (Note that under MS-DOS/PC DOS, inline comments enclosed in double quotes are not ignored.)
Introduces inline comments, complementing the ; directive.
Prompts a Yes/No confirmation before executing subsequent commands. (FreeDOS supports optional conditions with boot menus but lacks optional messages.) Starting with DOS 6.0, similar behavior can be achieved by appending after commands.
Executes the following command without condition.

ATemplate:NbndC

Determines whether programs may be interrupted upon encountering errors.
Sets which drives record file access timestamps within FAT file systems.
Enables conditional execution on AT-compatible hardware.
Boot loader utility.
Adjusts the verbosity level of error messages.
Alters the default serial driver assigned to the AUX: device.
Prevents character devices from being accessible outside the phantom \DEV directory.
Loads the fundamental device driver into system memory.
Produces a brief beep even when notifications are turned off.
Indicates the operating system designated for the next boot.
Enables or disables extended Ctrl+C monitoring.
Determines the quantity of disk buffers allocated.
Similar to BUFFERS but places buffers into HMA or UMB areas.
, CACHETTL, CACHEFLUSH (Embedded DOS 6-XL exclusive)
Control cache block allocation and flushing intervals.
Executes programs defined in CONFIG.SYS, pausing processing until completion.
Sets the Caps Lock key status on the keyboard.
, CDDBUFFERS (PTS-DOS exclusive)
Configures CD-ROM driver name and buffer settings.
Continues processing CONFIG.SYS using a new file or label reference.
, CLS, CODEPAGE, CMOSADDR, COLOR (various OS editions)
Manage screen clearing, OEM codepage settings, CMOS RAM address configuration, and boot menu color schemes respectively.
, COM2, COM3, COM4 (DR-DOS 7.02 and later)
Specify count, sequence, I/O port address, and timeout parameters for serial COM ports.
, COMMENT(S), COUNTRY (various OS versions)
Define DMA buffer sizes, customize inline comment characters or ignore lines, and enable internationalization support accordingly.
, CPSW (various OS versions)
Configure cursor positioning on display and codepage switching capabilities.
, CPU88 variants, CPU86 variants, CPU286 variants, CPU386 variants, CPU486 variants (PTS-DOS and DR-DOS)
Execute conditionally based on CPU model or clock speed.

DTemplate:NbndF

Configures relocation settings for drive descriptor tables.
Specifies the highest memory segment address permitted for multi-sector disk data deblocking.
Activates internal debugger functionality.
Boot loader utility.
Loads device drivers into conventional memory space.
Loads device drivers into upper memory blocks (equivalent to in DRDOS 5.0).
Sets country and codepage parameters for keyboard, screen, and printer devices.
Adjusts cache memory size allocations.
Defines compatibility mode for floppy disk drives.
Selects display font settings.
Controls whether DOS loads into high memory and/or utilizes upper memory areas.
Specifies loading of DOS internal tables (BUFFERS, FCBS, FILES, LASTDRIVE, STACKS) into upper memory regions.
Defines alternative search paths for locating DOS files.
Specifies search paths used for data files.
Establishes physical characteristics of disk drives.
Sets parameters for unrecognized or unknown drives.
Refer to .
Enables specifying an error log drive for PDUMP.nnn files.
Displays messages on the console screen.
Outputs messages including ANSI escape codes for enhanced formatting.
Applies additional verification steps when launching programs.
Defines an assumed error or return code following execution.
Controls the state of the A20 address line when starting applications.
Terminates CONFIG.SYS processing prematurely (except under certain conditions for SWITCHES and SHELL directives).
Configures hash table size to optimize file open operations (differs from MS-DOS/PC DOS FASTOPEN driver).
Specifies how many File Control Blocks (FCBs) can be cached simultaneously (shares buffer space with FILES under DR-DOS).
Similar to FCBS but loads FCBs into upper memory areas.
Boot loader utility.
Determines maximum number of open files allowed concurrently.
Similar to FILES but loads file handles into upper memory blocks.
Allows execution of specified CONFIG.SYS subsections (see IGNORE).

GTemplate:NbndI

Awaits a key press or timeout, assigning the error level to the ASCII value or 1024 if timed out.
Resumes processing of CONFIG.SYS at a designated label.
Processes CONFIG.SYS at a label in a nested manner, returning control afterward.
Refer to , , or for additional context.
Consult for further details.
See for related information.
Refer to or for more insight.
See or for supplementary details.
Consult for additional information.
Loads TSR after relocating the DOS data segment. Compare with INSTCDEX.
See , , or for related commands.
Refer to for more details.
See or for further explanation.
Activates console and command line history with enhanced pattern search capabilities.
Defines the address of the HMA segment.
Configures power-saving settings via HLT instruction.
Performs boot sector virus detection.
Loads file systems that can be installed dynamically.
Prevents execution of certain sections within CONFIG.SYS.
Permits programs to execute at ring 2 level, allowing direct hardware I/O access.
Incorporates directives from another menu block (achieved through GOSUB/RETURN emulation in DR-DOS).
Sets the status of the keyboard Insert mode.
Installs TSR utilities into memory space.
Loads TSR programs into upper memory, equivalent to HIINSTALL in DR DOS 5.0.
Installs TSR after relocating DOS data segment, similar to INSTALL command.
Rotates PIC interrupt priorities to elevate a specified IRQ number.

KTemplate:NbndM

Defines the keyboard layout configuration.
Specifies the relocated keyboard buffer's memory address.
Sets the highest drive letter accessible by the system.
Equivalent to LASTDRIVE but additionally loads the Current Directory Structure (CDS) into upper memory.
Establishes search paths for DLL files.
Manages compatibility behavior with legacy software applications.
Determines the maximum number of file locks allowed.
Configures boot logo display when using PTS-DOS boot manager.
Defines parameters such as count, order, I/O port address, and timeout for the LPT1 device.
Applies similar settings as LPT1 for the LPT2 device.
Mirrors LPT1 configuration for LPT3 device setup.
Enables and configures LPT4 device with comparable options.
Sets delay before escalating process priority levels.
Adjusts memory allocation policies and strategies.
Specifies default method for DOS memory allocation routines.
Defines available menu options within CONFIG.SYS interface.
Sets color schemes for menus (can be emulated under DR-DOS).
Designates default menu block (emulatable in DR-DOS environments).
Declares a menu block structure (also emulated by DR-DOS).
Activates multitrack disk operation support.
Continues CONFIG.SYS execution from a new file after loading a device driver, setting %NEWFILE% environment variable.

NTemplate:NbndQ

Determines default No () response character in Yes/No/Resume prompts.
Controls keyboard [[Num Lock|Template:Keypress]] state, enabling or disabling it on startup.
Allows conditional processing based on last error code, e.g., .
Displays a message and waits for user key press, similar to DR-DOS's and .
Requires user confirmation when errors occur during CONFIG.SYS processing.
Configures buffer sizes assigned to LPT printer ports.
Enables conditional execution on PC-compatible hardware platforms.
Assigns scheduling priority levels for processes.
Sets priority specifically for disk I/O related programs.
Changes default printer device driver assignment among LPT1 through LPT4 ports.
Controls whether DOS applications are permitted to run under current conditions.
Loads the user interface shell environment at startup.
Enables conditional execution on IBM PS/1 compatible systems only.
Enables conditional execution on IBM PS/2 compatible hardware exclusively.
Suppresses output display on STDOUT stream.

RTemplate:NbndT

Activates automatic system reboot upon encountering errors.
Permits inclusion of comments within CONFIG.SYS.
Allocates drive letters reserved by local block device drivers.
Defines the default Resume () character used in Yes/No/Resume prompts.
Returns nested CONFIG.SYS execution to the previous GOSUB or SWITCH point, optionally passing a return code.
Sets the amount of real mode memory available.
Allows concurrent loading of programs specified in CONFIG.SYS in the background.
Designates storage of the first character of deleted files within the FAT reserved sector.
Determines video mode settings (FreeDOS) or screen access methods (PTS-DOS).
Controls the keyboard Scroll Lock state, turning it on or off.
Defines environment variables.
Loads the command interpreter shell.
Similar to SHELL but supports pre-allocation for relocating COMMAND.COM into HMA or UMBs, enhancing memory efficiency with third-party shells.
Specifies keyboard modifier states such as Shift Lock, Num Lock, Scroll Lock, and Insert mode.
Controls whether files are closed upon pressing Ctrl+Alt+Del.
Indicates if POST is bypassed during reboot sequences.
, STACKSIZE, STACKSHIGH
Configure hardware interrupt stack sizes and buffer locations across various DOS editions and embedded platforms, with some parameters ignored depending on the OS variant.
, SYSBOOT, SYSGEN, SYSLOAD, SYSTOUMB
PTS-DOS-specific options for boot management tasks, alternative system loading methods, memory allocation into UMBs, and system configuration placement.
, SUBMENU, SUPPRESSPOPUPS, SWAPPATH, SWITCH, SWITCHAR, SWITCHES
A collection of OS-dependent directives managing internal-use strings, menu configurations, error logging preferences, swap file directories, conditional processing flows, default switch characters ('/' or '-'), and specialized options for DOS variants including OS/2 and Novell DOS.
, THREADS, TIMESLICE
OS/2-exclusive settings addressing FPU bug fixes, number of concurrent threads, and scheduler time slice durations.
, TMPEXT}, TRACE}, TRACEBUF}, TRAPDUMP}
Control timeout durations for CONFIG.SYS processing (DR-DOS and PTS-DOS), temporary file extension settings (PTS-DOS), enabling or disabling single-step trace execution across multiple DOS flavors including OS/2, trace buffer size adjustments (OS/2), and detailed error logging capabilities (OS/2).

UTemplate:NbndZ

Assigns a specific segment to function as an Upper Memory Block (UMB) in DOS.
Configures the UMB management server.
Defines address ranges allocated for UMB RAM usage.
Toggles disk write verification on or off.
Specifies the DOS version that is reported to applications.
Manages VGA display status settings.
Sets the current video mode similarly to FreeDOS's SCREEN command functionality.
Enables the use of virtual DMA capabilities.
Controls processor Virtual Mode Extensions (VME).
Configures VxD drivers for Windows environments.
Sets parameters for Windows system support integration.
Handles relocation of the Extended BIOS Data Area (XBDA).
Enables conditional execution tailored for XT-compatible hardware platforms.
Configures built-in Year 2000 compliance support mechanisms.
Defines the default character used for Yes responses in prompts.
Manages tracking options for file deletions.

Issues

Although the system can initiate booting without CONFIG.SYS or AUTOEXEC.BAT present, these files remain crucial for tailoring the operating system and meeting software dependency requirements. Any corruption or damage necessitates diagnostic efforts.

In cases where CONFIG.SYS does not contain a SHELL directive—or if it is missing or corrupted—DOS will attempt to locate COMMAND.COM in the root directory of the boot drive. Earlier DOS versions prior to 6.0 fail to boot without this file. From MS-DOS 6.0/PC DOS 6.1 onward, as well as Novell DOS 7 and later releases, users are prompted to specify a command interpreter path if COMMAND.COM is absent or fails to load. This prompt also allows swapping out the shell at runtime without requiring a reboot.

COMMAND.COM from MS-DOS version 7.0 and above is incompatible with DR-DOS systems, which impacts dual-boot configurations where COMMAND.COM resides in C:\ root. Starting with DR-DOS 7.02 and later, skipping SHELL directives during skip/trace/step modes (Ctrl+F5/F7/F8) is no longer permitted. Some subsequent versions reintroduced Ctrl+F6 functionality to restore skip behavior as a recovery method when invalid SHELL arguments are encountered. If no valid shell is found while skipping CONFIG.SYS processing, users receive a prompt to enter a shell filename before COMMAND.COM is loaded.

Limits on CONFIG.SYS file size differ among operating systems: MS-DOS and PC DOS restrict sizes to several kilobytes (up to approximately 64 KB in newer versions), whereas DR-DOS imposes no effective limit aside from filesystem constraints. MS-DOS compiles CONFIG.SYS into an internal tokenized structure in memory that processes device drivers before TSRs in a fixed order. In contrast, DR-DOS parses directives sequentially line-by-line, enabling more precise control over load order and conditional execution based on hardware presence or error conditions. This approach benefits complex setups and facilitates troubleshooting.

The maximum length of SHELL command lines varies by version: MS-DOS/PC DOS versions 2.0 through 4.01 limit this to 31 characters; later releases permit up to 128 characters. DR-DOS extends this limit further up to 255 characters. It should be noted that CONFIG.SYS directives do not support long filenames.

Dual Booting Between DOS and Windows 9x

During the installation of Windows 95 on a system already running DOS or an earlier Windows version, the files CONFIG.SYS and AUTOEXEC.BAT are renamed to CONFIG.DOS and AUTOEXEC.DOS. This renaming supports dual boot functionality, allowing users to switch between Windows 9x and DOS. When booting into DOS mode, these files temporarily revert to their original names, CONFIG.SYS and AUTOEXEC.BAT. Additionally, backup copies of the Windows 95 versions are preserved under the names CONFIG.W40 and AUTOEXEC.W40.

In setups where Caldera DR-DOS 7.02 or 7.03 coexists with Windows 95, the system does not alter Windows' CONFIG.SYS and AUTOEXEC.BAT files. Instead, DR-DOS employs its own startup configuration files named DCONFIG.SYS and AUTODOS7.BAT.

OS/2 and Windows NT

OS/2 extensively depends on CONFIG.SYS for loading drivers, configuring settings, and establishing the environment before initiating its graphical user interface.

Within the OS/2 subsystem integrated into Windows NT, CONFIG.SYS was presented as a configuration file accessible to OS/2 applications; however, its data was actually maintained within the system registry.

A significant number of CONFIG.SYS commands utilized by OS/2 remain either undocumented or only sparsely explained.

The use of CONFIG.SYS persists 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
  • Archived details on Windows 98 / MS-DOS 7.10 CONFIG.SYS directives
  • Archived Caldera CONFIG.SYS Command Reference – overview of DR-DOS 7 directives
  • Guide to FreeDOS CONFIG.SYS directives
  • PTS-DOS 2000 Pro User Manual covering CONFIG.SYS directives
  • German-language unofficial PTS-DOS FAQ (PTS/FAQD) including CONFIG.SYS directives