Skip to content

v1.20.0

Choose a tag to compare

@github-actions github-actions released this 11 Nov 07:40
· 27 commits to main since this release

v1.20.0 — 反馈闭环:一键诊断 + 泄漏修复

版本特色

把"报障"从聊天记录变成一条命令。netsteer-doctor 十段输出 + VERDICT 判定,配合 issue 模板构成完整反馈闭环——这是项目从单人内部产品走向可被陌生人使用的关键一步。同时修复了 7×24 soak 监控首日抓到的 sense-daemon 泄漏。

新增

  • netsteer-doctor 一键诊断命令:SSH 到路由器执行即可收集定位问题所需的全部信息——包版本/环境/依赖组件/SQM 整形/硬件分载/观测面/场景引擎/加速通道/转向状态/配置与日志尾十段,末行 VERDICT 判定(OK/WARN/FAIL)。已知边界自动标注:缺依赖、flow offload 导致计数冻结、daemon 泄漏、DNS 观测降级、SQM 未启用、游戏通道缺 IP、state 未初始化
  • GitHub issue 模板:bug report(doctor 输出为必填项)与 feature request,中英双语
  • README「排障与反馈」章节(中英双语)

修复

  • sense-daemon 进程泄漏(7×24 soak 监控首日实锤:单机累积 3 个孤儿进程),四层修复:
    • 函数级防重:daemon 启动前校验 pid 文件 + /proc/<pid>/cmdline 双证据,直调秒退(此前任何绕过 init.d guard 的调用路径都会再起一个进程并覆盖 pid 文件)
    • init.d 补 stop():旧版 restart()=start() 导致升级后旧 daemon 永生(一直跑旧代码)
    • apk postinst 由 start 改 restart:升级时真正换新 daemon
    • trap 退出清理 pid 文件前校验属主:修复升级窗口内旧 daemon 退出误删新 daemon pid 文件的竞态(busybox sh 在 sleep 结束后才处理信号,窗口最长一个轮询周期)

实测

  • 真机(NanoPi R5C / OpenWrt 25.12.6):restart 后 daemon 数量=1;直调 netsteer-qos sense-daemon 退出码 0 且进程数恒 1;doctor 输出 VERDICT: OK,数值字段(SQM 带宽/分载标志)与 audit 原始值一致
  • e2e 新增 2 项(doctor 十段断言 + 直调防重断言),16→18 项全绿;单测 413 项全绿

已知边界

  • doctor 的 daemon 泄漏检测只报告不回收(/etc/init.d/netsteer restart 可手动回收);升级到本版本后存量泄漏进程需要一次 restart
  • 观测面结论依赖 netsteer-qos env 缓存,代理内核刚启停时 doctor 显示的通道可能滞后一个探测周期

v1.20.0 — Feedback loop: one-command diagnostics + leak fix

Highlights

Turns bug reporting from chat logs into a single command. netsteer-doctor prints ten sections plus a VERDICT line, and pairs with the new issue templates to close the feedback loop — the step that takes this from a single-user internal tool to something strangers can actually run. Also fixes the sense-daemon leak caught on day one of 7×24 soak monitoring.

Added

  • netsteer-doctor one-command diagnostics: run it over SSH to collect everything needed to debug — package version, environment, dependencies, SQM state, offload flags, observation channel, scene engine, acceleration tunnels, steering state, config and log tail — ending with a VERDICT line (OK/WARN/FAIL). Known boundaries are flagged automatically: missing deps, flow-offload counter freeze, daemon leaks, degraded DNS observation, SQM disabled, game tunnel without IP, uninitialized state
  • GitHub issue templates: bug report (doctor output required) and feature request, bilingual
  • "Troubleshooting & feedback" section in both READMEs

Fixed

  • sense-daemon process leak (caught on day one of 7×24 soak: 3 orphaned daemons on one box), fixed in four layers:
    • Function-level guard: daemon startup verifies pid file + /proc/<pid>/cmdline as dual evidence; direct invocation exits immediately (previously any path bypassing the init.d guard spawned another process and overwrote the pid file)
    • init.d gains a real stop(): the old restart()=start() meant a daemon survived every upgrade, forever running old code
    • apk postinst now runs restart instead of start so upgrades actually swap the daemon
    • The TERM trap now checks pid-file ownership before deleting: fixes a race where an old daemon's exit removed the new daemon's pid file during the upgrade window (busybox sh handles signals only after sleep returns, so the window lasts up to one poll interval)

Tested

  • On-device (NanoPi R5C / OpenWrt 25.12.6): daemon count = 1 after restart; direct netsteer-qos sense-daemon invocation returns exit code 0 with process count unchanged; doctor reports VERDICT: OK with numeric fields (SQM bandwidth, offload flags) matching raw audit output
  • e2e extended by 2 checks (doctor ten-section assertions + direct-invocation guard), 16→18 all green; 413 unit assertions all green

Known limits

  • Doctor reports daemon leaks but does not recycle them (/etc/init.d/netsteer restart does); pre-existing leaked processes need one restart after upgrading to this version
  • Observation-channel findings rely on the netsteer-qos env cache; right after a proxy core starts or stops, the channel shown by doctor may lag by one probe cycle

Download the .apk matching your device architecture (check /etc/apk/arch on the router).

Install (OpenWrt 24.10+/25.12):

apk add --allow-untrusted /tmp/luci-app-netsteer-*.apk

Built automatically by CI from this tag — unit tests + 4-arch build matrix.
Every package is verified with apk verify before it is attached.