Note
This view is available starting with V4.0.0.
Purpose
This view displays the status of a log stream Palf. Common use cases are as follows:
- Query whether a log stream has a leader (the replica where the leader resides).
- Query the list of members (number of Paxos replicas) of a log stream.
- Query the synchronization status of a replica.
- Query the recyclable log position of a log stream.
- Query the range of log consumption services that a log stream allows (including: LSN/SCN).
- Query the access mode of a Palf.
Columns
| Column | Type | Nullable | Description |
|---|---|---|---|
| TENANT_ID | NUMBER(38) | NO | The tenant ID. |
| LS_ID | NUMBER(38) | NO | The log stream ID. |
| SVR_IP | VARCHAR2(46) | NO | The IP address of the server. |
| SVR_PORT | NUMBER(38) | NO | The port number of the server. |
| ROLE | VARCHAR2(32) | NO | The replica role. Valid values:
|
| PROPOSAL_ID | NUMBER(38) | NO | The Paxos proposal ID. |
| CONFIG_VERSION | VARCHAR2(128) | NO | The version number of the configuration change (for example, changing the member list, changing the number of replicas, or changing the access mode). |
| ACCESS_MODE | VARCHAR2(32) | NO | The access mode. Valid values:
|
| PAXOS_MEMBER_LIST | VARCHAR2(1024) | NO | The list of Paxos members. |
| PAXOS_REPLICA_NUM | NUMBER(38) | NO | The number of Paxos replicas. |
| IN_SYNC | VARCHAR2(3) | NO | Indicates whether the replica is synchronized. |
| BASE_LSN | NUMBER(38) | NO | The maximum recyclable log position. |
| BEGIN_LSN | NUMBER(38) | NO | The minimum log position that can be consumed (LSN). |
| BEGIN_SCN | NUMBER(38) | NO | The minimum log position that can be consumed (SCN). |
| END_LSN | NUMBER(38) | NO | The maximum continuous majority log position or the maximum log position that can be consumed (LSN). |
| END_SCN | NUMBER(38) | NO | The maximum continuous majority log position or the maximum log position that can be consumed (SCN). |
| MAX_LSN | NUMBER(38) | NO | The maximum write log position (LSN). |
| MAX_SCN | NUMBER(38) | NO | The maximum write log position (SCN). |
| ARBITRATION_MEMBER | VARCHAR2(128) | NO | The server address of the arbitration member
NoteThis column is available starting with V4.1.0. |
| DEGRADED_LIST | VARCHAR2(1024) | NO | The list of full-featured replicas that are downgraded in arbitration mode
NoteThis column is available starting with V4.1.0. |
| LEARNER_LIST | CLOB | NO | The list of read-only replicas of the current log stream
NoteThis column is available starting with V4.2.0. |
Sample query
Query the log stream replicas of the current user tenant.
obclient [SYS]> SELECT * FROM SYS.GV$OB_LOG_STAT\G
The query result is as follows:
*************************** 1. row ***************************
TENANT_ID: 1004
LS_ID: 1
SVR_IP: 172.xx.xx.xx
SVR_PORT: 2882
ROLE: LEADER
PROPOSAL_ID: 1
CONFIG_VERSION: {proposal_id:1, config_seq:2}
ACCESS_MODE: APPEND
PAXOS_MEMBER_LIST: 172.xx.xx.xx:2882:1
PAXOS_REPLICA_NUM: 1
IN_SYNC: YES
BASE_LSN: 67104768
BEGIN_LSN: 0
BEGIN_SCN: 2
END_LSN: 146555538
END_SCN: 1723169141790414000
MAX_LSN: 146555538
MAX_SCN: 1723169141790414000
ARBITRATION_MEMBER: NULL
DEGRADED_LIST: NULL
LEARNER_LIST: NULL
*************************** 2. row ***************************
TENANT_ID: 1004
LS_ID: 1001
SVR_IP: 172.xx.xx.xx
SVR_PORT: 2882
ROLE: LEADER
PROPOSAL_ID: 1
CONFIG_VERSION: {proposal_id:1, config_seq:2}
ACCESS_MODE: APPEND
PAXOS_MEMBER_LIST: 172.xx.xx.xx:2882:1
PAXOS_REPLICA_NUM: 1
IN_SYNC: YES
BASE_LSN: 67104768
BEGIN_LSN: 0
BEGIN_SCN: 1723084154840180002
END_LSN: 103734592
END_SCN: 1723169141790414000
MAX_LSN: 103734592
MAX_SCN: 1723169141790414000
ARBITRATION_MEMBER: NULL
DEGRADED_LIST: NULL
LEARNER_LIST: NULL
2 rows in set
