OpenWrt解决【/tmp/openclash_last_version】下载失败
第一次进入openwrt
里安装的openclash
进行内核更新出现以下错误:
1 | 2025-04-26 14:31:16【/tmp/openclash_last_version】下载失败:【curl: (6) Could not resolve host: raw.githubusercontent.com curl: (6) Could not resolve host: raw.githubusercontent.com curl: (6) Could not resolve host: raw.githubusercontent.com】 |
解决办法:
1,SSH
连接openwrt
2,测试连通性
1 | ping raw.githubusercontent.com |
看到结果应该如下,这是不通的,这是因为DNS污染了ping: bad address 'raw.githubusercontent.com'
3,检查hosts
1 | cat /etc/hosts |
输出结果:1
2
3
4
5127.0.0.1 localhost
::1 localhost ip6-localhost ip6-loopback
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
输出以上结果说明需要添加DNS
,进入DNS查询网查询raw.githubusercontent.com
对应的dns
,结果选择中国的
我选项的是185.199.111.133
4,编辑hosts
输入以下代码编辑hosts
1 | vim /etc/hosts |
在ff02::2 ip6-allrouters
的下方输入以下内容1
185.199.111.133 raw.githubusercontent.com
按esc
,然后输入wq
保存退出
5,再次ping
连通性
1 | ping raw.githubusercontent.com |
假如看到64 bytes from 185.199.111.133: seq=8 ttl=55 time=134.035 ms
说明DNS
污染解决
以上已经解决【/tmp/openclash_last_version】下载失败的问题,再次进入
Openwrt
里的openclash
更新插件既可正常安装了
假如出现以下错误,同样的是因为DNS
污染,配置hosts
可以解决1
2
3
4
5
6
7
8
9
10
11
122025-04-26 15:12:08 错误:【文烨,Kristi,勇哥聚合-自动】下载失败,请检查网络或稍后再试...
2025-04-26 15:12:08 错误:配置文件【文烨,Kristi,勇哥聚合-自动】订阅失败,尝试不使用代理下载配置文件...
2025-04-26 15:12:08 【/tmp/yaml_sub_tmp_config.yaml】下载失败:【curl: (6) Could not resolve host: api.wcc.best curl: (6) Could not resolve host: api.wcc.best curl: (6) Could not resolve host: api.wcc.best】
2025-04-26 15:11:50 提示:配置文件【文烨,Kristi,勇哥聚合-自动】订阅的下载链接为【https://api.wcc.best/sub?target=clash&new_name=true&url=https%3A%2F%2Fsub.camelz.dpdns.org%2F110119%3Fclash&config=https%3A%2F%2Fgithub.geekery.cn%2Fraw.githubusercontent.com%2Feric52zhang%2Frouter-clash%2Frefs%2Fheads%2Fmain%2Fproxy%2Fclash-myself.ini&include=&exclude=(%3Fi)(%E5%89%A9%E4%BD%99)%7C(%E5%BC%82%E5%B8%B8)%7C(%E5%AE%98%E7%BD%91)%7C(%E5%A4%B1%E8%B4%A5)%7C(%E5%88%B0%E6%9C%9F)%7C(0.1)%7C(0.2)%7C(0.3)%7C(0.4)%7C(0.5)%7C(%E5%9F%9F%E5%90%8D)%7C(%E6%8F%90%E4%BE%9B)&emoji=false&list=false&sort=false&udp=true&scv=false&append_type=false&fdn=true】...
2025-04-26 15:11:50 提示:配置文件【文烨,Kristi,勇哥聚合-自动】订阅的 User-Agent 为【clash.meta】...
2025-04-26 15:11:50 开始更新配置文件【文烨,Kristi,勇哥聚合-自动】...
2025-04-26 15:11:49 错误:【文烨,Kristi,勇哥聚合-自动】下载失败,请检查网络或稍后再试...
2025-04-26 15:11:49 错误:配置文件【文烨,Kristi,勇哥聚合-自动】订阅失败,尝试不使用代理下载配置文件...
2025-04-26 15:11:49 【/tmp/yaml_sub_tmp_config.yaml】下载失败:【curl: (6) Could not resolve host: api.wcc.best curl: (6) Could not resolve host: api.wcc.best curl: (6) Could not resolve host: api.wcc.best】
2025-04-26 15:11:31 提示:配置文件【文烨,Kristi,勇哥聚合-自动】订阅的下载链接为【https://api.wcc.best/sub?target=clash&new_name=true&url=https%3A%2F%2Fsub.camelz.dpdns.org%2F110119%3Fclash&config=https%3A%2F%2Fgithub.geekery.cn%2Fraw.githubusercontent.com%2Feric52zhang%2Frouter-clash%2Frefs%2Fheads%2Fmain%2Fproxy%2Fclash-myself.ini&include=&exclude=(%3Fi)(%E5%89%A9%E4%BD%99)%7C(%E5%BC%82%E5%B8%B8)%7C(%E5%AE%98%E7%BD%91)%7C(%E5%A4%B1%E8%B4%A5)%7C(%E5%88%B0%E6%9C%9F)%7C(0.1)%7C(0.2)%7C(0.3)%7C(0.4)%7C(0.5)%7C(%E5%9F%9F%E5%90%8D)%7C(%E6%8F%90%E4%BE%9B)&emoji=false&list=false&sort=false&udp=true&scv=false&append_type=false&fdn=true】...
2025-04-26 15:11:31 提示:配置文件【文烨,Kristi,勇哥聚合-自动】订阅的 User-Agent 为【clash.meta】...
2025-04-26 15:11:31 开始更新配置文件【文烨,Kristi,勇哥聚合-自动】...
配置后的hosts
1
2
3
4
5
6
7127.0.0.1 localhost
::1 localhost ip6-localhost ip6-loopback
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
185.199.111.133 raw.githubusercontent.com
104.21.80.1 api.wcc.best
其他错误
假如如下错误
1 | 2025-04-26 16:38:06 【/tmp/yaml_sub_tmp_config.yaml】下载失败:【curl: (28) Failed to connect to api.wcc.best port 443 after 30002 ms: Error curl: (35) OpenSSL SSL_connect: SSL_ERROR_SYSCALL in connection to api.wcc.best:443 】 |
是因为订阅转换的问题,改一下订阅装换既可解决,假如不能,测试自建订阅装换地址,参考教程
自建地址:1
http://192.168.5.168:25500/sub