Microsoft KB Archive/149548

= Multiple Copies of Command.com in Memory in MS-DOS Mode =

Article ID: 149548

Article Last Modified on 1/19/2007

-

APPLIES TO


 * Microsoft Windows 95
 * Microsoft Windows 98 Standard Edition

-



This article was previously published under Q149548



SYMPTOMS
When you restart your computer in MS-DOS mode, the MEM command may report two or more copies of Command.com in memory.



CAUSE
This situation occurs for the following reasons:

 Command.com loads itself in multiple pieces, which may be reported separately.  When you restart your computer in MS-DOS mode, Windows checks the "Exit to DOS.pif" file. Or, when you run a program shortcut that specifies MS-DOS mode, Windows checks the program information file (PIF) for the shortcut. In either case, Windows uses that information to build a batch file that describes how MS-DOS mode should be configured. The batch file has the following structure:

rem This is the batch file for MS-DOS mode   command.com  After the Windows GUI is shut down, Command.com runs the batch file. Therefore, two copies of Command.com are resident in memory. The outer copy runs the batch file and the inner copy processes your commands.

When you type "exit" in the inner copy of Command.com, control is returned to the outer copy of Command.com, which restarts the Windows GUI. 

Note that two copies of Command.com require less than twice the amount of memory as one copy because the second and any subsequent copies share information with the first copy.



RESOLUTION
Instead of exiting to MS-DOS mode and then running the program manually, create a shortcut for the program and configure the shortcut to use MS-DOS mode. When you want to run the program, double-click the shortcut instead of exiting to MS-DOS mode manually.

For information about MS-DOS mode settings, please see the following article in the Microsoft Knowledge Base:

ARTICLE-ID: 134400

TITLE : General Tips for Using MS-DOS Mode

Keywords: kbenv kbprb KB149548

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.