Note
This view is introduced since OceanBase Database V4.0.0.
Purpose
The DBA_OB_LS_REPLICA_TASKS view displays the disaster recovery tasks at the replica level that are in progress.
Columns
| Column | Type | Nullable? | Description |
|---|---|---|---|
| LS_ID | NUMBER(38) | NO | Log stream ID |
| TASK_TYPE | VARCHAR2(64) | NO | Task type. Valid values include:
|
| TASK_ID | VARCHAR2(200) | NO | Task ID |
| TASK_STATUS | VARCHAR2(2048) | YES | Task status. Valid values include:
|
| PRIORITY | CHAR(5) | NO | Task priority. Valid values include:
|
| TARGET_REPLICA_SVR_IP | VARCHAR2(46) | YES | IP address of the target replica. |
| TARGET_REPLICA_SVR_PORT | NUMBER(38) | YES | Port number of the target replica. |
| TARGET_PAXOS_REPLICA_NUMBER | NUMBER(38) | YES | Number of paxos replicas for the target log stream. |
| TARGET_REPLICA_TYPE | VARCHAR2(16) | YES | Type of the target replica. |
| SOURCE_REPLICA_SVR_IP | VARCHAR2(46) | YES | IP address of the source replica. This field is invalid for tasks such as replica deletion and modification of the number of paxos replicas. The value is NULL. |
| SOURCE_REPLICA_SVR_PORT | NUMBER(38) | YES | Port number of the source replica. This field is invalid for tasks such as replica deletion and modification of the number of paxos replicas. The value is 0. |
| SOURCE_PAXOS_REPLICA_NUMBER | NUMBER(38) | YES | Number of paxos replicas for the source log stream. |
| SOURCE_REPLICA_TYPE | VARCHAR2(16) | YES | Type of the source replica. This field is invalid for tasks such as replica deletion and modification of the number of paxos replicas. The value is NULL. |
| DATA_SOURCE_SVR_IP | VARCHAR2(46) | YES | IP address of the data source
Note
|
| DATA_SOURCE_SVR_PORT | NUMBER(38) | YES | PORT of the data source
Note
|
| IS_MANUAL | CHAR(6) | NO | Indicates the source of the disaster recovery task. Valid values include:
Note
|
| TASK_EXEC_SVR_IP | VARCHAR2(46) | YES | IP address of the task execution server. |
| TASK_EXEC_SVR_PORT | NUMBER(38) | YES | Port number of the task execution server. |
| CREATE_TIME | TIMESTAMP(6) | NO | Task creation time |
| START_TIME | TIMESTAMP(6) | NO | Task scheduling time |
| MODIFY_TIME | TIMESTAMP(6) | NO | Task status update time |
| COMMENT | VARCHAR2(2048) | YES | Remarks about the reason for task generation |
Sample query
The following example shows how to query the disaster recovery tasks at the replica level that are in progress in the current tenant.
obclient [SYS]> SELECT * FROM SYS.DBA_OB_LS_REPLICA_TASKS;
The sample result is as follows:
+-------+-------------+------------------------------------+-------------+----------+-----------------------+-------------------------+-----------------------------+---------------------+-----------------------+-------------------------+-----------------------------+---------------------+--------------------+----------------------+-----------+------------------+--------------------+------------------------------+------------------------------+------------------------------+-----------------------+
| LS_ID | TASK_TYPE | TASK_ID | TASK_STATUS | PRIORITY | TARGET_REPLICA_SVR_IP | TARGET_REPLICA_SVR_PORT | TARGET_PAXOS_REPLICA_NUMBER | TARGET_REPLICA_TYPE | SOURCE_REPLICA_SVR_IP | SOURCE_REPLICA_SVR_PORT | SOURCE_PAXOS_REPLICA_NUMBER | SOURCE_REPLICA_TYPE | DATA_SOURCE_SVR_IP | DATA_SOURCE_SVR_PORT | IS_MANUAL | TASK_EXEC_SVR_IP | TASK_EXEC_SVR_PORT | CREATE_TIME | START_TIME | MODIFY_TIME | COMMENT |
+-------+-------------+------------------------------------+-------------+----------+-----------------------+-------------------------+-----------------------------+---------------------+-----------------------+-------------------------+-----------------------------+---------------------+--------------------+----------------------+-----------+------------------+--------------------+------------------------------+------------------------------+------------------------------+-----------------------+
| 1002 | ADD REPLICA | Y13CE64586BD4-000614A082090C60-0-0 | INPROGRESS | HIGH | xx.xx.xx.xx | 5075 | 4 | FULL | xx.xx.xx.xx | 5070 | 3 | FULL | 0.0.0.0 | 0 | TRUE | xx.xx.xx.xx | 5075 | 27-MAR-24 05.04.33.602595 PM | 27-MAR-24 05.04.33.602595 PM | 27-MAR-24 05.04.33.602595 PM | add replica by manual |
+-------+-------------+------------------------------------+-------------+----------+-----------------------+-------------------------+-----------------------------+---------------------+-----------------------+-------------------------+-----------------------------+---------------------+--------------------+----------------------+-----------+------------------+--------------------+------------------------------+------------------------------+------------------------------+-----------------------+
1 row in set