RX dropped 不为0

ifconfig 网卡详细解释

ifconfig docker0
docker0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 172.17.0.1  netmask 255.255.0.0  broadcast 172.17.255.255
        inet6 fe80::42:feff:feaa:6fb7  prefixlen 64  scopeid 0x20<link>
        ether 02:42:fe:aa:6f:b7  txqueuelen 0  (Ethernet)
        RX packets 761279  bytes 29939307524 (27.8 GiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 1384706  bytes 265308504 (253.0 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

这是对docker0网络接口的ifconfig输出的详细解释:

  • flags=4163<UP,BROADCAST,RUNNING,MULTICAST>:

    • UP: 接口已经启动。
    • BROADCAST: 接口支持广播。
    • RUNNING: 接口正在运行。
    • MULTICAST: 接口支持多播。
  • mtu 1500: Maximum Transmission Unit,表示接口的最大传输单元,即每个数据包的最大大小。

  • inet 172.17.0.1 netmask 255.255.0.0 broadcast 172.17.255.255:

    • inet: 表示接口的IPv4地址是172.17.0.1。
    • netmask: 子网掩码为255.255.0.0。
    • broadcast: 广播地址为172.17.255.255。
  • inet6 fe80::42:feff:feaa:6fb7 prefixlen 64 scopeid 0x20<link>:

    • inet6: 表示接口的IPv6地址是fe80::42:feff:feaa:6fb7。
    • prefixlen: IPv6地址的前缀长度为64。
    • scopeid: 接口的范围ID。
  • ether 02:42:fe:aa:6f:b7:

    • ether: 表示接口的物理地址(MAC地址)是02:42:fe:aa:6f:b7。
  • txqueuelen 0 (Ethernet):

    • txqueuelen: 表示传输队列长度为0,即没有排队等待发送的数据包。
  • RX (接收) 统计信息:

    • packets 761279: 接收的总数据包数为761279。
    • bytes 29939307524 (27.8 GiB): 接收的总字节数为29939307524,即27.8 GB。
    • errors 0: 接收过程中没有发生错误。
    • dropped 0: 没有丢弃的接收数据包。
    • overruns 0: 没有接收缓冲区溢出。
    • frame 0: 没有帧错误。
  • TX (发送) 统计信息:

    • packets 1384706: 发送的总数据包数为1384706。
    • bytes 265308504 (253.0 MiB): 发送的总字节数为265308504,即253.0 MB。
    • errors 0: 发送过程中没有发生错误。
    • dropped 0: 没有丢弃的发送数据包。
    • overruns 0: 没有发送缓冲区溢出。
    • carrier 0: 没有发生载波丢失。
    • collisions 0: 没有发生碰撞。

ethtool -S 网卡

ethtool -S em1
NIC statistics:
     rx_octets: 7692553581
     rx_fragments: 0
     rx_ucast_packets: 7108794
     rx_mcast_packets: 644477
     rx_bcast_packets: 20818
     rx_fcs_errors: 0
     rx_align_errors: 0
     rx_xon_pause_rcvd: 0
     rx_xoff_pause_rcvd: 0
     rx_mac_ctrl_rcvd: 0
     rx_xoff_entered: 0
     rx_frame_too_long_errors: 0
     rx_jabbers: 0
     rx_undersize_packets: 0
     rx_in_length_errors: 0
     rx_out_length_errors: 0
     rx_64_or_less_octet_packets: 0
     rx_65_to_127_octet_packets: 0
     rx_128_to_255_octet_packets: 0
     rx_256_to_511_octet_packets: 0
     rx_512_to_1023_octet_packets: 0
     rx_1024_to_1522_octet_packets: 0
     rx_1523_to_2047_octet_packets: 0
     rx_2048_to_4095_octet_packets: 0
     rx_4096_to_8191_octet_packets: 0
     rx_8192_to_9022_octet_packets: 0
     tx_octets: 10112892455
     tx_collisions: 0
     tx_xon_sent: 11
     tx_xoff_sent: 16
     tx_flow_control: 0
     tx_mac_errors: 0
     tx_single_collisions: 0
     tx_mult_collisions: 0
     tx_deferred: 0
     tx_excessive_collisions: 0
     tx_late_collisions: 0
     tx_collide_2times: 0
     tx_collide_3times: 0
     tx_collide_4times: 0
     tx_collide_5times: 0
     tx_collide_6times: 0
     tx_collide_7times: 0
     tx_collide_8times: 0
     tx_collide_9times: 0
     tx_collide_10times: 0
     tx_collide_11times: 0
     tx_collide_12times: 0
     tx_collide_13times: 0
     tx_collide_14times: 0
     tx_collide_15times: 0
     tx_ucast_packets: 8298813
     tx_mcast_packets: 332
     tx_bcast_packets: 5094
     tx_carrier_sense_errors: 0
     tx_discards: 0
     tx_errors: 0
     dma_writeq_full: 0
     dma_write_prioq_full: 0
     rxbds_empty: 15
     rx_discards: 9
     rx_errors: 0
     rx_threshold_hit: 0
     dma_readq_full: 0
     dma_read_prioq_full: 0
     tx_comp_queue_full: 0
     ring_set_send_prod_index: 0
     ring_status_update: 0
     nic_irqs: 0
     nic_avoided_irqs: 0
     nic_tx_threshold_hit: 0
     mbuf_lwm_thresh_hit: 9

这是通过ethtool -S em1命令获取的em1网卡的统计信息。以下是一些关键的内容和解释:

接收统计信息:

  • rx_octets: 7692553581: 接收的总字节数。
  • rx_ucast_packets: 7108794: 接收的单播数据包数量。
  • rx_mcast_packets: 644477: 接收的多播数据包数量。
  • rx_bcast_packets: 20818: 接收的广播数据包数量。
  • rx_fcs_errors: 0: 接收过程中的帧校验错误数量。
  • rx_align_errors: 0: 接收过程中的帧对齐错误数量。
  • rx_errors: 0: 接收过程中的其他错误数量。
  • rx_discards: 9: 由于某种原因而被丢弃的接收数据包数量。

发送统计信息:

  • tx_octets: 10112892455: 发送的总字节数。
  • tx_ucast_packets: 8298813: 发送的单播数据包数量。
  • tx_mcast_packets: 332: 发送的多播数据包数量。
  • tx_bcast_packets: 5094: 发送的广播数据包数量。
  • tx_collisions: 0: 发送过程中发生的冲突次数。
  • tx_errors: 0: 发送过程中的其他错误数量。
  • tx_discards: 0: 由于某种原因而被丢弃的发送数据包数量。

其他统计信息:

  • dma_writeq_full: 0: DMA写队列已满的次数。
  • rxbds_empty: 15: 接收缓冲区描述符(RXBDS)为空的次数。
  • tx_comp_queue_full: 0: 发送完成队列已满的次数。
  • rx_discards: 9: 由于某种原因而被丢弃的接收数据包数量。
  • rx_threshold_hit: 0: 接收阈值被击中的次数。
  • tx_comp_queue_full: 0: 发送完成队列已满的次数。

注意事项:

  • 如果rx_errorstx_errors的值不为零,可能需要进一步调查,以确定具体的问题。
  • 丢弃的数据包数量可能表明一些问题,特别是在rx_discardstx_discards的情况下,可能需要进一步检查。
  • 冲突计数(tx_collisions)为零,这是正常的,因为现代以太网通常采用全双工模式,不会发生冲突。

ethtool -a 网卡

ethtool -a em1
Pause parameters for em1:
Autonegotiate:  on
RX:             on
TX:             on
RX negotiated:  on
TX negotiated:  on

通过ethtool -a em1命令,你可以查看网卡em1的暂停(Pause)参数。以下是关注的重点内容和解释:

  • Autonegotiate: on

    • Autonegotiate 表示网卡是否启用了自动协商。在这个情况下,on 表示启用了自动协商,网卡会自动协商最佳的通信参数,包括速度和双工模式。
  • RX: on

    • RX 表示接收方(网卡)是否启用了暂停(Flow Control)功能。在这个情况下,on 表示接收方启用了暂停。
  • TX: on

    • TX 表示发送方(网卡)是否启用了暂停(Flow Control)功能。在这个情况下,on 表示发送方启用了暂停。
  • RX negotiated: on

    • RX negotiated 表示接收方的暂停功能是否是通过协商得到的。在这个情况下,on 表示接收方的暂停功能是通过协商得到的。
  • TX negotiated: on

    • TX negotiated 表示发送方的暂停功能是否是通过协商得到的。在这个情况下,on 表示发送方的暂停功能是通过协商得到的。

解释:

  • 暂停(Flow Control)是一种用于在网络通信中协调数据流量的机制。它可以防止在高速网络中发生数据包丢失的情况,尤其是当接收方的处理速度跟不上发送方时。
  • 启用了自动协商表示网卡能够在与连接的其他设备之间协商最佳的通信参数,包括速度和双工模式。
  • 如果RXTX都是on,表示网卡启用了双向的暂停功能,即在数据传输的过程中,接收方和发送方都可以通过发送控制帧来暂停数据流,以避免丢失数据或者缓冲区溢出。
  • RX negotiatedTX negotiated 的值为 on 表明暂停功能是通过自动协商得到的,而不是手动配置的。

ethtool -i 网卡

ethtool -i em1
driver: tg3
version: 3.137
firmware-version: FFV7.10.61 bc 5720-v1.36
expansion-rom-version:
bus-info: 0000:01:00.0
supports-statistics: yes
supports-test: yes
supports-eeprom-access: yes
supports-register-dump: yes
supports-priv-flags: no

通过ethtool -i em1命令,你可以查看网卡em1的信息。以下是关注的重点内容和解释:

  • driver: tg3

    • driver 表示网卡使用的驱动程序。在这个情况下,tg3 是网卡的驱动程序。
  • version: 3.137

    • version 表示驱动程序的版本号。在这个情况下,版本号是 3.137
  • firmware-version: FFV7.10.61 bc 5720-v1.36

    • firmware-version 表示网卡的固件版本。在这个情况下,固件版本是 FFV7.10.61 bc 5720-v1.36
  • bus-info: 0000:01:00.0

    • bus-info 表示网卡所连接的总线信息。在这个情况下,网卡连接到的总线信息是 0000:01:00.0
  • supports-statistics: yes

    • supports-statistics 表示网卡是否支持统计信息。在这个情况下,yes 表示网卡支持统计信息。
  • supports-test: yes

    • supports-test 表示网卡是否支持测试功能。在这个情况下,yes 表示网卡支持测试功能。
  • supports-eeprom-access: yes

    • supports-eeprom-access 表示网卡是否支持EEPROM访问。在这个情况下,yes 表示网卡支持EEPROM访问。
  • supports-register-dump: yes

    • supports-register-dump 表示网卡是否支持寄存器转储。在这个情况下,yes 表示网卡支持寄存器转储。
  • supports-priv-flags: no

    • supports-priv-flags 表示网卡是否支持私有标志(Private Flags)。在这个情况下,no 表示网卡不支持私有标志。

解释:

  • 驱动程序信息 (driver) 指示正在使用的网卡驱动程序。
  • 驱动程序版本 (version) 表示网卡驱动程序的版本。
  • 固件版本 (firmware-version) 表示网卡当前使用的固件版本。
  • 总线信息 (bus-info) 提供了网卡所连接的总线的详细信息。
  • supports-statistics, supports-test, supports-eeprom-access, supports-register-dump 等表示网卡支持的功能,例如统计信息、测试、EEPROM访问和寄存器转储。
  • supports-priv-flags 表示网卡是否支持私有标志。在这个情况下,no 表示不支持。

/proc/meminfo

/proc/meminfo 文件提供了关于系统内存使用的详细信息。以下是一些关键的内容和解释:

  • MemTotal: 98441724 kB

    • MemTotal 表示系统总内存容量,单位是千字节。在这个情况下,系统总内存容量为 98441724 kB。
  • MemFree: 6173264 kB

    • MemFree 表示系统当前空闲的内存量,单位是千字节。在这个情况下,系统当前有 6173264 kB 的空闲内存。
  • MemAvailable: 63999028 kB

    • MemAvailable 表示系统当前可用的内存量,考虑了缓存和缓冲区。在这个情况下,系统当前有 63999028 kB 的可用内存。
  • Buffers: 8876 kB

    • Buffers 表示用于存储块设备的缓冲区的内存量,单位是千字节。
  • Cached: 61790256 kB

    • Cached 表示系统当前用于文件缓存的内存量,单位是千字节。这包括页面缓存和文件系统缓存。
  • SwapTotal: 0 kB

    • SwapTotal 表示交换空间的总量,单位是千字节。在这个情况下,系统没有启用交换空间。
  • SwapFree: 0 kB

    • SwapFree 表示当前可用的交换空间量,单位是千字节。在这个情况下,交换空间不可用。
  • Active: 33200276 kB

    • Active 表示当前正在使用的活动内存量,单位是千字节。包括正在使用的和最近被使用的内存。
  • Inactive: 52034956 kB

    • Inactive 表示当前未被使用的内存量,单位是千字节。这是最近未被使用的内存,但仍然在系统中。
  • CommitLimit: 49220860 kB

    • CommitLimit 表示系统能够保证不会耗尽内存和交换空间的“安全”限制,单位是千字节。
  • Committed_AS: 75100124 kB

    • Committed_AS 表示系统已经分配的内存总量(包括交换空间),单位是千字节。
  • VmallocTotal: 34359738367 kB

    • VmallocTotal 表示虚拟内存总量,单位是千字节。包括通过vmalloc分配的内存。
  • DirectMap4k, DirectMap2M, DirectMap1G:

    • 分别表示直接映射到物理内存的4KB、2MB和1GB页的内存量,单位是千字节。

这些信息对于监视系统的内存使用情况以及诊断性能问题非常有用。

  • 24
    点赞
  • 21
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值