良许Linux教程网 Linux命令大全 Linux常用命令ethtool命令具体使用方法

Linux常用命令ethtool命令具体使用方法

Linux常用命令ethtool命令用于查询ethX网口基本设置、及设置网卡的参数,下面良许教程网为大家分享一下Linux常用命令ethtool命令具体使用方法。

Linux常用命令ethtool命令具体使用方法

语法格式:

ethtool [参数]

常用参数:

-i 显示网卡驱动的信息
-E 修改网卡只读存储器字节
-K 修改网卡 Offload 的状态
ethx 查询ethx网口基本设置,其中 x 是对应网卡的编号,如eth0、eth1等
-s 修改网卡的部分配置
-t 让网卡执行自我检测

实例

例1

 [root@redhat ~]# ethtool eth1         #查询eth1网口基本设置
 
 [root@redhat ~]# ethtool -i eth1      #查询eth1网口相关信息
 
 [root@redhat ~]# ethtool -S eth1       #查询eth1网口收发包统计
 
 [root@redhat ~]# ethtool -s eth1 autoneg off speed 100 duplex full   #设置eth1网口速率

例2

 root@c:~# ethtool -k br-prv  #显示网卡详细信息
 Features for br-prv:
 Cannot get device udp-fragmentation-offload settings: Operation not supported
 rx-checksumming: off [fixed]
 tx-checksumming: on
  tx-checksum-ipv4: off [fixed]
  tx-checksum-ip-generic: on
  tx-checksum-ipv6: off [fixed]
  tx-checksum-fcoe-crc: off [fixed]
  tx-checksum-sctp: off [fixed]
 scatter-gather: on
  tx-scatter-gather: on
  tx-scatter-gather-fraglist: on
 tcp-segmentation-offload: on
  tx-tcp-segmentation: on
  tx-tcp-ecn-segmentation: on
  tx-tcp-mangleid-segmentation: on
  tx-tcp6-segmentation: on
 udp-fragmentation-offload: off
 generic-segmentation-offload: on
 generic-receive-offload: on
 large-receive-offload: off [fixed]
 rx-vlan-offload: off [fixed]
 tx-vlan-offload: on
 ntuple-filters: off [fixed]
 receive-hashing: off [fixed]
 highdma: on
 rx-vlan-filter: off [fixed]
 vlan-challenged: off [fixed]
 tx-lockless: on [fixed]
 netns-local: off [fixed]
 tx-gso-robust: off [fixed]
 tx-fcoe-segmentation: off [fixed]
 tx-gre-segmentation: on
 tx-gre-csum-segmentation: on
 tx-ipxip4-segmentation: on
 tx-ipxip6-segmentation: on
 tx-udp_tnl-segmentation: on
 tx-udp_tnl-csum-segmentation: on
 tx-gso-partial: off [fixed]
 tx-sctp-segmentation: on
 tx-esp-segmentation: off [fixed]
 fcoe-mtu: off [fixed]
 tx-nocache-copy: off
 loopback: off [fixed]
 rx-fcs: off [fixed]
 rx-all: off [fixed]
 tx-vlan-stag-hw-insert: on
 rx-vlan-stag-hw-parse: off [fixed]
 rx-vlan-stag-filter: off [fixed]
 l2-fwd-offload: off [fixed]
 hw-tc-offload: off [fixed]
 esp-hw-offload: off [fixed]
 esp-tx-csum-hw-offload: off [fixed]
 rx-udp_tunnel-port-offload: off [fixed]

至此关于Linux常用命令ethtool命令的使用方法分享结束,大家如果对ethtool命令的使用方法还有问题可以通过评论区将问题提交我们。

以上就是良许教程网为各位朋友分享的Linux系统相关内容。想要了解更多Linux相关知识记得关注公众号“良许Linux”,或扫描下方二维码进行关注,更多干货等着你 !

img

本文由 良许Linux教程网 发布,可自由转载、引用,但需署名作者且注明文章出处。如转载至微信公众号,请在文末添加作者公众号二维码。
良许

作者: 良许

良许,世界500强企业Linux开发工程师,公众号【良许Linux】的作者,全网拥有超30W粉丝。个人标签:创业者,CSDN学院讲师,副业达人,流量玩家,摄影爱好者。
上一篇
下一篇

发表评论

联系我们

联系我们

公众号:良许Linux

在线咨询: QQ交谈

邮箱: yychuyu@163.com

关注微信
微信扫一扫关注我们

微信扫一扫关注我们

关注微博
返回顶部