0

Let's say two hosts are connected with an Ethernet connection. There is a similar sounding question that talks about how the two LAN cards determine the link speed by sending and receiving auto-negotiation pulses where both cards advertise their capabilities.

However, how is the cable taken into account? Let's say that both LAN cards are identical and support a much higher speed than the cable, how do they "sense" that they need to settle for a slower speed?

1
  • There are so many ethernet variants, each requiring a specific medium,, and most are a fixed speed. Check out this answer for a list of many of the ethernet variants and maximum cable length of the variant.
    – Ron Maupin
    Mar 21 '21 at 14:40
3

There's Auto Negotiation and that's it. Both sides advertise the speeds and modes they support and the best mutual mode is chosen. The cable is not tested. If the cable quality doesn't support the chosen speed, transmission errors and even repeated link loss have to be expected.

The rare exception are "smart-rate" ports for 2.5/5 Gbit/s (and often 1/10G) over twisted pair that use a training mode (within the PMA sublayer) for testing the cable and (optional) fast retraining.

Also, there may be proprietary mechanisms for falling back to lower speeds, based on pair connectivity or cable training. Likely the most widely used is Broadcom's Ethernet@Wirespeed driver option that disables 1000BASE-T temporarily when PCS fails to link all lanes (because of a two-pair or damaged cable), effectively falling back to 100BASE-TX.

5
  • 1
    But when I put a low quality ethernet cable between my machine and my NAS, then ubuntu will tell me "ethernet wired xx MB/s". And if I switch out the cable to a CAT 6 cable, then I see this message change... So somehow ubuntu seems to know how much throughput the cable can take.
    – kuropan
    Mar 21 '21 at 15:15
  • 1
    @kuropan It's possible that your NIC and driver have some sort of smart-rate technology but it certainly isn't the default.
    – richardb
    Mar 21 '21 at 19:55
  • 1
    My understanding is that many 1G interfaces will retry at 100M if they fail to succesfully establish a link at 1G. Mar 22 '21 at 14:44
  • @PeterGreen That's mostly Broadcom's "Ethernet@Wirespeed". I considered adding that to the answer, will do.
    – Zac67
    Mar 22 '21 at 15:05
  • 2
    @kuropan, 1 Gbps on UTP (1000Base-T) requires all four pairs to work, but if your cable does not have all four pairs good, then it will try to connect at 100 Mbps (100Base-TX), which only requires two good pairs. Many early ethernet UTP cables only connected the two pairs because 10Base-T and 100Base-TX only used the two pairs.
    – Ron Maupin
    Mar 22 '21 at 15:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.