RealTek Network card not working

FATAL

root@zorin:~# sudo depmod -a
root@zorin:~# sudo modprobe r8821
modprobe: FATAL: Module r8821 not found in directory /lib/modules/5.15.0-56-generic
root@zorin:~# sudo modprobe r8821ce-dkms
modprobe: FATAL: Module r8821ce-dkms not found in directory /lib/modules/5.15.0-56-generic
root@zorin:~#

Maybe check, using your file manager, this location

  • Installation
    • Installing to /lib/modules/5.15.0-56-generic/updates/

versus this location

  • not found in directory /lib/modules/5.15.0-56-generic

/lib/modules/5.15.0-56-generic/updates/ contains just one thing:

  • rtl8821ce.ko

/lib/modules/5.15.0-56-generic contains 5 folders (build, initrd, kernel, updates, vdso) and 13 files all starting "module...".

What if you copy rtl8821ce.ko from the updates folder into the /lib/modules/5.15.0-56-generic folder, then modprobe it...

After using Thunar as root to copy the file to other folder:

zorin@zorin:~$ sudo -i
root@zorin:~# thunar
root@zorin:~# modprobe r8821
modprobe: FATAL: Module r8821 not found in directory /lib/modules/5.15.0-56-generic
root@zorin:~# modprobe rtl8821ce
root@zorin:~#

So at least modprobe rtl8821ce doesn't give a fatal error, just... nothing? Looking at the Network icon, still no Wifi.

Can you run

lshw -C network

again?


root@zorin:~# lshw -C network
  *-network UNCLAIMED       
       description: Network controller
       product: Realtek Semiconductor Co., Ltd.
       vendor: Realtek Semiconductor Co., Ltd.
       physical id: 0
       bus info: pci@0000:03:00.0
       version: 00
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress cap_list
       configuration: latency=0
       resources: ioport:1000(size=256) memory:a1100000-a11fffff
  *-network
       description: Ethernet interface
       physical id: 3
       bus info: usb@1:8
       logical name: usb0
       serial: d6:bd:6e:ad:df:a8
       capabilities: ethernet physical
       configuration: autonegotiation=off broadcast=yes driver=rndis_host driverversion=5.15.0-56-generic duplex=half firmware=RNDIS device ip=192.168.42.88 link=yes multicast=yes port=twisted pair
root@zorin:~#

Let's

modprobe -r rtl8821ce

sudo apt remove --purge rtl8821ce-dkms

Our Big Issue here is that it is not even identifying the device.

What is the Year Make and Model of the computer?

Summary
root@zorin:~# modprobe -r rtl8821ce
root@zorin:~# sudo apt remove --purge rtl8821ce-dkms
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following package was automatically installed and is no longer required:
  dkms
Use 'sudo apt autoremove' to remove it.
The following packages will be REMOVED:
  rtl8821ce-dkms*
0 upgraded, 0 newly installed, 1 to remove and 330 not upgraded.
After this operation, 25.2 MB disk space will be freed.
Do you want to continue? [Y/n] y
(Reading database ... 270158 files and directories currently installed.)
Removing rtl8821ce-dkms (5.5.2.1-0ubuntu4~20.04.5) ...

-------- Uninstall Beginning --------
Module:  rtl8821ce
Version: 5.5.2.1
Kernel:  5.15.0-56-generic (x86_64)
-------------------------------------

Status: Before uninstall, this module version was ACTIVE on this kernel.

rtl8821ce.ko:
 - Uninstallation
   - Deleting from: /lib/modules/5.15.0-56-generic/updates/
 - Original module
   - No original module was found for this module on this kernel.
   - Use the dkms install command to reinstall any previous module version.

/etc/modprobe.d/dkms.conf: removed 'blacklist rtw88_8821ce'
depmod...

DKMS: uninstall completed.

------------------------------
Deleting module version: 5.5.2.1
completely from the DKMS tree.
------------------------------
Done.
root@zorin:~#

Make: Lenovo
Model: Ideapad 1, 15IGL
Year: 2023

Let's try a known driver for Lenovo:
(That 2023 year bothers me)
I am assuming you are using Ethernet to connect. These are lengthy:

sudo apt clean && sudo apt autoremove && sudo apt update

sudo apt install -y git build-essential

git clone https://github.com/lwfinger/rtw89.git

cd rtw89

make

sudo make install

sudo mkdir /usr/lib/firmware/rtw89

