Ethernet does not work (neither through router nor Wifi). Both work on Windows and I can connect to other WiFi

TLDR: Internet stopped randomly working a few weeks ago. I was using ethernet connected to my router. Tried resetting, reconnecting, changing settings etc and nothing worked. Directly using the ethernet cable also did not work. When I remove all connections or reboot sometimes it works for a minute before it stops again. Ethernet works on Windows through the router so it can’t be the cable or the router per se. Using other WiFi works so I think it might be Manjaro in regards to the specific router and ethernet connection. Different kernels also don’t work, not sure if the problem appeared after a kernel update back then.

A few potential problems that could be causing it after spending hours and hours reading stuff:

  • MAC address: I initially setup the router on my old Laptop. Somewhere in the manuals I think I read that the initial MAC is used by the router/ISP to ensure connection, but not sure if resetting should have solved it.
  • DNS server: I played around using different DNS servers. Sometimes it is the case that only google works, but as soon as I click a link it does not anymore. I’d be really interested in finding out what the actual correct settings for this are (IPv4 Method Automatic/Automatic (Addresses only), checking ‘IPv4 is required for this connection’, etc)
  • NetworkManager: restarting systemctl NetworkManager sometimes makes it work for a min. Afraid that rebooting resets some settings and that’s why it doesn’t work
  • Windows fast boot and BIOS: have read that this could also be a cause. Would rather not play with this as I am a noob.
inxi -Fazy
System:
  Kernel: 5.14.10-1-MANJARO x86_64 bits: 64 compiler: gcc v: 11.1.0
  parameters: BOOT_IMAGE=/boot/vmlinuz-5.14-x86_64
  root=UUID=06b30e92-62c4-4993-afc5-418fe5fc2094 rw quiet apparmor=1
  security=apparmor resume=UUID=52d25d71-bf36-4947-a3e9-d0c34a77d656
  udev.log_priority=3
  Desktop: KDE Plasma 5.22.5 tk: Qt 5.15.2 wm: kwin_x11 vt: 1 dm: SDDM
  Distro: Manjaro Linux base: Arch Linux
Machine:
  Type: Desktop Mobo: Micro-Star model: B450 TOMAHAWK MAX (MS-7C02) v: 1.0
  serial: <filter> UEFI: American Megatrends v: 3.70 date: 06/09/2020
CPU:
  Info: 8-Core model: AMD Ryzen 7 3700X bits: 64 type: MT MCP arch: Zen 2
  family: 17 (23) model-id: 71 (113) stepping: 0 microcode: 8701021 cache:
  L2: 4 MiB
  flags: avx avx2 lm nx pae sse sse2 sse3 sse4_1 sse4_2 sse4a ssse3 svm
  bogomips: 115250
  Speed: 4221 MHz min/max: 2200/3600 MHz boost: enabled Core speeds (MHz):
  1: 4221 2: 2301 3: 2406 4: 2110 5: 2494 6: 2347 7: 2840 8: 2130 9: 2126
  10: 2137 11: 2763 12: 2310 13: 2253 14: 2142 15: 4188 16: 2808
  Vulnerabilities: Type: itlb_multihit status: Not affected
  Type: l1tf status: Not affected
  Type: mds status: Not affected
  Type: meltdown status: Not affected
  Type: spec_store_bypass
  mitigation: Speculative Store Bypass disabled via prctl and seccomp
  Type: spectre_v1
  mitigation: usercopy/swapgs barriers and __user pointer sanitization
  Type: spectre_v2 mitigation: Full AMD retpoline, IBPB: conditional, STIBP:
  conditional, RSB filling
  Type: srbds status: Not affected
  Type: tsx_async_abort status: Not affected
