vernesong / OpenClash

A Clash Client For OpenWrt
MIT License
17.51k stars 3.18k forks source link

[Bug] Reality+XTLS Vision 协议下遇到大流量(如SpeedTest)时内核反复崩溃,并持续占用大量内存 #3394

Closed wayne0926 closed 1 year ago

wayne0926 commented 1 year ago

Verify Steps

OpenClash Version

v0.45.129-beta

Bug on Environment

Official OpenWrt

Bug on Platform

Linux-amd64(x86-64)

To Reproduce

使用 speedtest 测速,在测速中或测速完后可在日志中发现内核崩溃

Describe the Bug

大流量时内核崩溃、崩溃重启后持续占用极大量内存(730MB)且只有重启 OpenWrt 才能解决 目前测试普通VMess + WS + CDNVless + TCP + XTLS-rprx-Vision协议都未造成崩溃

OpenClash Log

插件日志

2023-07-16 05:16:24 守护程序:检测到 Clash 内核崩溃,重启中...
2023-07-16 05:11:13 OpenClash 启动成功,请等待服务器上线!
2023-07-16 05:11:13 第九步: 添加计划任务,启动进程守护程序...
2023-07-16 05:11:12 第八步: 重启 Dnsmasq 程序...
2023-07-16 05:11:12 提示:开始添加自定义防火墙规则...
2023-07-16 05:11:12 提示:正在根据防火墙端口转发和防火墙通信规则添加端口绕过规则...
2023-07-16 05:11:12 提示:DNS 劫持模式为 Dnsmasq 转发...
2023-07-16 05:11:12 第七步: 设置防火墙规则...
2023-07-16 05:11:12 第六步: 等待主程序下载外部文件...
2023-07-16 05:11:09 第五步: 检查内核启动状态...
2023-07-16 05:11:08 配置文件【/etc/openclash/6-beta.yaml】测试成功...
2023-07-16 05:11:06 启动前调用内核测试配置文件...
2023-07-16 05:11:06 提示:检测到配置了 Meta 内核专属功能,调用 Meta 内核启动...
2023-07-16 05:11:06 第四步: 启动主程序...
2023-07-16 05:11:06 提示:开始运行自定义覆写脚本...
2023-07-16 05:11:04 提示:您为 SOCKS5/HTTP(S) 代理设置的账户密码为【Clash:VoZFTweY】
2023-07-16 05:11:02 第三步: 修改配置文件...
2023-07-16 05:11:02 提示:由于文件【 /etc/config/openclash 】被修改,暂停快速启动...
2023-07-16 05:11:02 第二步: 组件运行前检查...
2023-07-16 05:11:02 第一步: 获取配置...
2023-07-16 05:11:02 OpenClash 开始启动...
2023-07-16 05:11:02 第六步:删除 OpenClash 残留文件...
2023-07-16 05:11:01 第五步: 重启 Dnsmasq 程序...
2023-07-16 05:11:01 第四步: 关闭 Clash 主程序...
2023-07-16 05:11:01 第三步: 关闭 OpenClash 守护程序...
2023-07-16 05:10:59 第二步: 删除 OpenClash 防火墙规则...
2023-07-16 05:10:59 第一步: 备份当前策略组状态...
2023-07-16 05:10:59 OpenClash 开始关闭...
2023-07-16 05:10:59 OpenClash 重新启动中...
2023-07-16 05:04:31 守护程序:检测到 Clash 内核崩溃,重启中...

内核日志(崩溃时间附近)

