Howto: change Port OR Network Interface Speed?

How to change Port speed OR Network Interface Speed?

To set a specific speed limit on a Network Interface say 10mbps, edit the file network interface file and set the limit which will make the changes permanent even after a reboot.

Edit the file:

root@server [~]# pico /etc/sysconfig/network-scripts/ifcfg-eth0

Add the following line at the end of the file:

ETHTOOL_OPTS=”speed 10 duplex full autoneg off”

Save the file and restart the network service.

root@server [~]# service network restart

This way you can set the duplex or auto negotiation as well. Once done, you can check the network speed using the ethtool command

root@server [~]# ethtool eth0

This entry was posted on Sunday, November 22nd, 2009 and is filed under Linux Administration. You can follow any responses to this entry through the RSS 2.0 feed. Both comments and pings are currently closed.

4 Responses to “Howto: change Port OR Network Interface Speed?”

  1. Peter Quinn

    Hi. I am a long time reader. I wanted to say that I like your blog and the layout.

    Peter Quinn

  2. greg

    Thanks for support!

    But what’s wrong if I don’t have the file
    /etc/sysconfig/network-scripts/ifcfg-eth0 ?
    and if i made new one it’s useless 🙁

    Greg

  3. admin

    If ifcfg-eth0 isn’t there, then check if the network interface is something else i.e. eth1 in which case the file would be ifcfg-eth1. If the “network-scripts” directory doesn’t exist at all, then you surely should be on Debian OR Ubuntu system in which case, the interface file is /etc/network/interfaces

  4. greg

    actually I am on Dabian,
    the ethtool_opt didn’t work in my interfaces,
    so i put ethtool in rc.local, now it works.

    thanks a lot.