IDONCLOUDHOSTING & NETWORK SERVICES

How to Diagnose Packet Loss with MTR on Linux Print

  • 0

MTR is a network diagnostic tool that combines the functionality of ping and traceroute. It helps identify packet loss, latency and routing problems between your Linux server and a remote destination.

This guide explains how to install MTR, run network tests and understand the results.

What Is MTR?

MTR continuously sends packets toward a destination and displays information about each network hop along the route.

It can help troubleshoot:

  • Packet loss
  • High latency
  • Unstable network connections
  • Routing problems
  • Connectivity issues between servers
  • Problems affecting specific network paths

MTR is particularly useful when troubleshooting VPS and dedicated server connectivity.

Install MTR on Ubuntu or Debian

Update your package list:

sudo apt update

Install MTR:

sudo apt install mtr-tiny -y

Verify the installation:

mtr --version

Run a Basic MTR Test

To test connectivity to a destination:

mtr 1.1.1.1

You can also test a hostname:

mtr example.com

MTR will continuously update the network statistics until you stop it.

Press:

Ctrl + C

to exit.

Generate an MTR Report

When contacting a hosting provider or network administrator, report mode is usually more useful.

Run:

mtr -rw -c 100 1.1.1.1

The options mean:

-r  Report mode
-w  Wide report
-c  Number of packets

This test sends 100 probes and then displays the results.

Test Using IPv4

To force IPv4:

mtr -4 -rw -c 100 example.com

Test Using IPv6

To test IPv6 connectivity:

mtr -6 -rw -c 100 example.com

This can be useful when IPv4 works correctly but IPv6 connectivity is experiencing problems.

Understanding MTR Results

A typical MTR report includes columns such as:

Loss%
Snt
Last
Avg
Best
Wrst
StDev

Loss%

Shows the percentage of probes that did not receive a response from that hop.

Snt

Shows the number of probes sent.

Last

Latency of the most recent response.

Avg

Average latency.

Best

Lowest measured latency.

Wrst

Highest measured latency.

StDev

Shows how much latency varies during the test.

Large variations can indicate an unstable network path.

Does Packet Loss on One Hop Mean There Is a Problem?

Not necessarily.

This is one of the most important things to understand when reading an MTR report.

Some routers limit or deprioritize ICMP responses.

For example, you might see packet loss on an intermediate hop while all following hops, including the destination, show no packet loss.

In that situation, the intermediate router is probably limiting responses rather than actually dropping forwarded traffic.

Packet loss becomes more significant when it begins at one hop and continues through the following hops to the final destination.

Example

Imagine an MTR report where:

Hop 3: 30% loss
Hop 4: 0% loss
Hop 5: 0% loss
Destination: 0% loss

This normally does not indicate 30% actual end-to-end packet loss.

However:

Hop 3: 20% loss
Hop 4: 20% loss
Hop 5: 21% loss
Destination: 20% loss

may indicate a genuine problem beginning around that part of the route.

The complete route should always be considered before drawing conclusions.

Test in Both Directions

Internet routing can be asymmetric.

The route from:

Server A → Server B

may be different from:

Server B → Server A

When possible, run MTR from both endpoints.

This provides much better information when diagnosing routing or packet loss problems.

Test for Longer Periods

A short test may not detect intermittent network problems.

For example:

mtr -rw -c 500 example.com

sends 500 probes.

Longer tests can help identify occasional packet loss or latency spikes.

Disable DNS Resolution

DNS lookups can make MTR output slower or harder to read.

Use:

mtr -n -rw -c 100 1.1.1.1

This displays IP addresses instead of resolving hostnames.

This format is often useful when sending network diagnostic reports to a provider.

TCP MTR

Some networks treat ICMP traffic differently from normal application traffic.

MTR can also perform TCP-based tests when supported:

sudo mtr --tcp -P 443 -rw -c 100 example.com

This tests the route using TCP port 443.

It can provide additional information when ICMP results appear unusual.

High Latency vs Packet Loss

High latency and packet loss are different problems.

Latency measures how long packets take to reach the destination.

Packet loss means packets fail to reach the destination or return successfully.

A connection can have high latency without packet loss.

Likewise, a low-latency connection can still experience packet loss.

What Can Cause Packet Loss?

Possible causes include:

  • Network congestion
  • Faulty network interfaces
  • Interface errors
  • Routing problems
  • Overloaded equipment
  • Traffic filtering
  • Virtualization limits
  • Upstream network issues
  • Problems at the destination
  • Physical network faults

An MTR report helps identify where a problem may be occurring, but it should be combined with other diagnostic information.

Check Your Local Interface

Check interface statistics:

ip -s link

Look for increasing:

errors
dropped
overruns

You can also inspect the interface with:

sudo ethtool eth0

Replace eth0 with your network interface.

Combine MTR with iperf3

MTR and iperf3 measure different aspects of network performance.

Use MTR to investigate:

  • Routing
  • Latency
  • Packet loss

Use iperf3 to investigate:

  • Network throughput
  • TCP performance
  • UDP performance
  • Available bandwidth between two endpoints

Using both tools provides a much clearer picture of server network performance.

Information to Send to Your Hosting Provider

When reporting a network problem, provide:

  • Source IP
  • Destination IP
  • Approximate time of the problem
  • MTR report
  • Reverse MTR when available
  • Description of the problem
  • Whether the issue is continuous or intermittent

A useful command is:

mtr -n -rw -c 100 DESTINATION-IP

Providing this information can significantly reduce troubleshooting time.

IDONCLOUD Network Infrastructure

IDONCLOUD provides VPS and Dedicated Server infrastructure with IPv4, IPv6 and high-bandwidth network connectivity.

Our Knowledge Base provides practical Linux and networking guides to help administrators configure, test and troubleshoot their infrastructure.

Visit idoncloud.com to explore IDONCLOUD infrastructure.

Related Guides

  • How to Test Network Speed on a Linux Server with iperf3
  • How to Use Traceroute on Linux
  • How to Check Network Interface Speed on Linux
  • How to Optimize Ubuntu for 10Gbps Networking
  • How to Configure a Static IP Address on Ubuntu with Netplan

Was this answer helpful?

« Back