ethtool speed HowTo : Change Speed and Duplex of Ethernet card in Linux
To change Speed and Duplex of an ethernet card, we can use ethtool - a Linux utility for Displaying or Changing ethernet card settings.
1. Install ethtool
You can install ethtool by typing one of the following commands, depending upon your Linux distribution.
Install ethtool in Fedora, CentOS, RHEL etc. :
# yum install ethtool
Install ethtool in Ubuntu, Debian etc. :
# sudo apt-get install ethtool
2. Get the Speed, Duplex and other information for the interface eth0
To get speed, duplex and other information for the network interface eth0, type the following command as root.
# ethtool eth0
Sample output :
Settings for eth0:
Supported ports: [ MII ]
Supported link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
1000baseT/Half 1000baseT/Full
Supports auto-negotiation: Yes
Advertised link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
1000baseT/Half 1000baseT/Full
Advertised auto-negotiation: Yes
Speed: 100Mb/s
Duplex: Half
Port: Twisted Pair
PHYAD: 1
Transceiver: internal
Auto-negotiation: on
Supports Wake-on: g
Wake-on: d
Current message level: 0x000000ff (255)
Link detected: yes
3. Change the Speed and Duplex settings
The following changes are temporary and they'll stop working after reboot. Read the next section, to make settings permanent.
The next command enables Auto-Negotiate feature :
# ethtool -s eth0 autoneg on
The next command disables Auto-Negotiation, enables Half Duplex and sets up Speed to 10 Mb/s :
# ethtool -s eth0 speed 10 duplex half autoneg off
The next command disables Auto-Negotiation, enables Full Duplex and sets up Speed to 100 Mb/s :
# ethtool -s eth0 speed 100 duplex full autoneg off
4. Change the Speed and Duplex settings Permanently on CentOS/RHEL
To make settings permanent, you need to edit /etc/sysconfig/network-scripts/ifcfg-eth0 file for eth0 interface. This file is used by RHEL, CentOS, Fedora etc.
# vi /etc/sysconfig/network-scripts/ifcfg-eth0
Append the line as follows to disable Auto-Negotiation, enable Full Duplex and set up Speed to 100 Mb/s :
ETHTOOL_OPTS="speed 100 duplex full autoneg off"
Restart the interface to apply changes :
# ifdown eth0 && ifup eth0
zhuan: http://www.shellhacks.com/en/HowTo-Change-Speed-and-Duplex-of-Ethernet-card-in-Linux
ethtool speed HowTo : Change Speed and Duplex of Ethernet card in Linux的更多相关文章
- How to change system keyboard keymap layout on CentOS 7 Linux
The easiest way to swap between keymaps and thus temporarily set keys to different language by use o ...
- Howto: Connect MySQL server using C program API under Linux or UNIX
From my mailbag: How do I write a C program to connect MySQL database server? MySQL database does su ...
- Changing Ethernet Media Speed for AIX
ITS UNIX Systems Changing Ethernet Media Speed for AIX First you need to find out the device name of ...
- hdu FatMouse's Speed 动态规划DP
动态规划的解决方法是找到动态转移方程. 题目地址:http://acm.hdu.edu.cn/game/entry/problem/show.php?chapterid=3§ionid ...
- HD1160FatMouse's Speed(最长单调递增子序列)
FatMouse's Speed Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others) ...
- HDU 1160 FatMouse's Speed(要记录路径的二维LIS)
FatMouse's Speed Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others) ...
- hdu 1160 FatMouse's Speed 解题报告
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1160 题目意思:给出一堆老鼠,假设有 n 只(输入n条信息后Ctrl+Z).每只老鼠有对应的weigh ...
- HDU 1160 FatMouse's Speed
半个下午,总算A过去了 毕竟水题 好歹是自己独立思考,debug,然后2A过的 我为人人的dp算法 题意: 为了支持你的观点,你需要从给的数据中找出尽量多的数据,说明老鼠越重速度越慢这一论点 本着“指 ...
- HDU 1160 FatMouse's Speed (DP)
FatMouse's Speed Time Limit:1000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64u Su ...
随机推荐
- HXXXES 高可用双机RMAN异地备份 Notes
一.总览 大致上的逻辑如上图,简化细节来归纳,便是 用一个bat脚本来驱动整个备份过程. 二.一些准备工作 1.为备份所需的脚本,以及最终备份生成的文件创建目录 开始=>运行=> ...
- What is Thread
A thread is a fundamental unit of CPU utilization –a thread ID –a program counter –a register set –a ...
- IOS开发之——画图(CGContext)
版权声明:本文为博主原创文章.未经博主同意不得转载. https://blog.csdn.net/zhenyu5211314/article/details/24230581 0 CGContext ...
- Codeforces 396A 数论,组合数学
题意:给一个a数组,求b 数组的方案数,但是要求两者乘积相同. 分析: 不可能将它们乘起来,对于每个数质因数分解,得到每个质因子个数,遍历这些质因子,将某个质因子放到 对应的盒子里面,可以不放,方案数 ...
- Codeforces Round #521 (Div. 3) D. Cutting Out 【二分+排序】
任意门:http://codeforces.com/contest/1077/problem/D D. Cutting Out time limit per test 3 seconds memory ...
- SignalR集成Autofac
SignalR SignalR集成需要 Autofac.SignalR NuGet 包. SignalR 集成提供SignalR 集线器的依赖集成.由于 SignalR 是内部构件,所以不支持Sign ...
- WebSocket消息推送(实现进行聊天)和WebSocket简介
WebSocket简介 WebSocket是HTML5开始提供的一种浏览器与服务器间进行全双工通讯的网络技术.依靠这种技术可以实现客户端和服务器端的长连接,双向实时通信.特点:事件驱动异步使用ws或者 ...
- [LuoguP1111]修复公路
[LuoguP1111]修复公路 题目描述: A地区在地震过后,链接所有村庄的公路都损坏了,而导致无法通车,政府派人修复这些公路. 给出A地区的N村庄数和M公路数,并且对于每一个公路给出其链接的两个村 ...
- CSS3 小会
-webkit-perspective:800px; 其子元素获得3D元素支持,这里是设置子元素距离试图的位置:若设为0 则不支持子元素获得3d效果,不支持透视. 常与transform:rota ...
- Vue node.js商城-购物车模块
一.渲染购物车列表页面 新建src/views/Cart.vue获取cartList购物车列表数据就可以在页面中渲染出该用户的购物车列表数据 data(){ return { car ...