CLOCK$
| Company type | Operating system family |
|---|---|
| Industry | Computer software |
| Founded | 1981 |
| Headquarters | United States |
| Products | IBM PC DOS, MS-DOS, DR-DOS, ROM-DOS, PTS-DOS, FreeDOS |
DOS (, ) refers to a collection of disk-based operating systems designed for IBM PC compatible machines. The principal members of this family are IBM PC DOS and Microsoft's rebranded MS-DOS, both introduced in 1981. Subsequently, other compatible variants emerged, including DR-DOS (1988), ROM-DOS (1989), PTS-DOS (1993), and FreeDOS (1994). MS-DOS maintained a dominant position in the IBM PC compatible sector from 1981 through 1995.
Although often linked specifically with MS-DOS, the term DOS is an abbreviation for disk operating system, a generic phrase that existed prior to the IBM PC era. Various other operating systems also used this acronym, such as mainframe DOS/360 (1966), Apple DOS, Apple ProDOS, Atari DOS, Commodore DOS, TRSDOS, and AmigaDOS.
Origins
IBM PC DOS and MS-DOS, along with their predecessor 86-DOS, operated on Intel 8086 16-bit processors. Their design closely mirrored Digital Research's CP/M OS, which was prevalent on 8-bit microcomputers, facilitating easier porting of CP/M applications to MS-DOS.
When IBM developed the IBM PC featuring the Intel 8088 processor, they required an operating system. IBM Chairman John Opel was introduced to Bill Gates by Mary Maxwell Gates. Initially, IBM approached Digital Research to license CP/M, but negotiations failed due to disagreements over licensing conditions and naming rights. Gary Kildall, founder of Digital Research, declined IBM’s proposals, prompting IBM to withdraw.
IBM then turned to Bill Gates, who had acquired a CP/M-like operating system from Tim Paterson at Seattle Computer Products. Originally named QDOS (Quick and Dirty Operating System), it was marketed as 86-DOS. Microsoft purchased this OS for about $50,000 and rebranded it as MS-DOS in 1981.
Within a year, Microsoft licensed MS-DOS to more than 70 companies, many of which sold it under their own brand names—such as Zenith Data Systems' Z-DOS. Microsoft later required licensees to use the MS-DOS name except for IBM’s version. IBM continued developing its edition under the name PC DOS. In response to competition from PC DOS—which shared a name reminiscent of CP/M—Digital Research released CP/M-86 at a higher price point; however, its sales fell short compared to MS-DOS and PC DOS.
Initially, Microsoft sold MS-DOS exclusively to original equipment manufacturers (OEMs) because early PCs featured diverse hardware configurations. The OEM Adaptation Kit enabled customization of device drivers for different hardware platforms. By the early 1990s, as hardware standards became more uniform, Microsoft began retail distribution starting with MS-DOS version 5.0.
In the mid-1980s, Microsoft developed a multitasking version of DOS for International Computers Limited (ICL) and other European firms called "European MS-DOS 4." This edition supported preemptive multitasking and shared memory but was separate from IBM’s PC DOS 4.0 and did not influence subsequent DOS releases. Nevertheless, its features contributed to the kernel design of OS/2 version 1.0.
Digital Research attempted to reclaim market presence through products like Concurrent DOS, FlexOS, DOS Plus, Multiuser DOS, and DR DOS—all compatible with MS-DOS or CP/M-86 software. Following acquisition by Novell, DR DOS evolved through PalmDOS and Novell DOS before transitioning to Caldera (OpenDOS/DR-DOS), Lineo, and DeviceLogics.
Microsoft co-founder Gordon Letwin revealed in 1995 that DOS was originally intended as a temporary solution to satisfy IBM while Microsoft focused on selling programming languages; it was meant as a stopgap until Xenix adoption. The plan involved incremental enhancements aimed at compatibility with Xenix—a multi-user UNIX variant—envisioned as "the multi-user MS-DOS of the future."
However, IBM did not immediately replace DOS. After AT&T started marketing Unix, Microsoft and IBM collaborated on OS/2 as an alternative but eventually diverged due to differing priorities between OS/2 and Windows development. This divergence led each company down separate paths regarding their respective DOS systems.
The final retail release of MS-DOS was version 6.22; later iterations were incorporated into Windows 95, 98, and Me. IBM's last retail edition was PC DOS 2000 (a revision of PC DOS 7), followed by internal OEM versions such as PC DOS 7.10.
The FreeDOS initiative began in June 1994 after Microsoft discontinued sales and support for MS-DOS. Spearheaded by Jim Hall’s open-source manifesto, contributors including Pat Villani and Tim Norman developed components like the kernel, COMMAND.COM shell, and utilities. FreeDOS version 1.0 was released in September 2006 under the GNU General Public License (GPL), providing a royalty-free alternative compatible with business applications previously relying on MS-DOS.
Decline
Earlier editions of Microsoft Windows operated on top of MS-DOS. By the early 1990s, the graphical user interface of Windows had become widely accepted. The release of Windows 95 in 1995 marked its debut as an independent operating system that no longer required a separate DOS license. Windows 95, along with its successors Windows 98 and ME, became the principal OS kernel, although MS-DOS persisted for backward compatibility. With Windows 95 and 98, but not ME, it was possible to run MS-DOS separately from Windows. As DOS was no longer indispensable, the majority of users stopped using it directly.
Continued use
Several DOS-compatible systems still exist today, including FreeDOS, ROM-DOS, PTS-DOS, RxDOS, and REAL/32. Some hardware vendors, such as Dell and HP, have offered machines preloaded with FreeDOS as an OEM operating system. Although these offerings have become less common, FreeDOS remains favored by developers and engineers who require low-level hardware interaction.
Embedded systems
Due to DOS's ability to access hardware directly, it continues to be utilized in embedded devices. The last versions of DR-DOS were designed specifically for this sector. For example, ROM-DOS is employed as the operating system in devices like the Canon PowerShot Pro 70.
Emulation
On Linux, the DOSEMU emulator enables DOS applications to run at speeds close to native performance. Other emulators such as DOSBox support DOS environments on Unix-like systems and Microsoft Windows. DOSBox is primarily targeted at running classic games (for instance, King's Quest and Doom) on contemporary hardware. It includes an integrated DOS implementation linked to the emulator but can also boot MS-DOS, FreeDOS, or other DOS variants when necessary.
Design
MS-DOS and IBM PC DOS are chiefly associated with Intel x86 or compatible processors, predominantly found in IBM PC compatible computers. Various MS-DOS derivatives were developed for non-IBM-compatible x86 machines, ranging from rebranded Microsoft versions to customized releases for incompatible hardware platforms. Software utilizing DOS APIs could operate on both compatible and incompatible systems. The original kernel of FreeDOS, known as DOS-C, was adapted from DOS/NT designed for Motorola 68000 CPUs; while its architecture mirrored DOS, it lacked binary compatibility due to differing instruction sets. Nonetheless, applications written in high-level languages could be transferred.
DOS functions as a single-user, single-tasking operating system with a simple kernel that is non-reentrant—only one program executes at any given time. The kernel provides an application programming interface offering services such as character input/output, file and memory management, as well as program execution control.
Batch scripts (.BAT) allow basic shell scripting by processing each line as either an external program or an internal command like GOTO and conditional statements.
The operating system supplies an API oriented toward text-based applications but does not natively support most hardware devices (such as graphics adapters, printers, or mice), requiring programmers to access hardware directly. As a result, many applications incorporated their own device drivers for peripherals. Hardware manufacturers published specifications to assist developers in creating drivers compatible with widely used software.
Boot sequence
- On PC-compatible systems, the bootstrap loader resides within the master boot record (MBR), positioned in the boot sector—the initial sector of the bootable disk. The ROM BIOS loads this sector into memory at address :, verifying the presence of a signature "" at offset . If this signature is absent or invalid, the BIOS attempts to boot from the next physical disk; if valid, control is transferred to the load address with registers set accordingly.
- When an MBR is loaded, it is relocated in memory to address :. The MBR then examines its partition table for an active partition and loads that partition’s first sector—the Volume Boot Record (VBR)—into memory at :, subsequently handing over execution.
- The VBR is tailored to specific operating systems and often incompatible between DOS variants. Early DOS releases (such as DOS 1.x) load the entire IO.SYS/IBMBIO.COM file into memory at :, necessitating that these files occupy contiguous disk sectors. Later DOS versions identify the first two entries in the root directory and load initial sectors of IO.SYS/IBMBIO.COM, preserving the Disk Parameter Table (DPT) before passing control onward.
- In more recent DOS editions, the partially loaded IO.SYS/IBMBIO.COM contains a secondary loader responsible for completing its own loading using root directory information, typically requiring contiguous file sectors. This step is omitted in older DOS versions.
- The DOS system initialization routines then proceed to load built-in device drivers along with the DOS kernel (MSDOS.SYS on MS-DOS). In Windows 9x, these components are merged into IO.SYS, while MSDOS.SYS functions as a configuration file.
- Configuration parameters are read from the CONFIG.SYS file; the variable designates the shell's location, defaulting to COMMAND.COM.
- The shell program is subsequently loaded and executed.
- Finally, the startup batch script AUTOEXEC.BAT is run.
System files loaded by the boot sector within DOS must be stored contiguously and occupy the first two entries in the directory table. Modifying these files risks making the media unbootable; however, substituting the shell can streamline launching dedicated applications. This requirement for contiguous files does not apply to DR DOS, where system files may reside anywhere in the root directory provided that the boot sector is compatible with DR DOS.
In PC DOS and DR DOS versions 5.0 and later, system files are named IBMBIO.COM (replacing IO.SYS) and IBMDOS.COM (replacing MSDOS.SYS). Earlier DR DOS releases used DRBIOS.SYS and DRBDOS.SYS instead.
Beginning with MS-DOS 7.0, IO.SYS and MSDOS.SYS binaries were consolidated into a single IO.SYS file; MSDOS.SYS became a configuration file similar to CONFIG.SYS and AUTOEXEC.BAT. Setting the BootGUI directive in MSDOS.SYS to 0 stops booting after loading COMMAND.COM rather than automatically launching WIN.COM.
File system
DOS utilizes a filesystem that supports 8.3 filename conventions: filenames limited to 8 characters with a 3-character extension. Hierarchical directories have been supported since DOS 2, also following the 8.3 format, with internal current directory structure (CDS) tables restricting maximum path length to 64 characters. Including drive identifiers, fully qualified filenames can extend up to 80 characters (drive:\path\filename.ext).
The underlying filesystem employed by DOS is based on the File Allocation Table (FAT). Initially, FAT12 supported drives with up to 4,078 clusters. DOS 3.0 introduced FAT16, utilizing 16-bit entries and allowing up to 65,518 clusters per volume. Compaq MS-DOS 3.31 added support for FAT16B, which eliminated the previous 32 MiB drive size limit and extended support up to 512 MiB. MS-DOS 7.1 (as part of Windows 9x) introduced FAT32, enabling volumes exceeding 137 GiB.
File redirector functionality was introduced starting with DOS 3.1, initially targeting network drives and later extended to CD-ROM drives through MSCDEX. IBM PC DOS 4.0 included early support for installable file systems (IFS), which was removed in DOS 5.0. Additionally, DOS supported Block Devices loaded via CONFIG.SYS to integrate network devices within its filesystem framework.
Drive letter allocation system
Within DOS, drive identification relies on assigning letters. Typically, letters "A" and "B" are designated for floppy drives. On systems equipped with only one floppy drive, both letters refer to the same device to simplify disk swapping during tasks such as copying files or executing programs that require data from multiple disks. The first hard drives in the sequence generally receive letters starting at "C" and "D". DOS permits only a single active partition per physical drive; consequently, drive letters are allocated initially to active primary partitions, then to logical drives within extended partitions, followed by any inactive primary partitions if they exist, and finally to optical drives, RAM disks, and other hardware peripherals. Although letter assignments typically follow the order in which drivers load, certain drivers can influence this order—for example, network drives are frequently assigned letters toward the end of the alphabet.
Because DOS applications access storage devices directly through these letter assignments (in contrast to Unix-like systems that use device files under /dev), introducing new hardware can alter existing drive letter mappings. For example, installing an additional hard disk containing a primary partition may cause letters previously allocated to logical drives within extended partitions to be reassigned or impact the designations of RAM disks and optical drives. This challenge remained throughout Microsoft's DOS-based Windows 9x series until the transition to NT-based Windows versions, which maintain existing drive letter assignments unless manually modified by users. Workarounds in DOS include using the SUBST command to create virtual drives and installing software on these virtual drives, with batch files adjusting mappings during system startup. Certain iterations of Concurrent DOS, Multiuser DOS, System Manager, and REAL/32 automatically assign the reserved letter L: to the drive from which applications are launched.
Device names reserved by the system
DOS encompasses a set of reserved device names that cannot be utilized as filenames regardless of any file extension because they correspond to internal character devices. These restrictions have persisted into various Windows versions and have occasionally led to system crashes and security vulnerabilities.
The reserved device names encompass:
COM1throughCOM9(serial communication ports)LPT1throughLPT9(parallel printer ports)CON("console"; representing keyboard input and display output)AUX("auxiliary"; commonly mapped to the first serial port)PRN("printer"; typically linked to the first parallel port)NUL(null device)
In Windows 95 and 98, referencing these reserved names within file paths could cause system crashes, prompting Microsoft to release patches addressing these issues. Windows XP handles such filenames silently by reverting them without alerting users, whereas Windows Vista and subsequent versions present an error message indicating "The specified device name is invalid."
Except for NUL, these reserved names remain supported across all MS-DOS, PC DOS, and DR-DOS releases. Additionally, some OEM MS-DOS versions introduced extra aliases such as LST, PLT, along with specific aliases for serial and parallel devices. Later DOS variants added further device names including CLOCK$, while multitasking MS-DOS 4.0 incorporated devices like KEYBD$ and SCREEN$. DR-DOS 5.0 and later also support a power management device named $IDLE$.
In certain DOS versions, default targets for AUX and PRN can be redirected to alternative serial or parallel hardware. By convention, reserved device names are followed by a colon (for instance, NUL:) when referring to device files; however, this colon is not part of the actual driver name and is often optional in command usage.
While standard file management operations prevent creation of files or directories named after these reserved devices, it remains feasible through direct manipulation of disk sectors—a method sometimes exploited by malicious software to conceal files from users.
Memory management
DOS was originally created for the Intel 8088 CPU, which supports direct access to a maximum of 1 MiB of RAM. IBM and Microsoft designated 640 kibibytes (KiB) for application use, reserving the remaining 384 KiB for video memory, adapter ROMs, and BIOS functions. By the mid-1980s, certain DOS programs began to approach this memory ceiling, although significant portions of the reserved space often remained idle depending on hardware configurations.
To increase accessible memory capacity, various standards were introduced. The Expanded Memory Specification (EMS) allowed additional memory on expansion cards to be accessed through a 64 KiB page frame located in upper memory. Systems equipped with 80386 or newer processors could utilize virtual 8086 mode managers such as EMM386 to simulate expanded memory from extended memory without requiring physical hardware. The Extended Memory Specification (XMS), designed for 80286 and later CPUs, facilitated data transfers to and from extended memory as well as access to the 65,520-byte high memory area and upper memory blocks. XMS support was commonly provided via HIMEM.SYS or virtual 8086 mode managers like QEMM or 386MAX, which also offered EMS capabilities.
Starting with DOS version 5, it became possible to load the kernel and disk buffers into the HMA by enabling DOS=HIGH in CONFIG.SYS. Additionally, DOS 5 and later versions allowed the utilization of upper memory blocks through the DOS=UMB directive.
DOS under OS/2 and Windows
DOS emulation within OS/2 and Windows functions similarly to native applications, granting access to drives, system services, and clipboard operations. Since file system drivers operate within the host operating system, the DOS layer translates DOS system calls into OS/2 or Windows equivalents while virtualizing BIOS interrupts and I/O port interactions typical of DOS software.
In Windows 3.1 and Windows 9x, the DOS virtual machine is managed by WINOLDAP, which relies on program information files (PIFs) and system state at launch. This environment supports DOS graphical modes inside windows and enables clipboard sharing between DOS and Windows applications.
DOS emulation in OS/2 and Windows NT is based on DOS version 5, allowing users to configure config.sys and autoexec.bat files individually per session. These configuration files can load drivers that provide access to host resources, often facilitated by third-party utilities.
Beginning with OS/2 version 2.x, DOSKRNL—a merged file combining IBMBIO.COM and IBMDOS.COM—routes system calls through OS/2’s windowing system. DOS applications execute in isolated sessions supported by helper tools bundled with integrated DOS/OS2 programs located in \OS2. OS/2 can also run Windows 3.1 applications via Win-OS/2, enabling either seamless integration within the OS/2 desktop or operation in a separate windowed session.
Furthermore, OS/2 offers "DOS from Drive A:" (VMDISK), a bootable DOS environment such as MS-DOS 6.22 augmented with OS/2 device drivers to provide hardware support beyond native capabilities.
All 32-bit editions of Windows NT since their introduction in 1993 implement a virtual DOS machine (NTVDM) for running DOS applications. However, 64-bit versions of Windows do not include NTVDM support and therefore cannot execute 16-bit DOS programs natively; users typically rely on third-party emulators like DOSBox for this purpose.
User interface
DOS environments employ a command-line interface, where users start applications by typing their filenames at a prompt. The system includes both utility programs and built-in commands that do not require separate executable files.
To improve user experience, numerous developers created file management software featuring WIMP-style graphical interfaces. Microsoft Windows notably evolved into a comprehensive program loader that ultimately supplanted DOS as the primary PC-compatible operating environment. Among text-based interfaces were Norton Commander, DOS Navigator, Volkov Commander, Quarterdeck's DESQview, and Sidekick. Graphical shells included Digital Research’s GEM and GEOS.
Leading DOS providers also incorporated environment managers: MS-DOS/IBM DOS version 4 introduced DOS Shell, while DR DOS 5.0 offered ViewMAX, which was built upon GEM technology.
Terminate and Stay Resident
Although DOS does not support multitasking natively, its terminate-and-stay-resident (TSR) capability allows applications to remain loaded in memory. These programs intercept system timers or keyboard interrupts to perform background operations or be activated on demand. For instance, the DOS PRINT utility utilizes TSR functionality for background print spooling, while Borland Sidekick operates as a popup personal organizer using this method.
TSRs also introduce functionalities not included by default in DOS. Tools such as CED and DOSKEY improve command-line editing, whereas Microsoft CD-ROM Extensions (MSCDEX) provide access to CD-ROM drives.
Certain TSR applications offer rudimentary task switching; for example, the shareware Back and Forth (1990) enables saving one program's state to disk, loading another, and toggling between them—though performance is hindered by disk I/O delays. Genuine background multitasking, however, required utilities like DESQview running on processors no older than the 386.
Software
- Arachne, a 16-bit graphical web browser
- dBase, a database management program
- Harvard Graphics, software for creating presentation graphics
- Lotus 1-2-3, a spreadsheet application credited with boosting IBM PC adoption
- File management tools such as Norton Commander and XTree
- Leading file compression software like PKZIP
- Modem communication programs including ProComm, Qmodem, and Telix
- Personal information manager Sidekick, usable alongside other applications
- The widely used 1980s word processor WordPerfect
- Popular IBM PC word processor WordStar
Development Tools
- BASIC interpreters: BASICA and GW-BASIC
- DJGPP, a 32-bit DPMI-compliant port of the GNU Compiler Collection (gcc) for DOS
- Microsoft's development environment featuring Microsoft Macro Assembler, Microsoft C, and CodeView
- Watcom's C/C++ compiler suite
- Borland’s Turbo product line: including Turbo Pascal, Turbo BASIC, Turbo C, Turbo Prolog, and Turbo Assembler
See Also
- COMMAND.COM – command interpreter for DOS and Windows 9x
- CP/M – early operating system from Digital Research resembling DOS
- – East German VEB Robotron’s MS-DOS derivative (DCP)
- DOS API
- DOS/V
- Index of DOS games
- List of DOS operating systems
- PC-MOS/386 – multiuser DOS-compatible OS
- VGA-compatible text mode – basis for DOS text user interface on IBM PC compatibles
Further Reading
- IBM Corp., IBM, (January 1984). "IBM DOS Release 2.10 Cloth bound retail hard board box". 1st edition. IBM Corp. Item Number. 6183946
- IBM Corp., IBM, (January 1984). "Disk Operating System User's guide (DOS Release 2.10)". 1st edition. Microsoft Corp. (100 pages including colour illustrations) Item Number. 6183947
- IBM Corp., IBM, (January 1984). "Disk Operating System Manual (DOS Release 2.10)". 1st edition. Microsoft Corp. (574 looseleaf pages in 3 ring folder) Item No. 6183940
- Mueller, Scott, Upgrading and Repairing PCs, Que Publishing, 1998, ISBN 0-7897-1295-4
- Bailes, Lenny & Mueller, John, Memory Management and Multitasking Beyond 640K, McGraw-Hill, 1992, ISBN 0-8306-3476-2
External links
- Origins of DOS, a collection of articles and manuals authored by Tim Paterson
- Timeline of DOS and Windows versions
- DOS - where hardware is the only limit
- Batfiles: The DOS batch file programming handbook
- The Rise of DOS: How Microsoft Secured the IBM PC OS Contract – PCMag, 2021
- Application Software - DOS Short File Name Family – archive hosting free and discontinued DOS programs
- Online Windows XP Simulator
- MS-DOS v1.25, v2.0, v4.0 Source Code repository