Ubuntu操作系统服务器安装OpenClaw详细教程

张开发
2026/4/16 15:35:02 15 分钟阅读

分享文章

Ubuntu操作系统服务器安装OpenClaw详细教程
需要先切换root才可以安装依赖sudo -i先更新系统依赖apt update apt upgrade -y安装 Linux 构建工具对应脚本里的 make/g/cmake/python3apt install -y build-essential cmake python3 python3-pip安装系统原生 Node.js 22.xcurl -fsSL https://deb.nodesource.com/setup_22.x | sudo -E bash - sudo apt-get install -y nodejs配置阿里云npm源npm config set registry https://registry.npmmirror.com配置腾讯云npm源 二选一 npm config set registry http://mirrors.tencent.com/npm/避免 SSL 校验失败npm config set strict-ssl false移除代理配置npm config delete proxy npm config delete https-proxy查看配置信息npm config list npm config ls -l | grep registry npm config get registry安装 OpenClaw指定版本 ( 推荐安装 2026.3.8或者2026.3.28 )npm add -g openclawv2026.3.28 npm add -g openclawv2026.3.8先验证版本 确保没有安装失败 openclaw --version which openclaw测试 openclaw 是否正常直接运行测试openclaw --help需要自行手动安装通道默认使用的飞书。根据自己的实际情况来定初始化openclawopenclaw onboard启动 openclaw gateway start 停止 openclaw gateway stop 重启 openclaw gateway restart 强制重启 openclaw gateway stop sleep 2 openclaw gateway start 状态 openclaw gateway status 设备配对批准最新设备配对 openclaw devices approve --latest 查看已配对设备 openclaw devices list 验证进程 ps aux | grep openclaw | grep -v grep 验证是否在跑 ps aux | grep openclaw

更多文章