You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Ubuntu 22.04.2 LTS下Realtek RTL8821CU USB无线网卡无法工作的求助

Ubuntu 22.04.2 LTS下Realtek RTL8821CU USB无线网卡无法工作的求助

大家好,我是Ubuntu新手,目前在用Ubuntu 22.04.2 LTS系统。我有一块Realtek Semiconductor Co., Ltd.的RTL8111/8168/8411 PCIe千兆以太网卡,还有一块RTL8821CU USB无线网卡(lsusb里显示设备ID为0bda:c811),但这块无线网卡开箱即用不了,我查了网上的方法尝试解决,但还是没成功,想请大家帮忙看看问题出在哪。

以下是我收集的系统和设备相关信息:

1. lsusb命令输出

执行lsusb后,无线网卡已被识别:

Bus 002 Device 008: ID 0e8d:2004 MediaTek Inc. moto g22
Bus 002 Device 005: ID 058f:6361 Alcor Micro Corp. Multimedia Card Reader
Bus 002 Device 004: ID 0bda:c811 Realtek Semiconductor Corp. 802.11ac NIC
Bus 002 Device 003: ID 24ae:2013 Shenzhen Rapoo Technology Co., Ltd. Rapoo 2.4G Wireless Device
Bus 002 Device 002: ID 8087:0020 Intel Corp. Integrated Rate Matching Hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 003: ID 275d:0ba6  USB OPTICAL MOUSE
Bus 001 Device 002: ID 8087:0020 Intel Corp. Integrated Rate Matching Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

2. sudo lshw -C network命令输出

*-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:02:00.0
logical name: enp2s0
version: 06
serial: 9e:07:07:e3:98:a0
capacity: 1Gbit/s
width: 64 bits
clock: 33MHz
capabilities: pm msi pciexpress msix vpd 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 latency=0 link=no multicast=yes port=twisted pair
resources: irq:25 ioport:e800(size=256) memory:f9fff000-f9ffffff memory:f9ff8000-f9ffbfff

*-network
description: Ethernet interface
physical id: 5
bus info: usb@2:1.6
logical name: enx463925c9264f
serial: 46:39:25:c9:26:4f
capabilities: ethernet physical
configuration: autonegotiation=off broadcast=yes driver=rndis_host driverversion=5.19.0-38-generic duplex=half firmware=RNDIS device ip=192.168.34.226 link=yes multicast=yes port=twisted pair

3. 安装r8168驱动后的dkms status输出

我已经安装了r8168驱动,执行sudo dkms status得到:

broadcom-sta/6.30.223.271, 5.19.0-38-generic, x86_64: installed
r8168/8.049.02, 5.19.0-38-generic, x86_64: installed
rtl8821CU/5.4.1: added

4. 重启时的错误日志

重启系统时,我看到以下错误信息:

[ 1.333512] r8168 0000:02:00.0 (unnamed net_device)(uninitialized): invalid ether addr 00:00:00:00:00:00


后续尝试的解决步骤及结果

感谢@chili555的回复,我按照建议尝试了操作,但问题还是没解决,以下是具体过程:

尝试移除旧驱动

执行sudo dkms remove rtl8821CU/5.4.1 --all时,出现错误:

Error! The module/version combo: rtl8821CU-5.4.1 is not located in the DKMS tree.

安装新的RTL8821CU驱动

进入~/8821cu-20210916目录,执行sudo ./install-driver.sh,安装过程输出如下:

: ---------------------------
: install-driver.sh v20230227
: x86_64 (architecture)
: 4/4 (in-use/total processing units)
: 12246640 (total system memory)
: 5.19.0-38-generic (kernel version)
: gcc (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0
: dkms-2.8.7
EFI variables are not supported on this system
: ---------------------------
Checking for previously installed drivers.
: ---------------------------
Starting installation.
Installing 8821cu.conf to /etc/modprobe.d
The dkms installation routines are in use.
Copying source files to /usr/src/rtl8821cu-5.12.0.4
Creating symlink /var/lib/dkms/rtl8821cu/5.12.0.4/source -> /usr/src/rtl8821cu-5.12.0.4
The driver was added to dkms successfully.
: ---------------------------
Kernel preparation unnecessary for this kernel. Skipping...
Building module:
cleaning build area...
./dkms-make.sh.................................
Signing module:
- /var/lib/dkms/rtl8821cu/5.12.0.4/5.19.0-38-generic/x86_64/module/8821cu.ko
EFI variables are not supported on this system
/sys/firmware/efi/efivars not found, aborting.
cleaning build area...
Compile time: 313.36 seconds
The driver was built by dkms successfully.
: ---------------------------
8821cu.ko:
Running module version sanity check.
- Original module
- No original module exists within this kernel
- Installation
- Installing to /lib/modules/5.19.0-38-generic/updates/dkms/
depmod............
The driver was installed by dkms successfully.
: ---------------------------
Info: Upgrade this driver with the following commands as needed:
$ git pull
$ sudo sh install-driver.sh
Note: Upgrades to this driver should be performed before distro upgrades.
Note: Upgrades can be performed as often as you like.
Note: Work on this driver is continuous.
: ---------------------------
Do you want to edit the driver options file now? (recommended) [Y/n]
Do you want to apply the new options by rebooting now? (recommended) [Y/n]

安装过程中多次提示EFI variables are not supported on this system,我不确定这个提示是否重要,当时选择了Y确认编辑配置并重启系统,但问题依旧。

安装后的dkms status输出

再次执行sudo dkms status,显示新驱动已安装:

broadcom-sta/6.30.223.271, 5.19.0-38-generic, x86_64: installed
rtl8821cu/5.12.0.4, 5.19.0-38-generic, x86_64: installed

dmesg相关日志

执行sudo dmesg | grep 8821得到:

[sudo] password for rgtm:
[   21.202833] RTW: rtl8821cu v5.12.0.4-1-g9241a6516.20210916_COEX20200730-5151
[   21.202835] RTW: rtl8821cu BT-Coex version = COEX20200730-5151
[   21.624773] usbcore: registered new interface driver rtl8821cu
[   21.655048] rtl8821cu 2-1.3:1.0 wlx1cbfce9da648: renamed from wlan0

目前无线网卡还是无法正常工作,希望有遇到过类似问题的朋友能给我一些建议,谢谢大家!

备注:内容来源于stack exchange,提问作者Rgtm

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.04.22 14:44:50