2023-07-16 05:16:58 level=info msg="[TCP] 192.168.2.1:50464 --> 104.199.240.237:80 match Match using Others[reality]"
2023-07-16 05:16:51 level=info msg="[TCP] 192.168.2.1:7911 --> 74.125.204.188:5228 match IPCIDR(74.125.204.188/32) using Google FCM[reality]"
2023-07-16 05:16:46 level=info msg="[TCP] 192.168.2.1:60381 --> 17.57.145.164:5223 match IPCIDR(17.0.0.0/8) using Apple[DIRECT]"
2023-07-16 05:16:44 level=info msg="[TCP] 192.168.2.1:7910 --> 140.82.112.25:443 match Match using Others[reality]"
2023-07-16 05:16:42 level=info msg="[TCP] 192.168.2.1:7909 --> 20.205.243.166:443 match Match using Others[reality]"
2023-07-16 05:16:41 level=info msg="[TCP] 192.168.2.1:60380 --> 35.186.224.25:443 match Match using Others[reality]"
2023-07-16 05:16:41 level=info msg="[TCP] 192.168.2.1:7908 --> 140.82.112.25:443 match Match using Others[reality]"
2023-07-16 05:16:35 level=info msg="[TCP] 192.168.2.1:7907 --> 216.144.253.178:443 match Match using Others[reality]"
2023-07-16 05:16:33 level=info msg="[TCP] 192.168.2.1:7906 --> 57.128.101.77:443 match Match using Others[reality]"
2023-07-16 05:16:33 level=info msg="[TCP] 192.168.2.1:60377 --> 151.101.110.248:443 match Match using Others[reality]"
2023-07-16 05:16:33 level=info msg="[TCP] 192.168.2.1:60378 --> 151.101.110.248:443 match Match using Others[reality]"
2023-07-16 05:16:33 level=info msg="[TCP] 192.168.2.1:60379 --> 151.101.110.248:443 match Match using Others[reality]"
2023-07-16 05:16:33 level=info msg="[TCP] 192.168.2.1:60374 --> 151.101.110.248:443 match Match using Others[reality]"
2023-07-16 05:16:33 level=info msg="[TCP] 192.168.2.1:60376 --> 151.101.110.248:443 match Match using Others[reality]"
2023-07-16 05:16:33 level=info msg="[TCP] 192.168.2.1:60375 --> 151.101.110.248:443 match Match using Others[reality]"
2023-07-16 05:16:32 level=info msg="[TCP] 192.168.2.1:60373 --> 151.101.110.248:443 match Match using Others[reality]"
2023-07-16 05:16:31 level=info msg="[TCP] 192.168.2.1:60372 --> 23.49.98.204:443 match Match using Others[reality]"
2023-07-16 05:16:28 level=info msg="[TCP] 192.168.2.1:7903 --> 20.198.162.78:443 match Match using Others[reality]"
2023-07-16 05:16:28 level=info msg="[TCP] 192.168.2.1:7904 --> 20.198.162.78:443 match Match using Others[reality]"
2023-07-16 05:16:27 level=info msg="[TCP] 192.168.2.1:60371 --> 35.186.224.25:443 match Match using Others[reality]"
2023-07-16 05:16:27 level=info msg="[TCP] 192.168.2.1:60370 --> 35.186.224.25:443 match Match using Others[reality]"
2023-07-16 05:16:26 level=info msg="[UDP] 192.168.2.1:55140 --> 58.63.233.102:443 match IPCIDR(58.32.0.0/11) using Domestic[DIRECT]"
2023-07-16 05:16:25 level=info msg="[TCP] 192.168.2.1:7902 --> 61.128.153.190:443 match IPCIDR(61.128.0.0/10) using Domestic[DIRECT]"
2023-07-16 05:16:25 level=info msg="[TCP] 192.168.2.1:7901 --> 61.128.153.190:443 match IPCIDR(61.128.0.0/10) using Domestic[DIRECT]"
2023-07-16 05:16:25 level=info msg="[TCP] 192.168.2.1:7897 --> 61.128.153.190:443 match IPCIDR(61.128.0.0/10) using Domestic[DIRECT]"
2023-07-16 05:16:25 level=info msg="[TCP] 192.168.2.1:7900 --> 61.128.153.190:443 match IPCIDR(61.128.0.0/10) using Domestic[DIRECT]"
2023-07-16 05:16:25 level=info msg="[TCP] 192.168.2.1:7898 --> 61.128.153.190:443 match IPCIDR(61.128.0.0/10) using Domestic[DIRECT]"
2023-07-16 05:16:25 level=info msg="[TCP] 192.168.2.1:7899 --> 61.128.153.190:443 match IPCIDR(61.128.0.0/10) using Domestic[DIRECT]"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider Speedtest"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider Apple"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider Auto - UrlTest"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider Spotify"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider Proxies"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider Discord"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider Google FCM"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider Others"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider Microsoft"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider Domestic"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider Crypto"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider Netease Music"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider Telegram"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider Scholar"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider Steam"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider Netflix"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider default"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider Bilibili"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider Bahamut"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider Disney Plus"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider YouTube"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider PayPal"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider AsianTV"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider GlobalTV"
2023-07-16 05:16:25 level=info msg="Start initial compatible provider AdBlock"
2023-07-16 05:16:25 level=info msg="Mixed(http+socks) proxy listening at: [::]:7893"
2023-07-16 05:16:25 level=info msg="TProxy server listening at: [::]:7895"
2023-07-16 05:16:25 level=info msg="Redirect proxy listening at: [::]:7892"
2023-07-16 05:16:25 level=info msg="SOCKS proxy listening at: [::]:7891"
2023-07-16 05:16:25 level=info msg="HTTP proxy listening at: [::]:7890"
2023-07-16 05:16:25 level=info msg="DNS server listening at: [::]:7874"
2023-07-16 05:16:25 level=info msg="Sniffer is closed"
2023-07-16 05:16:25 level=info msg="Authentication of local server updated"
2023-07-16 05:16:25 level=info msg="RESTful API listening at: [::]:9090"
2023-07-16 05:16:25 level=info msg="Initial configuration complete, total time: 25ms"
2023-07-16 05:16:25 level=info msg="Geodata Loader mode: memconservative"
2023-07-16 05:16:25 level=warning msg="To use xtls-rprx-vision, ensure your server is upgrade to Xray-core v1.8.0+"
2023-07-16 05:16:25 level=warning msg="To use xtls-rprx-vision, ensure your server is upgrade to Xray-core v1.8.0+"
2023-07-16 05:16:25 level=info msg="Start initial configuration in progress"
2023-07-16 05:15:08 level=info msg="[TCP] 192.168.2.1:60305 --> 59.82.14.171:443 match IPCIDR(59.82.0.0/16) using Domestic[DIRECT]"
2023-07-16 05:15:05 level=info msg="[TCP] 192.168.2.1:7579 --> 142.251.43.10:443 match Match using Others[reality]"
2023-07-16 05:14:57 level=info msg="[TCP] 192.168.2.1:60304 --> 35.186.224.25:443 match Match using Others[reality]"
2023-07-16 05:14:57 level=info msg="[TCP] 192.168.2.1:7575 --> 207.188.6.17:443 match Match using Others[reality]"
2023-07-16 05:14:47 level=info msg="[TCP] 192.168.2.1:7574 --> 20.198.162.78:443 match Match using Others[reality]"
2023-07-16 05:14:37 level=info msg="[TCP] 192.168.2.1:50406 --> 32.65.32.133:8080 match Match using Others[reality]"
2023-07-16 05:14:36 level=info msg="[TCP] 192.168.2.1:50448 --> 32.65.32.133:8080 match Match using Others[reality]"
2023-07-16 05:14:36 level=info msg="[TCP] 192.168.2.1:50443 --> 32.65.32.133:8080 match Match using Others[reality]"
2023-07-16 05:14:36 level=info msg="[TCP] 192.168.2.1:50449 --> 32.65.32.133:8080 match Match using Others[reality]"
2023-07-16 05:14:36 level=info msg="[TCP] 192.168.2.1:50439 --> 32.65.32.133:8080 match Match using Others[reality]"
2023-07-16 05:14:36 level=info msg="[TCP] 192.168.2.1:50450 --> 32.65.32.133:8080 match Match using Others[reality]"
2023-07-16 05:14:36 level=info msg="[TCP] 192.168.2.1:50441 --> 32.65.32.133:8080 match Match using Others[reality]"
2023-07-16 05:14:36 level=info msg="[TCP] 192.168.2.1:50445 --> 32.65.32.133:8080 match Match using Others[reality]"