sudo cp rtw8852a_fw.bin /usr/lib/firmware/rtw89/

sudo modprobe rtw89pci

Reboot and test...

If you are not connected to net, go to GitHub - lwfinger/rtw89: Driver for Realtek 8852AE, an 802.11ax device and manually grab the files with the green Code Button at the top right. Move it to the non functioning machine with a transfer device like USB or phone...

The first two steeps seemed to go OK but then this at the third step:

root@zorin:~# git clone https://github.com/lwfinger/rtw89.git
Cloning into 'rtw89'...
remote: Enumerating objects: 2654, done.
remote: Counting objects: 100% (503/503), done.
remote: Compressing objects: 100% (105/105), done.
error: RPC failed; curl 56 GnuTLS recv error (-54): Error in the pull function.
fatal: the remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed
root@zorin:~#

I downloaded the green code zip (rtw89-main.zip) onto relevant machine (currently tethered to phone), not sure what to do with it.

If you downloaded it as a .zip file or a compressed file, extract it. Then in terminal cd (change directory) into the new file:

cd rtw89

make

sudo make install

sudo mkdir /usr/lib/firmware/rtw89

sudo cp rtw8852a_fw.bin /usr/lib/firmware/rtw89/

sudo modprobe rtw89pci

Reboot and test...

Seems OK until step 4

zorin@zorin:~/Downloads/rtw89-main$ sudo mkdir /usr/lib/firmware/rtw89
mkdir: cannot create directory β€˜/usr/lib/firmware/rtw89’: File exists
Summary

