Detailed description of ethtool commands
Command description:
Ethtool is a command used to query and SET network interface card parameters.
Usage Overview:
Ethtool ethx // query the Basic settings of the ethx network port. x indicates the ID of the corresponding Nic, such as eth0 and eth1.
Ethtool-h // display the ethtool Command help (help)
Ethtool-I ethX // query ethX network port information
Ethtool-d ethX // query the registration information of the ethX network port
Ethtool-r ethX // reset the ethX network port to the Adaptive Mode
Ethtool-S ethX // query the ethX network port receiving and receiving packet statistics
Ethtool-s ethX [speed 10 | 100 | 1000] [duplex half | full] [autoneg on | off] // sets the network port rate to 10/100/1000 M, and sets the network port half/full duplex set whether the network port is self-negotiated
Example:
1) [root @ linux/] # ethtool eth1
Settings for eth1:
Supported ports: [TP]
Supported link modes: 10 baseT/Half 10 baseT/Full
100 baseT/Half 100 baseT/Full
1000 baseT/Full
Supports auto-negotiation: Yes
Advertised link modes: 10 baseT/Half 10 baseT/Full
100 baseT/Half 100 baseT/Full
1000 baseT/Full
Advertised auto-negotiation: Yes
Speed: 1000 Mb/s
Duplex: Full
Port: Twisted Pair
PHYAD: 0
Transceiver: internal
Auto-negotiation: on
Supports Wake-on: umbg
Wake-on: d
Link detected: yes
2) [root @ linux/] # ethtool-I eth1
Driver: e1000
Version: 5.0.43-k1
Firmware-version: N/
Bus-info: 06:08. 1
3) [root @ linux/] # ethtool-S eth1
NIC statistics:
Rx_packets: 58068300
Tx_packets: 87124083
Rx_bytes: 1589713008
Tx_bytes: 2165825901
Rx_errors: 0
Tx_errors: 0
Rx_dropped: 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_1_o_errors: 0
Rx_missed_errors: 0
Tx_aborted_errors: 0
Tx_carrier_errors: 0
Tx_1_o_errors: 0
Tx_heartbeat_errors: 0
Tx_window_errors: 0
4) [root @ linux/] # ethtool-s eth1