The Network Debugging Playbook
Debug Bottom-Up: The OSI Layer Approach
Senior engineers debug network issues by working bottom-up through the OSI model. Start at Layer 3 (IP/Network) and work your way up to Layer 7 (Application).
L3 Network: ping → Is the host reachable?
L3 Routing: traceroute → Where are packets going?
L4 Transport: ss -tuln / nc -zv → Is the port open?
L7 DNS: dig → Does the hostname resolve?
L7 Application: curl -I → Does the API respond?
Logs: grep → What does the application say?
🔍 Diagnostics
Test connectivity layer by layer.
ping -c 4 host— ICMP reachabilitytraceroute host— Network pathdig hostname— DNS resolutionnc -zv host port— Port testcurl -I url— HTTP health check
📊 Inspection
Examine local network state.
ip addr show— Interface IPsip route— Routing tabless -tuln— Listening portscat /etc/resolv.conf— DNS configgrep error logfile— Log filtering
Quick Reference: HTTP Status Codes
200— OK (everything is fine)301/302— Redirect (checkLocationheader)403— Forbidden (permission/auth issue)404— Not Found (wrong URL or endpoint not deployed)502— Bad Gateway (upstream server is down)503— Service Unavailable (server overloaded)504— Gateway Timeout (upstream server too slow)