zorin@zorin:~/Downloads$ cd rtw89-main
zorin@zorin:~/Downloads/rtw89-main$ make
make -C /lib/modules/5.15.0-56-generic/build M=/home/zorin/Downloads/rtw89-main modules
make[1]: Entering directory '/usr/src/linux-headers-5.15.0-56-generic'
CC [M] /home/zorin/Downloads/rtw89-main/core.o
CC [M] /home/zorin/Downloads/rtw89-main/chan.o
CC [M] /home/zorin/Downloads/rtw89-main/mac80211.o
CC [M] /home/zorin/Downloads/rtw89-main/mac.o
CC [M] /home/zorin/Downloads/rtw89-main/phy.o
CC [M] /home/zorin/Downloads/rtw89-main/fw.o
CC [M] /home/zorin/Downloads/rtw89-main/cam.o
CC [M] /home/zorin/Downloads/rtw89-main/efuse.o
CC [M] /home/zorin/Downloads/rtw89-main/regd.o
CC [M] /home/zorin/Downloads/rtw89-main/sar.o
CC [M] /home/zorin/Downloads/rtw89-main/acpi.o
CC [M] /home/zorin/Downloads/rtw89-main/coex.o
CC [M] /home/zorin/Downloads/rtw89-main/ps.o
CC [M] /home/zorin/Downloads/rtw89-main/debug.o
CC [M] /home/zorin/Downloads/rtw89-main/ser.o
CC [M] /home/zorin/Downloads/rtw89-main/wow.o
LD [M] /home/zorin/Downloads/rtw89-main/rtw89core.o
CC [M] /home/zorin/Downloads/rtw89-main/rtw8852a.o
CC [M] /home/zorin/Downloads/rtw89-main/rtw8852a_table.o
CC [M] /home/zorin/Downloads/rtw89-main/rtw8852a_rfk.o
CC [M] /home/zorin/Downloads/rtw89-main/rtw8852a_rfk_table.o
LD [M] /home/zorin/Downloads/rtw89-main/rtw_8852a.o
CC [M] /home/zorin/Downloads/rtw89-main/rtw8852ae.o
LD [M] /home/zorin/Downloads/rtw89-main/rtw_8852ae.o
CC [M] /home/zorin/Downloads/rtw89-main/rtw8851b.o
CC [M] /home/zorin/Downloads/rtw89-main/rtw8851b_table.o
CC [M] /home/zorin/Downloads/rtw89-main/rtw8851b_rfk.o
CC [M] /home/zorin/Downloads/rtw89-main/rtw8851b_rfk_table.o
LD [M] /home/zorin/Downloads/rtw89-main/rtw_8851b.o
CC [M] /home/zorin/Downloads/rtw89-main/rtw8851be.o
LD [M] /home/zorin/Downloads/rtw89-main/rtw_8851be.o
CC [M] /home/zorin/Downloads/rtw89-main/rtw8852b.o
CC [M] /home/zorin/Downloads/rtw89-main/rtw8852b_table.o
CC [M] /home/zorin/Downloads/rtw89-main/rtw8852b_rfk.o
CC [M] /home/zorin/Downloads/rtw89-main/rtw8852b_rfk_table.o
LD [M] /home/zorin/Downloads/rtw89-main/rtw_8852b.o
CC [M] /home/zorin/Downloads/rtw89-main/rtw8852be.o
LD [M] /home/zorin/Downloads/rtw89-main/rtw_8852be.o
CC [M] /home/zorin/Downloads/rtw89-main/rtw8852c.o
CC [M] /home/zorin/Downloads/rtw89-main/rtw8852c_table.o
CC [M] /home/zorin/Downloads/rtw89-main/rtw8852c_rfk.o
CC [M] /home/zorin/Downloads/rtw89-main/rtw8852c_rfk_table.o
LD [M] /home/zorin/Downloads/rtw89-main/rtw_8852c.o
CC [M] /home/zorin/Downloads/rtw89-main/rtw8852ce.o
LD [M] /home/zorin/Downloads/rtw89-main/rtw_8852ce.o
CC [M] /home/zorin/Downloads/rtw89-main/pci.o
LD [M] /home/zorin/Downloads/rtw89-main/rtw89pci.o
MODPOST /home/zorin/Downloads/rtw89-main/Module.symvers
CC [M] /home/zorin/Downloads/rtw89-main/rtw89core.mod.o
LD [M] /home/zorin/Downloads/rtw89-main/rtw89core.ko
BTF [M] /home/zorin/Downloads/rtw89-main/rtw89core.ko
Skipping BTF generation for /home/zorin/Downloads/rtw89-main/rtw89core.ko due to unavailability of vmlinux
CC [M] /home/zorin/Downloads/rtw89-main/rtw89pci.mod.o
LD [M] /home/zorin/Downloads/rtw89-main/rtw89pci.ko
BTF [M] /home/zorin/Downloads/rtw89-main/rtw89pci.ko
Skipping BTF generation for /home/zorin/Downloads/rtw89-main/rtw89pci.ko due to unavailability of vmlinux
CC [M] /home/zorin/Downloads/rtw89-main/rtw_8851b.mod.o
LD [M] /home/zorin/Downloads/rtw89-main/rtw_8851b.ko
BTF [M] /home/zorin/Downloads/rtw89-main/rtw_8851b.ko
Skipping BTF generation for /home/zorin/Downloads/rtw89-main/rtw_8851b.ko due to unavailability of vmlinux
CC [M] /home/zorin/Downloads/rtw89-main/rtw_8851be.mod.o
LD [M] /home/zorin/Downloads/rtw89-main/rtw_8851be.ko
BTF [M] /home/zorin/Downloads/rtw89-main/rtw_8851be.ko
Skipping BTF generation for /home/zorin/Downloads/rtw89-main/rtw_8851be.ko due to unavailability of vmlinux
CC [M] /home/zorin/Downloads/rtw89-main/rtw_8852a.mod.o
LD [M] /home/zorin/Downloads/rtw89-main/rtw_8852a.ko
BTF [M] /home/zorin/Downloads/rtw89-main/rtw_8852a.ko
Skipping BTF generation for /home/zorin/Downloads/rtw89-main/rtw_8852a.ko due to unavailability of vmlinux
CC [M] /home/zorin/Downloads/rtw89-main/rtw_8852ae.mod.o
LD [M] /home/zorin/Downloads/rtw89-main/rtw_8852ae.ko
BTF [M] /home/zorin/Downloads/rtw89-main/rtw_8852ae.ko
Skipping BTF generation for /home/zorin/Downloads/rtw89-main/rtw_8852ae.ko due to unavailability of vmlinux
CC [M] /home/zorin/Downloads/rtw89-main/rtw_8852b.mod.o
LD [M] /home/zorin/Downloads/rtw89-main/rtw_8852b.ko
BTF [M] /home/zorin/Downloads/rtw89-main/rtw_8852b.ko
Skipping BTF generation for /home/zorin/Downloads/rtw89-main/rtw_8852b.ko due to unavailability of vmlinux
CC [M] /home/zorin/Downloads/rtw89-main/rtw_8852be.mod.o
LD [M] /home/zorin/Downloads/rtw89-main/rtw_8852be.ko
BTF [M] /home/zorin/Downloads/rtw89-main/rtw_8852be.ko
Skipping BTF generation for /home/zorin/Downloads/rtw89-main/rtw_8852be.ko due to unavailability of vmlinux
CC [M] /home/zorin/Downloads/rtw89-main/rtw_8852c.mod.o
LD [M] /home/zorin/Downloads/rtw89-main/rtw_8852c.ko
BTF [M] /home/zorin/Downloads/rtw89-main/rtw_8852c.ko
Skipping BTF generation for /home/zorin/Downloads/rtw89-main/rtw_8852c.ko due to unavailability of vmlinux
CC [M] /home/zorin/Downloads/rtw89-main/rtw_8852ce.mod.o
LD [M] /home/zorin/Downloads/rtw89-main/rtw_8852ce.ko
BTF [M] /home/zorin/Downloads/rtw89-main/rtw_8852ce.ko
Skipping BTF generation for /home/zorin/Downloads/rtw89-main/rtw_8852ce.ko due to unavailability of vmlinux
make[1]: Leaving directory '/usr/src/linux-headers-5.15.0-56-generic'
zorin@zorin:~/Downloads/rtw89-main$ sudo make install
make -C /lib/modules/5.15.0-56-generic/build M=/home/zorin/Downloads/rtw89-main modules
make[1]: Entering directory '/usr/src/linux-headers-5.15.0-56-generic'
make[1]: Leaving directory '/usr/src/linux-headers-5.15.0-56-generic'
Install rtw89 SUCCESS
zorin@zorin:~/Downloads/rtw89-main$ sudo mkdir /usr/lib/firmware/rtw89
mkdir: cannot create directory β€˜/usr/lib/firmware/rtw89’: File exists
zorin@zorin:~/Downloads/rtw89-main$

