iftop

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 eth1   # 监控eth1
iftop -n        # 直接显示IP, 不进行DNS反解析
iftop -N        # 直接显示连接埠编号, 不显示服务名称
iftop -F 192.168.1.0/24 or 192.168.1.0/255.255.255.0  # 显示某个网段进出封包流量

若文章对你有帮助,可以点赞或打赏支持我们。发布者:Aurora,转载请注明出处:http://61.174.243.28:13541/AY-knowledg-hub/iftop/

(0)
AuroraAurora站点维系者
上一篇 2023年 12月 19日 下午3:26
下一篇 2023年 12月 19日 下午3:26

相关推荐

  • enable

    文章目录enable概要主要用途选项参数返回值例子(以下内容限于篇幅不再列出返回值部分)Q&A注意 enable 启动或禁用shell内建命令 概要 enable [-a]…

    入门教程 2023年 12月 14日
  • pushd

    文章目录pushd概要主要用途选项参数返回值例子注意参考链接 pushd 将目录添加到目录堆栈顶部。 概要 pushd [-n] [+N | -N | dir] 主要用途 将目录添…

    入门教程 2024年 3月 1日
  • centos 下安装go环境

    centos下安装go一般 有两种方式,一个是yum,一个是直接到官网下载.tar.gz包yum方式安装比较简单 直接执行 yum install golang 然后就可以使用go…

    2024年 4月 19日
  • bzcmp

    文章目录bzcmp补充说明语法参数 bzcmp 比较两个压缩包中的文件 补充说明 bzcmp命令 主要功能是在不真正解压缩.bz2压缩包的情况下,比较两个压缩包中的文件,省去了解压…

    入门教程 2023年 12月 6日
  • cut

    文章目录cut补充说明语法选项参数实例指定字段的字符或者字节范围 cut 连接文件并打印到标准输出设备上 补充说明 cut 命令 用来显示行中的指定部分,删除文件中指定字段。cut…

    入门教程 2023年 12月 7日
  • named-checkzone

    文章目录named-checkzone补充说明语法选项例子 named-checkzone 使用named-checkzone命令可以进行区域文件有效性检查和转换,必须指定区域名称…

    入门教程 2024年 1月 10日
  • e2label

    文章目录e2label补充说明语法参数实例 e2label 设置第二扩展文件系统的卷标 补充说明 e2label命令 用来设置第二扩展文件系统的卷标。 语法 e2label(参数)…

    入门教程 2023年 12月 14日
  • IOS音频和视频(Audio & Video)

    文章目录简介实例步骤注意项输出 简介 音频和视频在最新的设备中颇为常见。 将iosAVFoundation.framework和MediaPlayer.framework添加到Xc…

    2023年 4月 1日
  • pwd

    文章目录pwd补充说明内建命令概要选项返回值注意外部命令概要主要用途选项返回值注意例子 pwd 显示当前工作目录的绝对路径。 补充说明 pwd(英文全拼:print working…

    入门教程 2024年 3月 1日
  • pssh

    文章目录pssh补充说明安装pssh选项实例 pssh 批量管理执行 补充说明 pssh命令 是一个python编写可以在多台服务器上执行命令的工具,同时支持拷贝文件,是同类工具中…

    入门教程 2024年 3月 1日

发表回复

登录后才能评论
Translate »