Skip to main content

SHOW BACKUP

Description​

This statement is used to view BACKUP tasks

Syntax​

SHOW BACKUP [FROM <db_name>]
[WHERE SnapshotName { LIKE | = } '<snapshot_name>' ]

Parameters​

1.<db_name>

The name of the database to which the backup task belongs.

2.<snapshot_name>

Backup name.

Return Value​

ColumnDescription
JobIdUnique job id
SnapshotNameThe name of the backup
DbNamebelongs to the database
Statecurrent stage:
  • PENDING: The initial state after submitting the job.
  • SNAPSHOTING: Executing snapshot.
  • UPLOAD_SNAPSHOT: Snapshot completed, ready to upload.
  • UPLOADING: Snapshot uploading.
  • SAVE_META: Save job meta information to a local file.
  • UPLOAD_INFO: Upload job meta information.
  • FINISHED: The job was successful.
  • CANCELLED: Job failed.
BackupObjsBacked up tables and partitions
CreateTimetask submission time
SnapshotFinishedTimeSnapshot completion time
UploadFinishedTimeSnapshot upload completion time
FinishedTimeJob finish time
UnfinishedTasksDisplays unfinished subtask ids during SNAPSHOTING and UPLOADING stages
ProgressTask progress
TaskErrMsgDisplay task error messages
StatusIf the job fails, display the failure message
TimeoutJob timeout, in seconds

Example​

  1. View the last BACKUP task under example_db.
SHOW BACKUP FROM example_db;