Must-Know Windows Command

Press Windows button + s to lunch the search bar and type cmd to lunch the command prompt and lunch it as administrator.

  1. ipconfig – To find out what IP you are using but not all details, where is your MAC address? Where is your DNS?
  2. ipconfig /all – It will show you all your IP information.
  3. ipconfig /all | findstr DNS – To filter the DNS. You can use find string (findstr) on any command.
  4. ipconfig /release -Maybe your computer needs a new IP address, use this command to let go of the old IP.
  5. ipconfig /renew – To get a fresh new IP address. be advised that it will refresh all your interfaces.
  6. ipconfig /renew “Wi-Fi” – If you dont wanna do that then simply specify the interface just after your command.
  7. ipconfig /displaydns – If you are having a problem with your DNS, use this command to display basically all the website it knows about and their IP addresses.
  8. ipconfig /displaydns | clip – To copy all the information to the clipboard. (very useful command).
  9. ipconfig /flushdns – This will delete your DNS resolver cache on your computer, removing old stale DNS.
  10. nslookup – To troubleshoot DNS more use this command, “nslookup vinrade.com” it will tell you what a domains IP address, DNS server.
    • C:\WINDOWS\system32>nslookup vinrade.com
    • Server: ns1.prima.net.id
    • Address: 202.57.0.8
    • Non-authoritative answer:
    • Name: vinrade.com
    • Address: 64.37.52.172
  11. To find out more information on DNS use the following commands.
    • nslookup vinrade.com 8.8.8.8 – youll get a second opinion from google.
      • C:\WINDOWS\system32>nslookup vinrade.com 8.8.8.8
      • Server: dns.google
      • Address: 8.8.8.8
      • Non-authoritative answer:
      • Name: vinrade.com
      • Address: 64.37.52.172
  12. Other commands you can use for DNS are:
    • nslookup -type=mx
    • nslookup -type=txt
    • nslookup -type=ptr
  13. cls – To clear the screen
  14. getmac /v – To get your Mac address
  15. powercfg /energy – This command will see if you have any energy or power issues with your computer.
    • C:\WINDOWS\system32>powercfg /energy
    • Enabling tracing for 60 seconds…
    • Observing system behavior…
    • Analyzing trace data…
    • Analysis complete.
    • Energy efficiency problems were found.
    • 4 Errors
    • 9 Warnings
    • 32 Informational
    • See C:\WINDOWS\system32\energy-report.html for more details.
  16. powercfg /batteryreport – It will tell you about your battery life status.
    • C:\WINDOWS\system32>powercfg /batteryreport
    • Battery life report saved to file path C:\WINDOWS\system32\battery-report.html.
  17. assoc – It will tell you which file is associated with what program.
  18. if your computer is getting slow try these commands.
    • chkdsk /d (d= your drive letter). – It will check your HDD and see if there is any error.
    • chkdsk /r – To check the physical sector issues and fix ’em.
    • sfc /scannow – system file checker, checking DLL files and fix ’em.
  19. DISM /Online /Cleanup-Image /CheckHealth – Deployment Image Servicing and Management, its a command line tool that will actually fix your system image.
    • DISM /Online /Cleanup-Image /ScanHealth – To find more issues.
    • DISM /Online /Cleanup-Image /RestoreHealth – To fix the issues.
  20. netsh wlan show wlanreport – This will give you a fancy report about your wireless.
  21. netsh interface show interface. – Showing you your interfaces.
  22. netsh interface ip show address | findstr “IP Address” – To find IP addresses.
  23. netsh interface ip show dnsservers.
  24. netsh advfirewall set allprofiles state off – To shutdown windows bitdefender firewall with one command.
  25. netsh advfirewall set allprofiles state on – To turn it on.
  26. ping – To check network connectivity.
  27. ping -t – Continues ping.
  28. tracert – Trace Route, trace the path to your favorite website along each router to get there.
  29. tracert -d – Do not resolve domain names a little bit faster.
  30. netstat – Tells you what’s connected to you and what you’re connecting to.
  31. netstat -af – Tells you what ports you have open
  32. netstat -o – Show you all the process ID for all your connections, so if there is anything dangerous connected to you you can drop that PID.
  33. netstat -e -t – Gives you sent and receive statistics every 5 seconds.
  34. route print – Show the routes your computer will take to get to certain nerworks.
  35. route add – To add a route to our computer, to customize the way our computer reaches certain networks.
  36. route delete – to delete the route.
  37. shutdown /r /fw /f /t 0 – to restart your computer and go straight to the system BIOS without pressing any function key.

About VinRade

Cloud Tech Enthusiast, Microsoft 365 AD Administrator, Virtual Machine Lover, System Administrator, Network and Security Integration, Web Designing and Developing, ICT and Robotics Teacher, DJ, Photographer, and Drag Racer.
This entry was posted in InfoTech and tagged . Bookmark the permalink.