chore(i18n): refresh zh-CN translations

This commit is contained in:
openclaw-docs-i18n[bot] 2026-04-25 01:03:07 +00:00
parent 18e6d9805e
commit 34bbf355c8
2 changed files with 46 additions and 44 deletions

View File

@ -1,14 +1,14 @@
---
read_when:
- 你遇到了连接 / 认证问题,并希望获得引导式修复方案
- 你刚完成更新,并想做一次完整性检查
- 你遇到了连接或凭证问题,并希望获得引导式修复方案
- 你已完成更新,并想进行安装完整性检查
summary: '`openclaw doctor` 的 CLI 参考(健康检查 + 引导式修复)'
title: Doctor
x-i18n:
generated_at: "2026-04-24T04:00:56Z"
generated_at: "2026-04-25T01:02:45Z"
model: gpt-5.4
provider: openai
source_hash: c5ea3f4992effe3d417f20427b3bdb9e47712816106b03bc27a415571cf88a7c
source_hash: 18e185d17d91d1677d0b16152d022b633d012d22d484bd9961820b200d5c4ce5
source_path: cli/doctor.md
workflow: 15
---
@ -34,30 +34,30 @@ openclaw doctor --generate-gateway-token
## 选项
- `--no-workspace-suggestions`:禁用工作区 memory / 搜索建议
- `--yes`:无需提示,直接接受默认值
- `--repair`:无需提示,直接应用推荐修复
- `--no-workspace-suggestions`:禁用工作区 memory/search 建议
- `--yes`:无需提示,接受默认值
- `--repair`:无需提示,应用推荐修复
- `--fix``--repair` 的别名
- `--force`:应用激进修复,包括在需要时覆盖自定义服务配置
- `--force`:应用激进修复,包括在需要时覆盖自定义服务配置
- `--non-interactive`:无提示运行;仅执行安全迁移
- `--generate-gateway-token`:生成并配置 Gateway 网关令牌
- `--generate-gateway-token`:生成并配置 gateway token
- `--deep`:扫描系统服务以查找额外的 Gateway 网关安装
说明:
- 交互式提示(如钥匙串 / OAuth 修复)仅在 stdin 是 TTY 且**未**设置 `--non-interactive` 时运行。无头运行cron、Telegram、无终端跳过提示。
- 性能:非交互式 `doctor` 运行会跳过预先加载插件,以确保无头健康检查保持快速。交互式会话仍会在检查需要插件参与时完整加载插件。
- `--fix``--repair` 的别名)会将备份写入 `~/.openclaw/openclaw.json.bak`,并删除未知配置键,同时列出每一项被删除内容。
- 交互式提示(如钥匙串 / OAuth 修复)仅在 stdin 是 TTY 且**未**设置 `--non-interactive` 时运行。无头运行cron、Telegram、无终端跳过提示。
- 性能:非交互式 `doctor` 运行会跳过预先加载插件,因此无头健康检查可保持快速。交互式会话仍会在某项检查需要插件参与时完整加载插件。
- `--fix``--repair` 的别名)会将备份写入 `~/.openclaw/openclaw.json.bak`,并删除未知配置键,同时列出每一项被移除的内容。
- 状态完整性检查现在会检测会话目录中的孤立 transcript 文件,并可将其归档为 `.deleted.<timestamp>`,以安全回收空间。
- Doctor 还会扫描 `~/.openclaw/cron/jobs.json`(或 `cron.store`)中的旧版 cron 任务结构,并可在调度器于运行时自动规范化之前原地重写它们。
- Doctor 会修复缺失的内置插件运行时依赖,而无需对已安装的 OpenClaw 软件包具有写权限。对于 root 拥有的 npm 安装或加固的 systemd 单元,请将 `OPENCLAW_PLUGIN_STAGE_DIR` 设置为可写目录,例如 `/var/lib/openclaw/plugin-runtime-deps`
- Doctor 会自动将旧版扁平 Talk 配置(`talk.voiceId`、`talk.modelId` 等)迁移为 `talk.provider` + `talk.providers.<provider>`
- 重复运行 `doctor --fix` 时,如果唯一差异只是对象键顺序,将不再报告 / 应用 Talk 规范化。
- Doctor 包含 memory 搜索就绪性检查,并可在缺少嵌入凭证时推荐运行 `openclaw configure --section model`
- Doctor 还会扫描 `~/.openclaw/cron/jobs.json`(或 `cron.store`)中的旧版 cron 作业结构,并可在调度器需要在运行时自动规范化之前就地重写它们。
- Doctor 会修复缺失的内置插件运行时依赖,而不会写入已打包的全局安装目录。对于 root 拥有的 npm 安装或强化配置的 systemd 单元,请将 `OPENCLAW_PLUGIN_STAGE_DIR` 设置为可写目录,例如 `/var/lib/openclaw/plugin-runtime-deps`
- Doctor 会自动将旧版扁平 Talk 配置(`talk.voiceId`、`talk.modelId` 及相关项)迁移到 `talk.provider` + `talk.providers.<provider>`
- 当唯一差异只是对象键顺序时,重复执行 `doctor --fix` 将不再报告 / 应用 Talk 规范化。
- Doctor 包含 memory-search 就绪性检查,并且在缺少 embedding 凭证时会建议运行 `openclaw configure --section model`
- 如果已启用沙箱模式但 Docker 不可用doctor 会报告高信号警告,并提供修复建议(`install Docker` 或 `openclaw config set agents.defaults.sandbox.mode off`)。
- 如果 `gateway.auth.token` / `gateway.auth.password` 由 SecretRef 管理且在当前命令路径中不可用doctor 会报告只读警告,不会写入明文后备凭证。
- 如果在修复路径中检查渠道 SecretRef 失败doctor 会继续执行并报告警告,而不是提前退出。
- Telegram `allowFrom` 用户名自动解析(`doctor --fix`)要求在当前命令路径中存在可解析的 Telegram 令牌。如果令牌检查不可用doctor 会报告警告,并在本次运行中跳过自动解析。
- 如果 `gateway.auth.token` / `gateway.auth.password` 由 SecretRef 管理且在当前命令路径中不可用doctor 会报告只读警告,并且不会写入明文后备凭证。
- 如果在修复路径中渠道 SecretRef 检查失败doctor 会继续执行并报告警告,而不是提前退出。
- Telegram `allowFrom` 用户名自动解析(`doctor --fix`)要求当前命令路径中存在可解析的 Telegram token。如果 token 检查不可用doctor 会报告警告,并在本次运行中跳过自动解析。
## macOS`launchctl` 环境变量覆盖
@ -71,7 +71,7 @@ launchctl unsetenv OPENCLAW_GATEWAY_TOKEN
launchctl unsetenv OPENCLAW_GATEWAY_PASSWORD
```
## 相关内容
## 相关
- [CLI 参考](/zh-CN/cli)
- [Gateway 网关 Doctor](/zh-CN/gateway/doctor)

View File

@ -2,13 +2,13 @@
read_when:
- 更新 OpenClaw
- 更新后出现问题
summary: 安全更新 OpenClaw全局安装或源码安装),以及回滚策略
summary: 安全更新 OpenClaw全局安装或源码以及回滚策略
title: 更新
x-i18n:
generated_at: "2026-04-24T16:58:27Z"
generated_at: "2026-04-25T01:02:44Z"
model: gpt-5.4
provider: openai
source_hash: f57c5f4d4988eabb62a2c836c07f56e329149b1f9290baa0568ef1d86f66e0ad
source_hash: af88eaa285145dd5fc370b28c0f9d91069b815c75ec416df726cfce4271a6b54
source_path: install/updating.md
workflow: 15
---
@ -23,7 +23,7 @@ x-i18n:
openclaw update
```
如需切换道或指定特定版本:
如需切换道或指定特定版本:
```bash
openclaw update --channel beta
@ -31,17 +31,17 @@ openclaw update --tag main
openclaw update --dry-run # 仅预览,不实际应用
```
`--channel beta` 会优先选择 beta但当 beta 标签不存在或版本比最新 stable 发布更旧时,运行时会回退到 stable/latest。如果你想要一次性按原始 npm beta dist-tag 更新包,请使用 `--tag beta`
`--channel beta` 会优先选择 beta但当 beta 标签缺失,或其版本早于最新稳定版时,运行时会回退到 stable/latest。若你想针对一次性的包更新使用原始 npm beta dist-tag,请使用 `--tag beta`
道语义请参见 [Development channels](/zh-CN/install/development-channels)。
道语义请参见 [Development channels](/zh-CN/install/development-channels)。
## 另一种方式:重新运行安装脚本
## 另一种方式:重新运行安装
```bash
curl -fsSL https://openclaw.ai/install.sh | bash
```
添加 `--no-onboard` 可跳过新手引导。对于源码安装,传入 `--install-method git --no-onboard`
添加 `--no-onboard` 可跳过新手引导。对于源码安装,传入 `--install-method git --no-onboard`
## 另一种方式:手动使用 npm、pnpm 或 bun
@ -57,28 +57,30 @@ pnpm add -g openclaw@latest
bun add -g openclaw@latest
```
### 由 root 拥有的全局 npm 安装
### 全局 npm 安装与运行时依赖
某些 Linux npm 环境会将全局包安装到由 root 拥有的目录中,例如 `/usr/lib/node_modules/openclaw`。OpenClaw 支持这种布局:已安装的包在运行时会被视为只读,内置插件的运行时依赖会被暂存到可写的运行时目录中,而不是修改包目录树
OpenClaw 会将打包后的全局安装视为运行时只读,即使当前用户对全局包目录有写权限也是如此。内置插件的运行时依赖会被暂存到一个可写的运行时目录,而不是直接修改包目录树。这样可以避免 `openclaw update` 与正在运行的 Gateway 网关或本地智能体发生竞争,尤其是在同一次安装期间修复插件依赖时
对于加固的 systemd 单元,请设置一个可写的暂存目录,并将其包含在 `ReadWritePaths` 中:
某些 Linux 的 npm 配置会将全局包安装到由 root 拥有的目录下,例如 `/usr/lib/node_modules/openclaw`。OpenClaw 通过同一个外部暂存路径支持这种布局。
对于强化过的 systemd 单元,请设置一个可写的暂存目录,并确保它包含在 `ReadWritePaths` 中:
```ini
Environment=OPENCLAW_PLUGIN_STAGE_DIR=/var/lib/openclaw/plugin-runtime-deps
ReadWritePaths=/var/lib/openclaw /home/openclaw/.openclaw /tmp
```
如果未设置 `OPENCLAW_PLUGIN_STAGE_DIR`OpenClaw 会在 systemd 提供时使用 `$STATE_DIRECTORY`,否则回退到 `~/.openclaw/plugin-runtime-deps`
如果未设置 `OPENCLAW_PLUGIN_STAGE_DIR`OpenClaw 会在 systemd 提供 `$STATE_DIRECTORY` 时优先使用它,否则回退到 `~/.openclaw/plugin-runtime-deps`
### 内置插件运行时依赖
打包安装会将内置插件运行时依赖保留在只读包目录树之外。在启动期间以及执行 `openclaw doctor --fix`OpenClaw 只会为以下内置插件修复运行时依赖:在配置中处于活动状态、通过旧版渠道配置处于活动状态,或由其内置清单默认启用的插件。
打包安装会将内置插件运行时依赖保留在只读包目录树之外。在启动时以及运行 `openclaw doctor --fix` 期间OpenClaw 仅会为以下内置插件修复运行时依赖:在配置中处于活动状态、通过旧版渠道配置处于活动状态,或在其内置清单默认设置中启用的插件。
显式禁用具有最高优先级。已禁用的插件或渠道不会仅因为存在于安装包中就修复其运行时依赖。外部插件和自定义加载路径仍使用 `openclaw plugins install``openclaw plugins update`
显式禁用具有最高优先级。已禁用的插件或渠道不会仅因为存在于安装包中就修复其运行时依赖。外部插件和自定义加载路径仍使用 `openclaw plugins install``openclaw plugins update`
## 自动更新器
自动更新器默认关闭。在 `~/.openclaw/openclaw.json` 中启用
自动更新器默认关闭。在 `~/.openclaw/openclaw.json` 中启用:
```json5
{
@ -96,11 +98,11 @@ ReadWritePaths=/var/lib/openclaw /home/openclaw/.openclaw /tmp
| Channel | 行为 |
| -------- | ---- |
| `stable` | 等待 `stableDelayHours`,然后在 `stableJitterHours` 范围内按确定性抖动应用(分散发布)。 |
| `stable` | 等待 `stableDelayHours`,然后在 `stableJitterHours` 范围内按确定性抖动应用更新(分散发布)。 |
| `beta` | 每隔 `betaCheckIntervalHours` 检查一次(默认:每小时),并立即应用。 |
| `dev` | 不会自动应用。请手动使用 `openclaw update`。 |
Gateway 网关还会在启动时记录更新提示(可通过 `update.checkOnStart: false` 禁用)。
Gateway 网关 还会在启动时记录更新提示(可通过 `update.checkOnStart: false` 禁用)。
## 更新后
@ -112,7 +114,7 @@ Gateway 网关还会在启动时记录更新提示(可通过 `update.checkOnSt
openclaw doctor
```
迁移配置、审核私信策略,并检查 Gateway 网关健康状态。详情: [Doctor](/zh-CN/gateway/doctor)
迁移配置、审计私信策略,并检查 Gateway 网关 健康状态。详情请参见:[Doctor](/zh-CN/gateway/doctor)
### 重启 Gateway 网关
@ -138,9 +140,9 @@ openclaw doctor
openclaw gateway restart
```
提示:`npm view openclaw version` 会显示当前已发布版本。
提示:`npm view openclaw version` 会显示当前已发布版本。
### 固定提交(源码)
### 固定到某个提交(源码)
```bash
git fetch origin
@ -149,7 +151,7 @@ pnpm install && pnpm build
openclaw gateway restart
```
如需恢复到最新版本:`git checkout main && git pull`。
如需返回最新版本:`git checkout main && git pull`。
## 如果你卡住了
@ -160,6 +162,6 @@ openclaw gateway restart
## 相关内容
- [Install Overview](/zh-CN/install) — 所有安装方式
- [安装概览](/zh-CN/install) — 所有安装方式
- [Doctor](/zh-CN/gateway/doctor) — 更新后的健康检查
- [Migrating](/zh-CN/install/migrating) — 主要版本迁移指南
- [迁移](/zh-CN/install/migrating) — 主要版本迁移指南