← 返回 Skills 市场
178
总下载
0
收藏
0
当前安装
10
版本数
在 OpenClaw 中安装
/install error-monitor-fix
功能描述
错误监控 - 扫描 JSON 日志、捕获 ERROR 级别错误、OpenClaw 系统级错误修复建议
使用说明 (SKILL.md)
Error Monitor Fix — 错误监控技能
版本: 2.3.0 (所有修复策略改为提示手动,不再执行文件系统修改)
创建日期: 2026-03-23
更新日期: 2026-04-14
📋 功能
实时监控 OpenClaw 运行日志中的 error 类型错误,自动追加到 error.md,并尝试自动修复。
📂 文件结构
skills/error-monitor-fix/
├── SKILL.md
├── skill.json
├── _meta.json # ClawHub 元数据
└── scripts/
├── monitor-error.js # 错误监控(JSON 日志解析 + 去重)
└── auto-fix.js # 自动修复(5 种策略)
🔧 修复策略
| 策略 | 匹配条件 | 动作 |
|---|---|---|
| Gateway 重启(提示手动) | gateway/ws/连接错误 | ⚠️ 提示用户手动重启 |
| 端口释放(只读检查) | EADDRINUSE | 检查 node 监听端口 |
| 会话清理(只读检查) | INVALID_REQUEST | dry-run 检查 |
缓存清理、权限修复属于 dev/test/rule 子代理操作范畴,不属于本技能。
📊 Cron 任务
| 任务名 | 频率 | Job ID |
|---|---|---|
| 错误监控修复 | 每 5 分钟 | 176ecc83 |
⚠️ 注意事项
- 去重窗口:1 小时(避免同一错误重复报告)
- 日志格式:JSON 行格式
- 输出:追加到
memory/error.md
安全使用建议
This skill is plausible for log monitoring, but there are clear inconsistencies you should resolve before installing: (1) SKILL.md claims no filesystem writes, yet the scripts append to ~/.openclaw/workspace/error.md and write .error-dedup.json / .fix-log.json — if you want read-only behavior, inspect and remove file-write calls. (2) skill.json references scripts/install.sh which is missing — ask the author or treat that as a packaging error. (3) auto-fix.js runs system commands (ss, openclaw sessions cleanup --dry-run); these will execute on your machine when you run the scripts. Recommended next steps: review the two JS files line-by-line (or run them in an isolated sandbox/container), back up ~/.openclaw/workspace before running, verify presence/trust of the openclaw CLI, and if you need stricter guarantees, modify the scripts to run in dry-run/read-only mode only. If you cannot verify the missing install script or the author identity, treat this skill cautiously and avoid giving it persistent or automated execution on production hosts.
功能分析
Type: OpenClaw Skill
Name: error-monitor-fix
Version: 3.0.0
The skill bundle is classified as suspicious primarily because `skill.json` defines a `postinstall` script (`scripts/install.sh`) that is missing from the provided files, preventing a full audit of the installation behavior. Additionally, `scripts/auto-fix.js` utilizes `execSync` to execute shell commands (e.g., `ss` and `openclaw sessions cleanup`), which is a high-risk capability. While the current logic appears diagnostic, the script's reliance on parsing logs from the world-writable `/tmp` directory to trigger these commands creates a potential vector for local exploitation if log content is manipulated.
能力评估
Purpose & Capability
Name/description align with the provided scripts: both monitor /tmp/openclaw/*.log and produce fix suggestions. That capability justifies reading logs and producing reports. Minor mismatch: skill.json declares a postinstall script (bash scripts/install.sh) and systemd requirement, but no install.sh exists in the bundle — this is incoherent and could be a packaging/metadata error.
Instruction Scope
SKILL.md states “所有修复策略改为提示手动,不再执行文件系统修改”, but both scripts write to ~/.openclaw/workspace (append error.md, write .error-dedup.json and .fix-log.json). auto-fix.js executes system commands via child_process.execSync (ss pipeline and openclaw sessions cleanup --dry-run). The runtime instructions/behavior therefore go beyond the read-only description in SKILL.md.
Install Mechanism
No install spec is provided (instruction-only), which is low-risk, but skill.json lists a postinstall script (bash scripts/install.sh) that is missing from the package. That metadata/code mismatch is suspicious: either an expected install script is omitted or metadata was not updated. The included Node scripts will run if invoked but there is no automated installer in the bundle.
Credentials
The skill requests no credentials and no declared env vars, and only reads HOME (process.env.HOME). That is proportionate. However the code reads /tmp logs, writes to ~/.openclaw/workspace, and runs system commands (ss, openclaw CLI), which means it will access local system state and potentially require privileges to inspect sockets — appropriate for a monitoring tool but worth noting because SKILL.md claimed no filesystem modifications while the code does persist data.
Persistence & Privilege
always is false and the skill does not request elevated platform privileges. It does not modify other skills' configuration. Autonomous invocation is permitted (platform default) but not combined with an 'always:true' flag or broad credential requests.
如何使用
- 确保已安装 OpenClaw(本地或 Docker 部署)
- 在对话框中输入安装命令:
/install error-monitor-fix - 安装完成后,直接呼叫该 Skill 的名称或使用
/error-monitor-fix触发 - 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v3.0.0
职责边界重构: 移除缓存清理/权限修复(属dev/test/rule子代理操作),保留Gateway重启/端口检查/会话清理3个系统级策略
v2.3.0
所有修复策略改为提示手动: Gateway重启/缓存清理/权限修复 不再执行 rm-rf/chmod 等文件系统修改,仅提示用户手动操作
v2.2.0
移除硬编码的项目路径 /www/wwwroot/www.900az.com/runtime/*,缓存清理只清理工作区 runtime
v2.1.0
Gateway 连接错误改为提示用户手动重启,不再自动重启网关
v2.0.3
错误监控与自动修复技能更新
v2.0.2
错误监控与自动修复技能更新,作者改为c32
v2.0.1
错误监控与自动修复技能 - 实时捕获 error 日志 + 自动修复
v2.0.0
Node.js 重写,JSON 日志解析 + 5 种自动修复策略
v1.0.2
移除 install.sh 中的 hook 注册逻辑; 更新 SKILL.md 文档
v1.0.1
改名 error-monitor → error-monitor-fix; 移除不必要的 gateway:startup hook; 纯定时任务驱动
元数据
常见问题
Error Monitor Fix 是什么?
错误监控 - 扫描 JSON 日志、捕获 ERROR 级别错误、OpenClaw 系统级错误修复建议. 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 178 次。
如何安装 Error Monitor Fix?
在 OpenClaw 或 Claude Code 对话框中运行命令「/install error-monitor-fix」即可一键安装,无需额外配置。
Error Monitor Fix 是免费的吗?
是的,Error Monitor Fix 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。
Error Monitor Fix 支持哪些平台?
Error Monitor Fix 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。
谁开发了 Error Monitor Fix?
由 c32(@amd5)开发并维护,当前版本 v3.0.0。
推荐 Skills