Note
This view is available starting with V4.0.0.
Purpose
This topic describes how to back up a tenant in the current database.
Columns
| Column | Type | Nullable | Description | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| JOB_ID | NUMBER(38) | NO | The backup job ID. Each backup job corresponds to one job record. | ||||||||||
| COLUMN | TYPE | NULLABLE | DESCRIPTION | --- | --- | --- | --- | INCARNATION | NUMBER(38) | NO | Specifies the number of times a flashback occurs. | ||
| COLUMN | TYPE | NULLABLE | DESCRIPTION | --- | --- | --- | --- | BACKUP_SET_ID | NUMBER(38) | YES | Backup set ID. For the sys tenant, the value is 0. For a user tenant, it starts from 1 and increases in order. | ||
| INITIATOR_TENANT_ID | NUMBER(38) | NO | The tenant ID of the task initiator, which indicates the tenant that initiated the task, corresponding to the tenant ID of the tenant that executed the backup SQL command. | ||||||||||
| INITIATOR_JOB_ID | NUMBER(38) | NO | The ID of the job that starts the task. | ||||||||||
| EXECUTOR_TENANT_ID | varchar2(65536) | NO | The ID of the tenant to which the job-level backup task belongs. | ||||||||||
| PLUS_ARCHIVELOG | varchar2(4096) | NO | Specifies whether to enable the archive log catch-up feature: |
||||||||||
| BACKUP_TYPE | varchar2(4096) | NO | Backup type: |
||||||||||
| JOB_LEVEL | varchar2(4096) | NO | JOB level: |
||||||||||
| ENCRYPTION_MODE | varchar2(4096) | YES | Encryption mode: Only None and Password modes are supported. |
||||||||||
| Column | Type | Nullable | Description | --- | --- | --- | --- | PASSWD | varchar(4096) | YES | password | ||
| START_TIMESTAMP | VARCHAR2(256) | NO | The start time of the backup at the job level. | ||||||||||
| END_TIMESTAMP | VARCHAR2(256) | NO | Job-level backup job end time | ||||||||||
| Column | Type | Nullable | Description | --- | --- | --- | --- | STATUS | varchar2(4096) | NO | The status of the backup. | ||
| RESULT | NUMBER(38) | NO | Backup error code result | ||||||||||
| COMMENT | varchar2(4096) | YES | Error description | ||||||||||
| Column | Type | Nullable | Description | --- | --- | --- | --- | DESCRIPTION | varchar2(4096) | YES | The user-specified description for backup. | ||
| PATH | varchar2(4096) | YES | Backup path |
Sample query
The user tenant can view the backup job tasks in their own tenant.
obclient [SYS]> SELECT * FROM SYS.DBA_OB_BACKUP_JOBS\G
The query result is as follows:
*************************** 1. row ***************************
JOB_ID: 3
INCARNATION: 1
BACKUP_SET_ID: 2
INITIATOR_TENANT_ID: 1004
INITIATOR_JOB_ID: 0
EXECUTOR_TENANT_ID: 1004
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/backupdataorc
1 row in set