Network guides
Network Troubleshooting: A Step-by-Step Diagnostic Method
Network failures are frustrating because they hide their cause. The same 'it does not work' symptom can come from a dead device, a wrong IP, a blocking firewall, a DNS failure, or a service that is simply down. Guessing rarely solves the problem. What works is a method: test one layer at a time, from the closest point outward.
Each tool answers a specific question. Ping tells you whether a device is reachable. Traceroute shows you the path your traffic takes. DNS lookups confirm that names resolve. Port checks reveal whether a service actually answers. Used in the right order, they turn a mystery into a clear diagnosis.
-
1970s
Ping and the first diagnostics
The ping utility and ICMP Echo are created, giving engineers a simple way to test whether a remote host is reachable.
-
1980s
Traceroute maps the path
Traceroute is developed, using time-to-live values to reveal every router along the route between two hosts.
-
1990s
DNS tools become standard
Lookup tools and name resolution diagnostics become routine, since a name that fails to resolve can break the whole stack.
-
Today
Modern diagnostics and port checks
Port scanners and service probes join the toolbox, letting engineers verify not just reachability but whether an application answers.
Start with the basics: ping the gateway
The first step is to check connectivity to the closest point: your default gateway, usually your router. A successful ping to the gateway tells you that your device has a working IP configuration and that your local network is alive. If even this fails, the problem is on your device, your cable or Wi-Fi, or your router. This is the ground truth for everything that follows.
Use the gateway's IP address, not a domain name, to avoid DNS complicating the test. If the gateway responds but the internet does not, the fault is further out. This single test immediately divides the problem into local versus remote.
Ping an external host and run a traceroute
Next, test beyond your network. Ping a public IP or a well-known host. If the gateway works but a public address does not, your router may be misconfigured, or your ISP's connection is the issue. If pinging a public IP works but pinging a domain fails, you have already isolated the problem to DNS. Pick a target that is reliable and geographically neutral, such as a major public DNS server.
When you cannot reach a remote host, a traceroute reveals the path. It shows each router between you and the destination, and where the packets stop. A stop near the start points to your network; a stop deep into the path points to an upstream provider or the target itself.
Check DNS resolution
DNS failures produce symptoms that look exactly like network failures: nothing loads. Before blaming the connection, confirm that names resolve. Use a lookup tool to query the domain and compare against a known-good resolver. If a public resolver returns the correct answer but your configured resolver does not, the fault is in your DNS settings or your router. This step is often skipped, which is why many 'network' issues are actually DNS issues.
Test both an IP and a name. If you can reach a service by IP but not by name, the issue is purely DNS. If both fail, the connection itself is at fault. This single comparison cleanly separates a name problem from a network problem.
Verify the service and its port
Finally, test the service itself. A host can be reachable and DNS can resolve, yet a specific port can be closed, blocked or silent. A port check attempts a connection to the port and reports whether a service answers. This distinguishes a healthy service from one that is down, firewalled, or listening on the wrong port. Choose the port that the application is documented to use, and confirm the listening address on the server.
Work from the inside out: test the service locally, then on the LAN, then from outside. Each layer you clear removes a suspect. Following this order - gateway, external reachability, DNS, then the port - isolates a problem methodically instead of by trial and error.
要点总结
Troubleshooting is a process of elimination. Test the gateway, then external reachability, then DNS, then the port, and each step narrows the search. Done in the right order, a network failure stops being a mystery.