Export (0) Print
Expand All

To get information about a command by using command-line help

Archived content. No warranty is made as to technical accuracy. Content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

Windows 95 retains and enhances most of the functionality of MS-DOS and LAN Manager. This appendix lists and briefly describes all the command-line commands available in Windows 95. The list includes commands you can use to modify CONFIG.SYS files, write batch programs, and change international settings.

For information about a specific command, use command-line help, which provides syntax, notes about how the command works, and examples of how to use it.

  • At the command prompt, type the command name followed by a space and /?

    For example, for information about the dir command, type dir /? at the command prompt.

On This Page

Command Syntax
Using the Command Prompt
Native Windows 95 Commands
Command-Line Switches for Specific Commands
Command-Line Switches for Disk Utilities
TCP/IP Utilities

Command Syntax

Syntax is the order in which you must type a command and the elements that follow the command. Commands have up to four elements: command name, parameters, switches, and values. In the following illustration, the first example lists all hidden files in the C:\LETTERS directory. The second example allows up to 10 users to connect to the C:\USERS\PUBLIC directory.

Cc751126.rka_09(en-us,TechNet.10).gif

Besides these four elements, command symbols can be used to direct the output. Each element is explained below.

Command Name

States the action you want Windows 95 to carry out. Some commands (such as the cls command, which clears the screen) consist only of a command name. Most commands require more than a name. For all network commands, type net followed by a space and the command name, as in the following:

net config

Parameter

Defines or creates the object you want Windows 95 to act on. Windows 95 sometimes requires additional information, which you specify in one or more parameters after the command name. For example, the del command requires a parameter that is the name of the file you want to delete. Some commands require more than one parameter. For example, to rename a file by using the rename (ren) command, you must include the original name of the file in addition to the new name. The following command renames LETTER.TXT to MEMO.TXT:

ren letter.txt memo.txt

Caution: Some commands accept semicolons to separate parameters. For example, if you wanted to delete all files on drive A and typed del a;\*.* by mistake, Windows 95 would erase the file A in the current directory and all files in the root directory of the current drive.

Position in the syntax line determines how a command works and whether a parameter is a source (first) or a destination (second). In the example above, the source, LETTER.TXT, specifies the location of data to be transferred or used as input to a command. The destination, MEMO.TXT, specifies a location to which the data specified by source is to be transferred.

Switches

Modify how a command performs a task. A switch is a forward slash (/) or a hyphen (-), usually followed by words, letters, or numbers. Some commands do not have switches, whereas others have several. If a command has more than one switch, you type them one after the other, separated with a space. Switches can be in any position or order after the command name. Some commands accept more than one switch after a forward slash. Other commands, such as TCP/IP utilities, accept a hyphen (-) instead of the forward slash.

Tip The terms "parameter" and "switch" are often interchanged, since both elements follow the command name. The only meaningful difference between a switch and parameter is the presence of a forward slash or hyphen to indicate a switch and the parameter position in the syntax line to indicate whether the parameter is a source or a destination. The term "argument" is also used to refer to parameters or switches.

With some network commands for real-mode networking, Windows 95 presents a prompt that requires a user response before a task can be completed. Append the /yes (/y) or /no (/n) switch to a command to force a Yes or No answer for all responses. For example, stopping the workstation service causes Windows 95 to stop dependent services; Windows 95 prompts you before stopping each dependent service unless the /yes switch is included, as in the following:

net stop workstation /y

Value

Determines how a switch works. A value is a colon (:) or an equal sign (=), followed by a word, letter, or number and must immediately follow the switch it modifies without a space. The following example of the format command contains two values — the file system to use (VFAT in the following example) and a volume label (Backup2):

format d: /f:1.2 /v:backup2

Check the syntax for the specific command in online Help to determine whether the command you want to use requires an equal sign or a colon.

Command symbols

Direct the input or output of a command and permit conditional execution of a command. Used with commands and filter commands, the command symbols are powerful tools.

Symbol

Purpose

>

Redirects output.

>>

Appends redirected output to existing data.

<

Redirects input.

|

Pipes output.

Sort, more, and find are the built-in filter commands that work in the same way as command symbols, to allow you to sort input and output, cause output to the screen to be displayed one screen at a time, and search for specified text in a file.

Using the Command Prompt

This section explains how to:

  • Simplify entry of repetitive commands.

  • Pause or cancel execution of a command.

  • Cut and paste information to or from a command-prompt window.

Editing Commands with Doskey and Editing Keys

Windows 95 provides Doskey to give you quick access to your most recent commands and enable you to assign frequently used commands to a single keystroke. Doskey is also available for character-based programs that accept buffered input. Doskey allows you to assign multiple commands to a single key or a typed alias. In addition to Doskey, several editing keys allow you to use and edit the last command you typed, as described in the following table.

Key

Description

Doskey:

 

UP ARROW or
DOWN ARROW

Cycles through commands previously entered.

F7

Displays all of the previous commands in a list. Press F9 and then choose a number from the list, and press ENTER (or press ESCAPE to cancel).

Other editing keys:

 

F1

Displays the last command one character at a time.

F3

Displays the entire command.

BACKSPACE or
LEFT ARROW

Moves the cursor in a command.

INS

Toggles between insert and overtype mode.

Pausing or Canceling a Command

You can pause or stop the output of a command.

To pause the output of a command

  • Press CTRL+S or PAUSE.

    Press any key except PAUSE to restart the output of the command. You can stop and restart the output of a command as many times as you want.

To stop Windows 95 from completing a command

  • Press CTRL+BREAK or CTRL+C.

Important: Any action Windows 95 carried out before you pressed CTRL+BREAK or CTRL+C cannot be undone.

Transferring Information to or from a Command-Prompt Window

You can transfer information to or from the command prompt. The following topics describe how to do this using the Edit buttons in a window or using QuickEdit mode in a window or in full-screen mode.

In full-screen mode, you can also use the Edit menu commands to copy and paste information in any window, not just command-prompt windows. The data is transferred as text or as a bitmap to the Clipboard depending on how it was copied.

Tip To quickly switch a command prompt or MS-DOS – based application between a full screen and a window, press ALT+ENTER.

Copying and Pasting Information Using Edit Buttons

When running MS-DOS Prompt or an MS-DOS – based application in a window, you can use the Edit buttons to copy and paste text at the command prompt.

To select and copy text at the command prompt

  1. Click the Mark button, and then select the text you want to copy, using either the mouse or the arrow keys.

    rka_03

  2. Click the Copy button.

    rka_04

    This places the selected text on the Clipboard, so you can paste it anywhere, not just at the command line.

To paste text at the command prompt

  1. Make sure the text you want is on the Clipboard.

    This text can come from any source, not just from the command line.

  2. Place the insertion point where you want to paste it, and then click the Paste button.

    rka_05

Copying and Pasting Information Using QuickEdit Mode

QuickEdit mode allows you to copy and paste text in command-prompt windows using only the mouse, bypassing the Edit commands. QuickEdit mode copies data only when the command prompt is running as a window; however, you can paste text either in a window or a full screen.

Note: When QuickEdit mode is on, the mouse works as usual in MS-DOS – based applications that are running in a full screen; the mouse does not work when such applications run in a window if QuickEdit mode is on. Use the start command to retain use of the mouse when starting a program from a command-prompt window with QuickEdit mode enabled.

To copy and paste text at the command prompt using QuickEdit mode

  1. If necessary, turn on QuickEdit mode in the window properties.

  2. Position the pointer at the beginning of the text you want to copy. Press the left mouse button. Keeping the left mouse button depressed, drag the cursor to the last character of the section you want to copy and release the left mouse button. The portion of the screen you want to copy is highlighted.

  3. Right-click to copy the highlighted area to the Clipboard. The highlight will disappear.

  4. Right-click to copy the contents of the Clipboard to the command-prompt cursor. If you copy more than one line, a carriage return (CR) is added at the end of each line.

    You must still use the Paste command from the Edit menu to paste the contents of the Clipboard into Windows-based applications.

Native Windows 95 Commands

A native command takes advantage of the 32-bit operating system. Most commands familiar to MS-DOS users are now native Windows 95 system commands.

Some commands, such as dir and chdir, are internal, meaning the command resides in memory at all times. Internal commands can be run at the command prompt and in batch files.

Other commands, such as drvspace and xcopy, are external, meaning the command is stored in its own file and loads from disk when you use the command. External commands can be run at the command prompt, from Windows Explorer, from the Run command, or from the Start menu, and can also be run in batch files. Batch commands are for use in batch programs only, as described later in this appendix.

The following tables summarize the commands included with Windows 95. Unless otherwise specified, you can type these commands at the command prompt.

Command

Purpose

attrib2

Displays or changes file attributes.

break1

Sets or clears extended CTRL+C checking.

cd1

Displays the name of the current directory or changes the current directory.

chcp1

Displays the number of the active character set (code page). You can also use this command to change the active character set for all devices that support character-set switching.

chdir1

See the cd command.

chkdsk2

Checks the status of a disk and displays a status report. Can also fix disk errors. However, Windows ScanDisk (scandskw) is the recommended command for repairing disks.

cls1

Clears the screen.

command2

Starts a new instance of the command interpreter.

copy1

Copies one or more files to the location you specify.

ctty1

Changes the terminal device used to control the computer.

date1

Displays the date and prompts you to change the date, if necessary.

drvspace2

Compresses hard disk drives or floppy disks, and configures drives that were compressed by using DriveSpace or DoubleSpace. This is a Windows-based utility; for information, see the syntax description later in this appendix.

debug2

Starts the Debug program, which you can use to test and debug executable files.

defrag2

Reorganizes the files on a disk to optimize disk performance. This is a Windows-based utility; for information, see the syntax description later in this appendix.

del (erase)1

Deletes the files you specify.

deltree2

Deletes a directory and all the files and subdirectories that are in it.

dir1

Displays a list of the files and subdirectories that are in the current or specified directory.

