Note
This view is available starting with V4.0.0.
Purpose
Purpose This view displays all backup jobs in the cluster for all tenants. One job record is created for each backup task initiated by the user.
Columns
| Column | Column | Nullable | Description | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| TENANT_ID | bigint(20) | NO | Tenant ID | ||||||||||
| FIELD | TYPE | NULLABLE | DESCRIPTION | --- | --- | --- | --- | JOB_ID | bigint(20) | NO | The ID of the backup job. One backup task record corresponds to a job. | ||
| Column | Type | Nullable | Description | --- | --- | --- | --- | INCARNATION | bigint(20) | NO | This column records the number of times a flashback is performed on the database. | ||
| BACKUP_SET_ID | bigint(20) | YES | The ID of the backup set. For the sys tenant, the value is 0. For a user tenant, the value is an incrementing integer starting from 1. | ||||||||||
| INITIATOR_TENANT_ID | bigint(20) | NO | The tenant ID of the task initiator, indicating the tenant that initiated the task. This is the tenant ID of the tenant that executed the backup SQL command. | ||||||||||
| INITIATOR_JOB_ID | bigint(20) | NO | The ID of the job that is the task initiator. | ||||||||||
| EXECUTOR_TENANT_ID | varchar(65536) | NO | The ID of the tenant for which the backup task is executed. | ||||||||||
| PLUS_ARCHIVELOG | varchar(4096) | NO | Specifies whether the log fill-in feature is enabled or disabled. Values:
|
||||||||||
| BACKUP_TYPE | varchar(4096) | NO | The backup type. Valid values:
|
||||||||||
| JOB_LEVEL | varchar(4096) | NO | JOB level:
|
||||||||||
| ENCRYPTION_MODE | varchar(4096) | YES | Encryption mode:
Currently, only the None and Password modes are supported. |
||||||||||
| Column | Type | Nullable | Description | --- | --- | --- | --- | PASSWD | varchar(4096) | YES | Password | ||
| START_TIMESTAMP | timestamp(6) | NO | The start time of the backup task at the job level. | ||||||||||
| END_TIMESTAMP | timestamp(6) | NO | The end time of a backup task at the job level. | ||||||||||
| STATUS | varchar(4096) | NO | The backup status. | ||||||||||
| RESULT | bigint(20) | NO | The result of the backup error. | ||||||||||
| COMMENT | varchar(4096) | YES | Error code description | ||||||||||
| Description | varchar(4096) | YES | The user-specified description of the backup. | ||||||||||
| PATH | varchar(4096) | YES | Backup path | PATH | varchar(4096) | YES | Backup path |
Sample query
The system tenant views the backup job tasks of the tenant with tenant 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
References
View the history of all tenant-level backup tasks at the job level: CDB_OB_BACKUP_JOB_HISTORY
View the task-level backup tasks for all tenants: CDB_OB_BACKUP_TASKS
View the historical record of task-level backups for all tenants: CDB_OB_BACKUP_TASK_HISTORY
For more information about how to view the data backup progress, see View data backup progress.
