vxiaov / vClash

Clash插件 for Koolshare系列梅林、官方改版,适用于380/384/386/388版本固件啦。安装即用(内置免费代理订阅源)。
https://vlike.work/
GNU General Public License v3.0
526 stars 62 forks source link

kernel: out_fd is a pipe #37

Closed JiaRG closed 11 months ago

JiaRG commented 1 year ago

Bug描述 开启 Clash 服务后路由器一直打印 kernel: out_fd is a pipe

Bug重现 开启 Clash 服务后路由器一直打印 kernel: out_fd is a pipe

截图 image image

路由器信息:

您的路由器基本信息(反馈开发者帮您分析问题用):
| system : Linux RT-AC68U-00B0 2.6.36.4brcmarm armv7l ASUSWRT-Merlin-KoolShare|
| rom    : RT-AC68U:koolshare梅林改版固件:386.7|
| memory : free:  54.36 MB,total: 249.72 MB,usage:  78.23%|
| /jffs  : free:  39.73 MB,total:  62.75 MB,usage:  36.68%|
+---------------------------------------------------------------+
|>> vClash当前正在使用的软件版本:                                   << |
|              vClash : v2.2.19                                 |
|       clash_premium : 2023.04.16_linux_arm                    |
|                  yq : 4.13.2                                  |
|                  jq : jq-1.5rc2-245-g7b81a83-dirty            |
|>> vClash初始安装包自带的软件版本(分析是否个人更改过):                                   << |
|              vClash : v2.2.19                                 |
|       clash_premium : 2021.09.15_v1.7.1                       |
|                  yq : 4.13.2                                  |
|                  jq : jq-1.5rc2-245-g7b81a83-dirty            |
+---------------------------------------------------------------+
vClash的转发规则(iptables -t nat -S | grep clash),分析转发规则是否正常:
-N clash
-N clash_dns
-A PREROUTING -s 192.168.50.0/24 -p tcp -j clash
-A PREROUTING -s 192.168.50.0/24 -p udp -m udp --dport 53 -j clash_dns
-A OUTPUT -s 192.168.50.0/24 -p udp -m udp --dport 53 -j clash_dns
-A clash -d 10.0.0.0/8 -j RETURN
-A clash -d 127.0.0.0/8 -j RETURN
-A clash -d 169.254.0.0/16 -j RETURN
-A clash -d 172.16.0.0/12 -j RETURN
-A clash -d 192.168.50.0/24 -j RETURN
-A clash -s 192.168.50.0/24 -p tcp -m multiport --dports 80,443 -j REDIRECT --to-ports 3333
-A clash_dns -s 192.168.50.0/24 -p udp -m udp --dport 53 -j REDIRECT --to-ports 1053
+---------------------------------------------------------------+
JiaRG commented 1 year ago

并且还有个问题就是 google netflix 能访问了,但是 youtube facebook 啥的就不能

JiaRG commented 1 year ago

路由器上同时还安装的 AdguardHome , 不知道是不是它影响的

JiaRG commented 1 year ago

clash 那也提了个 issue Dreamacro/clash#2732

JiaRG commented 1 year ago

并且还有个问题就是 google netflix 能访问了,但是 youtube facebook 啥的就不能

路由器上同时还安装的 AdguardHome , 不知道是不是它影响的

不能访问 youtube 的问题定位到了,由于 AdguardHome 在 iptables 的规则影响到了,调整下顺序就行了

原始:

Chain PREROUTING (policy ACCEPT)
target     prot opt source               destination
DNSFILTER  udp  --  anywhere             anywhere             udp dpt:domain
DNSFILTER  tcp  --  anywhere             anywhere             tcp dpt:domain
clash      tcp  --  192.168.50.0/24      anywhere
clash_dns  udp  --  192.168.50.0/24      anywhere             udp dpt:domain

调整后:

Chain PREROUTING (policy ACCEPT)
target     prot opt source               destination
clash      tcp  --  192.168.50.0/24      anywhere
clash_dns  udp  --  192.168.50.0/24      anywhere             udp dpt:domain
DNSFILTER  udp  --  anywhere             anywhere             udp dpt:domain
DNSFILTER  tcp  --  anywhere             anywhere             tcp dpt:domain
JiaRG commented 1 year ago

还有个问题就是路由器本身不支持代理 https://github.com/Dreamacro/clash/issues/158#issuecomment-483908308

Awkee commented 11 months ago

可能还是Clash可执行程序的问题,试试最新版本的Clash吧。