Mscdex command

Updated: 11/12/2023 by Computer Hope
mscdex command

Mscdex is a "redirector" that enables CD-ROM access from the MS-DOS.


Mscdex or mscdexnt are external commands that are available for the following versions of Microsoft operating systems as mscdex.exe or mscdexnt.exe.

Mscdex syntax

MSCDEX.EXE /D:x /M:n /E /V /L:x /S /K
/D:Device name Allows you to specify the name for the driver. This device name must be identical to the device name in the config.sys file. Usually, MSCD0001 is commonly used.
/M:<n> Specifies the number of sector buffers to cache the path table of a CD-ROM disk. Each drive should have four to five buffers. The larger this number is, the less your computer will read directly from the CD-ROM drive.
/E Tells MSCDEX.exe to use expanded memory.
/V Displays information on memory usage when you boot your PC.
/L:<drive letter> Specifies the drive letter you want to assign the first CD-ROM drive. Such as D:
/S Allows the CD-ROM to be shared on MS-NET based systems.
/K (Japanese) Tells MSCDEX.EXE to use any KANJI file structures if present rather than the default of alphanumeric file structures.

Extra notes

When loading the MSCDEX line in Windows 3.x, make sure to define the LASTDRIVE= statement with a line similar to "LASTDRIVE=Z" line.

Mscdex examples

Below is an example of how the MSCDEX line should look in your autoexec.bat:


Remember that if you use the example above must have the same device driver name as the CD-ROM driver in the config.sys.

Errors and issues

When booting, I receive the message "MSCDEX is already running," and if I continue, all programs stop running.

It's likely you have more than one MSCDEX statement in your autoexec.bat. Edit the autoexec.bat and place a REM in front of one of the MSCDEX lines in the autoexec.bat.