我最近使用了sudo apt-get autoremove
命令,之后“启用 Wifi”选项没有显示。
$ lspci -knn | grep Net -A3
02:00.0 Network controller [0280]: Realtek Semiconductor Co., Ltd. RTL8821AE 802.11ac PCIe Wireless Network Adapter [10ec:8821]
Subsystem: Lenovo RTL8821AE 802.11ac PCIe Wireless Network Adapter [17aa:a814]
Kernel modules: rtl8821ae, wl
$ iwconfig is
lo no wireless extensions.
enp1s0 no wireless extensions.
从/var/apt/history.log
:
Start-Date: 2017-11-06 01:15:38
Commandline: apt-get autoremove
Requested-By: praveen (1000)
Remove: linux-headers-4.10.0-28-generic:amd64 (4.10.0-28.32~16.04.2), librpmsign3:amd64 (4.12.0.1+dfsg1-3build3), linux-image-extra-4.10.0-33-generic:amd64 (4.10.0-33.37~16.04.1),
librpmbuild3:amd64 (4.12.0.1+dfsg1-3build3),
linux-image-extra-4.10.0-35-generic:amd64 (4.10.0-35.39~16.04.1),
debugedit:amd64 (4.12.0.1+dfsg1-3build3),
linux-headers-4.10.0-33-generic:amd64 (4.10.0-33.37~16.04.1),
linux-image-4.10.0-28-generic:amd64 (4.10.0-28.32~16.04.2),
linux-headers-4.10.0-35-generic:amd64 (4.10.0-35.39~16.04.1),
rpm:amd64 (4.12.0.1+dfsg1-3build3),
linux-image-4.10.0-33-generic:amd64 (4.10.0-33.37~16.04.1),
linux-headers-4.10.0-28:amd64 (4.10.0-28.32~16.04.2),
linux-headers-4.10.0-33:amd64 (4.10.0-33.37~16.04.1),
linux-headers-4.10.0-35:amd64 (4.10.0-35.39~16.04.1),
linux-image-4.10.0-35-generic:amd64 (4.10.0-35.39~16.04.1),
linux-image-extra-4.10.0-28-generic:amd64 (4.10.0-28.32~16.04.2)
End-Date: 2017-11-06 01:17:19
输出uname -a
:
Linux praveen-Lenovo-ideapad-300-15ISK 4.10.0-38-generic #42~16.04.1-Ubuntu SMP Tue Oct 10 16:32:20 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
$ dpkg-query -Wf '${db:Status-Abbrev} ${Package;-40} ${Version}\n' linux-{image,headers}-\* | grep '^i'
ii linux-headers-4.10.0-37 4.10.0-37.41~16.04.1
ii linux-headers-4.10.0-37-generic 4.10.0-37.41~16.04.1
ii linux-headers-4.10.0-38 4.10.0-38.42~16.04.1
ii linux-headers-4.10.0-38-generic 4.10.0-38.42~16.04.1
ii linux-headers-4.4.0-98 4.4.0-98.121
ii linux-headers-4.4.0-98-generic 4.4.0-98.121
ii linux-headers-generic 4.4.0.98.103
ii linux-headers-generic-hwe-16.04 4.10.0.38.40
ii linux-image-4.10.0-37-generic 4.10.0-37.41~16.04.1
ii linux-image-4.10.0-38-generic 4.10.0-38.42~16.04.1
ii linux-image-extra-4.10.0-37-generic 4.10.0-37.41~16.04.1
ii linux-image-extra-4.10.0-38-generic 4.10.0-38.42~16.04.1
ii linux-image-generic-hwe-16.04 4.10.0.38.40
答案1
这些命令适用于 rtl8192ce、rtl8192se、rtl8192de、rtl8188ee、rtl8192ee、rtl8723ae、rtl8723be 和 rtl8821ae。如果您有任何其他驱动程序,请搜索并安装。
sudo apt-get install linux-headers-generic build-essential git
git clone http://github.com/lwfinger/rtlwifi_new.git
cd rtlwifi_new
make
sudo make install
此后,如果您的系统没有加载适当的内核模块,您可以在同一目录中运行以下命令(确保为您的特定驱动程序运行此命令,在我的情况下是 rtl8821ae):
sudo modprobe rtl8821ae