In this article I will show How To Check Ethernet Connection Speed in Linux using 3 different ways.
Ethtool Show Speed
ethtool is powerful utility for query or control network driver and hardware settings for wired Ethernet devices.
To determine link connection speed using ethtool command type:
# ethtool eth0
example output:
or if you want see brief report only about connection speed and nothing else:
# ethtool eth0 | grep Speed
Check Ethernet Connection Speed using mii-tool command
mii-tool utility checks or sets the status of a network interface’s Media Independent Interface (MII) unit. Most fast ethernet adapters use an MII to autonegotiate link speed and duplex setting.
# mii-tool eth0
Example output:
eth0: negotiated 1000baseT-FD flow-control, link ok
possible outputs for different connections:
1000baseTx-HD, 1000baseTx-FD,
100baseT4, 100baseTx-FD, 100baseTx-HD,
10baseT-FD, 10baseT-HD,
(to advertise both HD and FD) 1000baseTx, 100baseTx, 10baseT
View Interface Speed From Kernel
We can also ‘cat’ kernel files to check Ethernet connection speed:
# cat /sys/class/net/eth0/speed /sys/class/net/eth0/duplex
Example output:
Conclusion
You just learn How to Check Ethernet Connection Speed in Linux using ethtool, mii-tool, and kernel files.
5 Great Commands to Monitor Network Bandwidth