openwrt 安装Clash指南
1.安装openwrt
1.1 下载固件
进入官网页面,建议安装稳定版本,在稳定版本页面页面选择自己合适的版本。本次我选用的是23.05.4
1.2 安装固件
虚拟机安装固件,此处忽略自行配置。配置2核 1G内存足够
2.下载clash
前往Github项目,在已发布页面找到最新版本。
2.1 安装前置依赖
#iptables
opkg update
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
⚠️此时可能报错 xxdns安装问题
clash 依赖的是
dnsmasq-full
,移除系统自带的dnsmasq
并安装dnsmasq-full
opkg remove dnsmasq && opkg install dnsmasq-full
2.2 安装Clash
从项目的release
列表下载自己喜欢的版本。借助openwrt默认的luci
UI工具上传安装。
2.3 配置
配置订阅链接,并设置更新频率
一定要注意,如果需要在内网代理使用,一定在
覆写设置
里把用户名密码取消
到这里基本就完成了