# Network interface running at wrong Speed after update

## HealerLFG

Good morning all.

After a world update, my network speeds seem to have regressed.  There are no config files to update via etc-update/dispatch-conf.  After looking into it via ethtool, it seems that my LAN speed has been set to 10MB/s.  Previously, it was running at 1GB/s full duplex.

I have ruled out physical issues like damaged ports/cables;  All cables test fine on a cable tester, and all ports work fine with other PCs.  Furthermore, I get the full speed while on the minimal/live CD.  The ethernet driver used in the install environment is the same (igb).

DNS/DHCP seem to be working as usual on both server/client side.

The world update did *not* include my kernel sources or linux-firmware.

Also of note, I use systemd, with NetworkManager set as default and pulled in by KDE Plasma.  In the plasma settings gui, I can attempt to force link negotiation to 1GB/s and Full Duplex, but it seems to make no difference.  Ethtool still reports 10MB/s, and online speedtests confirm it.

I have also tried to force it via ethtool commands with 

```
 sudo ethtool -s enp9s0 speed 1000 duplex full autoneg off 
```

 but doing so ethtool reports both Speed and Duplex as "Unknown!" and completely kills my connection until I reboot.

Also, dmesg seems to report my link speed changing a few times.

```
 dmesg | grep igb

[    0.213573] igb: Intel(R) Gigabit Ethernet Network Driver

[    0.213574] igb: Copyright (c) 2007-2014 Intel Corporation.

[    0.213587] igb 0000:09:00.0: enabling device (0000 -> 0002)

[    0.242392] igb 0000:09:00.0: Intel(R) Gigabit Ethernet Network Connection

[    0.242394] igb 0000:09:00.0: eth0: (PCIe:2.5Gb/s:Width x1) a8:a1:59:91:10:dc

[    0.242398] igb 0000:09:00.0: eth0: PBA No: FFFFFF-0FF

[    0.242398] igb 0000:09:00.0: Using MSI-X interrupts. 2 rx queue(s), 2 tx queue(s)

[    1.024829] igb 0000:09:00.0 enp9s0: renamed from eth0

[   35.016645] igb 0000:09:00.0 enp9s0: igb: enp9s0 NIC Link is Up 10 Mbps Full Duplex, Flow Control: RX

[   35.016739] igb 0000:09:00.0 enp9s0: Link Speed was downgraded by SmartSpeed

[   58.766603] igb 0000:09:00.0 enp9s0: igb: enp9s0 NIC Link is Up 100 Mbps Full Duplex, Flow Control: RX

[   81.751603] igb 0000:09:00.0 enp9s0: igb: enp9s0 NIC Link is Up 100 Mbps Full Duplex, Flow Control: RX

[  104.737602] igb 0000:09:00.0 enp9s0: igb: enp9s0 NIC Link is Up 100 Mbps Full Duplex, Flow Control: RX

[  127.825601] igb 0000:09:00.0 enp9s0: igb: enp9s0 NIC Link is Up 100 Mbps Full Duplex, Flow Control: RX

[  150.894641] igb 0000:09:00.0 enp9s0: igb: enp9s0 NIC Link is Up 100 Mbps Full Duplex, Flow Control: RX

[  174.214598] igb 0000:09:00.0 enp9s0: igb: enp9s0 NIC Link is Up 100 Mbps Full Duplex, Flow Control: RX

[  209.986598] igb 0000:09:00.0 enp9s0: igb: enp9s0 NIC Link is Up 10 Mbps Full Duplex, Flow Control: RX

[  209.986686] igb 0000:09:00.0 enp9s0: Link Speed was downgraded by SmartSpeed

[  233.440595] igb 0000:09:00.0 enp9s0: igb: enp9s0 NIC Link is Up 100 Mbps Full Duplex, Flow Control: RX

[  256.509595] igb 0000:09:00.0 enp9s0: igb: enp9s0 NIC Link is Up 100 Mbps Full Duplex, Flow Control: RX

[  279.579593] igb 0000:09:00.0 enp9s0: igb: enp9s0 NIC Link is Up 100 Mbps Full Duplex, Flow Control: RX

[  302.481591] igb 0000:09:00.0 enp9s0: igb: enp9s0 NIC Link is Up 100 Mbps Full Duplex, Flow Control: RX

[  325.597632] igb 0000:09:00.0 enp9s0: igb: enp9s0 NIC Link is Up 100 Mbps Full Duplex, Flow Control: RX

[  348.620590] igb 0000:09:00.0 enp9s0: igb: enp9s0 NIC Link is Up 100 Mbps Full Duplex, Flow Control: RX

[  351.111236] igb 0000:09:00.0 enp9s0: igb: enp9s0 NIC Link is Up 10 Mbps Full Duplex, Flow Control: None

[  414.556588] igb 0000:09:00.0 enp9s0: igb: enp9s0 NIC Link is Up 100 Mbps Full Duplex, Flow Control: RX

[  417.151233] igb 0000:09:00.0 enp9s0: igb: enp9s0 NIC Link is Up 10 Mbps Full Duplex, Flow Control: None 
```

