1

I have a dual boot set up with Ubuntu 18.04 and 22.04. When I log in 18.04 the wired connection in the network settings shows a Link speed of 1000 Mb/s, while in 22.04 it shows 100 Mb/s.

Info on Ubuntu 22.04:

> uname -a

Linux cc 5.19.0-35-generic #36~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Fri Feb 17 15:17:25 UTC 2 x86_64 x86_64 x86_64 GNU/Linux

> sudo lshw -C network

-network
description: Wireless interface product: RTL8812AE 802.11ac PCIe Wireless Network Adapter vendor: Realtek Semiconductor Co., Ltd. physical id: 0 bus info: pci@0000:07:00.0 logical name: wlp7s0 version: 01 serial: d0:37:45:4c:0f:b3 width: 64 bits clock: 33MHz capabilities: pm msi pciexpress bus_master cap_list ethernet physical wireless configuration: broadcast=yes driver=rtl8821ae driverversion=5.19.0-35-generic firmware=N/A latency=0 link=no multicast=yes wireless=IEEE 802.11 resources: irq:79 ioport:e000(size=256) memory:fcb00000-fcb03fff
-network description: Ethernet interface product: RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller vendor: Realtek Semiconductor Co., Ltd. physical id: 0 bus info: pci@0000:08:00.0 logical name: enp8s0 version: 15 serial: 04:d9:f5:76:15:b0 size: 100Mbit/s capacity: 1Gbit/s width: 64 bits clock: 33MHz capabilities: pm msi pciexpress msix bus_master cap_list ethernet physical tp mii 10bt 10bt-fd 100bt 100bt-fd 1000bt-fd autonegotiation configuration: autonegotiation=on broadcast=yes driver=r8169 driverversion=5.19.0-35-generic duplex=full firmware=rtl8168h-2_0.0.2 02/26/15 ip=192.168.0.100 latency=0 link=yes multicast=yes port=twisted pair speed=100Mbit/s resources: irq:39 ioport:d000(size=256) memory:fca04000-fca04fff memory:fca00000-fca03fff

> sudo ethtool enp8s0

Settings for enp8s0: Supported ports: [ TP MII ] Supported link modes: 10baseT/Half 10baseT/Full 100baseT/Half 100baseT/Full 1000baseT/Full Supported pause frame use: Symmetric Receive-only Supports auto-negotiation: Yes Supported FEC modes: Not reported Advertised link modes: 100baseT/Full Advertised pause frame use: Symmetric Receive-only Advertised auto-negotiation: Yes Advertised FEC modes: Not reported Link partner advertised link modes: 10baseT/Half 10baseT/Full 100baseT/Half 100baseT/Full 1000baseT/Half 1000baseT/Full Link partner advertised pause frame use: Symmetric Receive-only Link partner advertised auto-negotiation: Yes Link partner advertised FEC modes: Not reported Speed: 100Mb/s Duplex: Full Auto-negotiation: on master-slave cfg: preferred slave master-slave status: slave Port: Twisted Pair PHYAD: 0 Transceiver: external MDI-X: Unknown Supports Wake-on: pumbg Wake-on: d Link detected: yes

> sudo ethtool -i enp8s0

version: 5.19.0-35-generic firmware-version: rtl8168h-2_0.0.2 02/26/15 expansion-rom-version: bus-info: 0000:08:00.0 supports-statistics: yes supports-test: no supports-eeprom-access: no supports-register-dump: yes supports-priv-flags: no

> lspci | awk '/[Nn]et/ {print $1}' | xargs -i% lspci -ks %

07:00.0 Network controller: Realtek Semiconductor Co., Ltd. RTL8812AE 802.11ac PCIe Wireless Network Adapter (rev 01) Subsystem: Realtek Semiconductor Co., Ltd. RTL8812AE 802.11ac PCIe Wireless Network Adapter Kernel driver in use: rtl8821ae Kernel modules: rtl8821ae 08:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller (rev 15) Subsystem: ASUSTeK Computer Inc. PRIME B450M-A Motherboard Kernel driver in use: r8169 Kernel modules: r8169

> sudo dmesg | grep r8169 # the up and down links are me setting the speed to 1000 and 100

