raspberry pi 4b上安装和配置openwrt系统

raspberry pi上选择哪个版本的openwrt,刷写系统,调整分区大小 ,查看这个视频:

https://www.youtube.com/watch?v=_pBf2hGqXL8

 

目前最新版本是22.03.5

https://firmware-selector.openwrt.org/?version=22.03.5&target=bcm27xx%2Fbcm2711&id=rpi-4

选择 FACTORY(EXT-4)来刷写,后面可以紧接着修改分区大小

 

注意:下载时,可以预先 指定安装哪些应用:

 

点击:"Customize installed packages and/or first boot script"

 

* Requires fdisk and resize2fs
* First use lsblk to see disks and where they are mounted
* Then unmount rootfs! Otherwise changes won’t work (use sudo umount /media/username/rootfs)
* Then use fdisk to delete second partition, and recreate it using the rest of the available space
* sudo fdisk /dev/sdb
* p
* d
* 2
* n
* p
* 2
* Use sector from previous 2nd partition before deletion
* (Press Enter to assume using the last sector as end point for partition)
* n
* w
* Then run command sudo e2fsck -f /dev/sdb2
* Press ‘y’ to fix padding
* Then run command sudo resize2fs /dev/sdb2
* Then unmount first partition, unplug from computer, and plug sd card into raspberry pi
* sudo umount /dev/sdb1

 

 

2023#最新版#OpenWRT安装配置#OpenClash

查看这个视频:https://www.youtube.com/watch?v=KKOFKOyQLh8

使用到命令如下:

1. opkg remove dnsmasq
2. mv /etc/config/dhcp /etc/config/dhcp.bak
3. opkg update
4. opkg install coreutils-nohup bash iptables dnsmasq-full curl ca-certificates ipset ip-full iptables-mod-tproxy iptables-mod-extra libcap libcap-bin ruby ruby-yaml kmod-tun kmod-inet-diag unzip luci-compat luci luci-base

在此页面https://github.com/vernesong/OpenClash/releases
下载*.ipk文件

上传下载的文件 luci-app-openclash_0.45.87-beta_all.ipk 到/tmp安装目录
安装

5. opkg install /tmp/luci-app-openclash_0.45.87-beta_all.ipk
6. 重启系统
7. Clash服务启动前请先在===全局设置===页面的===版本更新===标签下确认内核编译版本,您也可以手动下载 Clash内核 后解压到 /etc/openclash/core/文件夹

 

posted @ 2023-08-18 17:27  profesor  阅读(714)  评论(0编辑  收藏  举报