Also if I reboot , won't everything be lost? I'm running on Live USB, "Try Zorin", no persistence features enabled as far as I know.

oh...

That could explain our troubles... The LiveUSB falls back on the most generic drivers instead of reading your hardware and assigning the proper driver for that hardware.

[Just found out my cheap-as-chips KaiOS backup burner phone can do USB tethering, so hopefully I won't have to keep disconnecting like with my main phone.]

Thanks so much for all the tips you've given to help with this issue.

Is there a way to get the live USB to read the hardware and use the right driver? So that I can fully test & confirm Zorin Lite works on this hardware before I wipe Windows and install ZL?

I would use Ventory - with persistence enabled. Then try installing and enabling the driver as we had above.

I think the wireless card is diffferent from the driver tried installing earlier.

zorin@zorin:~$ lspci -nnk | grep -iA3 net
03:00.0 Network controller [0280]: Realtek Semiconductor Co., Ltd. Device [10ec:b852]
	Subsystem: Lenovo Device [17aa:4853]
	Kernel modules: rtw_8852be

Online info about installing driver for that card says computer has to reboot and doesn't seem to work with persistence, so I might have to go ahead and install ZL in order to try it.
https://forums.linuxmint.com/viewtopic.php?t=392752

I'd really rather test this out on live and then do a whole disk install of ZL. But if there's no way to test it first live, then maybe I can dual boot until itΒΏs all working, then take over the whole disk.

OK, I researched how to enable persistence in Ventoy and I set it up.

I've tested it briefly. I changed the theme and wallpaper, and created two files. When I reboot with persistence, the changes to appearance do not persist, but the files I created do persist. Hopefully the driver-related stuff will persist.

Currently doing sudo apt update and will then try the other steps for installing drivers.

There have been so many steps in this thread I not sure which to do next. Maybe the ones here?

Although now I'm successfully tethered, maybe some of the steps are different? EDIT: E.g. can I use apt to get/ install the rtw89 driver or should I still manually download the zip from the website?

I did:

sudo apt-get update
sudo apt-get install make gcc linux-headers-$(uname -r) build-essential git
git clone https://github.com/lwfinger/rtw89.git
cd rtw89
make
sudo make install

All successfully.

Then:
sudo mkdir /usr/lib/firmware/rtw89
but the directory already existed.

Then:
sudo cp rtw8852a_fw.bin /usr/lib/firmware/rtw89/
but that file/directory did not exist (or could not be made).

Then:
sudo modprobe rtw89pci
No feedback, no error message.

Then I rebooted with persistence.
"No network devices available." :frowning: