• 使用ethtool显示硬件PHY信息


    1、总结:

    使用ethtool 可以查看端口的phy配置 

    2、显示端口配置

    [root@localhost zhou]# ethtool ens33
    Settings for ens33:
    Supported ports: [ TP ]
    Supported link modes: 10baseT/Half 10baseT/Full
    100baseT/Half 100baseT/Full
    1000baseT/Full
    Supported pause frame use: No
    Supports auto-negotiation: Yes
    Advertised link modes: 10baseT/Half 10baseT/Full
    100baseT/Half 100baseT/Full
    1000baseT/Full
    Advertised pause frame use: No
    Advertised auto-negotiation: Yes
    Speed: 1000Mb/s
    Duplex: Full
    Port: Twisted Pair
    PHYAD: 0
    Transceiver: internal
    Auto-negotiation: on
    MDI-X: off (auto)
    Supports Wake-on: d
    Wake-on: d
    Current message level: 0x00000007 (7)
    drv probe link
    Link detected: yes
    [root@localhost zhou]#

    3、显示硬件统计详细统计信息  ethtool -S dev

    [root@localhost zhou]# ethtool -S ens33
    NIC statistics:
    rx_packets: 250
    tx_packets: 340
    rx_bytes: 23665
    tx_bytes: 33906
    rx_broadcast: 0
    tx_broadcast: 0
    rx_multicast: 0
    tx_multicast: 0
    rx_errors: 0
    tx_errors: 0
    tx_dropped: 0
    multicast: 0
    collisions: 0
    rx_length_errors: 0
    rx_over_errors: 0
    rx_crc_errors: 0
    rx_frame_errors: 0
    rx_no_buffer_count: 0
    rx_missed_errors: 0
    tx_aborted_errors: 0
    tx_carrier_errors: 0
    tx_fifo_errors: 0
    tx_heartbeat_errors: 0
    tx_window_errors: 0
    tx_abort_late_coll: 0
    tx_deferred_ok: 0
    tx_single_coll_ok: 0
    tx_multi_coll_ok: 0
    tx_timeout_count: 0
    tx_restart_queue: 0
    rx_long_length_errors: 0
    rx_short_length_errors: 0
    rx_align_errors: 0
    tx_tcp_seg_good: 0
    tx_tcp_seg_failed: 0
    rx_flow_control_xon: 0
    rx_flow_control_xoff: 0
    tx_flow_control_xon: 0
    tx_flow_control_xoff: 0
    rx_long_byte_count: 23665
    rx_csum_offload_good: 114
    rx_csum_offload_errors: 0
    alloc_rx_buff_failed: 0
    tx_smbus: 0
    rx_smbus: 0
    dropped_smbus: 0
    [root@localhost zhou]#

    4、显示网口驱动信息  ethtool -i dev

    [root@localhost zhou]# ethtool -i ens33 
    driver: e1000
    version: 7.3.21-k8-NAPI
    firmware-version: 
    expansion-rom-version: 
    bus-info: 0000:02:01.0
    supports-statistics: yes
    supports-test: yes
    supports-eeprom-access: yes
    supports-register-dump: yes
    supports-priv-flags: no
    [root@localhost zhou]#

    参考:

    http://man.linuxde.net/ethtool

  • 相关阅读:
    Unity中传入任意数,转换成分,秒,并进行倒计时换算..(两种方式)
    Unity中调用手机中的粘贴功能
    关于Unity中IphoneX的适配
    可以接受多个字符串的可变参数
    可变参数函数示例
    多维数组指针指向引用问题
    printf的封装与实现
    关于MQTT的相关工具和使用(参考百度天工)
    单片机的堆和栈(Heap & Stack)详解
    单片机的内存分配(变量的存储位置)详解
  • 原文地址:https://www.cnblogs.com/zhouhaibing/p/9534744.html
Copyright © 2020-2023  润新知