Network diagnostics (traceroute/ping.)

     mtr [-hvrctglspni46] [--help] [--version] [--report] [--report-cycles COUNT]
        [--curses] [--split] [--raw] [--no-dns] [--gtk] [--address IP.ADD.RE.SS]
           [--interval SECONDS] [--psize BYTES | -s BYTES] HOSTNAME [PACKETSIZE]

   -c COUNT
   --report-cycles COUNT
       Use this option to set the number of pings sent to determine both the machines on the network and
       the reliability of those machines. Each cycle lasts one second.

   -s BYTES
   --psize BYTES
       These options or a trailing PACKETSIZE on the commandline set the packet size (in Bytes
       inclusive IP and ICMP headers) used for probing.
       If set to a negative number, every iteration will use a different, random packetsize up to that number. 

       Force mtr to use the GTK+ based X11 window interface (if available). GTK+ must have
       been available on the system when mtr was built for this to work. See GTK+

       Set mtr to spit out a format that is suitable for a split-user interface.

       Print a summary of command line argument options. 

       Tell mtr to use the raw output format. This format is better suited for archival of the
       measurement results. It could be parsed to be presented into any of the other display methods. 

   -a IP.ADD.RE.SS
   --address IP.ADD.RE.SS
       Bind outgoing packets' socket to a specific interface, so that any packet will be sent
       through this interface. NOTE that this option doesn't apply to DNS requests (which
       could be and could not be what you want). 

   --interval SECONDS
       Use this option to specify the positive number of seconds between ICMP ECHO requests.
       The default value for this parameter is one second. 

       Force mtr to use the curses based terminal interface (if available). 

       Force mtr to display numeric IP numbers and not try to resolve the host names. 

       Put mtr into report mode. When in this mode, mtr will run for the number of cycles specified by
       the -c option, and then print statistics and exit. 
       This mode is useful for generating statistics about network quality.
       Note that each running instance of mtr generates a significant amount of network traffic.
       Using mtr to measure the quality of your network can result in decreased network performance.

       Print the installed version of mtr.

   -4  Use IPv4 only. 

   -6  Use IPv6 only.

mtr combines the functionality of the traceroute and ping programs in a single network diagnostic tool.

As mtr starts, it investigates the network connection between the host mtr runs on and HOSTNAME. by sending packets with purposly low TTLs. It continues to send packets with low TTL, noting the response time of the intervening routers. This allows mtr to print the response percentage and response times of the internet route to HOSTNAME. A sudden increase in packetloss or response time is often an indication of a bad (or overloaded) link.

Some modern routers give a lower priority to ICMP ECHO packets than to other network traffic. Consequently, the reliability of these routers reported by mtr will be significantly lower than the actual reliability of these routers.


$ mtr
$ mtr

MTR (Matt's traceroute) was written by Matt Kimball, with contributions by many people.

“I don’t measure a man’s success by how high he climbs but how high he bounces when he hits bottom” ~ General George S. Patton

Related linux commands

The mtr web page - download the latest version.
ping - Test a network connection.
traceroute - Trace Route to Host.
Equivalent Windows command: PATHPING - Trace route and provide network latency and packet loss for each router and link in the path.

Copyright © 1999-2023
Some rights reserved