running 

```
 sudo ifconfig enp9s0 && sudo ethtool enp9s0 
```

 while my network is slow (but functional) gives the following info:

```
 enp9s0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500

        inet 192.168.50.100  netmask 255.255.255.0  broadcast 192.168.50.255

        inet6 fe80::a36f:9029:d2ef:c76f  prefixlen 64  scopeid 0x20<link>

        ether a8:a1:59:91:10:dc  txqueuelen 1000  (Ethernet)

        RX packets 9644  bytes 10036999 (9.5 MiB)

        RX errors 0  dropped 0  overruns 0  frame 0

        TX packets 8313  bytes 990189 (966.9 KiB)

        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

        device memory 0xfc600000-fc61ffff

Settings for enp9s0:

   Supported ports: [ TP ]

   Supported link modes:   10baseT/Half 10baseT/Full

                           100baseT/Half 100baseT/Full

                           1000baseT/Full

   Supported pause frame use: Symmetric

   Supports auto-negotiation: Yes

   Supported FEC modes: Not reported

   Advertised link modes:  Not reported

   Advertised pause frame use: Symmetric

   Advertised auto-negotiation: No

   Advertised FEC modes: Not reported

   Speed: 10Mb/s

   Duplex: Full

   Port: Twisted Pair

   PHYAD: 1

   Transceiver: internal

   Auto-negotiation: off

   MDI-X: off (auto)

   Supports Wake-on: pumbg

   Wake-on: g

   Current message level: 0x00000007 (7)

                drv probe link

```

----------

## pietinger

If you google this text: "Link Speed was downgraded by SmartSpeed" you will find many articles saying, it is a problem with:

1. the cable, OR

2. your NIC and your switch are incompatible

So, try to use another ethernet cable first.

----------

## HealerLFG

 *pietinger wrote:*   

> If you google this text: "Link Speed was downgraded by SmartSpeed" you will find many articles saying, it is a problem with:
> 
> 1. the cable, OR
> 
> 2. your NIC and your switch are incompatible
> ...

 

Thank you for taking the time to take a look and respond, it's appreciated 

As stated in the post, I've ruled out bad cabling/hardware.

----------

## pietinger

Here is an article saying cable tester said OK but it wasnt: http://www.linux-databook.info/?page_id=4371

And here its a problem with the switch: https://extremeportal.force.com/ExtrArticleDetail?an=000076190

And last but not least it could be a problem with the firmware. Its an IGB ... I hear sometimes problems with it.

----------

## HealerLFG

To humor you, new cabling didn't work.

A switch/nic imcompatibility us not the issue either.  It wouldn't be "working for months" >world update > "not working properly" if that were the case.

----------

## pietinger

May I ask you which kernel version do you use ?

Is IGB at the moment configured as module or static ?

How do you load firmware into kernel ?

----------

## HealerLFG

I use latest Zen-sources, but  I also tested it with the latest gentoo-sources and the result is the same.  

In both cases, I use built-in drivers, not modules.

----------

## pietinger

 *HealerLFG wrote:*   

> [...] latest gentoo-sources [...]

 

This means 5.17.2 ? (There was a HUGE update from 5.17.1; very seldom; some reverts)

And does IGB needs external firmware ?

----------

## pietinger

You also said that it worked with old kernel version. If you now boot this old kernel, is it okay ?

If yes, it is the kernel.

If no, your card has just "died" at the moment of update.

----------

## HealerLFG

