You are on page 1of 7

Typing DOS commands on the Windows Command Line prompt is a most efficient and faster

way of doing things in Windows XP. Here's a run-down of the most useful DOS commands
available in Windows XP. Some of these DOS commands even do not have an visual alternative.

DOS Command-line tools must be run at the prompt of the Cmd.exe command interpreter. To
open Command Prompt, click Start, click Run, type cmd, and then click OK.

ipconfig - Windows IP configuration


Useful for troubleshooting your internet connection. Displays the current IP address of your
computer and the DNS server address. If you call your ISP for reporting a bad internet
connection, he will probably ask you to run ipconfig.

fc - Free BeyondCompare in XP
FC is an advanced DOS Command that compares two files and displays the differences between
them. Though the file comparison results are not as interactive as BeyondCompare or Altova
DiffDog, fc is still very useful. You can even set fc to resynchronize the files after finding a
mismatch.

type - open text files sans Notepad


Similar to Unix cat command, Type is my favorite DOS command for displaying the contents of
a text files without modifying them. When used in combination with more switch, type splits the
contents of lengthy text files into multiple pages. Avoid using the type command with binary
files or you'll hear alien PC beeps and see some greek characters on your PC.

ping - Say hello to another computer


Ping network command followed by the web-address or IP address tells you about the health of
the connection and whether the other party is responding to your handshake request. Ping tool
can also be used to convert the web address to a physical IP address.

tree - visual directory structure


You often need to take prints of your physical directory structure but XP has no simple "visual"
commands for printing directory contents. Here, try the Tree DOS command and redirect the
output to a text file.

tree > mydirectory.txt


print mydirectory.txt

attrib - make hidden files visible


Attrib lets you change attributes of System files and even hidden files. This is great for
troubleshooting Windows XP. Say your XP doesn't boot ever since you edited that startup
boot.ini file (Hidden), use attrib to remove the Hidden attibute and edit the file using EDIT dos
command.

assoc - which program will open that .xyz file


The assoc DOS command can be used to either isplay or even modify the file name extension
associations. The command assoc .htm will quickly tell you the name of your default web
browser (see picture)

move - more flexible than copy-paste


Say you got a lot of XLS and DOC files in you MyDocuments folder and want to move only
those XLS files that have their name ending with 2006. In XP Explorer, you have to manually
select each file and then cut-paste to another folder. However, the DOS move command make
things much simpler. Just type the following at the command prompt:
move *2006.xls c:\2006Reports\

find - advanced file search with filter


Find is the most powerful DOS command and even more useful than the Windows Desktop
Search tool or the Windows Find Wizard. The find command searches for a specific string of
text in a file or files. After searching the specified file or files, find displays any lines of text that
contain the specified string.

To search your hard disk to find and display the file names on drive C: that contain the string
"Google" use the pipe (|) to direct the results of a dir command to find as follows:
dir c:\ /s /b | find "Google"

Quick tip - Drag to avoid typing: When your command acts on a file or folder, you must type
the path to that folder after the command. You can save typing time by dragging the file or folder
from Windows Explorer into the command window.