[ 1.021751] r8169 0000:08:00.0 eth0: RTL8168h/8111h, 04:d9:f5:76:15:b0, XID 541, IRQ 54 [ 1.021756] r8169 0000:08:00.0 eth0: jumbo features [frames: 9194 bytes, tx checksumming: ko] [ 2.775004] r8169 0000:08:00.0 enp8s0: renamed from eth0 [ 5.878614] Generic FE-GE Realtek PHY r8169-0-800:00: attached PHY driver (mii_bus:phy_addr=r8169-0-800:00, irq=MAC) [ 6.066748] r8169 0000:08:00.0 enp8s0: Link is Down [ 22.934280] Generic FE-GE Realtek PHY r8169-0-800:00: Downshift occurred from negotiated speed 1Gbps to actual speed 100Mbps, check cabling! [ 22.934294] r8169 0000:08:00.0 enp8s0: Link is Up - 100Mbps/Full (downshifted) - flow control rx/tx [ 298.818969] r8169 0000:08:00.0 enp8s0: Link is Down [ 325.940383] r8169 0000:08:00.0 enp8s0: Link is Down [ 344.602188] Generic FE-GE Realtek PHY r8169-0-800:00: Downshift occurred from negotiated speed 1Gbps to actual speed 100Mbps, check cabling! [ 344.602201] r8169 0000:08:00.0 enp8s0: Link is Up - 100Mbps/Full (downshifted) - flow control rx/tx [ 892.022066] r8169 0000:08:00.0 enp8s0: Link is Down [ 1021.829180] r8169 0000:08:00.0 enp8s0: Link is Down [ 1033.732636] r8169 0000:08:00.0 enp8s0: Link is Down [ 1070.106381] r8169 0000:08:00.0 enp8s0: Link is Down [ 1082.716879] r8169 0000:08:00.0 enp8s0: Link is Down [ 1085.513138] r8169 0000:08:00.0 enp8s0: Link is Up - 100Mbps/Full - flow control rx/tx [ 1485.561946] r8169 0000:08:00.0 enp8s0: Link is Down [ 1587.331448] r8169 0000:08:00.0 enp8s0: Link is Down [ 1590.190212] r8169 0000:08:00.0 enp8s0: Link is Up - 100Mbps/Full - flow control rx/tx [ 1674.111292] r8169 0000:08:00.0 enp8s0: Link is Down [ 1843.666686] r8169 0000:08:00.0 enp8s0: Link is Down [ 1846.453070] r8169 0000:08:00.0 enp8s0: Link is Up - 100Mbps/Full - flow control rx/tx [ 2403.530799] r8169 0000:08:00.0 enp8s0: Link is Down [ 2439.863622] r8169 0000:08:00.0 enp8s0: Link is Down [ 2442.743673] r8169 0000:08:00.0 enp8s0: Link is Up - 100Mbps/Full - flow control rx/tx [ 2453.224431] r8169 0000:08:00.0 enp8s0: Link is Down [ 2457.465233] r8169 0000:08:00.0 enp8s0: Link is Down [ 2550.292449] r8169 0000:08:00.0 enp8s0: Link is Down [ 2553.750133] r8169 0000:08:00.0 enp8s0: Link is Up - 100Mbps/Full - flow control rx/tx [ 2602.361706] r8169 0000:08:00.0 enp8s0: Link is Down [ 2692.932207] r8169 0000:08:00.0 enp8s0: Link is Down [ 2695.792083] r8169 0000:08:00.0 enp8s0: Link is Up - 100Mbps/Full - flow control rx/tx

> ip link | grep enpip # on speed 100

2: enp8s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP mode DEFAULT group default qlen 1000

I already tried running sudo ethtool -s enp8s0 speed 1000 autoneg off duplex full, but it kills my connection when I do so.

> sudo ethtool enp8s0 # on speed 1000

Settings for enp8s0: Supported ports: [ TP MII ] Supported link modes: 10baseT/Half 10baseT/Full 100baseT/Half 100baseT/Full 1000baseT/Full Supported pause frame use: Symmetric Receive-only Supports auto-negotiation: Yes Supported FEC modes: Not reported Advertised link modes: 100baseT/Full Advertised pause frame use: Symmetric Receive-only Advertised auto-negotiation: No Advertised FEC modes: Not reported Speed: 1000Mb/s Duplex: Full Auto-negotiation: off master-slave cfg: preferred slave master-slave status: unknown Port: Twisted Pair PHYAD: 0 Transceiver: external MDI-X: Unknown Supports Wake-on: pumbg Wake-on: d Link detected: no

> ip link | grep enp # on speed 1000

2: enp8s0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc fq_codel state DOWN mode DEFAULT group default qlen 1000

My connection only comes back when I set the speed to 100 using ethtool -s. I'm ruling out hardware problems because the link works at 1000 Mb/s in the same machine when I boot in Ubuntu 18.04.

How can I make it run at 1000 Mb/s in Ubuntu 22.04?


Edit:

I ran:

> sudo apt install r8168-dkms
> sudo rmmod r8169
rmmod: ERROR: Module r8169 is not currently loaded

>echo "blacklist r8169" | sudo tee -a /etc/modprobe.d/blacklist.conf blacklist r8169

And performed a hard power cycle. These are the differences in the logs (basically just changed a few places from r8169 to r8168) but the problem persists:

> sudo lshw -C network