diskcopy2

Copies the entire contents of one floppy disk to another floppy disk.

doskey2

Loads the Doskey program into memory. The Doskey program recalls command-line commands, and it enables you to edit command lines and create and run macros. Doskey loads by default.

edit2

Starts a text editor you can use to create and edit ASCII text files.

emm3862

Enables or disables EMM386 expanded-memory support. Also provides support for loading real-mode device drivers in the upper memory area if both EMM386.EXE and HIMEM.SYS are loaded with device= commands in CONFIG.SYS.

erase1

See the del command.

exit1

Quits the command interpreter (COMMAND.COM) and returns to the program that started the command interpreter, if one exists.

expand2

Decompresses a compressed file.

fc2

Compares two files and displays the differences between them.

fdisk2

Starts the Fdisk program, which configures a hard disk for use with Windows 95. Although you can run this command at the command prompt, you cannot use it while running Windows 95 on the drive that contains the Windows system files.

find2

Searches for a specific string of text in a file or files.

for2

Runs a specified command for each file in a set of files.

format2

Formats a disk for use with Windows 95 or MS-DOS. You can use the right-click a drive icon in Windows Explorer to use a Windows-based version of this command.

keyb2

Starts the Keyb program, which configures a keyboard for a specific language.

label2

Creates, changes, or deletes the volume label (name) of a disk.

lh1

See the loadhigh command.

loadfix2

Ensures that a program is loaded above the first 64K of conventional memory.

loadhigh (lh)1

Loads a program into upper memory.

md1

Creates a directory or subdirectory.

mem2

Displays the amount of used and free memory on the computer.

mkdir1

See the md command.

mode2

Configures a printer, serial port, or display adapter; sets the typematic rate; redirects printer output from a parallel port to a serial port; prepares, selects, refreshes, or displays the numbers of the character sets (code pages) for parallel printers or the keyboard and screen; displays the status of all the devices installed on the computer.

more1

Displays one screen of output at a time.

move2

Moves one or more files to the location you specify. Can also be used to rename files and directories.

nlsfunc2

Starts the Nlsfunc program, which loads country-specific information for national language support (NLS).

path1

Indicates which directories the operating system should search for executable files (programs).

prompt1

Changes the appearance of the command prompt.

rd1

Deletes (removes) a directory.

ren1

Changes the name of the file or files you specify.

rename1

See the ren command.

rmdir1

See the rd command.

scandisk2

Checks disks and the file system for damage, and repairs them, if needed. Windows ScanDisk (scandskw) is the recommended command for repairing disks, as described later in this appendix.

set1

Displays, sets, or removes environment variables.

setver2

Displays the version table. Reports a version number to programs or device drivers designed for earlier versions of MS-DOS.

smartdrv2

Starts or configures SMARTDrive, which creates a disk cache in extended memory.
Important Under Windows 95, do not place the smartdrv command in AUTOEXEC.BAT. Windows 95 uses another method of disk caching.

sort2

Reads input, sorts data, and writes the results to the screen, a file, or another device.

start /W2

Allows you to run a Windows-based program from the command line and wait for it. For information about other switches that can be used with start, see the online Help for the command.

subst2

Associates a path with a drive letter.

sys2

Creates a startup disk by copying hidden Windows 95 system files and the command interpreter (COMMAND.COM) to the disk.

time1

Displays the system time or sets the computer's internal clock.

type1

Displays the contents of a text file.

ver1

Displays the operating system version number.

verify1

Directs the operating system to verify that files are written correctly to a disk, and displays the status of verification.

vol1

Displays the volume label and serial number for a disk, if the disk has them.

xcopy2

Copies directories, their subdirectories, and files (except hidden and system files). For details, see the syntax description later in this appendix.

1 Internal commands can be used in batch files and at the command prompt.

2 External commands can be run from the command prompt or in batch files, or can be run from Windows Explorer, the Run command, or other parts of the Windows 95 user interface.

Network Commands

The following networking commands can be used at the command prompt, in batch files, and in configuration files such as AUTOEXEC.BAT. Some commands are applicable only in real mode, such as before Windows 95 starts, or if your computer uses only real-mode networking.

Command

Purpose

net config

Displays the controllable services that are running.

net diag

Runs the Microsoft Network Diagnostic program to display diagnostic information about your network.

net help or
net /?

Provides a list of network commands and topics you can get help with, or provides help with a specific command or topic.

net init1

Loads protocol and network adapter drivers without binding them. This may be necessary for network adapter drivers from other vendors. You can bind them using net start bind.

net logoff1,2

Breaks the connection between your computer and the network resources to which it is connected.

net logon1,2

Identifies you as a member of a workgroup.

net password2,3

Changes your logon password.

net print2

Displays or controls print jobs.

net start1

Starts a service or displays a list of started services.

net stop1

Stops a network service.

net time

Synchronizes the computer's clock with that of a server or domain, or displays the time for a server or domain.

net use

Connects a computer to or disconnects it from a shared resource, or displays information about computer connections.

net ver

Displays the type and version number of the network redirector you are using.

net view

Displays a list of servers or displays resources being shared by a server.

1 This command is available only in real mode, and cannot be used in an MS-DOS window.

2 This command is not supported for NetWare NCP servers.

3 The form net password /domain:name or net password \\server can be used in an MS-DOS window. However, the standard form of net password is available only in real mode, and cannot be used in an MS-DOS window.

Commands Used in CONFIG.SYS Files

You can use the commands listed in the following table in CONFIG.SYS files.

Command

Purpose

break

Sets or clears extended CTRL+C checking. You can use this command at the command prompt or in a batch file.

buffers and
buffershigh1

Allocates memory for a specified number of disk buffers when the computer starts. The buffershigh form causes reserved memory to be taken out of the upper memory area. You can use these commands only in CONFIG.SYS.

country

Enables the operating system to use country-specific conventions for displaying dates, times, and currency; for determining the order by which characters are sorted; and for determining which characters can be used in filenames. You can use this command only in CONFIG.SYS.

device

Loads the device driver you specify into memory. You can use this command only in CONFIG.SYS.

devicehigh

Loads the device driver you specify into upper memory. You can use this command only in CONFIG.SYS.

dos

Specifies that the operating system should maintain a link to the upper memory area (UMA), load part of itself into the high memory area (HMA), or both. You can use this command only in CONFIG.SYS.

drivparm

Defines parameters for devices such as disk and tape drives when you start the operating system. You can use this command only in CONFIG.SYS.

fcbs or
fcbshigh1

Specifies the number of file control blocks (FCBs) that the operating system can have open at the same time. The fcbshigh form causes reserved memory to be taken out of the upper memory area. You can use these commands only in CONFIG.SYS.

files or
fileshigh1

Specifies the number of files that the operating system can access at one time. The fileshigh form causes reserved memory to be taken out of the upper memory area. You can use these commands only in CONFIG.SYS.

include

Includes the contents of one configuration block within another. You can use this command only in CONFIG.SYS.

install

Loads a memory-resident program into memory. You can use this command only in CONFIG.SYS.

lastdrive or
lastdrivehigh1

Specifies the maximum number of drives you can access. The lastdrivehigh form causes reserved memory to be taken out of the upper memory area. You can use these commands only in CONFIG.SYS.

menucolor

Sets the text and background colors for the startup menu. You can use this command only within a menu block in CONFIG.SYS.

menudefault

Specifies the default menu item on the startup menu and sets a time-out value, if desired. You can use this command only within a menu block in CONFIG.SYS.

menuitem

Defines up to nine items on the startup menu. You can use this command only within a menu block in CONFIG.SYS.

numlock

Specifies whether the NUMLOCK setting on the numeric keypad is set to ON or OFF. You can use this command only within a menu block in CONFIG.SYS.

rem

Enables you to include comments (remarks) or prevent commands in a batch program or CONFIG.SYS from running.

shell

Specifies the name and location of the command interpreter you want Windows 95 to use. You can use this command only in CONFIG.SYS.

stacks or
stackshigh1

Supports the dynamic use of data stacks to handle hardware interrupts. The stackshigh form causes reserved memory to be taken out of the upper memory area. You can use these commands only in CONFIG.SYS.

submenu

Defines an item on a startup menu that, when selected, displays another set of choices. You can use this command only within a menu block in CONFIG.SYS.

switches

Specifies special options. Used only in CONFIG.SYS.

1 Windows 95 automatically reserves memory in the upper memory area unless CONFIG.SYS contains the entry dos=noauto or if HIMEM.SYS and EMM386 are not loaded.

The following device drivers can be loaded in CONFIG.SYS using a device= statement.

Device driver

Description

display.sys

Enables you to display international character sets on EGA, VGA, and LCD monitors. This device driver must be loaded by a device or devicehigh command in CONFIG.SYS.

driver.sys

Creates a logical drive that you can use to refer to a physical floppy disk drive. This device driver must be loaded by a device or devicehigh command in CONFIG.SYS.

emm386.exe

Provides support for loading real-mode device drivers in the upper memory area if both EMM386.EXE and HIMEM.SYS are loaded with device= commands in CONFIG.SYS.

himem.sys

Himem is an extended-memory manager — a program that coordinates the use of your computer's extended memory, including the high memory area (HMA), so that no two applications or device drivers use the same memory at the same time. This device driver must be loaded by a device command in CONFIG.SYS, and the command line must come before any commands that start applications or device drivers that use extended memory.

keyboard.sys

Enables the operating system to use a keyboard other than the standard U.S. QWERTY keyboard layout. You can use this command only in CONFIG.SYS.

mscdex.exe

Provides access to CD-ROM drives.

Commands Used in Batch Programs

Batch programs (also called batch files) allow you to simplify routine or repetitive tasks. A batch program is an unformatted text file that contains one or more commands and has a .BAT or .CMD filename extension. When the filename is typed at the command prompt, the commands in the file are run sequentially.