Graphics:
  Device-1: NVIDIA GP104 [GeForce GTX 1070] vendor: ZOTAC driver: nvidia
  v: 470.63.01 alternate: nouveau,nvidia_drm bus-ID: 26:00.0
  chip-ID: 10de:1b81 class-ID: 0300
  Device-2: Sunplus Innovation EKACOM-K50E type: USB
  driver: snd-usb-audio,uvcvideo bus-ID: 3-2:3 chip-ID: 1bcf:2cb4
  class-ID: 0102 serial: <filter>
  Display: x11 server: X.Org 1.20.13 compositor: kwin_x11 driver:
  loaded: nvidia display-ID: :0 screens: 1
  Screen-1: 0 s-res: 3840x2160 s-dpi: 162 s-size: 602x341mm (23.7x13.4")
  s-diag: 692mm (27.2")
  Monitor-1: DP-2 res: 3840x2160 hz: 60 dpi: 163 size: 600x340mm (23.6x13.4")
  diag: 690mm (27.2")
  OpenGL: renderer: NVIDIA GeForce GTX 1070/PCIe/SSE2
  v: 4.6.0 NVIDIA 470.63.01 direct render: Yes
Audio:
  Device-1: NVIDIA GP104 High Definition Audio vendor: ZOTAC
  driver: snd_hda_intel v: kernel bus-ID: 26:00.1 chip-ID: 10de:10f0
  class-ID: 0403
  Device-2: AMD Starship/Matisse HD Audio vendor: Micro-Star MSI
  driver: snd_hda_intel v: kernel bus-ID: 28:00.4 chip-ID: 1022:1487
  class-ID: 0403
  Device-3: Sunplus Innovation EKACOM-K50E type: USB
  driver: snd-usb-audio,uvcvideo bus-ID: 3-2:3 chip-ID: 1bcf:2cb4
  class-ID: 0102 serial: <filter>
  Sound Server-1: ALSA v: k5.14.10-1-MANJARO running: yes
  Sound Server-2: JACK v: 1.9.19 running: no
  Sound Server-3: PulseAudio v: 15.0 running: yes
  Sound Server-4: PipeWire v: 0.3.38 running: no
Network:
  Device-1: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet
  vendor: Micro-Star MSI driver: r8169 v: kernel port: f000 bus-ID: 22:00.0
  chip-ID: 10ec:8168 class-ID: 0200
  IF: enp34s0 state: up speed: 100 Mbps duplex: full mac: <filter>
  Device-2: Belkin F7D2102 802.11n N300 Micro Wireless Adapter v3000 [Realtek
  RTL8192CU]
  type: USB driver: rtl8192cu bus-ID: 3-1:6 chip-ID: 050d:2103 class-ID: 0000
  serial: <filter>
  IF: wlp40s0f3u1 state: up mac: <filter>
Drives:
  Local Storage: total: 931.51 GiB used: 320.61 GiB (34.4%)
  SMART Message: Unable to run smartctl. Root privileges required.
  ID-1: /dev/nvme0n1 maj-min: 259:0 vendor: Kingston model: SA2000M81000G
  size: 931.51 GiB block-size: physical: 512 B logical: 512 B speed: 31.6 Gb/s
  lanes: 4 type: SSD serial: <filter> rev: S5Z42105 temp: 34.9 C scheme: GPT
Partition:
  ID-1: / raw-size: 413.91 GiB size: 406.41 GiB (98.19%)
  used: 319.25 GiB (78.6%) fs: ext4 dev: /dev/nvme0n1p6 maj-min: 259:6
  ID-2: /boot/efi raw-size: 100 MiB size: 96 MiB (96.00%)
  used: 25.1 MiB (26.1%) fs: vfat dev: /dev/nvme0n1p2 maj-min: 259:2
Swap:
  Kernel: swappiness: 60 (default) cache-pressure: 100 (default)
  ID-1: swap-1 type: partition size: 16.6 GiB used: 1.33 GiB (8.0%)
  priority: -2 dev: /dev/nvme0n1p5 maj-min: 259:5
Sensors:
  System Temperatures: cpu: 49.4 C mobo: N/A gpu: nvidia temp: 39 C
  Fan Speeds (RPM): N/A gpu: nvidia fan: 41%
Info:
  Processes: 336 Uptime: 1h 43m wakeups: 0 Memory: 15.58 GiB
  used: 10.02 GiB (64.3%) Init: systemd v: 249 tool: systemctl Compilers:
  gcc: 11.1.0 alt: 10 Packages: 1562 pacman: 1550 lib: 429 flatpak: 0 snap: 12
  Shell: Bash v: 5.1.8 running-in: yakuake inxi: 3.3.08

I’ve been battling this problem for multiple weeks now, tried all kinds of things which did not work and my only solution was to work on my Windows partition. At my wits end, would really appreciate any help!

I seem to have a similar network adapter, and my problem is the same.

1 Like

There are several posts on the internet with an equal problem … but most older. In the most places they say that the ‘r8169-driver’ not worked well with ‘Realtek RTL8111/8168/8411’.

So you could try to install the ‘r8168-driver’. There is a package in the repos called ‘linux514-r8168 8.049.02-13’.

2 Likes

Thanks a lot for the help! Truly incredible how you could find that.

It seems to be going in the right direction. When I installed it yesterday it worked. Today I turned on my PC again at which point it did not work. I reinstalled the package and restarted and now it seems to be working again. Not sure if that’s due to the restarting or the reinstallation.

Do I need to uninstall any other/older drivers so that Manjaro knows to only use the r8168 one?

Try and blacklist the r8169 driver.

in /etc/modprobe.d/ create a file called r8169_blacklist.conf or similar. In that file type
blacklist r8169 and save the file. You will need to reboot for the change to take effect.

3 Likes

Nice to hear! Yes blacklist the r8169 driver like @jrichard326 said should help. Unistall this driver would not work because I think its a inbuild Kernel driver. :grinning:

1 Like

@jrichard326, @kisun Thanks to the both of you! I set up the blacklist. Wanted to wait and see if the problem’s gone for good, but it seems like shutting off/using Windows must mix up something as the error reoccured today :frowning: Google worked, but other websites did not. Was able to fix it by reinstalling the r8168 package, but now it seems like it still stops working for no reason at times…

Hello @king,

could you reboot so that the error occur and do an ‘inxi -Nxa’ and post the output here, so that we can check if the blacklist works. :grinning:

inxi -Nxa
1 Like

At some point, you have to cut your losses unless you have unlimited time. I would buy a USB 3.0 ethernet adapter, preferably with an ASIX AX88179 chip, which will work out of the box and not look back.

1 Like

I take it the blacklist didn’t work as it still shows up under modules?

inxi -Nxa
Network:   Device-1: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet vendor: Micro-Star MSI driver: r8168
           v: 8.049.02-NAPI modules: r8169 port: f000 bus-ID: 22:00.0 chip-ID: 10ec:8168 class-ID: 0200
           Device-2: Belkin F7D2102 802.11n N300 Micro Wireless Adapter v3000 [Realtek RTL8192CU] type: USB driver: rtl8192cu
           bus-ID: 3-1:2 chip-ID: 050d:2103 class-ID: 0000 serial: 00e04c000001

cat /etc/modprobe.d/r8169_blacklist.conf 
# https://forum.manjaro.org/t/ethernet-does-not-work-neither-through-router-nor-wifi-both-work-on-windows-and-i-can-connect-to-other-wifi/89283/3
blacklist r8169

Could be, but I dont really know cause its above knowledge.

Please read the Ach Wiki Section for Blacklisting and especially the ‘Note:’ Section. Perhaps this way of ‘blacklist’ work more.

1 Like

Are you certain that you have installed the r8168 driver successfully? Does it show up if you run

lsmod

Please see section beginning with “Realtek no link / WOL problem” at the link below. It may be of some help:

https://wiki.archlinux.org/title/Network_configuration/Ethernet

“Windows fast boot and BIOS: have read that this could also be a cause. Would rather not play with this as I am a noob.”

The above could be a lot of the problem here. Fast boot, hybrid sleep and Windows hibernation need to be disabled and Windows always needs to be shutdown completely in a dual boot setup. I would ask myself if you really do need dual boot or can you get by with Windows running in a virtual machine and avoid all of these headaches.

Some basic information here:

Please see section regarding Windows 10 preparation.

3 Likes

Another thought: Are the kernel headers installed? In this case, linux514-headers.

1 Like

Hey man, I just wanted to thank you again and really appreciate your help!

I think it should be running, though I’m also confused why r8169 shows up here

lsmod | grep r816
r8168                 561152  0
r8169                  98304  0
mdio_devres            16384  1 r8169
libphy                159744  3 r8169,mdio_devres,realtek

and here (now driver is 69 while module is 68 while with ‘blacklist r8169’ it was the other way around)

inxi -Nxa
Network:   Device-1: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet vendor: Micro-Star MSI driver: r8169 v: kernel
           modules: r8168 port: f000 bus-ID: 22:00.0 chip-ID: 10ec:8168 class-ID: 0200
           Device-2: Belkin F7D2102 802.11n N300 Micro Wireless Adapter v3000 [Realtek RTL8192CU] type: USB driver: rtl8192cu
           bus-ID: 3-1:2 chip-ID: 050d:2103 class-ID: 0000 serial: 00e04c000001

I have blacklisted it according to the new link of @kisun (thanks for that!)

cat /etc/modprobe.d/r8169_blacklist.conf 
# https://forum.manjaro.org/t/ethernet-does-not-work-neither-through-router-nor-wifi-both-work-on-windows-and-i-can-connect-to-other-wifi/89283/3
#blacklist r8169
install r8169 /bin/true

Realtek no link / WOL problem

I tried out “Enable WOL in Windows driver” which was already enabled, didn’t try the other two options which I might come back to later.

I looked at the Dual Boot link and disabled fast startup and hibernation completely. I’ve tried to recreate the problem twice now and I think that might have fixed it. (Also tried only disabling fast startup which did not work). I’ll come back to you tomorrow and let you know if I am able to reproduce the error! If this is only it, might be able to use r8169 but will also test that tomorrow.

linux514-headers is not installed. If it works, should I still install it?

Also found this: Internet works on wifi, live ISO and Windows laptop but wont work on ethernet on current system - #7 by megavolt

1 Like

headers should be installed as they are a dependency of r8168

The NIC mac-address usually doesn’t change (it can be change but there is really no need)

This can cause issues - the network is extremely sensitive to errors in DNS

:man_shrugging:

No - the only thing which can cause interference is the system time

IPv6 can cause dysfunctional network - so unless you have very specific requirements - I suggest you disable IPv6 - IPv6 - ArchWiki

Edit the grub defaults file (install the package micro if you don’t have it)

sudo micro /etc/default/grub

Add ipv6.disable=1 to default cmdline

GRUB_CMDLINE_LINUX_DEFAULT="...  ipv6.disable=1  ..."

Hit Ctrls to save and Ctrlq to exit and rebuild

sudo grub-mkconfig -o /boot/grub/grub.cfg

Edit the hosts file and comment the line on IPv6 linke below

sudo micro /etc/hosts
#::1        localhost ip6-localhost ip6-loopback
#ff02::1    ip6-allnodes
#ff02::2    ip6-allrouters

Hit Ctrls to save and Ctrlq to exit and rebuild

Reboot your system and recheck

Also you shouldn’t have to blacklist r8169 - the kernel driver has been good for a very long time

1 Like

Thanks for the help! Tried to switch to this approach, but it unfortunately also doesn’t seem to be working.

Something that is always common is that when it turns on, it works for a minute and then stops working. At times google being the only website that works.

Reinstalling r8168 does seem to make it work for a day/until I shut it off. Are you sure that r8169 shouldn’t be the root cause? Due to the fact that it works for a minute and then stops working I’m afraid that maybe the networkmanager (or smth like that) loads/changes something which then makes it stop working…

Same problem but my network card is an Intel

lspci -v
00:1f.6 Ethernet controller: Intel Corporation Ethernet Connection (13) I219-V (rev 20)
        Subsystem: Lenovo Device 22d1
        Flags: bus master, fast devsel, latency 0, IRQ 174, IOMMU group 14
        Memory at bce00000 (32-bit, non-prefetchable) [size=128K]
        Capabilities: <access denied>
        Kernel driver in use: e1000e
        Kernel modules: e1000e

sudo dmesg | grep e1000e
[    2.036908] e1000e: Intel(R) PRO/1000 Network Driver
[    2.036909] e1000e: Copyright(c) 1999 - 2015 Intel Corporation.
[    2.037476] e1000e 0000:00:1f.6: Interrupt Throttling Rate (ints/sec) set to dynamic conservative mode
[    2.485702] e1000e 0000:00:1f.6 0000:00:1f.6 (uninitialized): registered PHC clock
[    2.561798] e1000e 0000:00:1f.6 eth0: (PCI Express:2.5GT/s:Width x1) 38:f3:ab:4c:6e:f5
[    2.561808] e1000e 0000:00:1f.6 eth0: Intel(R) PRO/1000 Network Connection
[    2.562417] e1000e 0000:00:1f.6 eth0: MAC: 14, PHY: 12, PBA No: FFFFFF-0FF
[    2.580315] e1000e 0000:00:1f.6 enp0s31f6: renamed from eth0

reference:
https://bugzilla.kernel.org/show_bug.cgi?id=213481