Note
This view is introduced since OceanBase Database V4.0.0.
Purpose
The V$OB_LS_REPLICA_TASK_PLAN view displays all the tasks that should be generated, including those that have been generated and those that have not.
Columns
| Column | Type | Nullable? | Description |
|---|---|---|---|
| TENANT_ID | bigint(20) | NO | The ID of the tenant. |
| LS_ID | bigint(20) | NO | The ID of the log stream. |
| TASK_TYPE | varchar(64) | NO | The type of the task. Valid values:
|
| PRIORITY | varchar(5) | NO | The priority of the task. Valid values:
|
| TARGET_REPLICA_SVR_IP | varchar(46) | YES | The IP address of the server where the destination replica resides. |
| TARGET_REPLICA_SVR_PORT | bigint(20) | YES | The port number of the server where the destination replica resides. |
| TARGET_PAXOS_REPLICA_NUMBER | bigint(20) | YES | The quorum of the Paxos group for the destination replica. |
| TARGET_REPLICA_TYPE | varchar(16) | YES | The type of the destination replica. |
| SOURCE_REPLICA_SVR_IP | varchar(46) | YES | The IP address of the server where the source replica resides. For tasks such as deleting replicas and modifying the quorum of the Paxos group, this column is invalid and is NULL. |
| SOURCE_REPLICA_SVR_PORT | bigint(20) | YES | The port number of the server where the source replica resides. For tasks such as deleting replicas and modifying the quorum of the Paxos group, this column is invalid and is 0. |
| SOURCE_PAXOS_REPLICA_NUMBER | bigint(20) | YES | The quorum of the Paxos group for the source replica. |
| SOURCE_REPLICA_TYPE | varchar(16) | YES | The type of the source replica. For tasks such as deleting replicas and modifying the quorum of the Paxos group, this column is invalid and is NULL. |
| TASK_EXEC_SVR_IP | varchar(46) | YES | The IP address of the server where the task is executed. |
| TASK_EXEC_SVR_PORT | bigint(20) | YES | The port number of the server where the task is executed. |
| COMMENT | varchar(2048) | YES | The reason why the task was generated. |
Sample query
View the tasks that should be generated for the current tenant.
obclient> SELECT * FROM oceanbase.V$OB_LS_REPLICA_TASK_PLAN\G
The query result is as follows:
*************************** 1. row ***************************
TENANT_ID: 1004
LS_ID: 1
TASK_TYPE: ADD REPLICA
PRIORITY: HIGH
TARGET_REPLICA_SVR_IP: 172.xx.xxx.243
TARGET_REPLICA_SVR_PORT: 2882
TARGET_PAXOS_REPLICA_NUMBER: 3
TARGET_REPLICA_TYPE: FULL
SOURCE_REPLICA_SVR_IP: 172.xx.xxx.254
SOURCE_REPLICA_SVR_PORT: 2882
SOURCE_PAXOS_REPLICA_NUMBER: 2
SOURCE_REPLICA_TYPE: FULL
TASK_EXEC_SVR_IP: 172.xx.xxx.243
TASK_EXEC_SVR_PORT: 2882
COMMENT: add paxos replica according to locality
CONFIG_VERSION:
1 row in set