Diagnose network problems with mtr
Run <code>mtr -rwbzc 100</code> from your computer to the server and from the server back to your computer, over IPv4 and IPv6. Loss that appears at one middle hop but not at the final hop is usually harmless rate limiting; loss that starts at a hop and continues to the end points to a real problem there. Send both reports, the times and your source IP in a ticket.
Recovery and troubleshooting guide, updated 2026-12-03
Which tool answers which question?
Three classic tools cover nearly every case:
- ping: is the host reachable, how long is the round trip, and are packets lost? It tests the full path only.
- traceroute: which routers sit on the path? One snapshot, sensitive to short glitches.
- mtr: traceroute and ping combined, run many times, with loss and latency statistics per hop. This is the one support wants to see.
Install mtr with apt install mtr-tiny on Ubuntu and Debian servers (or mtr for the full package), dnf install mtr on Rocky, Alma and Fedora, Homebrew on macOS, and WinMTR on Windows. On the server you also need traceroute and iputils-tracepath for some tests below.
How do you run mtr in report mode?
Interactive mtr is nice to watch but hard to share. Report mode runs a fixed number of cycles and prints a table:
mtr -rwbzc 100 203.0.113.10-r is report mode, -w wide output with full host names, -b shows names and IP addresses, -z adds the network (AS) number of each hop, and -c 100 sends 100 probes per hop, which takes under two minutes. Fewer probes give noisy numbers.
If ICMP is filtered somewhere, test the port your service uses: mtr -rwbzc 100 -T -P 443 203.0.113.10 sends TCP SYN probes to port 443. For UDP services such as WireGuard, -u -P 51820 does the same with UDP.
How do you read the loss column?
A typical report looks like this:
HOST Loss% Snt Last Avg Best Wrst StDev
1. 192.168.1.1 0.0% 100 0.6 0.7 0.5 1.4 0.1
2. 198.51.100.1 0.0% 100 7.9 8.3 7.1 14.0 1.0
3. 198.51.100.65 42.0% 100 9.1 9.4 8.8 11.2 0.4
4. 198.51.100.130 0.0% 100 18.2 18.5 17.9 21.0 0.5
5. 203.0.113.10 0.0% 100 18.9 19.1 18.4 22.3 0.6Hop 3 shows 42 percent loss, but hops 4 and 5 show none. Routers handle traffic for others in hardware and answer probes aimed at themselves in software, with a strict rate limit. A loss figure that does not carry on to later hops is that rate limit, not a problem. The final hop is the one that counts.
Real trouble looks different: loss starts at one hop and every hop after it shows similar or higher loss, including the destination. The first hop with lasting loss is where to look. The same logic applies to latency: a single slow middle hop is noise, while a jump that persists to the end shows a long or congested link.
Why test in both directions?
Internet routing is often asymmetric: packets from you to the server take one path, the replies take another. An mtr from your side shows only the forward path, but the loss may sit on the return path and still show up in your report, which is confusing. Run mtr from the server back to your own public IP as well:
curl -4 ifconfig.me # on your computer, shows your public IPv4
mtr -rwbzc 100 198.51.100.20 # on the server, towards that IPSome home routers do not answer probes; in that case aim at the last hop that answers in your forward report, which is usually your provider's gateway.
Should you test IPv4 and IPv6 separately?
Yes. The two families often use different routes and different peering, and many problems affect only one. Force each one explicitly:
mtr -4 -rwbzc 100 203.0.113.10
mtr -6 -rwbzc 100 2001:db8:1234:5678::1
ping -4 -c 20 example.com
ping -6 -c 20 example.comIf a site loads slowly for some visitors only, check whether those visitors use IPv6 and whether your server answers on its IPv6 address at all: curl -6 -I https://example.com from outside. A missing AAAA record, or a firewall that allows IPv4 but forgets IPv6, are common causes. The guide on firewall setup covers both families.
What if the problem is on the server itself?
Before blaming the network, rule out the machine:
- Is the CPU pegged?
top. A server at 100 percent answers pings slowly. - Is the service up?
ss -tulpnandsystemctl status nginx. - Is the firewall dropping?
nft list rulesetand counters on drop rules. - Is the interface healthy?
ip -s linkshows errors and drops per interface. - Is outgoing traffic saturating the link?
iftopornloadshow live usage per connection.
Large transfers that hang while small requests work point to an MTU issue; see MTU and MSS.
What should a network ticket include?
A ticket that support can act on in one go contains:
- The server name and its IPv4 or IPv6 address.
- Your source IP (from
curl -4 ifconfig.me) and rough location. - The mtr report from your side and from the server back to you, as plain text, with 100 or more cycles.
- Whether IPv4, IPv6 or both are affected, and which ports or protocols.
- The exact times with time zone when the problem appeared, and whether it is constant or comes and goes.
Paste the reports inside the ticket rather than as screenshots, so hop addresses can be copied. If the problem is intermittent, run mtr while it happens and again when it is fine; the difference between the two is the most useful data you can send.
How do you watch a recurring problem over time?
For issues that come at certain hours, log mtr from cron every 10 minutes:
*/10 * * * * root /usr/bin/mtr -rwbzc 60 198.51.100.20 >> /var/log/mtr-home.log 2>&1Put that line in /etc/cron.d/mtr-watch, and add a date call or timestamped wrapper so each report has a time. Remove it when you are done; a permanent probe adds load and log volume for no reason. For long-term latency graphs, the tools in monitoring basics fit better.
Questions about this guide
Is loss at one middle hop a problem?
Usually not. If the following hops and the destination show no loss, that router simply limits replies to probes.
Why does traceroute show stars?
Some routers do not reply to probes at all. Stars in the middle are normal as long as the path continues to the destination.
Should I use ICMP or TCP mode?
Start with ICMP. If results look odd or ICMP is filtered, use -T -P 443 to follow the path your real traffic takes.
How many cycles are enough?
At least 100. Short runs of 10 probes make 10 percent loss out of a single dropped packet.
Does DDoS filtering affect mtr results?
Normal tests are unaffected. During an active attack on your IP, filtering may change what reaches the server; mention attack times in the ticket.
Can I test from several places without other servers?
Public looking glass and probe services run traceroutes from many networks. Note the times you used them in your ticket.