今天看啥
热点:

  Ethtool的工具用于查看和更改的以太网设备。

  1. 查看以太网设备属性列表

  当你执行ethtool命令,它显示有关的以太网设备的以下信息。

  # ethtool eth0

  Settings for eth0:

  Supported ports: [ TP ]

  Supported link modes: 10baseT/Half 10baseT/Full

  100baseT/Half 100baseT/Full

  1000baseT/Full

  Supports auto-negotiation: Yes

  Advertised link modes: 10baseT/Half 10baseT/Full

  100baseT/Half 100baseT/Full

  1000baseT/Full

  Advertised auto-negotiation: Yes

  Speed: 100Mb/s

  Duplex: Full

  Port: Twisted Pair

  PHYAD: 1

  Transceiver: internal

  Auto-negotiation: on

  Supports Wake-on: d

  Wake-on: d

  Link detected: yes

  上面的ethtool输出显示以太网卡的速度,唤醒,全双工和链路状态属性。以下是复式可用的三种类型。

  Full duplex : Enables sending and receiving of packets at the same time. This mode is used when the ethernet device is connected to a switch.

  全双工:允许发送和接收的数据包在同一时间。

  Half duplex : Enables either sending or receiving of packets at a single point of time. This mode is used when the ethernet device is connected to a hub.

  半双工:允许发送或接收的数据包在一个时间点。

  Auto-negotiation : If enabled, the ethernet device itself decides whether to use either full duplex or half duplex based on the network the ethernet device attached to.

  自适应模式:如果启用,以太网设备本身决定是否使用或全双工或半双工的工作模式。

  2.更改网卡参数 使用的ethtool – s选项 autoneg

  上述的ethtool eth0的输出显示,启用状态是“自适应”。您可以禁用此参数,如下所示的ethtool使用autoneg选项。

  # ifdown eth0

  eth0 device: Broadcom Corporation NetXtreme II BCM5709 Gigabit Ethernet (rev 20)

  eth0 configuration: eth-bus-pci-0000:0b:00.0

  # ethtool -s eth0 autoneg off

  # ethtool eth0

  Settings for eth0:

  Supported ports: [ TP ]

  Supported link modes: 10baseT/Half 10baseT/Full

  100baseT/Half 100baseT/Full

  1000baseT/Full

  Supports auto-negotiation: Yes

  Advertised link modes: Not reported

  Advertised auto-negotiation: No

  Speed: Unknown! (65535)

  Duplex: Unknown! (255)

  Port: Twisted Pair

  PHYAD: 1

  Transceiver: internal

  Auto-negotiation: off

  Supports Wake-on: g

  Wake-on: g

  Link detected: no

  # ifup eth0

  经过上面的命令操作改变了以太网卡工作状态,你可以看到检测的值从”自适应”改为OFF状态。

www.bkjia.comtruehttp://www.bkjia.com/jinghua/jinghua_88376.htmlTechArticleEthtool的工具用于查看和更改的以太网设备。 1. 查看以太网设备属性列表 当你执行ethtool命令,它显示有关的以太网设备的以下信息。 # et...

相关文章

    暂无相关文章
相关搜索:
相关频道:

帮客评论

视觉看点