forked from traviscross/mtr
-
Notifications
You must be signed in to change notification settings - Fork 3
/
mtr.8
389 lines (384 loc) · 8.52 KB
/
mtr.8
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
.TH MTR 8 "May 5, 2015" "mtr" "mtr"
.SH NAME
mtr \- a network diagnostic tool
.SH SYNOPSIS
.B mtr
[\c
.BR \-4 |\c
.B \-6\c
]
[\c
.BI \-F \ FILENAME\c
]
[\c
.B \-\-report\c
]
[\c
.B \-\-report-wide\c
]
[\c
.B \-\-xml\c
]
[\c
.B \-\-gtk\c
]
[\c
.B \-\-curses\c
]
[\c
.BI \--displaymode \ MODE\c
]
[\c
.B \-\-raw\c
]
[\c
.B \-\-csv\c
]
[\c
.B \-\-split\c
]
[\c
.B \-\-no-dns\c
]
[\c
.B \-\-no-geolocation\c
]
[\c
.B \-\-show-ips\c
]
[\c
.BI \-o \ FIELDS\c
]
[\c
.BI \-y \ IPINFO\c
]
[\c
.B \-\-aslookup\c
]
[\c
.BI \-i \ INTERVAL\c
]
[\c
.BI \-c \ COUNT\c
]
[\c
.BI \-s \ PACKETSIZE\c
]
[\c
.BI \-B \ BITPATTERN\c
]
[\c
.BI \-Q \ TOS\c
]
[\c
.B \-\-mpls\c
]
[\c
.BI \-a \ ADDRESS\c
]
[\c
.BI \-f \ FIRST\-TTL\c
]
[\c
.BI \-m \ MAX\-TTL\c
]
[\c
.B \-\-udp\c
]
[\c
.B \-\-tcp\c
]
[\c
.BI \-P \ PORT\c
]
[\c
.BI \-Z \ TIMEOUT\c
]
[\c
.BI \-M \ MARK\c
]
.I HOSTNAME
.SH DESCRIPTION
.B mtr
combines the functionality of the
.B traceroute
and
.B ping
programs in a single network diagnostic tool.
.PP
As
.B mtr
starts, it investigates the network connection between the host
.B mtr
runs on and
.BR HOSTNAME
by sending packets with purposely low TTLs. It continues to send
packets with low TTL, noting the response time of the intervening
routers. This allows
.B mtr
to print the response percentage and response times of the internet
route to
.BR HOSTNAME .
A sudden increase in packet loss or response time is often an indication
of a bad (or simply overloaded) link.
.PP
The results are usually reported as round-trip-response times in miliseconds
and the percentage of packetloss.
.SH OPTIONS
.TP
.B \-h\fR, \fB\-\-help
Print the summary of command line argument options.
.TP
.B \-v\fR, \fB\-\-version
Print the installed version of mtr.
.TP
.B \-4
Use IPv4 only.
.TP
.B \-6
Use IPv6 only. (IPV4 may be used for DNS lookups).
.TP
.B \-F \fIFILENAME\fR, \fB\-\-filename \fIFILENAME
MISSING
.TP
.B \-r\fR, \fB\-\-report
This option puts
.B mtr
into
.B report
mode. When in this mode,
.B mtr
will run for the number of cycles specified by the
.B \-c
option, and then print statistics and exit.
.TP
\c
This mode is useful for generating statistics about network quality.
Note that each running instance of
.B mtr
generates a significant amount of network traffic. Using
.B mtr
to measure the quality of your network may result in decreased
network performance.
.TP
.B \-w\fR, \fB\-\-report\-wide
This option puts
.B mtr
into
.B wide report
mode. When in this mode,
.B mtr
will not cut hostnames in the report.
.TP
.B \-x\fR, \fB\-\-xml
Use this option to tell
.B mtr
to use the xml output format. This format is better suited for
automated processing of the measurement results.
.TP
.B \-t\fR, \fB\-\-curses
Use this option to force
.B mtr
to use the curses based terminal
interface (if available).
.TP
.B -\-displaymode \fIMODE
Use this option to select the initial display mode: 0 (default)
selects statistics, 1 selects the stripchart without latency
information, and 2 selects the stripchart with latency
information.
.TP
.B \-g\fR, \fB\-\-gtk
Use this option to force
.B mtr
to use the GTK+ based X11 window interface (if available).
GTK+ must have been available on the system when
.B mtr
was built for this to work. See the GTK+ web page at
.B http://www.gtk.org/
for more information about GTK+.
.TP
.B \-l\fR, \fB\-\-raw
Use this option to tell
.B 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.
.TP
.B \-C\fR, \fB\-\-csv
MISSING
.TP
.B \-p\fR, \fB\-\-split
Use this option to set
.B mtr
to spit out a format that is suitable for a split-user interface.
.TP
.B \-n\fR, \fB\-\-no\-dns
Use this option to force
.B mtr
to display numeric IP numbers and not try to resolve the
host names.
.TP
.B \-N\fR, \fB\-\-no\-geolocation
Use this option to force
.B mtr not to use the geoip location. This might speed up initialization,
since a persistent connection to the geolocation needs to be established
when mtr starts up otherwise. When geolocation is enabled, you can simply press
.B c
to toggle the location of the hosts (only available with curses for now).
.TP
.B \-b\fR, \fB\-\-show\-ips
Use this option to tell
.B mtr
to display both the host names and numeric IP numbers. In split mode
this adds an extra field to the output. In report mode, there is usually
too little space to add the IPs, and they will be truncated. Use the
wide report (-w) mode to see the IPs in report mode.
.TP
.B \-o \fIFIELDS\fR, \fB\-\-order \fIFIELDS
Use this option to specify which fields to display and in which order.
You may use one or more space characters to separate fields.
.br
Available fields:
.TS
center allbox tab(%);
ll.
L%Loss ratio
D%Dropped packets
R%Received packets
S%Sent Packets
N%Newest RTT(ms)
B%Min/Best RTT(ms)
A%Average RTT(ms)
W%Max/Worst RTT(ms)
V%Standard Deviation
G%Geometric Mean
J%Current Jitter
M%Jitter Mean/Avg.
X%Worst Jitter
I%Interarrival Jitter
.TE
.br
Example:
-o "LSD NBAW X"
.TP
.B \-y \fIn\fR, \fB\-\-ipinfo \fIn
MISSING
.TP
.B \-z\fR, \fB\-\-aslookup
MISSING
.TP
.B \-i \fISECONDS\fR, \fB\-\-interval \fISECONDS
Use this option to specify the positive number of seconds between ICMP
ECHO requests. The default value for this parameter is one second. The
root user may choose values between zero and one.
.TP
.B \-c \fICOUNT\fR, \fB\-\-report\-cycles \fICOUNT
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.
.TP
.B \-s \fIPACKETSIZE\fR, \fB\-\-psize \fIPACKETSIZE
This option sets the packet size used for probing. It is in bytes,
inclusive IP and ICMP headers.
If set to a negative number, every iteration will use a different, random
packet size up to that number.
.TP
.B \-B \fINUM\fR, \fB\-\-bitpattern \fINUM
Specifies bit pattern to use in payload. Should be within range 0 - 255. If
.I NUM
is greater than 255, a random pattern is used.
.TP
.B \-Q \fINUM\fR, \fB\-\-tos \fINUM
Specifies value for type of service field in IP header. Should be within range 0
- 255.
.TP
.B \-e\fR, \fB\-\-mpls
Use this option to tell
.B mtr
to display information from ICMP extensions for MPLS (RFC 4950)
that are encoded in the response packets.
.TP
.B \-a \fIADDRESS\fR, \fB\-\-address \fIADDRESS
Use this option to bind the outgoing socket to
.IR ADDRESS ,
so that all packets will be sent with
.I ADDRESS
as source address. NOTE that this option doesn't apply to DNS requests
(which could be and could not be what you want).
.TP
.B \-f \fINUM\fR, \fB\-\-first-ttl \fINUM
Specifies with what TTL to start. Defaults to 1.
.TP
.B \-m \fINUM\fR, \fB\-\-max-ttl \fINUM
Specifies the maximum number of hops (max time-to-live value) traceroute will
probe. Default is 30.
.TP
.B \-u\fR, \fB\-\-udp
Use UDP datagrams instead of ICMP ECHO.
.TP
.B \-T\fR, \fB\-\-tcp
Use TCP SYN packets instead of ICMP ECHO.
.I PACKETSIZE
is ignored, since SYN packets can not contain data.
.TP
.B \-P \fIPORT\fR, \fB\-\-port \fIPORT
The target port number for TCP traces.
.TP
.B \-Z \fISECONDS\fR, \fB\-\-timeout \fISECONDS
The number of seconds to keep the TCP socket open before giving up on
the connection. This will only affect the final hop. Using large values
for this, especially combined with a short interval, will use up a lot
of file descriptors.
.TP
.B \-M \fIMARK\fR, \fB\-\-mark \fIMARK
MISSING
.SH ENVIRONMENT
.B mtr
recognizes a few environment variables.
.TP
.B MTR_OPTIONS
This environment variable allows to specify options, as if they were
passed on the command line. It is parsed before reading the actual
command line options, so that options specified in
.B MTR_OPTIONS
are overriden by command-line options.
Example:
.BI MTR_OPTIONS ="-4\ -c\ 1"
.B mtr
.I \-6\ localhost
would send one probe (because of
.I -c\ 1\c
) towards
.B ::1
(because of
.IR -6 ,
which overrides the
.I -4
passed in
.B MTR_OPTIONS\c
).
.TP
.B DISPLAY
Used for the GTK+ frontend.
.SH BUGS
Some modern routers give a lower priority to ICMP ECHO packets than
to other network traffic. Consequently, the reliability of these
routers reported by
.B mtr
will be significantly lower than the actual reliability of
these routers.
.SH CONTACT INFORMATION
.PP
For the latest version, see the mtr web page at
.BR http://www.bitwizard.nl/mtr/ .
.PP
The mtr mailinglist was little used and is no longer active.
.PP
For patches, bug reports, or feature requests, please open an issue on
GitHub at:
.BR https://github.com/traviscross/mtr .
.SH "SEE ALSO"
traceroute(8),
ping(8)
TCP/IP Illustrated (Stevens, ISBN 0201633469).