Listen to this Post
Here are 5 basic but powerful networking commands to help you troubleshoot and analyze network connectivity:
1. netstat – View Network Connections
Displays active connections, listening ports, and routing tables.
Commands:
netstat -a Show all connections and listening ports netstat -tuln List all listening TCP/UDP ports netstat -r Display the routing table
- tracert (Windows) / traceroute (Linux) – Trace the Route to a Host
Helps identify the path taken to reach a destination and locate network delays.
Windows:
tracert google.com
Linux:
traceroute google.com
- ipconfig (Windows) / ifconfig (Linux) – Display IP Configuration
Shows network interface details, including IP, subnet, and gateway.
Windows:
ipconfig /all
Linux:
ifconfig (Deprecated in some distros, use ip instead) ip a Modern alternative
4. ping – Check Connectivity
Tests reachability and latency to a host.
Basic Usage:
ping google.com
Advanced (Linux):
ping -c 4 google.com Send only 4 packets ping -i 2 google.com Set interval between packets (seconds)
5. nslookup – Query DNS Records
Resolves domain names to IP addresses and checks DNS records.
Usage:
nslookup google.com
Linux Alternative:
dig google.com More detailed DNS query
You Should Know:
- Combining Commands for Troubleshooting:
ping google.com && nslookup google.com
- Checking Open Ports (Linux):
ss -tuln Modern replacement for netstat
- Flush DNS Cache (Windows):
ipconfig /flushdns
- Persistent Network Stats (Linux):
watch -n 1 netstat -tuln Refresh every second
What Undercode Say:
Mastering these basic networking commands is essential for IT professionals. Whether diagnosing connectivity issues, analyzing routes, or verifying DNS resolutions, these tools form the foundation of network troubleshooting. Practice them in real-world scenarios to enhance your efficiency.
Expected Output:
$ ping google.com PING google.com (142.250.190.46) 56(84) bytes of data. 64 bytes from fra16s48-in-f14.1e100.net (142.250.190.46): icmp_seq=1 ttl=117 time=12.3 ms $ nslookup google.com Server: 8.8.8.8 Address: 8.8.8.853 Non-authoritative answer: Name: google.com Address: 142.250.190.46
Keep experimenting with these commands to deepen your networking expertise! 🚀
References:
Reported By: Shamseer Siddiqui – Hackers Feeds
Extra Hub: Undercode MoN
Basic Verification: Pass ✅



