您好,登錄后才能下訂單哦!
本篇內容介紹了“Linux iftop命令怎么使用”的有關知識,在實際案例的操作過程中,不少人都會遇到這樣的困境,接下來就讓小編帶領大家學習一下如何處理這些情況吧!希望大家仔細閱讀,能夠學有所成!
iftop命令 是一款實時流量監控工具,監控TCP/IP連接等,缺點就是無報表功能。必須以root身份才能運行。
一款實時流量監控工具
iftop(選項)
iftop: display bandwidth usage on an interface by host Synopsis: iftop -h | [-npblNBP] [-i interface] [-f filter code] [-F net/mask] [-G net6/mask6] -h display this message -n don't do hostname lookups -N don't convert port numbers to services -p run in promiscuous mode (show traffic between other hosts on the same network segment) -b don't display a bar graph of traffic -B Display bandwidth in bytes -i interface listen on named interface -f filter code use filter code to select packets to count (default: none, but only IP packets are counted) -F net/mask show traffic flows in/out of IPv4 network -G net6/mask6 show traffic flows in/out of IPv6 network -l display and count link-local IPv6 traffic (default: off) -P show ports as well as hosts -m limit sets the upper limit for the bandwidth scale -c config file specifies an alternative configuration file -t use text interface without ncurses Sorting orders: -o 2s Sort by first column (2s traffic average) -o 10s Sort by second column (10s traffic average) [default] -o 40s Sort by third column (40s traffic average) -o source Sort by source address -o destination Sort by destination address The following options are only available in combination with -t -s num print one single text output afer num seconds, then quit -L num number of lines to print
第一行為帶寬,這里為1Mbit,不是字節哦. 連接列表,最后三列分別是2秒,10秒和40秒的平均流量 => 代表發送 代表接收 最后三行表示發送,接收和全部的流量, 第二列為你運行iftop到目前流量,第三列為高峰值,第四列為平均值。
iftop # 默認是監控第一塊網卡的流量 iftop -i eth2 # 監控eth2 iftop -n # 直接顯示IP, 不進行DNS反解析 iftop -N # 直接顯示連接埠編號, 不顯示服務名稱 iftop -F 192.168.1.0/24 or 192.168.1.0/255.255.255.0 # 顯示某個網段進出封包流量
“Linux iftop命令怎么使用”的內容就介紹到這里了,感謝大家的閱讀。如果想了解更多行業相關的知識可以關注億速云網站,小編將為大家輸出更多高質量的實用文章!
免責聲明:本站發布的內容(圖片、視頻和文字)以原創、轉載和分享為主,文章觀點不代表本網站立場,如果涉及侵權請聯系站長郵箱:is@yisu.com進行舉報,并提供相關證據,一經查實,將立刻刪除涉嫌侵權內容。