Note
This view is available starting with V4.0.0.
Purpose
This view displays all backup jobs in the current cluster. A job record is added for each backup job initiated by a user.
Columns
| Column | Type | Nullable? | Description |
|---|---|---|---|
| TENANT_ID | bigint(20) | NO | The tenant ID. |
| JOB_ID | bigint(20) | NO | The backup job ID. Each backup job corresponds to one job task record. |
| INCARNATION | bigint(20) | NO | The number of times the database has been flashed back. |
| BACKUP_SET_ID | bigint(20) | YES | The ID of the backup set. For the sys tenant, the value is 0. For other tenants, it starts at 1 and increments for each new backup. |
| INITIATOR_TENANT_ID | bigint(20) | NO | The tenant ID of the initiator of the task, corresponding to the tenant that executed the backup SQL command. |
| INITIATOR_JOB_ID | bigint(20) | NO | The job ID of the task initiator. |
| EXECUTOR_TENANT_ID | varchar(65536) | NO | The tenant ID that is associated with the backup task at the job level and that needs to be backed up. |
| PLUS_ARCHIVELOG | varchar(4096) | NO | Whether to enable archive log filling: |
| BACKUP_TYPE | varchar(4096) | NO | Backup type:
|
| JOB_LEVEL | varchar(4096) | NO | JOB level. Valid values: |
| ENCRYPTION_MODE | varchar(4096) | YES | Encryption mode: Currently, only None and Password are supported. |
| PASSWD | varchar(4096) | YES | The password. |
| START_TIMESTAMP | timestamp(6) | NO | The start time of the job-level backup task. |
| END_TIMESTAMP | timestamp(6) | NO | The end time of the job-level backup task. |
| STATUS | varchar(4096) | NO | Backup status. |
| RESULT | bigint(20) | NO | Backup error code. |
| COMMENT | varchar(4096) | YES | Error code description. |
| DESCRIPTION | varchar(4096) | YES | User-specified backup description. |
| PATH | varchar(4096) | YES | Backup path. |
Sample query
In the system tenant, view the backup jobs of the tenant with ID 1002.
obclient [oceanbase]> SELECT * FROM oceanbase.CDB_OB_BACKUP_JOBS WHERE TENANT_ID = 1002\G
The query result is as follows:
*************************** 1. row ***************************
TENANT_ID: 1002
JOB_ID: 2
INCARNATION: 1
BACKUP_SET_ID: 2
INITIATOR_TENANT_ID: 1002
INITIATOR_JOB_ID: 0
EXECUTOR_TENANT_ID: 1002
PLUS_ARCHIVELOG: OFF
BACKUP_TYPE: FULL
JOB_LEVEL: USER_TENANT
ENCRYPTION_MODE: NONE
PASSWD:
START_TIMESTAMP: 2025-01-07 14:24:12.797543
END_TIMESTAMP: NULL
STATUS: DOING
RESULT: 0
COMMENT:
DESCRIPTION:
PATH: file:///home/admin/oceanbase/backupdata
1 row in set