6.1 Windows CMD Commands
6.1 Windows CMD Commands
Introduction
• Command Prompt,
commonly known as
cmd.exe or cmd, is the
default command-line
interpreter for the OS/2,
eComStation, ArcaOS,
Microsoft Windows, and
ReactOS operating systems.
Clear Screen
• Type “cls”
• Clears the text
Interrupts Running Command
• Type “Ctrl+C”
• Stops running commands
• For example
– Type “date”
– Then Ctrl-C
Encodes Deleted Files
• Type “cipher”
• Marks the files as no longer accessible
• Cipher command writes the directory with random
data
Lists Installed Drivers
• Type “driverquery”
• To check all the drivers
OR
• To get more information extend as “driverquery –v”
IP Address Information
• Type “ipconfig”
• To check the IP address and other required information
Checking Open Ports Information
• Type “netstat -an”
• List of open ports
• Helps to troubleshoot devices connected to your PC & to
locate malicious information
Processor & System Information
• Type “systeminfo”
• List of processor information
Checking Server Accessibility
• Type “ping <ip/domain>”
• Sends packets to the mentioned address
• If packets arrive & return it means device is working properly
or server is accessible
Traceroute Information
• Type “traceroute <ip/domain>”
• Shows routing time
Configure Power Options
• Type “powercfg”
• Managing and tracking computer energy usage
• Example
• powercfg /hibernate <on/off> to activate/deactivate mode
• Powercfg –a to check available power states to your pc
• Powercfg /energy will build detail consumption report
Shutdown
• Type “shutdown”
• This will shutdown your PC in various ways
• Shutdown /h (will enter your PC in hibernate mode)
• Shutdown /r (will restart your pc)
• shutdown /r /o (will restart and launch the advanced startup
menu)
Repairing Files
• Type “sfc /scannow”
• Will scan and repair windows system files
• If sfc finds any corrupt or missing files, it will automatically
replace and copy the updated files
Checking Current Tasks
• Type “tasklist”
• Will display the current running tasks within the system
• tasklist –svc (will show services related to each task)
• tasklist –v (to obtain more details on each task)
For More Knowledge