

树莓派 4B+ 连接企业wifi 802.1x
source link: https://blog.51cto.com/xiaoyuanzheng/5705627
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

当您尝试在 Raspberry Pi 上使用 WPA 企业连接到 802.1x WiFi 时,您将看到 WiFi 接入点在 Raspberry Pi 上显示为灰色,如下图:

解决的思路是,将树莓派自带的dhcpcd网络管理工具卸载掉,然后安装Linux网络管理器
通过这个工具在图形化界面连接公司wifi
实际测试树莓派 4b+ 自带的dhcpcd工具连接无法成功。
具体步骤:
一、重装网络管理工具
如第一步的安装失败,请选择第三步,更换安装源,否则执行第一跟二步就行了。
在 Raspberry Pi 上打开终端窗口,然后运行以下命令以安装标准 Linux 网络管理器。
sudo apt install network-manager network-manager-gnome
sudo systemctl disable --now dhcpcd
sudo systemctl enable --now network-manager
第一行是安装Linux网络管理器
第二行是禁用 DHCP,因为 DHCP 无法与网络管理器一起使用
第三行是启用网络管理器服务
最后一行是重新启动设备。
二、重启后连接网络
重启设备后,您将可以看到一个新的网络图标,点击该图标,您将可以连接到 802.1x 企业 WiFi。

选择peap,勾选不需要ca证书,输入账号密码,如下图,即可完成连接

三、为树莓派更换国内apt镜像源
使用管理员权限(经由sudo),编辑/etc/apt/sources.list文件。参考命令行为:
sudo nano /etc/apt/sources.list
用#注释掉原文件内容,用以下内容取代:
deb http://mirrors.tuna.tsinghua.edu.cn/raspbian/raspbian/ buster main contrib non-free rpi
deb-src http://mirrors.tuna.tsinghua.edu.cn/raspbian/raspbian/ buster main contrib non-free rpi
注意: 上述代码只需要替换网址即可。网址后面的buster字段与系统版本有关,在替换时请参考原代码,不要照抄;main contrib non-free rpi这些字段同理,网址末尾的raspbian重复两次是必须的。因为Raspbian的仓库中除了APT软件源还包含其他代码。APT软件源不在仓库的根目录,而在raspbian/子目录下。保持内容:buster main contrib non-free rpi
用#注释掉原文件内容,用以下内容取代:
sudo nano /etc/apt/sources.list.d/raspi.list
deb http://mirrors.tuna.tsinghua.edu.cn/raspberrypi/ buster main
deb-src http://mirrors.tuna.tsinghua.edu.cn/raspberrypi/ buster main
编辑镜像站后,请使用sudo apt-get update命令,更新软件源列表,同时检查您的编辑是否正确。
保持内容:buster main
目前测试 树莓派 4B+是用的这个
Recommend
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK