Emergency recovery tool for OpenClaw. Diagnoses and fixes unresponsive bots via SSH.
The script is bundled at scripts/sos.sh. Install locally:
bash
cp scripts/sos.sh /usr/local/bin/sos
chmod +x /usr/local/bin/sos
To install on a remote machine:
bash
scp scripts/sos.sh root@<IP>:/usr/local/bin/sos
ssh root@<IP> "chmod +x /usr/local/bin/sos"
Alternative — install from GitHub:
bash
curl -fsSL https://raw.githubusercontent.com/clawsos/claw-sos/main/install.sh | bash
bash
sos # whiptail arrow-key menu
bash
sos auto # autofix: diagnose → doctor → restart → force → nuclear
sos net # network check only
sos tg # telegram test message
sos --version
sos --help
sos auto — handles 95% of cases automaticallysos net — if network is broken, fix DNS/internet firstsos tg — check Telegram deliverysos menu option 9 (Nuclear) — kills everything and starts fresh#NameWhat it doesSafe?1Check statusGateway running, RAM, disk, version✅ Read-only2RestartGraceful restart✅ Safe3Force killKill process + restart⚠️ Drops active sessions4RollbackRevert to previous version + config⚠️ Downgrade5View logsLast 50 lines of gateway log✅ Read-only6Full diagnosticRAM, disk, Telegram, sessions, process✅ Read-only7Backup configSave config + version before changes✅ Safe8Self-testVerify SOS script works✅ Read-only9NuclearKill ALL openclaw processes, reload🔴 Last resort10AutofixEscalating auto-repair⚠️ May restart11Network checkDNS, internet, Telegram API, Anthropic✅ Read-only12Telegram testSend real test message✅ Safe
openclaw doctor --fixStops as soon as gateway is healthy.
All actions logged to ~/.openclaw/backups/sos.log. Read this to understand what happened during recovery:
bash
cat ~/.openclaw/backups/sos.log
This skill uses no API keys or tokens of its own. It reads existing OpenClaw config to:
openclaw.json)No credentials are stored, transmitted, or required to install or run SOS.