Note
This view is available starting with V4.0.0.
Purpose
This view displays the status of a log stream Palf. Common use cases include:
- Checking whether a leader exists in the log stream (the replica where the leader resides).
- Checking the member list of the log stream (the number of Paxos replicas).
- Checking the synchronization status of the replicas.
- Checking the recyclable point of the log stream logs.
- Checking the range of log consumption services allowed for the log stream (including: LSN/SCN).
- Checking the access mode of the Palf.
The results vary depending on the tenant querying this view:
- When querying this view from the sys tenant, it displays the status of all tenants' log stream Palfs.
- When querying this view from a regular tenant, it displays the status of only the log stream Palfs of that tenant.
Columns
| Column | Type | Nullable | Description |
|---|---|---|---|
| TENANT_ID | bigint(20) | NO | The tenant ID. |
| LS_ID | bigint(20) | NO | The log stream ID. |
| SVR_IP | varchar(46) | NO | The IP address of the OBServer node. |
| SVR_PORT | bigint(20) | NO | The port number of the OBServer node. |
| ROLE | varchar(32) | NO | The role of the replica. Valid values:
|
| PROPOSAL_ID | bigint(20) | NO | The Paxos proposal ID. |
| CONFIG_VERSION | varchar(128) | NO | The version number of the configuration change. |
| ACCESS_MODE | varchar(32) | NO | The access mode. Valid values:
|
| PAXOS_MEMBER_LIST | varchar(1024) | NO | The list of Paxos members. |
| PAXOS_REPLICA_NUM | bigint(20) | NO | The number of Paxos replicas. |
| IN_SYNC | varchar(3) | NO | Indicates whether the replica is completely synchronized with the leader. |
| BASE_LSN | bigint(20) | NO | The maximum recyclable point. |
| BEGIN_LSN | bigint(20) | NO | The minimum consumable point (LSN). |
| BEGIN_SCN | bigint(20) | NO | The minimum consumable point (SCN). |
| END_LSN | bigint(20) | NO | The maximum continuous majority point or the maximum consumable point (LSN). |
| END_SCN | bigint(20) | NO | The maximum continuous majority point or the maximum consumable point (SCN). |
| MAX_LSN | bigint(20) | NO | The maximum write point (LSN). |
| MAX_SCN | bigint(20) | NO | The maximum write point (SCN). |
| ARBITRATION_MEMBER | varchar(128) | NO | The server address of the arbitration member.
NoteThis column is available starting with V4.1.0. |
| DEGRADED_LIST | varchar(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 | longtext | NO | The list of read-only replicas of the log stream.
NoteThis column is available starting with V4.2.0. |
Sample query
Query the log stream replicas of all tenants from the sys tenant.
obclient [oceanbase]> SELECT * FROM oceanbase.GV$OB_LOG_STAT\G
The query result is as follows:
*************************** 1. row ***************************
TENANT_ID: 1
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: 134209536
BEGIN_LSN: 0
BEGIN_SCN: 2
END_LSN: 318191562
END_SCN: 1722479340929986934
MAX_LSN: 318191562
MAX_SCN: 1722479340929986934
ARBITRATION_MEMBER:
DEGRADED_LIST:
LEARNER_LIST:
*************************** 2. row ***************************
TENANT_ID: 1001
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: 268419072
BEGIN_LSN: 0
BEGIN_SCN: 2
END_LSN: 557711344
END_SCN: 1722479340939152599
MAX_LSN: 557711344
MAX_SCN: 1722479340939152599
ARBITRATION_MEMBER:
DEGRADED_LIST:
LEARNER_LIST:
*************************** 3. row ***************************
TENANT_ID: 1002
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: 114146658
END_SCN: 1722479340863708484
MAX_LSN: 114146658
MAX_SCN: 1722479340863708484
ARBITRATION_MEMBER:
DEGRADED_LIST:
LEARNER_LIST:
*************************** 4. row ***************************
TENANT_ID: 1002
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: 0
BEGIN_LSN: 0
BEGIN_SCN: 1722408567239862706
END_LSN: 86426047
END_SCN: 1722479340863708484
MAX_LSN: 86426047
MAX_SCN: 1722479340863708484
ARBITRATION_MEMBER:
DEGRADED_LIST:
LEARNER_LIST:
*************************** 5. row ***************************
TENANT_ID: 1003
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: 268419072
BEGIN_LSN: 0
BEGIN_SCN: 2
END_LSN: 552332267
END_SCN: 1722479341104912661
MAX_LSN: 552332267
MAX_SCN: 1722479341104912661
ARBITRATION_MEMBER:
DEGRADED_LIST:
LEARNER_LIST:
*************************** 6. 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: 121609719
END_SCN: 1722479340863954133
MAX_LSN: 121609719
MAX_SCN: 1722479340863954133
ARBITRATION_MEMBER:
DEGRADED_LIST:
LEARNER_LIST:
*************************** 7. 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: 1722408696347874714
END_LSN: 86210139
END_SCN: 1722479340863954133
MAX_LSN: 86210139
MAX_SCN: 1722479340863954133
ARBITRATION_MEMBER:
DEGRADED_LIST:
LEARNER_LIST:
7 rows in set
