Operating System - Linux
1828330 Members
4097 Online
109976 Solutions
New Discussion

how to see speed and change speed of one lan

 
SOLVED
Go to solution
Carme Torca
Super Advisor

how to see speed and change speed of one lan

Hi,

I would like to know how can I see the speed that have one lan and how can I change it.

Thanks a lot of!
Carmen.
Users are not too bad ;-)
6 REPLIES 6
Jeff_Traigle
Honored Contributor
Solution

Re: how to see speed and change speed of one lan

To see settings of the interface:

ethtool eth0

(substitute the interface you want to check if other than eth0)

To set speed and duplex:

ethtool â s eth0 duplex full speed 100 autoneg off

There several other options you can use on this command. See ethtool(8) man page for details.
--
Jeff Traigle
Ivan Ferreira
Honored Contributor

Re: how to see speed and change speed of one lan

The commands above are correct, just take in account that not all network adapters modules supports ethtool.
Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
Manuel Wolfshant
Trusted Contributor

Re: how to see speed and change speed of one lan

the usual tools are the already mentioned ethtool (in RH it is provided by the ethtool package) and mii-tool (useful mostly for older cards - provided in RH by the net-tools rpm).

Vipulinux
Respected Contributor

Re: how to see speed and change speed of one lan

Hi

ethtool -s eth0 speed 100 duplex full autoneg off

this command will set full duplex at 100 mbps for eth0
( make sure you do autoneg off)

Cheers
Atul Gautam
Valued Contributor

Re: how to see speed and change speed of one lan

Hi Carme,

All my fellow forummers are right but here's a point....after setting up ur "eth0" using the "ethtool" command, if you restart your machine/server you'll see that the settings again go back to the default ones.

So, here are the steps to check and change the settings of your ethernet ---

TO CHECK
---------

# ethtool eth0

It will show all the supported settings and will also display the settings implemented on your eth0.

TO CHANGE
----------

1) Edit the file "/etc/sysconfig/network-scripts/ifcfg-eth0" and add the following options at the end ----

ETHTOOL_OPTS="speed (100|1000) duplex (half|full) autoneg (on|off)"

NOTE : For other options, you can also consult the man page for "ethtool"

2) Save your file and then either reboot ur server else you can also restart your "network" services using the command --

# service network restart





--
Atul
Karsten Breivik_1
Frequent Advisor

Re: how to see speed and change speed of one lan


Hi.

One problem with IP applications is that they are notoriously greedy and often will use all the bandwidth it can get its hand on. This often leads to congestion in the network. So you may be interested in limiting the speed of the link, per user, per port, per application, etc.

If this is the case, have a look at the linux kernel implementation for "traffic shaping", especially the tc command and the theory underpinning of Hierarchical Token Bucket. Be prepared for a few hours of intensive reading to understand the concepts. But it is well worth it :-)

Main sites are:

http://lartc.org/
http://luxik.cdi.cz/~devik/qos/htb/

but other sites give better primers:

http://en.wikipedia.org/wiki/Traffic_shaping

http://www.knowplace.org/pages/howtos/traffic_shaping_with_linux.php




poi