sing-box icon indicating copy to clipboard operation
sing-box copied to clipboard

1.12.5 在 Arch 下无法使用 tun system 堆栈

Open hour-keeper opened this issue 1 year ago • 7 comments

操作系统

Linux

系统版本

Arch with 6.16.6-lqx1-1-lqx Kernel

安装类型

sing-box 原始命令行程序

如果您使用图形客户端程序,请提供该程序版本。

No response

版本

sing-box version 1.12.5

Environment: go1.25.1 linux/amd64
Tags: with_gvisor,with_quic,with_dhcp,with_wireguard,with_utls,with_acme,with_clash_api,with_tailscale
Revision: fcde0c94e01f990b5d67c16a2382032f784a6ed0
CGO: disabled

描述

更新到 1.12.5 后 tun system 堆栈失效,无法正常路由连接,面板中显示仅显示两个连接,回退到 1.12.4 后一切正常 tun 配置

    {
      "type": "tun",
      "tag": "tun-in",
      "address": [
        "172.18.0.1/30",
        "fdfe:dcba:9876::1/126"
      ],
      "auto_route": true,
      "auto_redirect": true,
      "strict_route": true,
      "stack": "system"
    }

在 1.12.4 下的 sing-box version 输出

sing-box version 1.12.4

Environment: go1.24.6 linux/amd64
Tags: with_gvisor,with_quic,with_dhcp,with_wireguard,with_utls,with_acme,with_clash_api,with_tailscale
CGO: enabled

重现方式

paru -S sing-box-bin 配置中 tun 入站使用 system 堆栈可以复现 例如

    {
      "type": "tun",
      "tag": "tun-in",
      "address": [
        "172.18.0.1/30",
        "fdfe:dcba:9876::1/126"
      ],
      "auto_route": true,
      "auto_redirect": true,
      "strict_route": true,
      "stack": "system"
    }

日志


支持我们

完整性要求

  • [x] 我保证阅读了文档,了解所有我编写的配置文件项的含义,而不是大量堆砌看似有用的选项或默认值。
  • [x] 我保证提供了可以在本地重现该问题的服务器、客户端配置文件与流程,而不是一个脱敏的复杂客户端配置文件。
  • [x] 我保证提供了可用于重现我报告的错误的最简配置,而不是依赖远程服务器、TUN、图形界面客户端或者其他闭源软件。
  • [x] 我保证提供了完整的配置文件与日志,而不是出于对自身智力的自信而仅提供了部分认为有用的部分。

hour-keeper avatar Sep 11 '25 10:09 hour-keeper

I also had all configurations stop working after updating to 1.12.5 in Tun mode in Arch, rolling back to 1.12.4 or updating to 1.13.0-alpha.11 solves the problem.

di1905 avatar Sep 11 '25 10:09 di1905

Same issue happend even change stack to gvisor , both on docker and direct installation. Rolling back 1.12.4 fix the problem, or remove "auto_redirect": true in tun outbound.

JKSTAFF avatar Sep 11 '25 13:09 JKSTAFF

so do i, maybe its dns module has problem ,when i use 1.12.5 , i can play video by dns cache, can't search new web

blaobla avatar Sep 11 '25 14:09 blaobla

@nekohasekai 对比了一下 1.12.5 的 nft 规则 相较于前面提到的其他版本,在 chain output 的 redirect 前面多了一条

chain output {
  ...
  meta mark set 2023 ct mark set meta mark return
  meta nfproto ipv4 meta l4proto tcp counter packets 0 bytes 0 redirect to :36743 return
}

导致流量根本到不了 redirect 就被 return 了 猜想应该是这个原因导致的本机进程出站 tcp 流量都有问题

doveccl avatar Sep 11 '25 17:09 doveccl

fixed in 1.12.8, @nekohasekai thank you.

hour-keeper avatar Sep 13 '25 08:09 hour-keeper

fixed in 3.12.8, @nekohasekai thank you.

1.12.8* ?

varnie avatar Sep 13 '25 12:09 varnie

fixed in 3.12.8, @nekohasekai thank you.

1.12.8* ?

是的,拼错了

hour-keeper avatar Sep 13 '25 12:09 hour-keeper