#!/bin/bash # 看配比对照有没有开始 set -u echo " ── 隧道当前配比 ──" for s in lanremote-tunnel lanremote-tunnel-h2; do printf " %-24s %s (%s)\n" "$s" \ "$(grep -oE -- '--ha-connections [0-9]+' "/etc/systemd/system/$s.service" 2>/dev/null | tr '\n' ' ')" \ "$(systemctl is-active "$s" 2>/dev/null)" done echo echo " ── 对照脚本/进程 ──" pgrep -af 'ab_long|rp_ab|collapse|ratio' 2>/dev/null | head -5 | sed 's/^/ /' || echo " (没在跑)" echo echo " ── 最近 20 分钟内设备上改过的文件 ──" find /root -maxdepth 1 -type f -mmin -20 2>/dev/null | head -10 | sed 's/^/ /' || true echo echo " ── 有没有对照的产物 ──" ls -la --time-style=+%H:%M /root/*ab*.tsv /root/*ab*.out /root/*ratio*.tsv /root/*collapse*.tsv 2>/dev/null | sed 's/^/ /' || echo " (没有)" echo echo " ── 公网 ──" curl -s --max-time 20 -o /dev/null -w ' HTTP %{http_code} %{time_total}s\n' \ -H 'User-Agent: LanRemote/1.8.2' https://relay.xxmxxs.top/v1/health echo echo " ── 时间 ──" date '+ %H:%M:%S'