From eca24d9245b9ed86d07a66fd10695a7ce03705e7 Mon Sep 17 00:00:00 2001 From: Liuxiaozhen12 Date: Mon, 19 Jul 2021 16:23:22 +0800 Subject: [PATCH 1/2] br/use-br-command-line-tool: supplement br note --- br/use-br-command-line-tool.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/br/use-br-command-line-tool.md b/br/use-br-command-line-tool.md index 25fc603e680d3..85b6f9016c382 100644 --- a/br/use-br-command-line-tool.md +++ b/br/use-br-command-line-tool.md @@ -361,6 +361,10 @@ br restore db \ In the above command, `--db` specifies the name of the database to be restored. For descriptions of other options, see [Restore all backup data](#restore-all-the-backup-data)). +> **Note**: +> +> When you are restoring the backup data, the name of the database specified by `--db` must be the same as the one specified by `-- db` when the backup is in progress, otherwise the process fails. The reason is that the metafile `backupmeta` of the backup data records the database name so you can only restore data to the database with the same name. You are recommended to restore the backup data to the database with the same name of another cluster. + ### Restore a table To restore a single table to the cluster, execute the `br restore table` command. To get help on this command, execute `br restore table -h` or `br restore table --help`. From d0eddc1eed8c8e860d18cef6f365992117fc7121 Mon Sep 17 00:00:00 2001 From: Liuxiaozhen12 <82579298+Liuxiaozhen12@users.noreply.github.com> Date: Thu, 5 Aug 2021 19:48:08 +0800 Subject: [PATCH 2/2] Apply suggestions from code review Co-authored-by: TomShawn <41534398+TomShawn@users.noreply.github.com> --- br/use-br-command-line-tool.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/br/use-br-command-line-tool.md b/br/use-br-command-line-tool.md index 85b6f9016c382..6921d73670a03 100644 --- a/br/use-br-command-line-tool.md +++ b/br/use-br-command-line-tool.md @@ -361,9 +361,9 @@ br restore db \ In the above command, `--db` specifies the name of the database to be restored. For descriptions of other options, see [Restore all backup data](#restore-all-the-backup-data)). -> **Note**: +> **Note:** > -> When you are restoring the backup data, the name of the database specified by `--db` must be the same as the one specified by `-- db` when the backup is in progress, otherwise the process fails. The reason is that the metafile `backupmeta` of the backup data records the database name so you can only restore data to the database with the same name. You are recommended to restore the backup data to the database with the same name of another cluster. +> When you restore the backup data, the name of the database specified by `--db` must be the same as the one specified by `-- db` in the backup command. Otherwise, the restore fails. This is because the metafile of the backup data ( `backupmeta` file) records the database name, you can only restore data to the database with the same name. The recommended method is to restore the backup data to the database with the same name in another cluster. ### Restore a table