When to use traceroute
Use traceroute to inspect the sequence of responding routers toward a destination. Probe types and filtering affect visibility, so an incomplete trace is diagnostic evidence rather than a complete map of every forwarding device.
Syntax
traceroute [PARAMETERS] NODESquare brackets mark optional arguments; an ellipsis means repetition. Replace example file names, user names and server addresses with your own values.
Common options and arguments
Usage examples
Follow route
traceroute -n example.comNumeric addresses are shown without reverse-DNS lookup delays.
Limit route to ten hops
traceroute -n -m 10 example.comThe maximum number of hops is bounded for a short investigation.
Trace the HTTPS route using TCP probes
traceroute -T -p 443 example.comTCP probes target port 443, which can produce different results from default probes.
Notes and limitations
- Asterisks indicate no response to the test, and not necessarily a break in the route.
- The result depends on the sampling protocol, balancing and ICMP rules; compare it with the availability of the target service.
Common questions and troubleshooting
Why do some hops show only asterisks?
Those routers may not answer the probe type or may rate-limit replies. Later responding hops can still demonstrate that traffic passed onward.
Does traceroute always follow the application's path?
Not exactly. Load balancing and protocol-based routing can change paths. Use an appropriate probe type and correlate with application tests.
Further help
Options vary by version and distribution. Check the installed documentation with this command: man traceroute.