AFAIK, igb doesn't need anything special although I do have linux-firmware installed.

----------

## HealerLFG

 *pietinger wrote:*   

> You also said that it worked with old kernel version. If you now boot this old kernel, is it okay ?
> 
> If yes, it is the kernel.
> 
> If no, your card has just "died" at the moment of update.

 

Mighty bold assumptions.  Hardware *is not the issue*.  

as stated in the post, it works on the live CD.  While the gentoo install media are excellent, they wouldn't magically fix hardware issues   :Wink: 

I may not have been clear, but I tried Gentoo sources *in addition* to zen-sources.  Neither work.  And neither the kernel nor firmware were touched by the update, so It is unlikely that either of those are the issue here.

----------

## pietinger

This is the reason I asked for your firmware. It is possible that our LiveCD loads the correct firmware, and you havent installed the correct firmware in gentoo sources AND zen kernel ...

----------

## HealerLFG

 *pietinger wrote:*   

> This is the reason I asked for your firmware. It is possible that our LiveCD loads the correct firmware, and you havent installed the correct firmware in gentoo sources AND zen kernel ...

 

I do not have the firmware info on hand, but the first thing I checked was to see if anything was unmerged as part of the world update, and it was not.  Again  It was previously in a working state on the machine for months.  for that reason, I do not suspect that it's a firmware issue either.

----------

## pietinger

 *HealerLFG wrote:*   

> [...] Again  It was previously in a working state on the machine for months.  for that reason, I do not suspect that it's a firmware issue either.

 

There are many chances to change something. Only one example: If you had IGB as module before and then changed it to static, there is a big difference with handling the firmware:

a) When it is a module, the kernel is able (and does it) to load firmware from root partition /lib/firmware at BOOT TIME.

b) When it is static in the kernel, firmware must be put INTO the kernel (as blob) at COMPILE TIME. Therefore you need additionaly configuration. See my lines for example:

```
#

# Firmware loader

#

CONFIG_FW_LOADER=y

CONFIG_EXTRA_FIRMWARE="i915/skl_dmc_ver1_27.bin intel-ucode/06-5e-03"

CONFIG_EXTRA_FIRMWARE_DIR="/lib/firmware
```

Many kernel modules telling you what they want to have: e.g. STATIC WiFi modules say in systemlog "...wanted to load blabla but not in kernel error -2" if they need it and you havent configured it ... I have heard some modules dont do this. There is a neighbour thread with an IGC ... 

So, to find out what it is you have to check ALL changes you have done between WORKING kernel and today ...

----------

## HealerLFG

Once again, as stated in the post, I have made ZERO changes to kernel/firmware between the time it was normal and the time I am having issues......

It was initially, and always has been, compiled in as a module with zero issues.

----------

## Hu

If you boot the LiveCD, but tell it to mount your hard drive instead of the LiveCD environment, does it work?  That would be a LiveCD kernel with the current userspace tools.  From your first post, we would expect that to fail.

If you boot from the installed kernel and installed userspace, but stop in single user mode and bring the network up manually using ip commands, what speeds does ethtool report?  This could rule in or out any automated (mis)configuration from systemd/NetworkManager.

----------

## HealerLFG

 *Hu wrote:*   

> If you boot the LiveCD, but tell it to mount your hard drive instead of the LiveCD environment, does it work?  That would be a LiveCD kernel with the current userspace tools.  From your first post, we would expect that to fail.
> 
> If you boot from the installed kernel and installed userspace, but stop in single user mode and bring the network up manually using ip commands, what speeds does ethtool report?  This could rule in or out any automated (mis)configuration from systemd/NetworkManager.

 

Thank you for taking a peek and reaching out, it's appreciated.

I did not get a chance to do that, as it seems to have resolved after another world update.  Notably, a large portion of KDE packages (including network manager) were updated again.  Not only did they show an update, they also showed up as (rU) when updating in portage, automatically forcing a reinstall instead of just an upgrade.  I waited a bit to get back to this thread to see if it would stay fixed, and that seems to be the case.  That points to the issue being somewhere in userspace as Hu suggested, not a firmware or hardware issue.

Still, if anyone wants my logs to find out exactly *what* happened in case they want to know for anything else, I'd be happy to provide them.  Thanks everyone for the help.

----------

