Check speed of connected link in Linux

If you’ve ever wanted to check on the status of your Ethernet links, you’ve probably used the ip commands (or ifconfig) to view some basic information.  However, you might have noticed these commands do not tell you what the current link speed is, or other possibly important details.  That’s where ethtool comes in.

[jonmoore@megaton ~]$ sudo ethtool eth0
Settings for eth0:
Supported ports: [ MII ]
Supported link modes:   10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
1000baseT/Full
Supports auto-negotiation: Yes
Advertised link modes:  10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
1000baseT/Full
Advertised auto-negotiation: Yes
Speed: 1000Mb/s
Duplex: Full
Port: MII
PHYAD: 1
Transceiver: external
Auto-negotiation: on
Supports Wake-on: g
Wake-on: d
Link detected: yes

As you can see, ethtool will show you the support modes, as well as the current mode.  From the above example, I’m currently connected at 1000Mb/s at Full Duplex.  Very nice.

Check out the ethtool man page for more useful commands.

Related posts:

  1. Find Text and Find/Replace Easier Than You Think in Linux How to search all files for a text string: grep...
  2. Creating empty files in Linux I had a need for several files of various sizes...

Related posts brought to you by Yet Another Related Posts Plugin.

This entry was posted in quickfire, tips and tagged , . Bookmark the permalink. Post a comment or leave a trackback: Trackback URL.

Post a Comment

Your email is never published nor shared. Required fields are marked *

*
*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>