Ethtool-display or change ethernet card settings (ethtool is a tool used to display and change Nic settings. 1. ethtool displays network port settings;
This function is easy to handle. That is, the ethtool is followed by the netmask interface. For example, the following example;
[Root @ localhost ~] # Ethtool eth0
Settings for eth0:
Supported ports: [tp mii]
Supported link modes: 10 BaseT/half 10 BaseT/full
100 Baset/half 100 Baset/full
Supports auto-negotiation: Yes
Advertised link modes: 10 BaseT/half 10 BaseT/full
100 Baset/half 100 Baset/full
Advertised auto-negotiation: no note: Automatic negotiation is disabled.
Speed: 100 Mb/s Note: Speed: 100 MB
Duplex: Full Note: Full Duplex
Port: MII
Phyad: 32
Transceiver: Internal
Auto-negotiation: Off
Supports wake-on: pumbg
Wake-on: d
Current message level: 0x00000007 (7)
Link detected: Yes Note: eth0 has been activated;
2. ethtool sets the network card negotiation mode;
In the-H help of ethtool, we can see such help information;
Ethtool-s devname/
[Speed 10 | 100 | 1000]/
[Duplex half | Full]/
[Port TP | AuI | BNC | MII | fiber]/
[Autoneg on | off]/
* Example 1: Change the eth0 speed of the network adapter to 10 Mb/s and adopt half duplex;
[Root @ cuc03 beinan] # ethtool-s eth1 speed 10 duplex half
[Root @ cuc03 beinan] # ethtool eth1
Settings for eth1:
Supported ports: [tp mii]
Supported link modes: 10 BaseT/half 10 BaseT/full
100 Baset/half 100 Baset/full
Supports auto-negotiation: Yes
Advertised link modes: 10 BaseT/half 10 BaseT/full
100 Baset/half 100 Baset/full
Advertised auto-negotiation: No
Speed: 10 Mb/s Note: Speed: 10 m/s
Duplex: Half note: Half Duplex
Port: MII
Phyad: 32
Transceiver: Internal
Auto-negotiation: Off
Supports wake-on: pumbg
Wake-on: d
Current message level: 0x00000007 (7)
Link detected: no note: eth1 is not activated;
* Example 2: Change the eth0 speed of the NIC to 100 Mb/s, and use full duplex;
[Root @ cuc03 beinan] # ethtool-s eth1 speed 100 duplex full
[Root @ cuc03 beinan] # ethtool eth1
Settings for eth1:
Supported ports: [tp mii]
Supported link modes: 10 BaseT/half 10 BaseT/full
100 Baset/half 100 Baset/full
Supports auto-negotiation: Yes
Advertised link modes: 10 BaseT/half 10 BaseT/full
100 Baset/half 100 Baset/full
Advertised auto-negotiation: No
Speed: 100 Mb/s note: the speed is 100 Mb/s
Duplex: Full Note: Full Duplex
Port: MII
Phyad: 32
Transceiver: Internal
Auto-negotiation: Off
Supports wake-on: pumbg
Wake-on: d
Current message level: 0x00000007 (7)
Link detected: no note: The eth1 Nic is not activated;