OpenClash Config

- name: reality
  type: vless
  server: xxxxxxxxxxxxx
  port: 48430
  udp: true
  uuid: xxxxxxxxxxxxxxx
  tls: true
  servername: xxxxxxxxx
  flow: xtls-rprx-vision
  network: tcp
  reality-opts:
    public-key: xxxxxxxxxxxxxxxxxxxxxxxxxxx
  client-fingerprint: chrome

Expected Behavior

不崩溃、内存问题解决

Screenshots

No response

vernesong commented 1 year ago

内核没有崩溃日志吗,还是oom了

wayne0926 commented 1 year ago

内核没有崩溃日志吗,还是oom了

似乎没有,内核日志看起来一切正常,po出来的就是了

vernesong commented 1 year ago

那就是oom了,得去跟内核提交问题

wayne0926 commented 1 year ago

那就是oom了,得去跟内核提交问题

thx

db-one commented 1 year ago

那就是oom了,得去跟内核提交问题

thx

你是直接编写的配置文件还是订阅的?我用订阅的方式更新出来节点是空白的

wayne0926 commented 1 year ago

那就是oom了,得去跟内核提交问题

thx

你是直接编写的配置文件还是订阅的?我用订阅的方式更新出来节点是空白的

我是直接编写的

db-one commented 1 year ago

那就是oom了,得去跟内核提交问题

thx

你是直接编写的配置文件还是订阅的?我用订阅的方式更新出来节点是空白的

我是直接编写的

那就是现在还不支持订阅链接了,坐等大佬更新了

wayne0926 commented 1 year ago

那就是oom了,得去跟内核提交问题

thx

你是直接编写的配置文件还是订阅的?我用订阅的方式更新出来节点是空白的

我是直接编写的

那就是现在还不支持订阅链接了,坐等大佬更新了

不会吧,我记得我以前用这个功能是正常的啊🤔️,你再检查下看下日志有没有什么问题

db-one commented 1 year ago

明天我再试试,我用的xray的分享地址订阅完直接是空白的,不显示这个节点,其他协议正常

wayne0926 commented 1 year ago

明天我再试试,我用的xray的分享地址订阅完直接是空白的,不显示这个节点,其他协议正常

噢你说Reality协议这个不行是吧,有可能是真不行,大部分节点转换都不支持Vless转Clash

db-one commented 1 year ago

明天我再试试,我用的xray的分享地址订阅完直接是空白的,不显示这个节点,其他协议正常

噢你说Reality协议这个不行是吧,有可能是真不行,大部分节点转换都不支持Vless转Clash

那就再等等了,v2rayn反正是支持了,其他客户端不清楚,等大佬们更新了