Any command can be included in a batch file. In addition, several commands allow conditional processing of the commands in the batch file. For example, the if command carries out a command based on the results of a condition. Other commands allow you to control input and output and to call other batch programs. You can use the following commands in batch programs.

Command

Purpose

call

Calls one batch program from another without causing the first batch program to stop.

choice

Prompts the user to make a choice in a batch program. Displays a specified prompt and pauses for the user to choose from among a specified set of keys.

echo

Displays or hides the text in batch programs when the program is running. Also indicates whether command-echoing is on or off.

for

Runs a specified command for each file in a set of files. You can use this command in batch programs or at the command prompt.

goto

Directs the operating system to a line in a batch program that is marked by a label you specify. You can use this command only in batch programs.

if

Performs conditional processing in batch programs. You can use this command only in batch programs.

pause

Suspends processing of a batch program and displays a message that prompts you to press any key to continue. You can use this command only in batch programs.

rem

Enables you to include comments (remarks) or prevent commands in a batch program or CONFIG.SYS from running.

shift

Changes the position of replaceable parameters in a batch program. You can use this command only in batch programs.

Commands Used to Change International Settings

You can use the following commands to change international settings such as country codes, keyboard layouts, and character sets (code pages):

chcp

keyb

nlsfunc

country

mode

 

Commands Not Included in Windows 95

The following commands are not included with the basic Windows 95 files:

append

graftabl

msav

ramdrive.sys

assign

graphics1

msbackup

romdrive.sys

backup

help

power

share

comp

interlink

print1

smartmon

dosshell

intersvr

printer.sys

tree

edlin1

join

qbasic1

undelete

ega.sys

memcard

recover

unformat

fasthelp

memmaker1

replace

vsafe

fastopen

mirror

restore1

 

1 This command is available on the Windows 95 compact disc.

Command-Line Switches for Specific Commands

This section describes command-line switches for certain commands or executable files that are of particular interest in Windows 95. These include the following:

  • emm386

  • Windows Explorer

  • xcopy

EMM386 Command-Line Switches

This section provides correct syntax and other details for using EMM386 command-line switches.

EMM386

Enables or disables EMM386 expanded-memory support.

The EMM386 device driver, EMM386.EXE, provides expanded-memory support and also provides access to the upper memory area. For information about EMM386.EXE, see its entry later in this appendix.

Syntax

emm386 [on|off|auto] [w=on|w=off]

To display the current status of EMM386 expanded-memory support, type emm386 at the command prompt:

Parameters

on|off|auto

Activates the EMM386 device driver (if set to on), or suspends the EMM386 device driver (if set to off), or places the EMM386 device driver in auto mode (if set to auto). Auto mode enables expanded-memory support only when a program calls for it. The default value is on.

w=on|w=off

Enables (if set to w=on) or disables (if set to w=off) Weitek coprocessor support. The default value is w=off.

Notes on EMM386

Installing the EMM386.EXE device driver.

To use the emm386 command, you must also install the EMM386.EXE device driver by using the device command in CONFIG.SYS.

Reactivating EMM386 expanded-memory support.

If EMM386 was loaded when the VM was started but is not currently in use, the on parameter reactivates expanded-memory support.

Suspending EMM386 expanded-memory support.

If EMM386 expanded-memory support is currently active, handle 0 is the only handle allocated, and EMM386 is not providing access to the upper memory area. The off parameter suspends EMM386 expanded-memory support. When EMM386 expanded-memory support is off, the EMM386.EXE device-driver header is changed so that programs cannot use expanded memory. This enables you to run programs that do not comply with the Virtual Control Program Interface (VCPI).

EMM386.EXE

Caution: Use EMM386.EXE parameters carefully. You can make the computer inoperable if you use them incorrectly.

Provides access to the upper memory area and uses extended memory to simulate expanded memory. This is for MS-DOS – based applications that need expanded memory. The EMM386.EXE device driver must be loaded by a device command in CONFIG.SYS. EMM386 uses extended memory to simulate expanded memory for programs that can use expanded memory. EMM386 also makes it possible to load programs and device drivers into upper memory blocks (UMBs).

Note: The EMM386.EXE device driver is different from the EMM386 command used to enable expanded-memory support.

Syntax

device=[drive:][path]emm386.exe [on|off|auto] [memory] [min=size]

[mx|frame=address|/pmmmm] [pn=address] [x=mmmm-nnnn]
[i=mmmm-nnnn] [b=address] [L=minXMS] [a=altregs] [h=handles]
[d=nnn] [ram=mmmm-nnnn] [noems] [novcpi] [highscan] [verbose]
[win=mmmm-nnnn] [nohi] [rom=mmmm-nnnn] [nomovexbda] [altboot]

Parameters

[ drive : path]

Specifies the location of the EMM386.EXE file.

on|off|auto

Activates the EMM386 device driver (if set to on), or suspends the EMM386 device driver (if set to off), or places the EMM386 device driver in auto mode (if set to auto). Auto mode enables expanded-memory support and upper memory block support only when a program calls for it. The default value is on. Use the emm386 command to change this value after EMM386 has started.

memory

Specifies the maximum amount of extended memory (in kilobytes) that you want EMM386 to provide as expanded/Virtual Control Program Interface (EMS/VCPI) memory. This amount is in addition to the memory used for UMBs and EMM386 itself. Values for memory are in the range 64 through the lesser of either 32768 or the amount of extended memory available when EMM386 is loaded. The default value is the amount of free extended memory. If you specify the noems switch, the default value is 0. EMM386 rounds the value down to the nearest multiple of 16.

Switches

min= size

Specifies the minimum amount of EMS/VCPI memory (in kilobytes) that EMM386 will provide, if that amount of memory is available. EMM386 reserves this amount of extended memory for use as EMS/VCPI memory when EMM386 is loaded by device=emm386.exe in CONFIG.SYS. EMM386 may be able to provide additional EMS/VCPI memory (up to the amount specified by the memory parameter) if sufficient XMS memory is available when a program requests EMS/VCPI memory. Values are in the range 0 through the value specified by the memory parameter. The default value is 256. If you specify the noems switch, the default value is 0. If the value of min is greater than the value of memory, EMM386 uses the value specified by min.

m x

Specifies the address of the page frame. Valid values for x are in the range 1 through 14. The following list shows each value and its associated base address in hexadecimal format:

1 => C000h

5 => D000h

9 => E000h

12 => 8800h

2 => C400h

6 => D400h

10 => 8000h

13 => 8C00h

3 => C800h

7 => D800h

11 => 8400h

14 => 9000h

4 => CC00h

8 => DC00h

 

 

frame= address

Specifies the page-frame segment base directly. To specify a specific segment-base address for the page frame, use the frame switch and specify the address you want. Valid values for address are in the ranges 8000h through 9000h and C000h through E000h, in increments of 400h. To provide expanded memory and disable the page frame, you can specify frame=none; however, this may cause some programs that require expanded memory to work improperly.

/p mmmm

Specifies the address of the page frame. Valid values for mmmm are in the ranges 8000h through 9000h and C000h through E000h, in increments of 400h.

p n = address

Specifies the segment address of a specific page, where n is the number of the page you are specifying and address is the segment address you want. Valid values for n are in the range 0 through 255. Valid values for address are in the ranges 8000h through 9C00h and C000h through EC00h, in increments of 400h. The addresses for pages 0 through 3 must be contiguous in order to maintain compatibility with version 3.2 of the Lotus/Intel/Microsoft Expanded Memory Specification (LIM EMS). If you use the mx switch, the frame switch, or the /pmmmm switch, you cannot specify the addresses for pages 0 through 3 for the /pmmmm switch.

x= mmmm-nnnn

Prevents EMM386 from using a particular range of segment addresses for an EMS page or for UMBs. Valid values for mmmm and nnnn are in the range A000h through FFFFh and are rounded down to the nearest 4-kilobyte boundary. The x switch takes precedence over the i switch if the two ranges overlap.

i= mmmm-nnnn

Specifies a range of segment addresses to be used (included) for an EMS page or for UMBs. Valid values for mmmm and nnnn are in the range A000h through FFFFh and are rounded down to the nearest 4-kilobyte boundary. The x switch takes precedence over the i switch if the two ranges overlap.

b= address

Specifies the lowest segment address available for EMS "banking" (swapping of 16-kilobyte pages). Valid values are in the range 1000h through 4000h. The default value is 4000h.

L= minXMS

Ensures that the specified amount (in kilobytes) of extended memory will still be available after EMM386 is loaded. The default value is 0.

a= altregs

Specifies how many fast alternate register sets (used for multitasking) you want to allocate to EMM386. Valid values are in the range 0 through 254. The default value is 7. Every alternate register set adds about 200 bytes to the size in memory of EMM386.

h= handles

Specifies how many handles EMM386 can use. Valid values are in the range 2 through 255. The default value is 64.

d= nnn

Specifies how many kilobytes of memory should be reserved for buffered DMA. Discounting floppy-disk DMA, this value should reflect the largest DMA transfer that will occur while EMM386 is active. Valid values for nnn are in the range 16 through 256. The default value is 16.

ram= mmmm-nnnn

Specifies a range of segment addresses to be used for UMBs and also enables EMS support. If you do not specify a range, EMM386 uses all available adapter space to create UMBs and a page frame for EMS.

noems

Provides access to the upper memory area but prevents access to expanded memory.

novcpi

Disables support for VCPI applications. This switch must be used with the noems switch. If you specify the novcpi switch without specifying the noems switch, EMM386 does not disable VCPI support. If you specify both switches, EMM386 disregards the memory parameter and the min switch. Disabling support for VCPI applications reduces the amount of extended memory allocated.

highscan

Specifies that EMM386 use an additional check to determine the availability of upper memory for use as UMBs or EMS windows. On some computers, specifying this switch may have no effect or cause EMM386 to identify upper memory areas as available when they are not. As a result, the computer might stop responding.

verbose

