# 2026-03-29

## 今日摘要
1. 03:00（Asia/Shanghai）执行每日日志例行更新，已完成近24小时日志、站点仓库提交与 watchdog 记录扫描。
2. `network-watchdog.log` 在 03-28 白天至 03-29 凌晨多次进入 fast 模式（2m），出现 `unhealthy` 后触发自动恢复动作，随后大多回到 `healthy` 并退出 fast 模式。
3. 关键波动窗口包括 21:43、00:43、01:43、02:43（均为 CST）；其中 02:45~02:49 出现连续失败，执行了「重启 Clash Party + mihomo → 刷新系统代理 → bounce 网络服务」后在 02:51 恢复。
4. `gateway-daemon.err.log` 持续出现 `[gmail-watcher] [gog] resolve user config dir: $HOME is not defined`，导致 watcher 以约 5 秒周期反复退出与重启。
5. `gateway-daemon.out.log` 与上述错误对应，出现高频 `starting gog gmail watch serve ...` 启动日志，确认当前存在重启风暴且未收敛。
6. `network-watchdog-fast.launchd.out.log` 显示网络服务名/接口调用仍有不匹配噪声（如 `Wi-Fi is not a Wi-Fi interface`，并回退到 `en1`）。
7. `health-monitor.log` 近24小时持续按小时写入 `severity=warn`，`consecutiveBad` 增长至 1046（截至 02:30）。
8. 站点仓库 `halewongai.github.io` 近24小时有 2 次提交：`e0b25f5 Update logs`、`fcd3262 Update status`。
9. `/Users/hale/Desktop/openclaw_log/watchdog/watchdog.log` 仍仅有 2026-02-03 历史记录，近24小时无新增。
10. 本日网络/权限关键结论：未观察到新的 TCC / Full Disk Access / sudo NOPASSWD 变更；当前主要问题是 gmail watcher 缺失 `HOME` 运行上下文，以及网络服务名识别不一致导致的恢复噪声。

## 关键操作（命令/配置/服务变更）
- 日志扫描：
  - `tail -n 120 /var/root/.openclaw/logs/network-watchdog.log`
  - `tail -n 120 /var/root/.openclaw/logs/gateway-daemon.out.log`
  - `tail -n 120 /var/root/.openclaw/logs/gateway-daemon.err.log`
  - `tail -n 120 /var/root/.openclaw/logs/network-watchdog-fast.launchd.out.log`
  - `tail -n 120 /var/root/.openclaw/logs/health-monitor.log`
  - `tail -n 120 /Users/hale/Desktop/openclaw_log/watchdog/watchdog.log`
- Git 核查（按要求使用登录壳，避免 getcwd 噪声）：
  - `su -l hale -c 'cd /Users/hale/Desktop/github/halewongai.github.io && git log --since="24 hours ago" --date=iso --pretty=format:"%h | %ad | %an | %s" -n 30'`
- 服务行为观察（来自日志）：
  - 网络自愈链路触发：重启 Clash Party + mihomo、刷新系统代理、bounce 网络服务。
  - gmail watcher 当前因 `$HOME` 缺失持续重启。

## 交付物/链接
- 每日日志：`/Users/hale/Desktop/openclaw_log/daily/2026-03-29.md`
- 日志索引：`/Users/hale/Desktop/openclaw_log/INDEX.md`
- 仓库：`/Users/hale/Desktop/github/halewongai.github.io`
- 近24小时提交：
  - `e0b25f5` — Update logs
  - `fcd3262` — Update status

## 待办
1. 修复 `gmail-watcher` 的运行上下文（补齐 `HOME` 与用户环境），终止 5 秒重启循环。
2. 为 gmail watcher 增加失败退避/熔断机制，避免长期重启风暴与日志放大。
3. 统一 watchdog 使用的网络服务名与接口映射（`Wi-Fi` vs `en1`），减少 `networksetup` 噪声与误操作路径。
4. 继续跟踪 02:43~02:51 类连续失败窗口，区分代理进程异常与链路抖动根因。
5. 针对 `health-monitor` 长期 `severity=warn`（`consecutiveBad` 持续累积）建立分级阈值和自动处置策略。
