DOS: Difference between revisions - Wikipedia
Article Images
Line 1:
{{Short description|GroupFamily of closely related IBM PC-compatible operating systems}}
{{About|a family of operating systems|the concept|disk operating system|the type of cyber attack|Denial-of-service attack{{!}}DoS|other uses|DOS (disambiguation)}}
{{redirect-distinguish|WinDOS|Microsoft Windows}}
Line 20:
[[File:Ibm pc 5150.jpg|thumb|The [[IBM Personal Computer]] (IBM 5150 PC)]]
When [[IBM]] introduced the [[IBM PC]], built with the [[Intel 8088]] microprocessor, they needed an operating system. Chairman [[John Opel]] had a conversation with fellow United Way National Board Executive Committee member [[Mary Maxwell Gates]], who referred Opel to her son [[Bill Gates]] for help with an 8088-compatible build of CP/M.<ref>{{Cite journal |url=https://www.nytimes.com/1994/06/11/obituaries/mary-gates-64-helped-her-son-start-microsoft.html |title=Mary Gates, 64; Helped Her Son Start Microsoft |date=1994-06-11 |journal=New York Times |access-date=2023-04-11 }}</ref> IBM was then sent to Digital Research, and a meeting was set up. However, initial negotiations for the use of CP/M broke down: Digital Research wished to sell CP/M on a royalty basis, while IBM sought a single license, and to change the name to "PC DOS". Digital Research founder [[Gary Kildall]] refused, and IBM withdrew.<ref name="rolander">{{cite interview |url=http://www.podtech.net/home/3801/the-rest-of-the-story-how-bill-gates-beat-gary-kildall-in-os-war-part-1 |title=The rest of the story: How Bill Gates beat Gary Kildall in OS war, Part 1 |author-last=Rolander |author-first=Tom |author-link=Tom Rolander |interviewer-first=Robert |interviewer-last=Scoble |work=The Scoble Show |url-status=dead |archive-url=https://web.archive.org/web/20071104052350/http://www.podtech.net/home/3801/the-rest-of-the-story-how-bill-gates-beat-gary-kildall-in-os-war-part-1 |archive-date=2007-11-04}}</ref><ref>{{cite book |title=Just Say No to Microsoft |url=https://archive.org/details/justsaynotomicro00bove |url-access=registration |author-last=Bove |author-first=Tony |publisher=[[No Starch Press]] |date=2005 |pages=[https://archive.org/details/justsaynotomicro00bove/page/9 9]–11 |isbn=1-59327-064-X }}</ref>
[[File:86-DOS running assembler and HEX2BIN (screenshot).png|thumb|A simulated [[Seattle Computer Products|SCP]] [[86-DOS]] session]]
{{anchor|QDOS}}
IBM again approached Bill Gates. Gates in turn approached [[Seattle Computer Products]]. There, programmer [[Tim Paterson]] had developed a variant of [[CP/M-80]], intended as an internal product for testing SCP's new 16-bit [[Intel 8086]] [[Central processing unit|CPU]] card for the [[S-100 bus]]. The system was initially named QDOS (Quick and Dirty Operating System), before being made commercially available as [[86-DOS]]. Microsoft purchased 86-DOS, allegedly for {{currency|amount=50000|code=USD|linked=no}}. This became Microsoft Disk Operating System, MS-DOS, introduced in 1981.<ref name="mshist">{{cite web |url=http://inventors.about.com/library/weekly/aa033099.htm |title=The Unusual History of MS-DOS The Microsoft Operating System |access-date=2008-09-02 |author-last=Bellis |author-first=Mary |archive-date=2012-04-27 |archive-url=https://wayback.archive-it.org/all/20120427184009/http://inventors.about.com/od/computersoftware/a/Putting-Microsoft-On-The-Map.htm |url-status=dead }}</ref>
Within a year Microsoft licensed MS-DOS to over 70 other companies,<ref name="freiberger19820823">{{cite journal |url=https://books.google.com/books?id=VDAEAAAAMBAJ&pg=PA22 |title=Bill Gates, Microsoft and the IBM Personal Computer |journal=[[InfoWorld]] |date=1982-08-23 |access-date=2015-01-29 |author-last=Freiberger |author-first=Paul |author-link=Paul Freiberger |page=22 |url-status=live |archive-url=https://web.archive.org/web/20150318020802/https://books.google.com/books?id=VDAEAAAAMBAJ&lpg=PA19&pg=PA22 |archive-date=2015-03-18}}</ref> which supplied the operating system for their own hardware, sometimes under their own names. Microsoft later required the use of the MS-DOS name, with the exception of the IBM variant. IBM continued to develop their version, [[PC DOS]], for the IBM PC.<ref name="mshist"/> Digital Research became aware that an operating system similar to CP/M was being sold by IBM (under the same name that IBM insisted upon for CP/M), and threatened legal action. IBM responded by offering an agreement: they would give PC consumers a choice of PC DOS or [[CP/M-86]], Kildall's 8086 version. Side-by-side, CP/M cost {{currency|amount=200|code=USD|linked=no}} more than PC DOS, and sales were low. CP/M faded, with MS-DOS and PC DOS becoming the marketed operating system for PCs and PC compatibles.<ref name="rolander"/>
Line 46 ⟶ 47:
{{Main|History of Microsoft Windows}}
Early versions of [[Microsoft Windows]] ran on MS-DOS.<ref name="emulate"/> By the early 1990s, the Windows graphical shell saw heavy use on new DOS systems. In 1995, [[Windows 95]] was bundled as a standalone operating system that did not require a separate DOS license. Windows 95 (and Windows 98 and ME, that followed it) took over as the default [[OS kernel]], though the MS-DOS component remained for compatibility. With Windows 95 and 98, but not ME, the MS-DOS component could be run without starting Windows.<ref>{{cite web |url=http://www.smartcomputing.com/Editorial/article.asp?article=articles/archive/95win/95win21/95win21.asp&guid= |archive-url=https://web.archive.org/web/20040707000544/http://www.smartcomputing.com/editorial/article.asp?article=articles%2Farchive%2F95win%2F95win21%2F95win21.asp&guid= |url-status=dead |archive-date=2004-07-07 |title=Finding The DOS In Windows 95 |work=Smart Computing |date=March 1996 |access-date=2008-07-12}}</ref><ref name="various-77715">{{cite web |url=httphttps://blogsdevblogs.msdnmicrosoft.com/b/oldnewthing/archive20071224-00/2007/12/24/6849530.aspx?p=24063 |title=What was the role of MS-DOS in Windows 95? |author-first=Raymond |author-last=Chen |author-link=Raymond Chen (Microsoft) |work=The Old New Thing - Site Home - MSDN Blogs |date=2007-12-24 |access-date=2014-02-05 |archive-url=https://web.archive.org/web/20140205100822/http://blogs.msdn.com/b/oldnewthing/archive/2007/12/24/6849530.aspx |archive-date=2014-02-05 |url-status=live}}</ref><ref name="various-42623">{{cite web |url=http://support.microsoft.com/kb/138996 |title=Description of Restarting Computer in MS-DOS Mode |work=support.microsoft.com |date=2007-01-19 |access-date=2014-02-05 |archive-url=https://web.archive.org/web/20140205101959/http://support.microsoft.com/kb/138996 |archive-date=2014-02-05 |url-status=live}}</ref> With DOS no longer required to use Windows, the majority of users stopped using it directly.
=== Continued use ===
[[File:DOSBox screenshot.png|thumb|upright=1.5|[[DOSBox]] ]]
{{As of|2023}}, available compatible systems are [[FreeDOS]], [[ROM-DOS]], [[PTS-DOS]], [[RxDOS]]<ref>{{cite web |url=http://rxdos.sourceforge.net/ |title=Home |website=rxdos.sourceforge.net}}</ref> and [[REAL/32]]. Some computer manufacturers, including [[Dell]] and [[Hewlett-Packard|HP]], sell computers with FreeDOS<!-- in the form of [[DRMK]] --> as an [[Original equipment manufacturer|OEM]] operating system. <ref>{{cite web |url=http://www.freedos.org/jhall/blog/?yr=2007 |title=Jim Hall's blog - 2007 |date=2007-07-13 |access-date=2008-06-12 |author-last=Hall |author-first=Jim |author-link=James Hall (programmer) |url-status=dead |archive-url=https://web.archive.org/web/20121025185935/http://www.freedos.org/jhall/blog/?yr=2007 |archive-date=2012-10-25}}</ref><ref>{{cite web |url=http://www.dell.com/content/topics/segtopic.aspx/e510_nseries?c=us&cs=19&l=en&s=dhs |title=Dell PCs Featuring FreeDOS |access-date=2008-06-14 |url-status=dead |archive-url=https://web.archive.org/web/20080319090122/http://www.dell.com/content/topics/segtopic.aspx/e510_nseries?c=us&cs=19&l=en&s=dhs |archive-date=2008-03-19}}</ref> {{Update inline|date=January 2024|reason=I could not find freedos computers on dell's website, and it seems likely they stopped selling them since 2008}} And a few developers and computer engineers still use it because it is close to the hardware.{{cncitation needed|date=October 2023}}
==== Embedded systems ====
Line 57 ⟶ 58:
==== Emulation ====
On [[Linux]], it is possible to run ''[[DOSEMU]]'', a Linux-native [[virtual machine]] for running DOS programs at near native speed. There are a number of other [[emulator]]s for running DOS on various versions of Unix and [[Microsoft Windows]] such as [[DOSBox]].<ref name="DOSBox"/><ref>{{cite web |url=http://www.dosemu.org/ |title=DOSEMU Home |date=2007-05-05 |access-date=2008-07-03 |url-status=live |archive-url=https://web.archive.org/web/20080723140604/http://www.dosemu.org./ |archive-date=2008-07-23}}</ref> DOSBox is designed for legacy gaming (e.g. ''[[King's Quest]]'', ''[[Doom (1993 video game)|Doom]]'') on modern operating systems.<ref name="emulate">{{cite web |url=http://apcmag.com/how_to_coax_retro_dos_games_to_play_on_vista.htm |title=HOW TO: Coax retro DOS games to play on Vista |date=2006-10-13 |access-date=2008-07-03 |author-first=James |author-last=Bannan |url-status=live |archive-url=https://web.archive.org/web/20080801222002/http://apcmag.com/how_to_coax_retro_dos_games_to_play_on_vista.htm |archive-date=2008-08-01}}</ref><ref name="DOSBox">{{cite web |url=http://www.dosbox.com/information.php |title=DOSBox Information |access-date=2008-05-18 |url-status=live |archive-url=https://web.archive.org/web/20080525111324/http://www.dosbox.com/information.php |archive-date=2008-05-25}}</ref> DOSBox includes its own implementation of DOS which is strongly tied to the emulator and cannot run on real hardware, but can also boot MS-DOS, FreeDOS, or other DOS operating systems if needed.
== Design ==
Line 78 ⟶ 79:
* The startup batch file [[AUTOEXEC.BAT]] is then run by the shell.<ref name="evergreen_edu-config-sys">{{cite web |title=CONFIG.SYS Commands |url=http://academic.evergreen.edu/projects/biophysics/technotes/program/config-sys.txt |url-status=live |archive-url=https://web.archive.org/web/20090502033350/http://academic.evergreen.edu/projects/biophysics/technotes/program/config-sys.txt |archive-date=2009-05-02}} 090913 academic.evergreen.edu</ref><ref>{{cite web |url=http://www.pcguide.com/ref/hdd/file/structBoot-c.html |title=The DOS Boot Process |work=The PC Guide |author-last=Kozierok |author-first=Charles |date=2001 |access-date=2008-09-02 |url-status=dead |archive-url=https://web.archive.org/web/20080719191224/http://www.pcguide.com/ref/hdd/file/structBoot-c.html |archive-date=2008-07-19 }}</ref>
The DOS system files loaded by the boot sector must be [[Fragmentation (computer)|contiguous]] and be the first two [[FAT directory table|directory entries]].<ref name="wustl_edu-misc">{{cite web |title=misc.txt |url=http://www.arl.wustl.edu/~lockwood/class/cse306-s04/resources/helppc/misc.txt.html |url-status=dead |archive-url=https://web.archive.org/web/20100629152149/http://arl.wustl.edu/~lockwood/class/cse306-s04/resources/helppc/misc.txt.html |archive-date=2010-06-29}} 090912 arl.wustl.edu</ref> As such, removing and adding this file is likely to render the media unbootable. It is, however, possible to replace the shell at will, a method that can be used to start the execution of dedicated applications faster. This limitation does not apply to any version of DR DOS, where the system files can be located anywhere in the root directory and do not need to be contiguous. Therefore, system files can be simply copied to a disk provided that the boot sector is DR DOS compatible already.
This limitation does not apply to any version of DR DOS, where the system files can be located anywhere in the root directory and do not need to be contiguous. Therefore, system files can be simply copied to a disk provided that the boot sector is DR DOS compatible already.
In PC DOS and DR DOS 5.0 and above, the DOS system files are named [[IBMBIO.COM]] instead of [[IO.SYS]] and [[IBMDOS.COM]] instead of [[MSDOS.SYS]]. Older versions of DR DOS used DRBIOS.SYS and DRBDOS.SYS instead.
Line 102:
{{Main|Device file}}
[[File:Windows Reserved Name Error.png|thumb|right|400px|Error message when attempting to use a reserved name while naming or renaming a file or folder]]
There are reserved device names in DOS that cannot be used as filenames regardless of extension as they are occupied by built-in character devices. These restrictions also affect several Windows versions, in some cases causing crashes and security vulnerabilities.<ref>{{cite web |url=http://www.juniper.net/security/auto/vulnerabilities/vuln1043.html |title=Microsoft Windows MS-DOS Device Name DoS Vulnerability |access-date=2008-09-02 |url-status=dead |archive-url=https://web.archive.org/web/20110725163840/http://www.juniper.net/security/auto/vulnerabilities/vuln1043.html |archive-date=2011-07-25}}</ref>▼
▲There are [[Reserved word|reserved]] device names in DOS that cannot be used as filenames regardless of extension as they are occupied by built-in character devices. These restrictions also affect several Windows versions, in some cases causing crashes and security vulnerabilities.<ref>{{cite web |url=http://www.juniper.net/security/auto/vulnerabilities/vuln1043.html |title=Microsoft Windows MS-DOS Device Name DoS Vulnerability |access-date=2008-09-02 |url-status=dead |archive-url=https://web.archive.org/web/20110725163840/http://www.juniper.net/security/auto/vulnerabilities/vuln1043.html |archive-date=2011-07-25}}</ref>
The reserved names are:
Line 112 ⟶ 114:
* <code>PRN</code>, for printer<ref>{{cite web|url=https://www.pcmag.com/encyclopedia_term/0,2542,t=DOS+device+names&i=41766,00.asp|title=DOS device names definition|publisher=[[PC Magazine]]|url-status=live|archive-url=https://web.archive.org/web/20080929150356/http://www.pcmag.com/encyclopedia_term/0%2C2542%2Ct%3DDOS+device+names%26i%3D41766%2C00.asp|archive-date=2008-09-29|access-date=2008-09-02}}</ref>
* <code>NUL</code>, for [[null device]]s; added in [[86-DOS]] 1.10 and [[IBM PC DOS|PC DOS]] 1.0.
In [[Windows 95]] and [[Windows 98]], typing in the location of the reserved name (such as CON/CON, AUX/AUX, or PRN/PRN) crashes the operating system, of which Microsoft has provided a security fix for the issue. In [[Windows XP]], the name of the file or folder using a reserved name silently reverts to its previous name, with no notification or error message. In [[Windows Vista]] and later, attempting to use a reserved name for a file or folder brings up an error message saying "The specified device name is invalid."
These names (except for NUL) have continued to be supported in all versions of MS-DOS, PC DOS and DR-DOS ever since.<ref name="Microsoft_Built-in_devices">{{cite web |title=MS-DOS Device Driver Names Cannot be Used As File Names |date=2003-05-12 |version=Revision 2.0 |id=KB74496, Q74496 |publisher=[[Microsoft]] |url=http://support.microsoft.com/kb/74496/en-us |url-status=dead |archive-url=https://archive.today/20120721143046/http://support.microsoft.com/kb/74496/en-us |archive-date=2012-07-21}}</ref> <code>LST</code> was also available in some OEM versions of MS-DOS 1.25,<!-- f.e. SCP MS-DOS 1.25 --> whereas other OEM versions of MS-DOS 1.25 already used <code>LPT1</code> (first [[parallel port|line printer]]) and <code>COM1</code> (first [[COM (hardware interface)|serial communication device]]) instead, as introduced with PC DOS<!-- 1.0, 1.1 or 2.? -->. In addition to <code>LPT1</code> and <code>LPT2</code> as well as <code>COM1</code> to <code>COM3</code>, Hewlett-Packard's OEM version of [[MS-DOS 2.11]] for the [[HP Portable Plus]] also supported <code>LST</code> as alias for <code>LPT2</code> and <code>82164A</code> as alias for <code>COM2</code>;<ref name="HP_1985_PP" /><ref name="HP_1986_PP" /> it also supported <code>PLT</code> for [[plotter]]s.<ref name="HP_1985_PP" /><ref name="HP_1986_PP" /> Otherwise, <code>COM2</code>, <code>LPT2</code>, <code>LPT3</code> and the <code>CLOCK$</code> (still named <code>CLOCK</code> in some issues of MS-DOS 2.11<ref name="Microsoft_2014_Altos">{{cite web |author-first1=Tim |author-last1=Paterson |author-link1=Tim Paterson |author2=Microsoft |title=Microsoft DOS V1.1 and V2.0: /msdos/v20source/SKELIO.TXT, /msdos/v20source/HRDDRV.ASM |url=http://www.computerhistory.org/atchm/microsoft-research-license-agreement-msdos-v1-1-v2-0/ |publisher=[[Computer History Museum]], [[Microsoft]] |date=2013-12-19<!-- 2014-03-25 --> |orig-year=1983<!-- 1983-05-17 --> |access-date=2014-03-25 |url-status=live |archive-url=https://web.archive.org/web/20140326183713/http://www.computerhistory.org/atchm/microsoft-research-license-agreement-msdos-v1-1-v2-0/ |archive-date=2014-03-26}} (NB. While the publishers claim this would be MS-DOS 1.1 and 2.0, it actually is [[SCP MS-DOS 1.25]] and a mixture of [[Altos MS-DOS 2.11]] and [[TeleVideo PC DOS 2.11]].)</ref><ref name="HP_1985_PP" /><ref name="HP_1986_PP" />) clock device were introduced with DOS 2.0,<!-- TBD: Recheck COM2, LPT2 and LPT3 intro --> and <code>COM3</code> and <code>COM4</code> were added with DOS 3.3.<ref name="Microsoft_Built-in_devices" /> Only the multitasking [[MS-DOS 4.0 (multitasking)|MS-DOS 4]] supported <code>KEYBD$</code> and <code>SCREEN$</code>. [[DR DOS 5.0]] and higher and Multiuser DOS support an <code>[[$IDLE$]]</code> device for dynamic idle detection to saving power and improve multitasking. <code>LPT4</code> is an optional built-in driver for a fourth line printer supported in some versions of DR-DOS since 7.02. <code>CONFIG$</code> constitutes the [[real mode]] [[Legacy Plug and Play|PnP]] manager in MS-DOS 7.0–8.0.
Line 148 ⟶ 152:
OS/2 allows for 'DOS from Drive A:', (VMDISK). This is a real DOS, like MS-DOS 6.22 or PC DOS 5.00. One makes a bootable floppy disk of the DOS, adds a number of drivers from OS/2, and then creates a special image. The DOS booted this way has full access to the system, but provides its own drivers for hardware. One can use such a disk to access cdrom drives for which there is no OS/2 driver.
In all 32-bit (IA-32) editions of the Windows NT family since 1993, DOS emulation is provided by way of a [[virtual DOS machine]] (NTVDM). 64-bit (IA-64 and x86-64) versions of Windows do not support NTVDM and cannot run 16-bit DOS applications directly; third-party emulators such as DOSbox can be used to run DOS programs on those machines.
== User interface ==
DOS systems use a [[command-line interface]]. A program is started by entering its filename at the command prompt. DOS systems include utility programs and provide internal commands that do not correspond to programs.<ref>{{cite book |title=DOS the Easy Way |author-last=Murdock |author-first=Everett |year=2008 |pages=7–12 |publisher=EasyWay Downloadable Books |isbn=978-0-923178-02-4}}</ref>
In an attempt to provide a more user-friendly environment, numerous software manufacturers wrote [[file manager|file management programs]] that provided users with menu-[[WIMP and/or icon-based(computing)|WIMP]] interfaces. Microsoft Windows is a notable example, eventually resulting in [[Windows 9x|Microsoft Windows 9x]] becoming a self-contained program loader, and replacing DOS as the most-used PC-compatible program loader. [[Text user interface]] programs included [[Norton Commander]], [[DOS Navigator]], [[Volkov Commander]], Quarterdesk [[DESQview]], and [[Borland Sidekick|Sidekick]]. [[Graphical user interface]] programs included Digital Research's [[Graphics Environment Manager|GEM]] (originally written for CP/M) and [[GEOS (16-bit operating system)|GEOS]].
Eventually, the manufacturers of major DOS systems began to include their own environment managers. MS-DOS/IBM DOS 4 included [[DOS Shell]];<ref>{{cite book |title=DOS the Easy Way |author-last=Murdock |author-first=Everett |year=2008 |page=71 |publisher=EasyWay Downloadable Books |isbn=978-0-923178-02-4 |url=https://books.google.com/books?id=vrsSflB2o5sC |url-status=live |archive-url=https://web.archive.org/web/20150318124401/http://books.google.com/books?id=vrsSflB2o5sC |archive-date=2015-03-18}}</ref> DR DOS 5.0, released the following year, included [[ViewMAX]], based upon GEM.<ref>{{cite book |title=Dvorak's Guide to DOS and PC Performance |author-last1=Dvorak |author-first1=John Charles |author-link1=John Charles Dvorak |author-first2=Nick |author-last2=Anis |pages=442–444 |publisher=[[Osborne McGraw-Hill]] |date=1991}}</ref>
Line 160 ⟶ 164:
{{Main|Terminate-and-stay-resident program}}
Although DOS is not a multitasking operating system, it does provide a ''terminate-and-stay-resident'' (TSR) function which allows programs to remain resident in memory. These programs can hook the system timer and/or keyboard interrupts to allow themselves to run tasks in the background or to be invoked at any time, preempting the current running program and effectively implementing a simple form of multitasking on a program-specific basis. The DOS [[PRINT (command)|PRINT]] command does this to implement background print spooling. [[Borland Sidekick]], a popup [[personal information manager]] (PIM), also uses this technique.
Terminate-and-stay-resident programs are also used to provide additional features not available by default. Programs like CED and [[DOSKEY]] provide command-line editing facilities beyond what is available in COMMAND.COM. Programs like the Microsoft CD-ROM Extensions (MSCDEX) provide access to files on CD-ROM disks.
Line 215 ⟶ 219:
* [https://archive.today/20121209035503/http://purl.oclc.org/net/Batfiles/ Batfiles: The DOS batch file programming handbook]
* {{cite web|url=https://www.pcmag.com/news/the-rise-of-dos-how-microsoft-got-the-ibm-pc-os-contract|title=The Rise of DOS: How Microsoft Got the IBM PC OS Contract|website=pcmag.com|access-date=2022-12-24}}
* {{cite web|url=https://www.jumpjet.info/Application-Software/DOS/sfn.htm|title=Application Software - DOS Short File Name Family|website=www.jumpjet.info|access-date=2020-02-07|archive-date=2020-02-17 |archive-url=https://web.archive.org/web/20200217192920/http://www.jumpjet.info/Application-Software/DOS/sfn.htm|url-status=dead}} "(...) An archive of carefully hand selected FREE [and [[abandonware|abandoned]]] software for DOS."
* [https://lrusso.github.io/VirtualXP/VirtualXP.htm Online Windows XP Simulator]
* [https://github.com/microsoft/MS-DOS/tree/main MS-DOS v1.25, v2.0, v4.0 Source Code]
{{Disk operating systems}}