卸载
两条路径:- 如果
openclaw仍然安装,选择 简单路径。 - 如果 CLI 已消失但服务仍在运行,选择 手动服务移除。
简单路径 (CLI 仍安装)
推荐:使用内置卸载程序:- 停止网关服务:
- 卸载网关服务 (launchd/systemd/schtasks):
- 删除状态 + 配置:
OPENCLAW_CONFIG_PATH 设置为状态目录之外的自定义位置,也删除该文件。
- 删除你的工作区 (可选,删除智能体文件):
- 移除 CLI 安装 (选择你使用的那个):
- 如果你安装了 macOS 应用:
- 如果你使用了配置文件 (
--profile/OPENCLAW_PROFILE),请为每个状态目录重复步骤 3 (默认为~/.openclaw-<profile>)。 - 在远程模式下,状态目录位于 网关主机 上,因此也在那里运行步骤 1-4。
手动服务移除 (CLI 未安装)
如果网关服务继续运行但openclaw 丢失,请使用此方法。
macOS (launchd)
默认标签为bot.molt.gateway (或 bot.molt.<profile>; 旧版 com.openclaw.* 可能仍存在):
bot.molt.<profile>。如果存在,请删除任何旧版 com.openclaw.* plist。
Linux (systemd 用户单元)
默认单元名称为openclaw-gateway.service (或 openclaw-gateway-<profile>.service):
Windows (计划任务)
默认任务名称为OpenClaw Gateway (或 OpenClaw Gateway (<profile>))。
任务脚本位于你的状态目录下。
~\.openclaw-<profile>\gateway.cmd。
正常安装 vs 源码 checkout
正常安装 (install.sh / npm / pnpm / bun)
如果你使用了https://openclaw.bot/install.sh 或 install.ps1,CLI 是通过 npm install -g openclaw@latest 安装的。
用 npm rm -g openclaw (如果你是以这种方式安装的,则用 pnpm remove -g / bun remove -g) 移除它。
源码 checkout (git clone)
如果你从仓库 checkout 运行 (git clone + openclaw ... / bun run openclaw ...):
- 在删除仓库 之前 卸载网关服务(使用上面的简单路径或手动服务移除)。
- 删除仓库目录。
- 如上所示删除状态 + 工作区。