Will data writes during the BR restore process affect the restore results?

This topic has been translated from a Chinese forum by GPT and might contain errors.

Original topic: 如果在使用br恢复的过程中有数据写入,会对恢复结果造成影响吗?

| username: 滴滴嗒嘀嗒

Mirror issue: 如果在使用br备份的过程中有数据写入,会对备份结果造成影响吗? - #12,来自 TiDBer_QYr0vohO - TiDB 的问答社区

For example, if a BR restore takes 1 hour (let’s assume from 9:00 to 10:00), and I insert a large amount of data into a table (let’s assume Table A) at 9:30, will it affect the final restore result?
Let’s assume an extreme situation: if an insert operation is performed on Table A while BR is also restoring that table, what will the data in Table A look like once the restore task is completed? Will there be any disorder?

| username: 大飞哥online | Original post link

If new data is written during the recovery process, this newly written data will conflict with the backup data, potentially leading to data inconsistency or loss.

| username: 大飞哥online | Original post link

To ensure the accuracy and completeness of the recovery, please avoid performing DDL and DML operations such as writing, deleting, or creating tables in the cluster during the recovery process. This is because the backup data may contain DDL operations that rename tables. If the cluster data is modified during the recovery process, the recovery operation will not be able to determine whether the deleted or existing tables were caused by external operations, which will affect the accuracy of the next recovery attempt.

| username: WalterWj | Original post link

Restoration requires the target cluster to be a new cluster and no changes should be made during the import process.

| username: 舞动梦灵 | Original post link

Generally, this situation is prohibited. If data is being imported into a table while a recovery is in progress, two things can happen: 1. The recovery will directly report an error and abort. 2. The recovery will continue, but the table data may be incomplete. After the recovery is completed, there will be a checksum, and this result will definitely indicate an issue.

During recovery and import operations, only one operation should be performed at a time to avoid accidents. If data import is detected during recovery, the normal procedure should be to stop everything, delete, and restart the recovery.

| username: tidb菜鸟一只 | Original post link

It will have an impact,
the data will be messed up in the end.

| username: Fly-bird | Original post link

MVCC ensures the consistency of backup data timing.

| username: system | Original post link

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.