Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

br: add "tiup br debug" command #18161

Merged
merged 7 commits into from
Aug 5, 2024
Merged
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 11 additions & 1 deletion br/use-br-command-line-tool.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,23 @@ tiup br backup full --pd "${PD_IP}:2379" \
* `tiup br backup`:用于备份 TiDB 集群的全量数据。
* `tiup br log`:用于启动和管理日志备份任务。
* `tiup br restore`:用于恢复备份数据到 TiDB 集群。
* `tiup br debug`:用于解析备份元信息,检查备份数据等操作。

`tiup br backup` 和 `tiup br restore` 还包含这些子命令
`tiup br backup` 和 `tiup br restore` 还包含以下子命令
lilin90 marked this conversation as resolved.
Show resolved Hide resolved

* `full`:用于备份或恢复整个备份数据。
* `db`:用于备份或恢复集群中的指定数据库。
* `table`:用于备份或恢复集群指定数据库中的单张表。

`tiup br debug` 包含以下子命令:

* `checksum`:(隐藏参数)离线校验备份数据完整性,确保全部备份文件跟记录的 [`ADMIN CHECKSUM TABLE`](/sql-statements/sql-statement-admin-checksum-table.md) 计算的 CRC64 校验结果一致。
* `backupmeta`:检查备份数据文件是否有交集。正常情况下备份数据没有交集。
* `decode`:将全量备份的元信息 `backupmeta` 文件解析成 JSON 格式,并且支持通过 `--field` 参数解析特定的字段。
* `encode`:将全量备份的元信息 `backupmeta.json` 文件编码成恢复数据时使用的 protobuf 格式。
lilin90 marked this conversation as resolved.
Show resolved Hide resolved
* `reset-pd-config-as-default`:复原数据恢复过程中改变的 PD 设置(已废弃)。
lilin90 marked this conversation as resolved.
Show resolved Hide resolved
* `search-log-backup`:在日志备份数据中查找特定的 Key 信息。

lilin90 marked this conversation as resolved.
Show resolved Hide resolved
### 常用选项

* `--pd`:PD 访问地址选项,例如 `"${PD_IP}:2379"`。
Expand Down
Loading