Directs EMM386 to display status and error messages while loading. By default, EMM386 displays messages only if it encounters an error condition. You can abbreviate verbose as V. (To display status messages without adding the verbose switch, press and hold ALT while EMM386 starts and loads.)

win= mmmm-nnnn

Reserves a specified range of segment addresses for Windows instead of for EMM386. Valid values for mmmm and nnnn are in the range A000h through FFFFh and are rounded down to the nearest 4-kilobyte boundary. The x switch takes precedence over the win switch if the two ranges overlap. The win switch takes precedence over the ram, rom, and i switches if their ranges overlap.

nohi

Prevents EMM386 from loading into the upper memory area. Normally, a portion of EMM386 is loaded into upper memory. Specifying this switch decreases available conventional memory and increases the upper memory area available for UMBs.

rom= mmmm-nnnn

Specifies a range of segment addresses that EMM386 uses for shadow RAM — random-access memory used for read-only memory (ROM). Valid values for mmmm and nnnn are in the range A000h through FFFFh and are rounded down to the nearest 4-kilobyte boundary. Specifying this switch may speed up the system if it does not already have shadow RAM.

nomovexbda

Prevents EMM386 from moving the extended BIOS data from conventional memory to upper memory.

altboot

Specifies that EMM386 use an alternate handler to restart the computer when you press CTRL+ALT+DEL. Use this switch only if the computer stops responding or exhibits other unusual behavior when EMM386 is loaded and you press CTRL+ALT+DEL.

Notes on EMM386.EXE

Must install HIMEM.SYS before EMM386.EXE.

You must include a device command for the HIMEM.SYS device driver in CONFIG.SYS before the device command for EMM386.EXE.

Using EMM386 memory switches.

Unless you want to use EMM386 to provide access to the upper memory area, you need not specify memory switches on the device command line. EMM386 usually runs properly with the default values. In some cases, however, you might want to control how EMM386 uses memory. For example, you can control where EMM386 puts the EMS page frame or which segments it uses for EMS pages. You can use as many of these memory switches as you want, in any order you want.

Using EMM386 to provide access to the upper memory area.

In addition to providing access to expanded memory, EMM386 provides access to the upper memory area, which you can use to load certain programs and device drivers. You must use either the ram or noems switch to provide access to the upper memory area.

To give the operating system access to the upper memory area but not to expanded memory, use the noems switch. To give the operating system access to both the upper memory area and expanded memory, use the ram switch. The ram switch provides access to less of the upper memory area for running device drivers and programs than does the noems switch. In either case, you must include the dos=umb command in CONFIG.SYS. The device command for EMM386.EXE must precede any devicehigh commands.

EMM386.EXE Examples

To start EMM386 as an expanded-memory emulator, using the default values, add the following lines to CONFIG.SYS:

device=himem.sys
device=emm386.exe

Because no location is specified, MS-DOS searches for the EMM386.EXE file in the root directory of the startup drive.

To specify that EMM386 allocate a maximum of 4096K of memory and a guaranteed 256K of memory (the default value), and to specify that the EMM386.EXE file is located in the DOS directory on drive C, add the following line to CONFIG.SYS:

device=c:\dos\emm386.exe 4096 

To emulate expanded memory, specify the segment-base address D000h for the EMS page frame, and allocate 512K of memory to EMM386, use one of the following commands:

device=emm386.exe 512 frame=d000
device=emm386.exe 512 p0=d000 p1=d400 p2=d800 p3=dc00

Suppose that, in addition to specifying the conditions set in the preceding commands, you want to prevent EMM386 from using the segment addresses E000h through EC00h. To do this and to specify that EMM386 can use 127 handles, add the following line to CONFIG.SYS:

device=emm386.exe 512 frame=d000 x=e000-ec00 h=127 

To provide access to the upper memory area but not provide EMS/VCPI memory, add the following line to CONFIG.SYS:

device=emm386.exe noems novcpi 

To provide access to the upper memory area and provide EMS/VCPI memory, add the following line to CONFIG.SYS:

device=emm386.exe ram 

Windows Explorer Command-Line Switches

You can use the command-line switches for Windows Explorer in shortcut links or batch files, for example, to run Windows Explorer with a specified file selected.

Syntax

explorer [/n] [/e][,/root,object][[,/select],subobject]

Parameters

/n

Always open a new window (even if the specified folder is already open).

/e

Use Windows Explorer view. The default is Open view.

/root, object

Specify the object in the normal namespace that will be used as the root of this Windows Explorer Folder. The default is to just use the normal namespace root (the desktop).

subobject

Specify the folder to receive the initial focus unless /select is used. The default is the root.

/select

Specifies that the parent folder is opened and the specified object is selected.

Windows Explorer Examples

To open a window rooted at \\myserver so you can easily browse the whole server, but nothing else:

explorer /e,/root,\\myserver

To open a folder window on C:\WINDOWS (or make an open window active) and select CALC.EXE, use:

explorer /select,c:\windows\calc.exe

Xcopy

This command is used to copy files and directories, including subdirectories.

Syntax

xcopy source [destination] [/w] [/p] [/c] [/v] [/q] [/f] [/l] [/d[:date]] [/u] [/i]

[/s [/e]] [/t] [/k] [/r] [/h] [/a|/m] [/n] [/exclude:filename]

Parameters

source

Specifies the location and names of the files you want to copy. Source must include either a drive or a path.

destination

Specifies the destination of the files you want to copy. Destination can include a drive letter and colon, a directory name, a filename, or a combination.

/w

Displays a message asking you to press a key to begin copying files, and waits for your response before starting to copy files.

/p

Prompts you to confirm whether you want to create each destination file.

/c

Ignores errors.

/v

Verifies each file as it is written to the destination file to make sure that the destination files are identical to the source files. This switch is ignored because the functionality is inherent to the Windows 95 operating system. The switch is accepted only for compatibility with previous versions of MS-DOS.

/q

Suppresses display of xcopy messages.

/f

Displays source and destination filenames while copying.

/l

Does not copy files, only displays (lists) files that would be copied.

/d[:date]

Copies only source files changed on or after the specified date. If the date value is missing, xcopy copies all source files that are newer than the time of existing destination files. This option allows you to update only files that have changed. Notice that dates in the twenty-first century must be specified using four digits (for example, /D:1-1-2001 if m-d-y is the date format). That is, /D:1-1-01 is interpreted as 1 January 1901 rather than 1 January 2001.

/u

Copies (updates) only files from source that exist on destination.

/i

If source is a directory or contains wildcards, and destination does not exist, xcopy assumes destination specifies a directory name and creates a new directory and then copies all specified files into the new directory. By default, xcopy prompts you to specify whether destination is a file or directory.

/s

Copies directories and subdirectories, unless they are empty. If you omit this switch, xcopy works within a single directory.

/e

Copies all subdirectories, even if they are empty. Used with the /s and /t switches.

/t

Copies only subdirectory structure (tree), not files. To copy empty directories, you must include the /e switch.

/k

Copies files and retains the read-only attribute on destination files if present on the source files. By default, the read-only attribute is removed.

/r

Copies over read-only files.

/h

Copies files with the hidden and system file attributes. Xcopy will not copy hidden or system files by default.

/a

Copies only source files that have their archive file attributes set. This switch does not modify the archive file attribute of the source file. For information about how to set the archive file attribute, see the online Help for the attrib command.

/m

Copies source files that have their archive file attributes set. Unlike the /a switch, the /m switch turns off archive file attributes in the files specified in source. For information about how to set the archive file attributes, see the online Help for the attrib command.

/n

Copies using aliases (short file or directory names). This switch is required when copying files or directories from a VFAT volume to a FAT volume or when the 8.3 file naming convention is required on the destination volume.

/exclude: filename

Excludes the files listed in the specified file from the copy operation. The exclusion file can have a list of exclusion patterns (one per line, no wild card characters are supported). If any exclusion pattern in the file matches any part of the path of a subject file, that file is not copied.

Notes on Xcopy

Default value for destination.

If you omit destination, the xcopy command copies the files to the current directory.

Specifying whether the destination is a file or a directory.

If destination does not contain an existing directory and does not end with a backslash (\), xcopy prompts you with a message in the following format:

Does destination specify a file name 
or directory name on the target 
(F = file, D = directory)? 

You can avoid this prompt by using the /i switch, in which case xcopy assumes the destination is a directory if the source is more than one file or a directory.

Xcopy sets an archive attribute for destination files.

Xcopy creates files with the archive attribute set, whether or not this attribute was set in the source file. For information, see the online Help for atttrib command.

Xcopy vs. diskcopy.

If you have a disk that contains files in subdirectories and you want to copy it to a disk that has a different format, you should use the xcopy command instead of diskcopy. The diskcopy command copies disks track by track; it requires that your source and destination disks have the same format. Xcopy has no such requirement. In general, use xcopy unless you need a complete disk image copy.

Xcopy exit codes.

The following list shows each exit code and a brief description of its meaning:

0

Files were copied without error.

1

No files were found to copy.

2

The user pressed CTRL+C to terminate xcopy.

4

Initialization error occurred. There is not enough memory or disk space, or you entered an invalid drive name or invalid syntax on the command line.

5

Disk write error occurred.

You can use the errorlevel parameter on the if command line in a batch program to process exit codes returned by xcopy.

Xcopy Examples

To copy all the files and subdirectories (including any empty subdirectories) from the disk in drive A to the disk in drive B, type:

xcopy a: b: /s /e 

To include any system or hidden files in the previous example, add the /h switch when typing:

xcopy a: b: /s /e /h

To update files in the REPORTS directory with the files in the directory RAWDATA that have changed since December 29, 1993, type:

xcopy \rawdata \reports /d:12/29/93 

To update all the files that exist on \REPORTS in the previous example, regardless of date, type:

xcopy \rawdata \reports /u

To obtain only a list of the files that would be copied for the previous command, without copying the files, type:

xcopy \rawdata \reports /d:12/29/93 /l > xcopy.out

The file XCOPY.OUT lists every file that would be copied.