To view help at the command-line, at the command prompt, type the following:
CommandName /?
Accessibility Controls = access.cpl
Add Hardware Wizard = hdwwiz.cpl
Add/Remove Programs = appwiz.cpl
Administrative Tools = control admintools
Automatic Updates = wuaucpl.cpl
Bluetooth Transfer Wizard = fsquirt
Calculator = calc
Certificate Manager = certmgr.msc
Character Map = charmap
Check Disk Utility = chkdsk
Clipboard Viewer = clipbrd
Command Prompt = cmd
Component Services = dcomcnfg
Computer Management = compmgmt.msc
Date and Time Properties = timedate.cpl
DDE Shares = ddeshare
Device Manager = devmgmt.msc
Direct X Control Panel (If Installed)* = directx.cpl
Direct X Troubleshooter = dxdiag
Disk Cleanup Utility = cleanmgr
Disk Defragment = dfrg.msc
Disk Management = diskmgmt.msc
Disk Partition Manager = diskpart
Display Properties = control desktop/desk.cpl
Dr. Watson System Troubleshooting Utility = drwtsn32
Driver Verifier Utility = verifier
Event Viewer = eventvwr.msc
File Signature Verification Tool = sigverif
Findfast = findfast.cpl
Folders Properties = control folders
Fonts = control fonts
Fonts Folder = fonts
Free Cell Card Game = freecell
Game Controllers = joy.cpl
Group Policy Editor (XP Prof) = gpedit.msc
Hearts Card Game = mshearts
Iexpress Wizard = iexpress
Indexing Service = ciadv.msc
Internet Properties = inetcpl.cpl
IP Configuration = ipconfig
Java Control Panel (If Installed) = jpicpl32.cpl
Java Application Cache Viewer (If Installed) = javaws
Keyboard Properties = control keyboard
Local Security Settings = secpol.msc
Local Users and Groups = lusrmgr.msc
Logs You Out Of Windows = logoff
Microsoft Chat = winchat
Minesweeper Game = winmine
Mouse Properties = control mouse
Mouse Properties = main.cpl
Network Connections = control netconnections
Network Connections = ncpa.cpl
Network Setup Wizard = netsetup.cpl
Notepad = notepad
Nview Desktop Manager (If Installed) = nvtuicpl.cpl
Object Packager = packager
ODBC Data Source Administrator = odbccp32.cpl
On Screen Keyboard = osk
Opens AC3 Filter (If Installed) = ac3filter.cpl
Password Properties = password.cpl
Performance Monitor = perfmon.msc
Performance Monitor = perfmon
Phone and Modem Options = telephon.cpl
Power Configuration = powercfg.cpl
Printers and Faxes = control printers
Printers Folder = printers
Private Character Editor = eudcedit
Quicktime (If Installed) = QuickTime.cpl
Regional Settings = intl.cpl
Registry Editor = regedit
Registry Editor = regedit32
Remote Desktop = mstsc
Removable Storage = ntmsmgr.msc
Removable Storage Operator Requests = ntmsoprq.msc
Resultant Set of Policy (XP Prof) = rsop.msc
Scanners and Cameras = sticpl.cpl
Scheduled Tasks = control schedtasks
Security Center = wscui.cpl
Services = services.msc
Shared Folders = fsmgmt.msc
Shuts Down Windows = shutdown
Sounds and Audio = mmsys.cpl
Spider Solitare Card Game = spider
SQL Client Configuration = cliconfg
System Configuration Editor = sysedit
System Configuration Utility = msconfig
System File Checker Utility = sfc
System Properties = sysdm.cpl
Task Manager = taskmgr
Telnet Client = telnet
User Account Management = nusrmgr.cpl
Utility Manager = utilman
Windows Firewall = firewall.cpl
Windows Magnifier = magnify
Windows Management Infrastructure = wmimgmt.msc
Windows System Security Tool = syskey
Windows Update Launches = wupdmgr
Windows XP Tour Wizard = tourstart
Wordpad = write
Some More

Ping

Ping tests a network connection.If successful, ping returns the ip address. Its a very useful and
popular command which we need to check whether our internet connection is working properly
or not.
Syntax
PING [options] destination_host
Example:
ping 192.168.0.1 -t
Ping Options

-w timeout (Timeout in milliseconds to wait for each reply)


-i TTL (Time To Live)
-v TOS (Type Of Service)
-a (Resolve addresses to hostnames)
-n count (Number of echo requests to send)
-t (Ping the destination host until interrupted)
-l size (Send buffer size)
-f (Set Don't Fragment flag in packet)
-r count (Record route for count hops)
-s count (Timestamp for count hops)
-j host_list (Loose source route along host_list)
-k host_list (Strict source route along host_list)
destination_host (The name of the remote host)

DIR

Display a list of files and subfolders.


Syntax
DIR [pathname(s)] [display_format] [file_attributes] [sorted] [time] [options]

[display_format]
/P Pause after each screen of data.
/W Wide List format, sorted horizontally.
/D Wide List format, sorted by vertical column.
[options]
/S include all subfolders.
/R Display alternate data streams. (Vista only)
/B Bare format (no heading, file sizes or summary).
/L use Lowercase.
/Q Display the owner of the file.

CLS

Simply typing cls and pressing enter will clear the dos screen.

EDIT

Syntax
EDIT [d:][path]filename [/B][/G][/H][/NOHI]

Starts the MS-DOS editor, a text editor used to create and edit ASCII text files.

HELP

Syntax
HELP [command] [/B][/G][/H][/NOHI]

Displays information about a DOS command.

MEM

Syntax
MEM [/program|/debug|/classify|/free|/module(name)] [/page]

Displays amount of installed and available memory, including extended, expanded, and upper
memory.
chkdsk

Syntax
CHKDSK [drive:][[path]filename] [/F] [/V] [/R] [/L[:size]]

Example:
CHKDSK C: /F

[drive:] The drive to check.


filename File(s) to check for fragmentation (FAT only).

/F Automatically Fix file system errors on the disk.


/X Fix file system errors on the disk
/R Scan for and attempt Recovery of bad sectors.
/V Display the full path and name of every file on the disk.
/C Skip directory corruption checks

Read more: http://www.techmynd.com/most-wanted-windows-dos-


commands/#ixzz17PYGnXOl

You might also like