Skip to main content
Topic solved
This topic has been marked as solved and requires no further attention.
Topic: [SOLVED] problem with wifi driver (Read 770 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

[SOLVED] problem with wifi driver

hello. artix xfce openrc. im tryed to install rtl8811 driver for usb wifi adapter, https://github.com/brektrou/rtl8821CU, i installed git, dkms, base-devel, bc, usb_modeswitch. but when i run sudo ./dkms-install.sh, i got this error:
Code: [Select]
About to run dkms install steps...
Creating symlink /var/lib/dkms/rtl8821CU/5.4.1/source -> /usr/src/rtl8821CU-5.4.1
Sign command: /usr/lib/modules/6.6.9-artix1-1/build/scripts/sign-file
Signing key: /var/lib/dkms/mok.key
Public certificate (MOK): /var/lib/dkms/mok.pub
Certificate or key are missing, generating self signed certificate for MOK...

Building module:
Cleaning build area...
'make' KVER=6.6.9-artix1-1........................(bad exit status: 2)
Error! Bad return status for module build on kernel: 6.6.9-artix1-1 (x86_64)
Consult /var/lib/dkms/rtl8821CU/5.4.1/build/make.log for more information.
Sign command: /usr/lib/modules/6.6.9-artix1-1/build/scripts/sign-file
Signing key: /var/lib/dkms/mok.key
Public certificate (MOK): /var/lib/dkms/mok.pub

Building module:
Cleaning build area...
'make' KVER=6.6.9-artix1-1........................(bad exit status: 2)
Error! Bad return status for module build on kernel: 6.6.9-artix1-1 (x86_64)
Consult /var/lib/dkms/rtl8821CU/5.4.1/build/make.log for more information.
Finished running dkms install steps.

then i tryed to reboot, and after that i can connect to the wireless network, but connection shut down after 15-30 sec. then after 15-30 sec too connection restored. then i tryed install driver with make, but i also got an error -  "make: *** [Makefile:2217: modules] Error 2"

and i also tryed usb-modeswitch like it is written in the readme(https://github.com/brektrou/rtl8821CU), but i got an error again:
Code: [Select]
Access device 006 on bus 002
Get the current device configuration ...
Current configuration number is 1
Use interface number 0
 with class 255
Error: can't use storage command in MessageContent with interface 0; interface class is 255, expected 8. Abort
how i can install this driver?

Re: problem with wifi driver

Reply #1
Have you possibly tried with rtl8821au-dkms-git:
Code: [Select]
trizen 8811
1 chaotic-aur/rtl88xxau-aircrack-dkms-git r1283.a3e0c0b-1
    Aircrack-ng kernel module for Realtek 88XXau (USB adapters only) network cards (8811au, 8812au and 8821au chipsets) with monitor mode and injection support
2 aur/rtl8821au-dkms-git 5.12.5.2.r148.g0bfe654-1 [47+] [0.51%] [2 Sep 2022]
    rtl8821AU and rtl8811AU chipset driver with firmware v5.12.5.2
3 aur/rtl8821cu-git 5.12.0.34.76605e4-1 [out-of-date] [1+] [0.00%] [20 Sep 2022]
    Linux Driver for USB WiFi Adapters that use the RTL8811CU, RTL8821CU and RTL8731AU Chipsets
4 aur/rtl88xxau-aircrack-dkms-git r1200.cab4e4e-1 [44+] [0.19%] [6 Jun 2022]
    Aircrack-ng kernel module for Realtek 88XXau (USB adapters only) network cards (8811au, 8812au and 8821au chipsets) with monitor mode and injection support


Re: problem with wifi driver

Reply #2
Since usb-modeswitch is simply to switch between treating the device like a usb thumbdrive and the wifi module, if linux is seeing it as a wifi device at all you shouldn't need to use usb-modeswitch.

Also do you have any other wifi adapters on your system (motherboard for example), if so I'd blacklist those so no configurations accidentally go to it instead (simplifies things a bit).

I  messed around with one of these devices and this driver a while back when my onboard wifi started failing.  Was fun getting it going but as I recall it was a bit of a headache and in the end I just bought a different usb wifi device that linux kernel could work with without messing with additional drivers.

This is the driver I ended up using and it worked and installed great:
https://github.com/morrownr/8821cu-20210916

Well technically I used 8821cu-20210118 but should be working the same I would think.