To copy the \CUSTOMER directory and all subdirectories, including empty directories, to the directory \PUBLIC\ADDRESS on network drive H and retain the read-only attribute, while being prompted when a new file is being created on H, type the following:

xcopy \customer h:\public\address /s /e /k /p 

To issue the previous command and ensure xcopy creates, without prompting, the directory \ADDRESS if it does not exist, add the /i switch:

xcopy \customer h:\public\address /s /e /k /p /i

You can create a batch program to perform xcopy operations and use the batch if command to process the exit code in case an error occurs. For example, the following batch program uses replaceable parameters for the xcopysource and destination parameters:

@echo off 
rem COPYIT.BAT transfers all files in all subdirectories of
rem the source drive or directory (%1) to the destination 
rem drive or directory (%2) 
xcopy %1 %2 /s /e 
if errorlevel 4 goto lowmemory 
if errorlevel 2 goto abort 
if errorlevel 0 goto exit 
:lowmemory 
echo Insufficient memory to copy files or 
echo invalid drive or command-line syntax. 
goto exit 
:abort 
echo You pressed CTRL+C to end the copy operation. 
goto exit 
:exit 

To use this batch program to copy all files in the C:\PRGMCODE directory and its subdirectories to drive B, type the following command:

copyit c:\prgmcode b: 

The command interpreter substitutes C:\PRGMCODE for %1 and B: for %2, then uses xcopy with the /e and /s switches. If xcopy encounters an error, the batch program reads the exit code and goes to the label indicated in the appropriate if errorlevel statement. Windows 95 displays the appropriate message and exits from the batch program.

Command-Line Switches for Disk Utilities

This section describes the commands that can be used from the command line to run the Windows-based versions of the ScanDisk, DriveSpace, and Defrag disk utilities. These commands are provided to allow these disk utilities to be run from batch files.

Note: To provide compatibility with existing batch files, Windows 95 provides a start command to allow synchronous use of Windows-based programs from the command-line. To run a Windows-based program from the command-line and wait for it, use this syntax:

start /W " program_name arguments "

Defrag

This command controls Windows Defragmenter. For more information about this utility, see Chapter 20, "Disks and File Systems."

Syntax

defrag [drive: | /all] [/F | /U | /Q] [/noprompt] [/concise | /detailed]

Parameters

drive:

Drive letter of the disk to be optimized.

/all

Defragment all local, nonremovable drives.

/F

Defragment files and free space.

/U

Defragment files only.

/Q

Defragment free space only.

/concise

Display the Hide Details view (default).

/detailed

Display the Show Details view.

/noprompt

Unattended mode; do not stop and display confirmation messages.

DrvSpace

This command controls Windows DriveSpace at the command line, and can be used with either DblSpace or DrvSpace drives. These command switches are maintained for use in batch files and for compatibility with the compression utilities provided in MS-DOS version 6 and higher. Each switch performs the indicated operation, without asking for any additional input before beginning.

Additionally, the /interactive switch can be added to any command line to have DriveSpace ask for any missing parameters, and the /noprompt switch can be added to any syntax except the /info and /settings command-lines. The /noprompt switch prevents any confirmation dialog boxes from appearing (except for error messages). Notice that there is no way to prevent error messages from being displayed.

When you run DriveSpace without command-line arguments, the DriveSpace Manager appears, with menu commands for selecting the operations to perform. For more information about this utility, see Chapter 20, "Disks and File Systems."

Syntax

drvspace /compress d: [/size=n| /reserve=n] [/new=e:]

drvspace /create d: [/size=n | /reserve=n] [/new=e:] [/cvf=nnn]
drvspace /deleted:\d??space.nnn
drvspace /format d:\d??space.nnn
drvspace /host=e: d:
drvspace [/info] d:
drvspace /mount {[=nnn] d: | d:\d??space.nnn} [/new=e:]
drvspace /moved:/new=e:
drvspace /ratio[=n] d:
drvspace /settings
drvspace /size[=n| /reserve=n] d:
drvspace /uncompressd:
drvspace /unmount d:

Parameters

d ?? space.nnn

The filename of the hidden compressed volume file on the host drive, which can be either DRVSPACE.nnn or DBLSPACE.nnn, where nnn represents the actual filename extension.

The following sections provide details for these switches.

If you add switches or parameters to the drvspace command, the operating system carries out the requested task without starting the DriveSpace program. The command syntax differs from task to task, as summarized in the following list.

Action

Command

Compress a hard disk drive or floppy disk.

drvspace /compress

Create a new compressed drive in the free space on an existing drive.

drvspace /create

Delete a compressed drive.

drvspace /delete

Format a compressed drive.

drvspace /format

Display information about a compressed drive.

drvspace /info

Mount a compressed volume file (CVF). When DriveSpace mounts a CVF, it assigns it a drive letter; you can then use the files that CVF contains.

drvspace /mount

Change estimated compression ratio of a compressed drive.

drvspace /ratio

Change the size of a compressed drive.

drvspace /size

Uncompress a compressed drive.

drvspace /uncompress

Unmount a compressed drive.

drvspace /unmount

Notes on Drvspace

Fixing problems with drives compressed using DriveSpace.

DriveSpace no longer provides a Chkdsk command as in earlier versions. Instead, Windows 95 includes the new ScanDisk program, a full-featured disk analysis and repair utility. ScanDisk can check and repair both uncompressed drives and DriveSpace or DoubleSpace drives. It can even check and repair unmounted DriveSpace or DoubleSpace compressed volume files. For more information, see "ScanDisk" later in this appendix.

DBLSPACE.BIN, DRVSPACE.BIN, and DRVSPACE.SYS.

DBLSPACE.BIN or DRVSPACE.BIN is the part of the system that provides access to the compressed drives. When you start the computer, the operating system loads D??SPACE.BIN along with other operating system functions, before carrying out the commands in CONFIG.SYS and AUTOEXEC.BAT. D??SPACE.BIN initially loads in conventional memory, since it loads before device drivers that provide access to upper memory. Normally, if the hard disk drive has been compressed using DriveSpace, D??SPACE.BIN is loaded even if you press F8 and choose an alternate startup option.

DRVSPACX.VXD is the protected-mode driver for DriveSpace. This driver takes over from the real-mode D??SPACE.BIN driver when Windows 95 switches to protected mode. The real-mode driver is required for starting the computer, but after the system switches to protected mode, DRVSPACX ensures that you have 32-bit, protected-mode performance, and the memory used by the real-mode driver is reclaimed.

The DBLSPACE.SYS device driver does not provide access to compressed drives; instead it determines the final location of D??SPACE.BIN in memory. When loaded with a device command, the DBLSPACE.SYS device driver moves D??SPACE.BIN from the top to the bottom of conventional memory. When loaded with a devicehigh command, DBLSPACE.SYS moves D??SPACE.BIN from conventional to upper memory, if available. Whenever possible, DBLSPACE.SYS moves a portion of D??SPACE.BIN into the HMA.

How DriveSpace assigns drive letters.

When you compress a drive using DriveSpace, it creates a new drive and assigns a drive letter to that drive. DriveSpace skips the first four available drive letters and assigns the next available drive letter to the new drive. For example, if the computer has only drives A, B, and C, DriveSpace skips letters D, E, F, and G, and assigns drive letter H to the new drive.

When assigning letters to additional drives (for example, if you compress another drive), DriveSpace works backwards from the first drive letter it assigned. In the example above, DriveSpace would next assign the letter G.

DriveSpace attempts to avoid drive-letter conflicts with drives created by fdisk, RAMDrive, networks, or other installable device drivers that assign drive letters. However, if a drive-letter conflict does occur, DriveSpace resolves the conflict by reassigning its drive letters.

Drvspace /Compress

Compresses the files and free space on an existing hard disk drive, floppy disk, or other removable media. Compressing an existing drive makes more space available on that drive.

Note: DriveSpace cannot compress a drive that's completely full. To compress the startup hard disk drive, the drive must contain at least 2 MB of free space. Other hard disk drives and floppy disks must contain at least 768K of free space. (DriveSpace cannot compress 360K floppy disks.)

Syntax

drvspace /compress drive1: [/new=drive2:] [/reserve=size]

Parameters

drive1 :

Specifies the existing drive you want to compress.

Switches

/compress

Compresses the hard disk drive or floppy disk specified by the drive parameter. This switch can be abbreviated to /com.

/new=drive2:

Specifies the drive letter for the uncompressed (host) drive. After DriveSpace compresses an existing drive, the system will include both the existing drive (now compressed) and a new uncompressed drive. If you omit the /new switch, DriveSpace assigns the next available drive letter to the new drive.

/reserve=size

Specifies how many megabytes of space to leave uncompressed. Because some files do not work properly when stored on a compressed drive, you may want to reserve some uncompressed space. The uncompressed space will be located on the new uncompressed drive. This switch can be abbreviated to /reser.

Drvspace /Compress Examples

To compress drive D, type the following command:

drvspace /compress d: 

On drives larger than 256 MB, more space will be left on the host (because D??Space drives cannot be larger than 512 MB). Because this command does not specify how much space to leave uncompressed, DriveSpace leaves 2 MB of uncompressed space (the default). Because the command does not specify a drive letter for the uncompressed drive, DriveSpace assigns the next available drive letter to the new uncompressed drive (the host drive).

To direct DriveSpace to compress drive E, assign the drive letter F to the new uncompressed drive (the host drive), and leave 4 MB of uncompressed space on drive F, type the following command:

drvspace /compress e: /new=f: /reserve=4 

Drvspace /Create

Creates a new compressed drive by using free space on an uncompressed drive. The new compressed drive will provide more storage capacity than the amount of space it uses.

Syntax

drvspace /create drive1: [/new=drive2:] [/size=size | /reserve=size] [/cvf=nnn]

Parameters

drive1 :

Specifies the uncompressed drive that contains the space you want to use to create the new drive.

Switches

/create

