Linux MTR 命令使用解釋

1、Mtr介紹: 一個不錯的網(wǎng)絡(luò)連通性判斷工具

2、安裝: yum install mtr -y 或者 dnf install mtr -y

3、基本使用: mtr 96.45.189.193

使用界面

4、名詞解釋

Host:主機ip地址
Lost:每個對應(yīng)IP的丟包率
Snt: 設(shè)置發(fā)送的ping次數(shù), 默認值是10 可以通過參數(shù) -c 來指定
Last: 最近一次的返回延時
Avg:是平均值 發(fā)送ping包的平均延時
Best: 最短的延時
Wrst: 最長的延時
StDev: 標(biāo)準(zhǔn)偏差

5、常規(guī)用法

mtr -n 96.45.189.193 不顯示host名稱

mtr -c 5 96.45.189.193 設(shè)置發(fā)送5次之后自動停止
mtr -s 256 96.45.189.193 設(shè)置每次發(fā)送的數(shù)據(jù)包大小為 256

6、MTR的參數(shù)

簡寫 全稱 詳細描述
-F, --filename FILE read hostname(s) from a file
-4 use IPv4 only
-6 use IPv6 only
-u, --udp use UDP instead of ICMP echo
-T, --tcp use TCP instead of ICMP echo
-a, --address ADDRESS bind the outgoing socket to ADDRESS
-f, --first-ttl NUMBER set what TTL to start
-m, --max-ttl NUMBER maximum number of hops
-U, --max-unknown NUMBER maximum unknown host
-P, --port PORT target port number for TCP, SCTP, or UDP
-L, --localport LOCALPORT source port number for UDP
-s, --psize PACKETSIZE set the packet size used for probing 用來指定ping數(shù)據(jù)包的大小 (常用)
-B, --bitpattern NUMBER set bit pattern to use in payload
-i, --interval SECONDS ICMP echo request interval
-G, --gracetime SECONDS number of seconds to wait for responses
-Q, --tos NUMBER type of service field in IP header
-e, --mpls display information from ICMP extensions
-Z, --timeout SECONDS seconds to keep probe sockets open
-M, --mark MARK mark each sent packet
-r, --report output using report mode
-w, --report-wide output wide report
-c, --report-cycles COUNT set the number of pings sent
-j, --json output json
-x, --xml output xml
-C, --csv output comma separated values 設(shè)置發(fā)送的ping次數(shù),通常到達次數(shù)后會自動退出 (常用)
-l, --raw output raw format
-p, --split split output
-t, --curses use curses terminal interface
--displaymode MODE select initial display mode
-n, --no-dns do not resove host names 不對IP地址做域名解析 (常用)
-b, --show-ips show IP numbers and host names
-o, --order FIELDS select output fields
-y, --ipinfo NUMBER select IP information in output
-z, --aslookup display AS number
-h, --help display this help and exit
-v, --version output version information and exit
最后編輯于
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時請結(jié)合常識與多方信息審慎甄別。
平臺聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點,簡書系信息發(fā)布平臺,僅提供信息存儲服務(wù)。

友情鏈接更多精彩內(nèi)容