-network
description: Wireless interface product: RTL8812AE 802.11ac PCIe Wireless Network Adapter vendor: Realtek Semiconductor Co., Ltd. physical id: 0 bus info: pci@0000:07:00.0 logical name: wlp7s0 version: 01 serial: d0:37:45:4c:0f:b3 width: 64 bits clock: 33MHz capabilities: pm msi pciexpress bus_master cap_list ethernet physical wireless configuration: broadcast=yes driver=rtl8821ae driverversion=5.19.0-35-generic firmware=N/A latency=0 link=no multicast=yes wireless=IEEE 802.11 resources: irq:79 ioport:e000(size=256) memory:fcb00000-fcb03fff
-network description: Ethernet interface product: RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller vendor: Realtek Semiconductor Co., Ltd. physical id: 0 bus info: pci@0000:08:00.0 logical name: enp8s0 version: 15 serial: 04:d9:f5:76:15:b0 size: 100Mbit/s capacity: 1Gbit/s width: 64 bits clock: 33MHz capabilities: pm msi pciexpress msix bus_master cap_list ethernet physical tp 10bt 10bt-fd 100bt 100bt-fd 1000bt-fd autonegotiation configuration: autonegotiation=on broadcast=yes driver=r8168 driverversion=8.049.02-NAPI duplex=full ip=192.168.0.100 latency=0 link=yes multicast=yes port=twisted pair speed=100Mbit/s resources: irq:46 ioport:d000(size=256) memory:fca04000-fca04fff memory:fca00000-fca03fff

> sudo ethtool enp8s0

Settings for enp8s0: Supported ports: [ TP ] Supported link modes: 10baseT/Half 10baseT/Full 100baseT/Half 100baseT/Full 1000baseT/Full Supported pause frame use: Symmetric Receive-only Supports auto-negotiation: Yes Supported FEC modes: Not reported Advertised link modes: 100baseT/Full Advertised pause frame use: Symmetric Receive-only Advertised auto-negotiation: Yes Advertised FEC modes: Not reported Link partner advertised link modes: 10baseT/Half 10baseT/Full 100baseT/Half 100baseT/Full 1000baseT/Half 1000baseT/Full Link partner advertised pause frame use: Symmetric Receive-only Link partner advertised auto-negotiation: Yes Link partner advertised FEC modes: Not reported Speed: 100Mb/s Duplex: Full Auto-negotiation: on Port: Twisted Pair PHYAD: 0 Transceiver: internal MDI-X: Unknown Supports Wake-on: pumbg Wake-on: g Current message level: 0x00000033 (51) drv probe ifdown ifup Link detected: yes

> sudo ethtool -i enp8s0

driver: r8168 version: 8.049.02-NAPI firmware-version: expansion-rom-version: bus-info: 0000:08:00.0 supports-statistics: yes supports-test: no supports-eeprom-access: no supports-register-dump: yes supports-priv-flags: no

> lspci | awk '/[Nn]et/ {print $1}' | xargs -i% lspci -ks %

07:00.0 Network controller: Realtek Semiconductor Co., Ltd. RTL8812AE 802.11ac PCIe Wireless Network Adapter (rev 01) Subsystem: Realtek Semiconductor Co., Ltd. RTL8812AE 802.11ac PCIe Wireless Network Adapter Kernel driver in use: rtl8821ae Kernel modules: rtl8821ae 08:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller (rev 15) Subsystem: ASUSTeK Computer Inc. PRIME B450M-A Motherboard Kernel driver in use: r8168 Kernel modules: r8168

> sudo ethtool enp8s0 # on speed 1000

Settings for enp8s0: Supported ports: [ TP ] Supported link modes: 10baseT/Half 10baseT/Full 100baseT/Half 100baseT/Full 1000baseT/Full Supported pause frame use: Symmetric Receive-only Supports auto-negotiation: Yes Supported FEC modes: Not reported Advertised link modes: 1000baseT/Full Advertised pause frame use: No Advertised auto-negotiation: Yes Advertised FEC modes: Not reported Speed: Unknown! Duplex: Unknown! (255) Auto-negotiation: on Port: Twisted Pair PHYAD: 0 Transceiver: internal MDI-X: Unknown Supports Wake-on: pumbg Wake-on: g Current message level: 0x00000033 (51) drv probe ifdown ifup

2 Answers2

2

I did manage to solve it by following these steps in this exact order using 5.19 kernel:

  1. Download "GBE Ethernet LINUX driver r8168 for kernel up to 5.19" from https://www.realtek.com/en/component/zoo/category/network-interface-controllers-10-100-1000m-gigabit-ethernet-pci-express-software
  2. Extract it and run the autorun.sh file as sudo
  3. Restart the computer
  4. Run sudo ethtool -s enp8s0 speed 1000 autoneg on duplex full
  5. Unplug the Ethernet cable and replug it

I'm not sure which of these steps were or weren't necessary, but now it looks like it's working.


Edit

I also followed https://askubuntu.com/a/1334101/231142 as suggested by @Terrance in the comments.

0

This seems to have been fixed in the latest updates for Ubuntu 22.04. I've just installed kernel 5.19.0-38 and that has brought the speed back to 1 GB on my r8168. Tested transferring files to a memory card, seeing up to 500 Mb speeds (HD read speed limited).

David DE
  • 2,316