windows Commands

Networking

ipconfig

Displays all current TCP/IP network configuration values and refreshes Dynamic Host Configuration Protocol (DHCP) and Domain Name System (DNS) settings.

ipconfig

Examples:
Display basic network configuration
ipconfig
Display detailed network configuration
ipconfig /all
Flush the DNS cache
ipconfig /flushdns
netstat

Displays active TCP connections, ports on which the computer is listening, Ethernet statistics, the IP routing table, IPv4 statistics, and IPv6 statistics.

netstat

Examples:
Show all active connections and listening ports
netstat -a
Show connections and the executables that created them
netstat -b
Show connections with their process IDs (PIDs)
netstat -ano
ping

Verifies IP-level connectivity to another TCP/IP computer by sending Internet Control Message Protocol (ICMP) echo Request messages.

ping

Examples:
Ping a host
ping google.com
Ping a host continuously
ping -t 8.8.8.8
Ping a host 10 times
ping -n 10 localhost
tracert

Determines the path taken to a destination by sending Internet Control Message Protocol (ICMP) echo Request messages with varying Time-to-Live (TTL) values.

tracert

Examples:
Trace the route to a host
tracert google.com
Trace the route without resolving IP addresses to names
tracert -d 8.8.8.8

Process Management

tasklist

Displays a list of currently running processes on either a local or remote machine.

tasklist

Examples:
List all running processes
tasklist
List processes and the services they host
tasklist /svc
Find the process with a specific PID
tasklist /fi "pid eq 1234"
taskkill

Ends one or more tasks or processes.

taskkill

Examples:
Kill a process by its image name
taskkill /im notepad.exe
Forcefully kill a process by its PID
taskkill /pid 1234 /f

System Management

sfc

System File Checker. Scans and verifies the integrity of all protected system files and replaces incorrect versions with correct Microsoft versions.

sfc

Examples:
Scan system files and repair them
sfc /scannow
Verify the integrity of system files without repairing
sfc /verifyonly
chkdsk

Checks a disk for errors and repairs them.

chkdsk

Examples:
Check the C: drive for errors
chkdsk C:
Check and fix errors on the D: drive
chkdsk D: /f
Check for errors, fix them, and locate bad sectors on drive E:
chkdsk E: /r
schtasks

Schedules commands and scripts to run on a computer at a specified time or event.

schtasks

Examples:
List all scheduled tasks
schtasks /query
Create a new task to run notepad daily at noon
schtasks /create /sc daily /tn "My Task" /tr "notepad.exe" /st 12:00
Run an existing task
schtasks /run /tn "My Task"
systeminfo

Displays detailed configuration information about a computer and its operating system.

systeminfo

Examples:
Display system information
systeminfo
Display system information in a list format
systeminfo /fo list