How to Cancel BR Backup

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

Original topic: BR备份怎么取消

| username: TiDB超级萌新

How do you cancel the execution of the BR command midway when using BR for backup or restore? Is there a BR command to cancel it? Is Ctrl + C the only way? I’m not referring to log backups, but how to terminate snapshot backups midway through the task. Also, how do you know the backup progress percentage when using BR for backup or restore? This can be known when using SQL for backup. I mean, without looking at the terminal, I use a Go program to call BR.

| username: TiDBer_vfJBUcxl | Original post link

Execute the br log pause command to pause the currently running log backup task.

| username: TiDB超级萌新 | Original post link

What I meant is, during a snapshot backup, is there any command that can stop it?

| username: TiDBer_小阿飞 | Original post link

| username: TiDB超级萌新 | Original post link

This is for log backup, right?
I mean terminating the task during the read progress of snapshot backup.

| username: TiDBer_小阿飞 | Original post link

The br log truncate command is used to delete expired or no longer needed backup log data from the backup storage.
br log stop is used to stop the backup task and delete the task metadata.

That’s how I understand it, but I haven’t tested it!

| username: TiDB超级萌新 | Original post link

I’ve tried all of these. What I’m referring to is not log backup but snapshot backup. During the backup process, when it’s at 20% or 30%, I want to stop it abruptly. I couldn’t find this in the documentation. Do I have to use CTRL+C?

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

The br backup is just one command, if you want to stop it, just kill it.

| username: Jolyne | Original post link

Just kill the background process directly.

| username: TiDB超级萌新 | Original post link

Alright, it seems this is the only way.

| username: caiyfc | Original post link

You can only kill it. During the backup, progress is output every 5 minutes, but not as a percentage. During the restore, the log will print the percentage progress.

| username: 哈喽沃德 | Original post link

kill -9 solves everything

| username: DBAER | Original post link

Use kill

| username: 小于同学 | Original post link

force kill

| username: TIDB-Learner | Original post link

Directly killing it may cause some issues.

| username: kkpeter | Original post link

Kill the br command.

| username: dba远航 | Original post link

Find the process ID and kill it directly.

| username: redgame | Original post link

If killing the process doesn’t work, you can only restart. I’ve seen this happen…

| username: kelvin | Original post link

The almighty kill -9

| username: system | Original post link

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