我刚买了一个 wifi 适配器 TP-Link AC 600,并从 github 存储库安装了此驱动程序https://github.com/aircrack-ng/rtl8812au.git。
但是当我尝试在 Ubuntu 20.04 LTS 中使用 NetworkManager 时显示它不可用:
$ nmcli d
DEVICE TYPE STATE CONNECTION
wlp6s0 wifi connected <My Wifi Network>
\264\260$k\035\362 wifi unavailable --
docker0 bridge unmanaged --
enp7s0 ethernet unmanaged --
lo loopback unmanaged --
p2p-dev-wlp6s0 wifi-p2p unmanaged --
我发现这个驱动程序有一个错误,并按照这个问题的指示无网络:在 Ubuntu 20.04 中显示 WIFI,但没有改变任何东西。此外
$ dkms status
8812au, 5.6.4.2_35491.20191025, 5.4.0-122-generic, x86_64: installed (WARNING! Diff between built and installed module!)
并rfkill
表示已解封
$ rfkill
ID TYPE DEVICE SOFT HARD
0 wlan phy0 unblocked unblocked
1 wlan phy1 unblocked unblocked
2 bluetooth hci0 unblocked unblocked
我看到它是第二台设备。而且
$ lspci -knn | grep Net -A3; rfkill list
06:00.0 Network controller [0280]: Qualcomm Atheros QCA9565 / AR9565 Wireless Network Adapter [168c:0036] (rev 01)
Subsystem: Dell QCA9565 / AR9565 Wireless Network Adapter [1028:020c]
Kernel driver in use: ath9k
Kernel modules: ath9k
这是lsusb
输出
Bus 001 Device 006: ID 0bda:0129 Realtek Semiconductor Corp. RTS5129 Card Reader Controller
Bus 001 Device 007: ID 0cf3:0036 Qualcomm Atheros Communications
Bus 001 Device 004: ID 0c45:670b Microdia
Bus 001 Device 003: ID 046d:c534 Logitech, Inc. Unifying Receiver
Bus 001 Device 002: ID 8087:8001 Intel Corp.
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 002 Device 002: ID 2357:011e TP-Link 802.11ac WLAN Adapter
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
我之前问过一个问题Ubuntu 20.04 LTS 中 Wifi 适配器不可用现在唯一的区别是出现在的名称lsusb
。
EDIT1:这是我在include/drv_types_linux.h中所做的更改
变更前
#ifndef __DRV_TYPES_LINUX_H__
#define __DRV_TYPES_LINUX_H__
#if (LINUX_VERSION_CODE < KERNEL_VERSION(5, 15, 0))
#define dev_addr_set(netdev, ethdata) _rtw_memcpy(netdev, ethdata, ETH_ALEN)
#endif
#endif
变更后
#ifndef __DRV_TYPES_LINUX_H__
#define __DRV_TYPES_LINUX_H__
#if (LINUX_VERSION_CODE < KERNEL_VERSION(5, 15, 0))
#define dev_addr_set(netdev, ethdata) _rtw_memcpy(netdev->dev_addr, ethdata, ETH_ALEN)
#endif
#endif
答案1
让我们尝试不同的驱动程序。首先,删除 aircrack-ng 版本:
cd rtl8812au
sudo make dkms_remove
接下来,通过以太网、网络共享或任何可能的方式建立有效的互联网连接,打开终端并执行以下操作:
git clone https://github.com/morrownr/8821au-20210708.git
cd 8821au-20210708
sudo ./install-driver.sh
重新启动并告诉我们是否有任何改进。