Warning: Undefined array key "custom_message" in /www/wwwroot/bbs.aaronyang.cc/wp-content/plugins/wpcopyrights/index.php on line 105

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

相关推荐

  • ltrace

    文章目录ltrace补充说明语法选项实例 ltrace 用来跟踪进程调用库函数的情况 补充说明 ltrace命令 是用来跟踪进程调用库函数的情况。 语法 ltrace [optio…

    入门教程 2023年 12月 19日
  • Java Scanner 类

    java.util.Scanner 是 Java5 的新特征,我们可以通过 Scanner 类来获取用户的输入。 下面是创建 Scanner 对象的基本语法: Scanner s …

    入门教程 2023年 3月 4日
  • ipcs

    文章目录ipcs补充说明语法选项资源选项输出选项通用选项实例相关命令 ipcs 分析消息队列共享内存和信号量 补充说明 ipcs命令 用于报告Linux中进程间通信设施的状态,显示…

    入门教程 2023年 12月 19日
  • HTTP content-type

    Content-Type(内容类型),一般是指网页中存在的 Content-Type,用于定义网络文件的类型和网页的编码,决定浏览器将以什么形式、什么编码读取这个文件,这就是经常看…

    2023年 5月 14日
  • ssh-copy-id

    文章目录ssh-copy-id补充说明语法选项实例 ssh-copy-id 把本地的ssh公钥文件安装到远程主机对应的账户下 补充说明 ssh-copy-id命令 可以把本地主机的…

    入门教程 2024年 3月 11日
  • getenforce

    文章目录getenforce补充说明语法例子 getenforce 显示当前SELinux的应用模式,是强制、执行还是停用 补充说明 grename命令 可以重命名卷组的名称。 语…

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

    文章目录timedatectl补充说明概要主要用途参数例子 timedatectl 用于在 Linux 中设置或查询系统时间、日期和时区等配置。 补充说明 在 Linux 运维中,…

    入门教程 2024年 3月 11日
  • pwck

    文章目录pwck补充说明语法选项参数实例 pwck 用来验证系统认证文件内容和格式的完整性 补充说明 pwck命令 用来验证系统认证文件/etc/passwd和/etc/shado…

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

    文章目录bzdiff补充说明语法参数 bzdiff 直接比较两个.bz2压缩包中文件的不同 补充说明 bzdiff命令 用于直接比较两个“.bz2”压缩包中文件的不同,省去了解压缩…

    入门教程 2023年 12月 6日
  • SSH 连接出现 Connection reset by peer 如何解决

    以上错误一般是因为以下原因导致: 服务器改了密码,试过密码多次后出现 服务器安全策略,无法下发ssh-key-id 调试方法一般是 ssh -v root@ip_addr 文章目录…

    2021年 8月 6日

发表回复

登录后才能评论
Translate »