Creates a new compressed drive by using free space on the uncompressed drive specified by drive1. This switch can be abbreviated to /cr.

/new=drive2:

Specifies the drive letter for the new compressed drive. The /new switch is optional; if you omit it, DriveSpace assigns the next available drive letter to the new drive.

/reserve=size

Specifies how many megabytes of free space DriveSpace should leave on the uncompressed drive. To make the compressed drive as large as possible, specify a size of 0.

You can include either the /reserve switch or the /size switch, but not both. If you omit both switches, DriveSpace uses all but 2 MB of free space. The /reserve switch can be abbreviated as /reser.

/size=size

Specifies the total size, in megabytes, of the compressed volume file. (This is the amount of space on the uncompressed drive that you want to allocate to the compressed drive.) You can include either the /reserve switch or the /size switch, but not both.

/cvf=nnn

Reports extension of the CVF file.

Drvspace /Create Examples

To create a new compressed drive that uses all available space on uncompressed drive E, type the following command:

drvspace /create e: /reserve=0 

To create a new compressed drive by using 10 MB of space on uncompressed drive E, type the following command:

drvspace /create e: /size=10 

To create a new compressed drive by using space on uncompressed drive D, and to direct DriveSpace to leave 2.75 MB of free space on drive D, type the following command:

drvspace /create d: /reserve=2.75 

The following command creates a new compressed drive by using all but 2 MB of the space on drive D:

drvspace /create d: 

Because the command includes neither the /reserve switch nor the /size switch, DriveSpace uses the default value for the /reserve switch and leaves 2 MB of space on drive D.

Drvspace /Delete

Deletes the selected compressed drive and erases the associated compressed volume file.

Caution: Deleting a compressed drive erases the entire drive and all the files it contains.

Syntax

drvspace /delete d :\d??space. ###

Parameters

d :\d??space. ###

Specifies the drive you want to delete. (DriveSpace will not allow you to delete any drive containing open files, including the drive containing Windows 95.)

Switch

/delete

Deletes the specified drive. This switch can be abbreviated as /del.

Drvspace /Delete Example

The following command directs DriveSpace to delete the compressed volume for drive C:

drvspace /delete h:\dblspace.### 

DriveSpace then deletes the compressed volume file for drive C. This completely erases the compressed drive and all the files it contains.

Drvspace /Format

Formats the selected compressed drive.

Caution: Formatting a compressed drive deletes all the files it contains. You cannot unformat a drive that has been formatted by using drvspace /format.

Syntax

drvspace /format d :\d??space. ###

Parameters

d :\d??space. ###

Specifies the drive you want to format. (DriveSpace will not allow you to format any drive containing open files, including the drive containing Windows 95.)

Switch

/format

Directs DriveSpace to format the specified compressed drive. This switch can be abbreviated as /f.

Drvspace /Format Example

The following command directs DriveSpace to format compressed drive E:

drvspace /format h:\dblspace.### 

DriveSpace then formats compressed drive E, which completely erases all the files on it.

Drvspace /Info

Displays information about the selected drive's free and used space, the name of its compressed volume file, and its actual and estimated compression ratios. You can use this command while Windows is running.

Syntax

drvspace [/info] | [drive:]

Parameters

drive :

Specifies the compressed drive about which you want information. If you don't specify a drive letter, DriveSpace displays information about the current drive.

Switch

/info

Directs DriveSpace to display information about the selected drive. This switch is optional and can be omitted as long as you specify a drive letter.

Drvspace /Info Examples

The following command displays information about the current drive:

drvspace /info

The following command displays information about drive C:

drvspace /info c: 

The following command displays information about drive E:

drvspace e: 

Drvspace /Mount

Establishes a connection between a compressed volume file (CVF) and a drive letter so that you can use the files the CVF contains. DriveSpace usually mounts CVFs automatically. You need to mount a CVF only if you previously unmounted it.

Syntax

drvspace /mount[=nnn] drive1: [/new=drive2:]

drvspace /mount d :\d??space.### [/new=drive2:]

Parameters

drive1 :

Specifies the drive that contains the compressed volume file you want to mount. You must specify a drive letter.

Switches

/mount=nnn

Directs DriveSpace to mount the compressed volume file with the filename extension specified by the nnn parameter. For example, to mount a CVF named DBLSPACE.001, you would specify /mount=001. If you omit the nnn parameter, DriveSpace attempts to mount the compressed volume file named DBLSPACE.000.

/new=drive2:

Specifies the drive letter to assign to the new drive. This switch is optional; if you don't specify a drive letter, DriveSpace assigns the new drive the next available drive letter.

Drvspace /Mount Examples

To mount a compressed floppy disk in drive A, type the following:

drvspace /mount a: 

To mount the compressed volume file DBLSPACE.001 located on uncompressed drive D, type the following:

drvspace /mount=001 d: 

Drvspace /Ratio

Changes the estimated compression ratio of the selected drive. DriveSpace uses this ratio to estimate how much free space the drive contains. You might want to change the estimated compression ratio if you plan to store new files with a compression ratio that differs greatly from the current ratio.

Syntax

drvspace /ratio[=r.r] [drive:]

Parameters

drive :

Specifies the drive for which you want to change the estimated compression ratio. If you do not specify a drive, DriveSpace changes the estimated compression ratio for the current drive.

Switch

/ratio=r.r

Changes the estimated compression ratio of the specified drive. To change the ratio to a specific number, specify the ratio you want. You can specify a ratio from 1.0 to 16.0. However, not all drives can accept values in this entire range. If you don't specify a ratio, DriveSpace sets the drive's estimated compression ratio to the average actual compression ratio for all the files currently on the drive. This switch can be abbreviated as /ra.

Drvspace /Ratio Examples

To change the estimated compression ratio of the current drive to match that drive's actual compression ratio, type the following command:

drvspace /ratio  

To change the estimated compression ratio for drive D so that it is 3.2 to 1, type the following:

drvspace /ratio=3.2 d: 

To change the estimated compression ratio of the current drive to 6 to 1, type the following:

drvspace /ratio=6 

Drvspace /Size

Enlarges or reduces the size of a compressed drive. You might want to enlarge a compressed drive if its host drive contains plenty of free space. You might want to reduce its size if you need more free space on the host drive.

Syntax

drvspace /size[=size1 | /reserve=size2] drive:

Parameters

drive :

Specifies the drive you want to resize.

Switches

/size=size1

Changes the size of the specified drive. You can specify the new size of the drive by using the size1 parameter. The size of the drive is the number of megabytes of space that the drive's compressed volume file uses on the uncompressed (host) drive.

You can specify the drive's new size by using either the size1 parameter or the /reserve switch, but not both. If you include neither the size1 parameter nor the /reserve switch, DriveSpace makes the drive as small as possible.

/reserve=size2

Specifies how many megabytes of free space you want the uncompressed (host) drive to contain after DriveSpace resizes the drive. The /reserve switch can be abbreviated as /reser.

You can specify the drive's new size by using either the /reserve switch or the size1 parameter of the /size switch, but not both. If you include neither the /reserve switch nor the size1 parameter, DriveSpace makes the drive as small as possible.

Drvspace /Size Examples

To change the size of drive C so that its compressed volume file uses 60.5 MB of space on drive D, type the following command:

drvspace /size=60.5 c: 

To change the size of drive E so that its host drive, drive D, contains 20 MB of free uncompressed space, type the following command:

drvspace /size /reserve=20 e: 

To change the size of drive C so that it is as large as possible, type the following command:

drvspace /size /reserve=0 c: 

Drvspace /Uncompress

Uncompresses a drive that was compressed by using DriveSpace.

Syntax

drvspace /uncompress drive:

Parameter

drive :

Specifies the drive you want to uncompress.

Switch

/ uncompress

Uncompresses the specified drive.

Notes on Drvspace /Uncompress

Backing up before uncompressing.

Before uncompressing the drive, you should back up the files it contains. If you include the /interactive switch, DriveSpace will prompt for this.

Invalid pathnames after uncompressing.

When you uncompress a drive, DriveSpace either changes that drive's letter or the letter of its host drive (depending on how the compressed drive was originally created). DriveSpace shows how the drive letters will change when it uncompresses the drive. Some programs have settings that include explicit pathnames and drive letters. If a program's settings specify a drive that is no longer valid after uncompressing, the program will probably display an error message or be unable to find one of its components or data files. In that case, you need to correct the drive letter specified by that setting.

Disk space.

You can uncompress a drive only if the data it contains will fit on the host drive. If you use the drvspace /uncompress command, and DriveSpace indicates the drive will not have enough free disk space, delete unnecessary files or move them to another drive.

Duplicate filenames on compressed and host drives.

If the root directories of the compressed and host drives contain files or directories with identical names, DriveSpace cannot uncompress the compressed drive. If this happens, DriveSpace displays an error message. Remove or rename one copy of each file, and then try uncompressing the drive again.

Uninstalling DriveSpace.

When you uncompress the last mounted compressed drive, DriveSpace first uncompresses the drive, and then prompts you to remove the DrvSpace driver from memory.

Drvspace /Uncompress Example

To uncompress drive E, type the following command:

drvspace /uncompress e:

Drvspace /Unmount

Breaks the connection between the selected drive's compressed volume file and its drive letter. Unmounting a drive makes it temporarily unavailable.

You cannot unmount a drive containing open files, including the drive containing Windows 95.

Syntax

drvspace /unmount [drive:]

Parameters

drive :

Specifies the drive you want to unmount. This parameter is optional; if you omit it, DriveSpace unmounts the current drive.

Switch

/unmount

Unmounts the specified compressed drive.

Drvspace /Unmount Example

To unmount compressed drive E, type the following command:

drvspace /unmount e: 

ScanDisk

This command syntax controls Windows ScanDisk. For more information about this utility, see Chapter 20, "Disks and File Systems."

Note: At the command prompt (for example, when you use F8 to start only the command prompt), you can use scandisk with the same switches to run the MS-DOS – based equivalent for this command. At the command prompt, type scandisk /? for more information.

