联想拯救者 + ubuntu16.04 + WIFI设置

问题一
1.1 问题描述
笔记本型号:Lenovo r720笔记本(i5-7300hq,gtx1060 maxq 6g),默认装入Win10系统,然而当装入Ubuntu16.04双系统时,会出现无线网卡(型号:RTL8821AE)被hard blocked问题。
即:
在终端敲入:
rfkill list all
会出现:
0:ideapad_wlan: Wireless LAN
Soft blocked: no
Hard blocked:yes
1:ideapad_bluetooth: Bluetooth
Soft blocked: no
Hard blocked: yes
2:phy0: Wireless LAN
Soft blocked: no
Hard blocked:no
3:hci0: Bluetooth
Soft blocked: yes
Hard blocked: no
可以看到,优先级前的ideapad_wlan的Hard blocked 默认为yes,即ubuntu默认关闭了硬件wifi开关,而联想R720的wifi只有软件开关,没有硬件开关的启动,所以引起了wifi无法开启的问题。


1.2 解决方法
从无线模块的显示列表可以看出,序号2的wifi模块是软硬件是可以启动的,所以,只要将前面默认的模块移出即可。
a)方法一:
1)移出ideapad无线模块:
sudo modprobe -r ideapad_laptop
2)使用命令查看:
rfkill list all
如下提示:

2:phy0: Wireless LAN
Soft blocked: no
Hard blocked:no
3:hci0: Bluetooth
Soft blocked: yes
Hard blocked: no
即wifi模块工作正常,然而每次重启ubuntu系统都要重新进行模块移出,故可将该命令设置为开机自启动。
3)在/etc/rc.local文件中添加命令:
---------------------------------------------------------------

#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.
#因为使用的是非管理员登录,故在执行sudo命令时要输入密码,方可自动化执行,
#此处假设用户密码为123,命令一定要在exit 0之前运行,该文件如果没有修改权限
#修改前使用 chmod 命令修改权限即可!
echo "123" |sudo modprobe -r ideapad_laptop
exit 0
--------------------------------------------------------------

开机启动后系统会自动执行改脚本文件,完成wifi模块的自动移出操作。

 

b)方法二(推荐):
通过列入黑名单的方式来实现自动移出ideapad_laptop设备。
1)创建/etc/modprobe.d/ideapad.conf文件:
sudo touch /etc/modprobe.d/ideapad.conf
2)编辑ideapad.conf文件:
sudo gedit ideapad.conf
3) 在ideapad.conf文件中添加:
blacklist ideapad_laptop
4) 关闭并保存ideapad.conf文件,移除ideapad_laptop设备:
sudo modprobe -r ideapad_laptop
5) 注销重启Ubuntu系统,可以看到无线设备能够被打开,并能搜索到WiFi信号。

问题二
2.1 问题描述
在解决以上无线网卡开启问题后,发现已连接的wifi容易断开并且信号强度较差

2.2 解决方法
1)插上有线网
2)打开终端
3)在终端依次执行:

sudo apt-get install git build-essential linux-headers-$(uname -r)$

git clone https://github.com/lwfinger/rtlwifi_new.git

cd rtlwifi_new

make

sudo make install

4) 重启计算机

posted @ 2018-01-23 11:11  rqnwpu  阅读(7347)  评论(0编辑  收藏  举报