在openSUSE-Leap-15.3-DVD-x86_64下安装USB无线网卡驱动rtl88x2bu
台式机电脑已经安装openSUSE-Leap-15.3-DVD-x86_64和KDE桌面,USB无线网卡为翼联EP-AC1610,已经得知驱动模块名称为rtl88x2bu,当前openSUSE-Leap-15.3是不可以上网的,将USB无线网卡插入主机后端
localhost:~ # lsusb
Bus 002 Device 002: ID 0bda:b812 Realtek Semiconductor Corp. RTL88x2bu [AC1200 Techkey]
一、让台式机电脑使用手机流量上网
安卓手机用数据线连接主机背后的USB接口——手机选择仅充电——设置——网络和互联网——热点和网络共享——USB网络共享
此时openSUSE-Leap-15.3打开firefox浏览器是能够正常上网
localhost:~ # lsusb
Bus 002 Device 006: ID 19d2:1365 ZTE WCDMA Technologies MSM ZTE A7010
二、到opensuse官网下载驱动rtl88x2bu
打开https://software.opensuse.org/——版本选择openSUSE Leap 15.3——关键字输入rtl88x2bu——单击右边的搜索
看到rtl88x2bu Kernel driver for Realtek 88x2bu wifi cards——单击查看——单击openSUSE Leap 15.3下边的显示社区软件包——Expert Download——单击右边SLE图标——添加软件源并手动安装——复制那三条命令到记事本
zypper addrepo https://download.opensuse.org/repositories/home:MasterPatricko:branches:hardware/15.3/home:MasterPatricko:branches:hardware.repo
zypper refresh
zypper install rtl88x2bu
三、安装驱动rtl88x2bu
屏幕左下角SUSE图标——应用——系统——konsole终端——切换到root用户——按顺序逐条复制粘贴命令并回车执行
ruhong@localhost:~> su -l root
密码:
localhost:~ # zypper addrepo https://download.opensuse.org/repositories/home:MasterPatricko:branches:hardware/15.3/home:MasterPatricko:branches:hardware.repo
localhost:~ # zypper refresh
localhost:~ # zypper install rtl88x2bu
Loading repository data…
Reading installed packages…
Resolving package dependencies…
The following 2 NEW packages are going to be installed:
rtl88x2bu rtl88x2bu-kmp-default
2 new packages to install.
Overall download size: 0 B. Already cached: 12.2 MiB. After the operation, additional 104.1 MiB will be used.
Continue? [y/n/v/…? shows all options] (y):
In cache rtl88x2bu-5.8.7.1+git20210928.f2bccb9-lp153.7.1.x86_64.rpm (1/2), 14.0 KiB ( 17.7 KiB unpacked)
In cache rtl88x2bu-kmp-default-5.8.7.1+git20210928.f2bccb9_k5.3.18_57-lp153.7.1.x86_64.rpm
(2/2), 12.2 MiB (104.1 MiB unpacked)
Checking for file conflicts: …[done]
(1/2) Installing: rtl88x2bu-5.8.7.1+git20210928.f2bccb9-lp153.7.1.x86_64 …[done]
(2/2) Installing: rtl88x2bu-kmp-default-5.8.7.1+git20210928.f2bccb9_k5.3.18_57-lp153.7.1.x86_64 …[done]
Executing %posttrans scripts …[done]
四、连接安卓手机便携式热点
安卓手机——设置——网络和互联网——热点和网络共享——WLAN热点——开启
重启台式机电脑——单击右下角的WIFI图标——单击手机热点右边的连接——输入密码——测试能否正常上网
五、后记:之前踩过的坑
到https://github.com/cilynx/rtl88x2bu下载驱动源代码rtl88x2bu-5.6.1_30362.20181109_COEX20180928-6a6a.zip,在openSUSE-Leap-15.2下编译是不会报错的,还是非常顺利正常使用,但在15.3下就会报错,在www.github.com和https://gitee.com/试过几个驱动源代码都是同样报错
/root/rtl88x2bu-5.6.1.6_35492.20191025_COEX20180928-6a6a/os_dep/linux/ioctl_cfg80211.c:9952:3: error: ‘struct cfg80211_ops’ has no member named ‘mgmt_frame_register’
.mgmt_frame_register = cfg80211_rtw_mgmt_frame_register,
^~~~~~~~~~~~~~~~~~~
最后,很意外发现suse软件官网有社区试验版本,希望此文章给遇到同样困难的人参考