Syntax

scandskw [drive:] [/A] [/N] [/P]

scandisk drive :\dblspace. nnn
scandisk drive :\drvspace. nnn

Parameters

drive:

Specifies one or more drives to be checked.

/A or /All

Checks all local, nonremovable hard disk drives.

/N or /NonInteractive

Starts and closes ScanDisk automatically. However, this switch does not prevent ScanDisk from stopping to report errors found on the drive.

/p or /PREVIEW

Runs ScanDisk in Preview mode, where it reports and seems to correct errors that it finds, but it does not actually write changes to the disk.

Important: When running scandskw in Preview mode, it appears as though ScanDisk is fixing errors, but it is not. Also, notice that unlike other settings in ScanDisk, the /PREVIEW switch is not saved in the Registry, so the next time you run ScanDisk, it is no longer in Preview mode.

To determine whether ScanDisk is running in Preview mode, look for the tag "(Preview)" in the caption of the main ScanDisk window.

dblspace. nnn or drvspace.nnn

Checks the specified unmounted DoubleSpace or DriveSpace compressed volume file, where nnn is the filename extension for the hidden host file.

The following table describes the codes provided when ScanDisk finished running.

Exit code

Description

0x00

Drive checked, no errors found

0x01

Errors found, all fixed

0xFA

Check could not start — cannot load or find DSKMAINT.DLL

0xFB

Check could not start — insufficient memory

0xFC

Errors found, but at least some were not fixed

0xFD

At least one drive could not be checked

0xFE

Check was canceled

0xFF

Check was terminated because of an error

You can capture the exit code in a batch file to define an action to take in the event of particular exit code. For example:

start /w scandksw c: d: /n
if errorlevel exitcode goto command
...

In this sample, start /w forces the batch file to stop and wait for scandskw to finish (otherwise, because it is a Windows-based program, the batch file would continue as soon as scandskw had been launched). Also in this example, if the actual exit code is greater than or equal to the exit code specified by exitcode, the batch file runs the specified command; otherwise, it continues to the next line in the batch file. The gotocommand entry could specify any command you want.

TCP/IP Utilities

The TCP/IP utilities offer network connections to non-Microsoft hosts such as UNIX® system computers. You must have the TCP/IP network protocol installedto use the TCP/IP utilities. These tools are installed automatically when you install Microsoft TCP/IP.

Command

Purpose

arp

Displays and modifies the IP-to-Ethernet address translation tables.

ftp

Transfers files to and from a node running ftp service; similar to tftp.

nbtstat

Displays protocol statistics and current TCP/IP connections using NetBIOS over TCP/IP.

netstat

Displays protocol statistics and current TCP/IP connections.

ping

Verifies connections to a remote host or hosts.

route

Manually controls network routing tables.

tracert

Determines the route taken to a destination.

Note: Switches used in the syntax for any TCP/IP are case-sensitive. For example, for the nbtstat command, the switch -R has a different effect from the -r switch.

To get help on TCP/IP utilities

  • At the command prompt, type -? followed by a space and the command name. For example, type ping -? to get help on the ping command.

Important: The FTP and Telnet utilities rely on password authentication by the remote computer. Passwords are not encrypted before being sent over the network. This allows another user equipped with a network analyzer on the same network to steal a user's remote account password. For this reason, it is strongly recommended that users of these utilities choose different passwords for their workgroup, computer, or domain from the passwords used when connecting to computers that are not on Microsoft networks.

The following presents a complete reference for the TCP/IP commands included with Windows 95.

Arp

This diagnostic command displays and modifies the IP-to-Ethernet or IP-to-token ring address translation tables used by the address resolution protocol (ARP).

Syntax

arp -a [inet_addr] [-N [if_addr]]

arp -d inet_addr [if_addr]
arp -sinet_addr ether_addr [if_addr]

Parameters

-a

Displays current ARP entries by querying TCP/IP. If inet_addr is specified, only the IP and physical addresses for the specified computer are displayed.

-d

Deletes the entry from the ARP cache table that is specified by inet_addr.

-s

Adds an entry in the ARP cache to associate the IP address inet_addr with the physical address ether_addr. The physical address is given as 6 hexadecimal bytes separated by hyphens. The IP address is specified using dotted decimal notation. The entry is permanent, that is, it will not be automatically removed from the cache after the timeout expires.

-N [if_addr]

Displays the ARP entries for the network interface specified by if_addr.

ether_addr

Specifies a physical address.

if_addr

Specifies, if present, the IP address of the interface for which the address translation table should be modified. If not present, the first applicable interface will be used.

inet_addr

Specifies an IP address in dotted decimal notation.

Ftp

This connectivity command transfers files to and from a computer running an FTP service. The ftp command can be used interactively or by processing ASCII text files.

Syntax

ftp [-v] [-n] [-i] [-d] [-g] [host] [-s: filename]

Parameters

-v

Suppresses display of remote server responses.

-n

Suppresses autologon upon initial connection.

-i

Turns off interactive prompting during multiple file transfers.

-d

Enables debugging, displaying all FTP commands passed between the client and server.

-g

Disables filename globbing, which permits the use of wildcard characters in local file and path names. (See the FTP glob command.)

host

Specifies the host name or IP address of the remote host to connect to.

-s: filename

Specifies a text file containing FTP commands; the commands will automatically run after ftp starts. Use this switch instead of redirection (>).

To use the ftp command

  • At the command prompt, type ftp plus any desired switches and press ENTER.

    For example, you might type ftp -s:myfile.scr

The following table shows the FTP commands available when Microsoft TCP/IP is installed on a computer.

Command

Purpose

!

Runs the specified command on the local computer.

?

Displays descriptions for ftp commands. Identical to help.

append

Appends a local file to a file on the remote computer, using the current file type setting.

ascii

Sets the file transfer type to ASCII, the default.

bell

Toggles a bell to ring after each file transfer command is completed. By default, the bell is off.

binary

Sets the file transfer type to binary.

bye

Ends the FTP session with the remote computer and exits ftp.

cd

Changes the working directory on the remote computer.

close

Ends the FTP session with the remote server and returns to the command interpreter.

debug

Toggles debugging. When debugging is on, each command sent to the remote computer is printed, preceded by the string --->. By default, debugging is off.

delete

Deletes files on remote computers.

dir

Displays a list of a remote directory's files and subdirectories.

disconnect

Disconnects from the remote computer, retaining the ftp prompt.

get

Copies a remote file to the local computer, using the current file transfer type.

glob

Toggles filename globbing. Globbing permits use of wildcard characters in local file or path names. By default, globbing is on.

hash

