← 返回
开发者工具

Gateway Watchdog Lite

Installs a macOS or Linux service that probes the OpenClaw gateway every 2 minutes and auto-recovers it on failure, sending Telegram alerts.
安装 macOS/Linux 服务,每 2 分钟探测 OpenClaw 网关,故障自动恢复并发送 Telegram 告警。
judas-oc
开发者工具 clawhub v1.0.2 1 版本 100000 Key: 无需
★ 0
Stars
📥 642
下载
💾 9
安装
1
版本
#auto-recovery#gateway#latest#linux#macos#reliability#vps#watchdog

概述

Gateway Watchdog Lite

Overview

The gateway-watchdog-lite skill installs a macOS LaunchAgent or Linux systemd user service that monitors the OpenClaw gateway every 2 minutes. If the gateway is unresponsive, it automatically runs the recovery sequence and alerts via Telegram.

Supported platforms:

  • macOS (LaunchAgent) — scripts/install.sh
  • Linux (systemd user service) — scripts/install-linux.sh

What It Does

FeatureDetail
------
Probe intervalEvery 120 seconds
Health checkHTTP probe to 127.0.0.1: — accepts 200, 301, 302
Auto-recoverylaunchctl bootout + launchctl bootstrap (macOS) / systemctl restart (Linux)
Cooldown5 minutes between recovery attempts (anti-thrash)
AlertsTelegram via gog telegram send — success and failure
Logs/tmp/openclaw/gateway-watchdog.log

> Want crash loop detection + auto-mitigation? Upgrade to the full Gateway Watchdog skill (paid, from confuseduser.com).

Install

macOS

WORKSPACE_PATH=/your/workspace OC_PORT=18789 TELEGRAM_ID=your_id bash scripts/install.sh

To disable Telegram alerts:

WORKSPACE_PATH=/your/workspace OC_PORT=18789 TELEGRAM_ID="" bash scripts/install.sh
VariableRequiredDescriptionHow to find it
------------
WORKSPACE_PATHPath to your OpenClaw workspace rootRun openclaw status
OC_PORTGateway port to probe (default: 18789)Run openclaw status
TELEGRAM_ID⬜ OptionalYour Telegram user IDMessage @userinfobot on Telegram

Linux

WORKSPACE_PATH=/your/workspace OC_PORT=18789 TELEGRAM_ID=your_id bash scripts/install-linux.sh

Verify (macOS)

launchctl list | grep watchdog

Verify (Linux)

systemctl --user status gateway-watchdog

Logs

tail -f /tmp/openclaw/gateway-watchdog.log

Manual Trigger

Test the watchdog immediately:

bash scripts/gateway-watchdog.sh

Reset cooldown first if testing recovery:

rm -f /tmp/openclaw/watchdog-last-recovery
bash scripts/gateway-watchdog.sh

Uninstall

macOS

launchctl bootout gui/$UID/ai.openclaw.gateway-watchdog
rm ~/Library/LaunchAgents/ai.openclaw.gateway-watchdog.plist

Linux

systemctl --user stop gateway-watchdog
systemctl --user disable gateway-watchdog
rm ~/.config/systemd/user/gateway-watchdog.service
systemctl --user daemon-reload

Recovery Gotchas

See references/gotchas.md for OC-specific recovery notes including:

  • GGML Metal crash on restart — add GGML_NO_METAL=1 to env vars
  • openclaw gateway install --force — use after config changes
  • Bootout + bootstrap sequence — the correct recovery pattern
  • Cooldown logic — 5 min between attempts, reset with rm /tmp/openclaw/watchdog-last-recovery
  • Telegram alert failures — won't block recovery (uses || true)

版本历史

共 1 个版本

  • v1.0.2 当前
    2026-03-19 07:23 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

developer-tools

Github

steipete
使用 `gh` CLI 与 GitHub 交互,通过 `gh issue`、`gh pr`、`gh run` 和 `gh api` 管理议题、PR、CI 运行及高级查询。
★ 666 📥 323,793
developer-tools

Gog

steipete
Google Workspace 命令行工具,支持 Gmail、日历、云端硬盘、通讯录、表格和文档。
★ 920 📥 185,727
developer-tools

CodeConductor.ai

larsonreever
AI驱动平台,提供快速全栈开发、智能体、工作流自动化及低代码AI集成的可扩展产品创建。
★ 65 📥 179,843