Toggles hash-mark (#) printing for each 2048 bytes data block transferred. By default, hash-mark printing is off.

help

Displays descriptions for FTP commands.

lcd

Changes the working directory on the local computer. By default, the current directory on the local computer is used.

literal

Sends arguments, verbatim, to the remote FTP server. A single FTP reply code is expected in return.

ls

Displays an abbreviated list of a remote directory's files and subdirectories.

mdelete

Deletes multiple files on remote computers.

mdir

Displays a list of a remote directory's files and subdirectories. Allows you to specify multiple files.

mget

Copies multiple remote files to the local computer using the current file transfer type.

mkdir

Creates a remote directory.

mls

Displays an abbreviated list of a remote directory's files and subdirectories.

mput

Copies multiple local files to the remote computer, using the current file transfer type.

open

Connects to the specified FTP server.

prompt

Toggles prompting. During multiple file transfers, ftp provides prompts to allow you to selectively retrieve or store files; mget and mput transfer all files if prompting is turned off. By default, prompting is on.

put

Copies a local file to the remote computer, using the current file transfer type.

pwd

Prints the current directory on the remote computer.

quit

Ends the FTP session with the remote computer and exits ftp.

quote

Sends arguments, verbatim, to the remote FTP server. A single FTP reply code is expected in return. Identical to literal.

recv

Copies a remote file to the local computer, using the current file transfer type. Identical to get.

remotehelp

Displays help for remote commands.

rename

Renames remote files.

rmdir

Deletes a remote directory.

send

Copies a local file to the remote computer, using the current file transfer type. Identical to put.

status

Displays the current status of FTP connections and toggles.

trace

Toggles packet tracing; displays the route of each packet when running an FTP command.

type

Sets or displays the file transfer type.

user

Specifies a user to the remote computer.

verbose

Toggles verbose mode. If on, all FTP responses are displayed; when a file transfer completes, statistics regarding the efficiency of the transfer are also displayed. By default, verbose is on.

Nbtstat

This diagnostic command displays protocol statistics and current TCP/IP connections using NetBIOS over TCP/IP.

Syntax

nbtstat [-aRemoteName] [-AIP_address] [-c] [-n] [-R] [-r] [-S] [-s] [interval]

Parameters

-a

Lists the remote computer's name table given its host name.

-A

Lists the remote computer's name table given its IP address specified in dotted decimal notation.

-c

Lists the contents of the NetBIOS name cache, with the IP address of each name.

-n

Lists local NetBIOS names. In this listing, "Registered" indicates that the name has been registered on this network node, either by b-node broadcast or by a WINS server.

-R

Reloads the LMHOSTS file after purging all names from the NetBIOS name cache.

-r

Lists name resolution statistics for Windows networking. On a computer configured to use WINS, this option returns the number of names resolved and registered broadcast or WINS.

-S

Displays both workstation and server sessions, listing the remote hosts by IP address only.

-s

Displays both workstation and server sessions. It attempts to convert the remote host IP address to a name using the HOSTS file.

interval

Redisplays selected statistics, pausing interval seconds between each display. Press CTRL+C to stop redisplaying statistics. If this parameter is omitted, nbtstat prints the current configuration information once.

Notes on Nbtstat

The column headings generated by the nbtstat utility have the following meanings.

Input

Number of bytes received.

Output

Number of bytes sent.

In/Out

Whether the connection is from the computer (outbound) or from another system to the local computer (inbound).

Life

The remaining time that a name table cache entry will live before it is purged.

Local Name

The local NetBIOS name associated with the connection.

Remote Host

The name or IP address associated with the remote host.

Type

This refers to the type of name. A name can either be a unique name or a group name.

<03>

Each NetBIOS name is 16 characters long. The last byte often has special significance, because the same name can be present several times on a computer. This notation is the last byte converted to hexadecimal. For example, <20> is a space in ASCII.

State

The state of NetBIOS connections as shown in the following list:

State

Meaning

Accepting

An inbound session is currently being accepted and will be connected shortly.

Associated

A connection endpoint has been created and associated with an IP address.

Connected

The session has been established.

Connecting

The session is in the connecting phase where the name-to-IP address mapping of the destination is being resolved.

Disconnected

The local computer has issued a disconnect, and it is waiting for confirmation from the remote computer.

Disconnecting

A session is in the process of disconnecting.

Idle

This endpoint has been opened but cannot receive connections.

Inbound

An inbound session is in the connecting phase.

Listening

This endpoint is available for an inbound connection.

Outbound

A session is in the connecting phase where the TCP connection is currently being created.

Reconnecting

A session is trying to reconnect if it failed to connect on the first attempt.

Netstat

This diagnostic command displays protocol statistics and current TCP/IP network connections.

Syntax

netstat [-a] [-ens] [-pprotocol] [-r] [interval]

Parameters

-a

Displays all connections; server connections are usually not shown.

-e

Displays Ethernet statistics. This may be combined with the -s option.

-n

Displays addresses and port numbers in numerical form (rather than attempting name look-ups).

-s

Displays per-protocol statistics. By default, statistics are shown for TCP, UDP, ICMP, and IP; the -p option may be used to specify a subset of the default.

-p protocol

Shows connections for the protocol specified by protocol; protocol may be tcp or udp. If used with the -s option to display per-protocol statistics, protocol may be tcp, udp, icmp,or ip.

-r

Displays the contents of the routing table.

interval

Redisplays selected statistics, pausing interval seconds between each display. Press CTRL+C to stop redisplaying statistics. If this parameter is omitted, netstat prints the current configuration information once.

Notes on Netstat

The netstat utility provides statistics on the following network components.

Statistic

Purpose

Foreign Address

The IP address and port number of the remote computer to which the socket is connected. The name corresponding to the IP address is shown instead of the number if the HOSTS file contains an entry for the IP address. In cases where the port is not yet established, the port number is shown as an asterisk (*).

Local Address

The IP address of the local computer, and the port number the connection is using. The name corresponding to the IP address is shown instead of the number if the HOSTS file contains an entry for the IP address. In cases where the port is not yet established, the port number is shown as an asterisk (*).

Proto

The name of the protocol used by the connection.

(state)

Indicates the state of TCP connections only. The possible states are:
CLOSED FIN_WAIT_1 SYN_RECEIVED
CLOSE_WAIT FIN_WAIT_2 SYN_SEND
ESTABLISHED LISTEN TIMED_WAIT
LAST_ACK

Ping

This diagnostic command verifies connections to one or more remote hosts.

Syntax

ping [-t] [-a] [-ncount] [-l length] [-f] [-ittl] [-vtos] [-rcount] [-scount]

[[-jhost-list] | [-k host-list]] [-wtimeout] destination-list

Parameters

-t

Pings the specified host until interrupted.

-a

Specifies not to resolve addresses to host names.

-n count

Sends the number of echo packets specified by count. The default is 4.

-l length

Sends echo packets containing the amount of data specified by length. The default is 64 bytes; the maximum is 8192.

-f

Sends a Do Not Fragment flag in the packet. The packet will not be fragmented by gateways on the route.

-i ttl

Sets the Time To Live field to the value specified by ttl.

-v tos

Sets the Type Of Service field to the value specified by tos.

-r count

Records the route of the outgoing packet and the returning packet in the Record Route field. A minimum of 1 to a maximum of 9 hosts must be specified by count.

-s count

Specifies the time stamp for the number of hops specified by count.

-j host-list

Routes packets by means of the list of hosts specified by host-list. Consecutive hosts may be separated by intermediate gateways (loose source routed). The maximum number allowed by IP is 9.

-k host-list

Routes packets by means of the list of hosts specified by host-list. Consecutive hosts may not be separated by intermediate gateways (strict source routed). The maximum number allowed by IP is 9.

-w timeout

Specifies a time-out interval in milliseconds.

destination-list

Specifies the remote hosts to ping.

Note on Ping

The ping command verifies connections to remote host or hosts, by sending Internet Control Message Protocol (ICMP) echo packets to the host and listening for echo reply packets. The ping command waits for up to 1 second for each packet sent and prints the number of packets transmitted and received. Each received packet is validated against the transmitted message. By default, four echo packets containing 64 bytes of data (a periodic uppercase sequence of alphabetic characters) are transmitted.

You can use the ping utility to test both the host name and the IP address of the host. If the IP address is verified but the host name is not, you may have a name resolution problem. In this case, be sure that the host name you are querying is in either the local HOSTS file or in the DNS database.

The following shows sample output for ping:

C:\>ping ds.internic.net
Pinging ds.internic.net [192.20.239.132] with 32 bytes of data:
Reply from 192.20.239.132: bytes=32 time=101ms TTL=243
Reply from 192.20.239.132: bytes=32 time=100ms TTL=243
Reply from 192.20.239.132: bytes=32 time=120ms TTL=243
Reply from 192.20.239.132: bytes=32 time=120ms TTL=243

Route

This diagnostic command manipulates network routing tables.

Syntax

route [-f] [command [destination] [MASK netmask] [gateway]]

Parameters

-f

Clears the routing tables of all gateway entries. If this parameter is used in conjunction with one of the commands, the tables are cleared prior to running the command.

command

Specifies one of four commands.

Command

Purpose

print

Prints a route

add

Adds a route

delete

Deletes a route

change

Modifies an existing route

destination

Specifies the host-to-send command.

MASK

Specifies, if present, that the next parameter be interpreted as the netmask parameter.

netmask

Specifies, if present, the subnet mask value to be associated with this route entry. If not present, this parameter defaults to 255.255.255.255.

gateway

Specifies the gateway.

Telnet

This connectivity command starts terminal emulation with a remote system running a Telnet service. Telnet provides DEC™ VT 100™, DEC VT 52, or TTY emulation, using connection-based services of TCP.

To provide terminal emulation from a Windows 95 computer, the foreign host must be configured with the TCP/IP program, the Telnet server program or daemon, and a user account for the computer running Windows 95.

The Telnet application is found in the Accessories program group if you install the TCP/IP connectivity utilities. Telnet is a Windows Sockets-based application that simplifies TCP/IP terminal emulation with Windows 95.

Note: Microsoft does not provide the Telnet server daemon (telnetd).

Syntax

telnet [host [port]]

Parameters

host

Specifies the host name or IP address of the remote system you want to connect to, providing compatibility with applications such as Gopher and Mosaic.

port

Specifies the remote port you want to connect to, providing compatibility with applications such as Gopher and Mosaic. The default value is specified by the telnet entry in the SERVICES file. If no entry exists in the SERVICES file, the default connection port value is decimal 23.

Tracert

This diagnostic utility determines the route taken to a destination by sending Internet Control Message Protocol (ICMP) echo packets with varying Time-To-Live (TTL) values to the destination. Each router along the path is required to decrement the TTL on a packet by at least 1 before forwarding it, so the TTL is effectively a hop count. When the TTL on a packet reaches 0, the router is supposed to send back an ICMP Time Exceeded message to the source system. The tracert command determines the route by sending the first echo packet with a TTL of 1 and incrementing the TTL by 1 on each subsequent transmission until the target responds or the maximum TTL is reached. The route is determined by examining the ICMP Time Exceeded messages sent back by intermediate routers. Notice that some routers silently drop packets with expired TTLs and are invisible to tracert.

Syntax

tracert [-d] [-h maximum_hops] [-j host-list] [-w timeout] target_name

Parameters

-d

Specifies not to resolve addresses to host names.

-h maximum_hops

Specifies maximum number of hops to search for target.

-j host-list

Specifies loose source route along host-list.

-w timeout

Waits the number of milliseconds specified by timeout for each reply.

target_name

Specifies the host name of the destination computer.

Notes on Tracert

The following shows sample output for tracert. The first column is the hop number, which is the Time To Live (TTL) value set in the packet. Each of the next three columns contains the round-trip times in milliseconds for an attempt to reach the destination with that TTL value. An asterisk (*) means that the attempt timed out. The fourth column is the host name (if it was resolved) and IP address of the responding system.

C:\>tracert ds.internic.net
Tracing route to ds.internic.net [198.49.45.10]
over a maximum of 30 hops:
1  <10 ms <10 ms   *    [131.107.1.100]
2   10 ms <10 ms  10 ms seattle1-gw.nwnet.net [192.80.12.82]
3    *     10 ms  10 ms enss143-enet.nwnet.net [192.35.180.2]
4   20 ms   *     10 ms t3-3.seattle-cnss8.t3.ans.net [140.222.88.4]
5   30 ms  30 ms  20 ms t3-0.los-angeles-cnss8.t3.ans.net [140.222.8.1
6   70 ms  70 ms  80 ms t3-0.new-york-cnss24.t3.ans.net [140.222.24.1]
7   80 ms  81 ms  80 ms t3-0.denver-cnss40.t3.ans.net [140.222.40.1]
8  100 ms  91 ms  90 ms t3-1.new-york-cnss32.t3.ans.net [140.222.32.2]
9   90 ms  90 ms  91 ms mf-0.new-york-cnss36.t3.ans.net [140.222.32.196]
10 100 ms  90 ms  91 ms t1-0.enss222.t3.ans.net [140.222.222.1]
11 140 ms  191 ms 100 ms ds.internic.net [198.49.45.10]
Trace complete.
Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft