Note
This view was introduced in OceanBase Database V4.0.0.
Purpose
The V$OB_PROCESSLIST view displays the information about sessions on the current OBServer node.
Columns
| Column | Type | Nullable? | Description |
|---|---|---|---|
| SVR_IP | VARCHAR2(46) | NO | The IP address of the OBServer node. |
| SVR_PORT | NUMBER(38) | NO | The port number of the OBServer node. |
| SQL_PORT | NUMBER(38) | NO | The SQL port number. |
| ID | NUMBER(38) | NO | The ID of the session. |
| USER | CHAR(193) | NO | The username. |
| HOST | VARCHAR2(128) | NO | The name of the client host. For example, if you connect to the OBServer node by using OceanBase Database Proxy (ODP), the value is the host address of ODP. |
| DB | VARCHAR2(128) | YES | The name of the database accessed. |
| TENANT | VARCHAR2(128) | NO | The name of the tenant accessed. |
| COMMAND | VARCHAR2(4096) | NO | The type of the command being executed in the session. |
| TIME | NUMBER(38) | NO | The execution time of the current command, in seconds. If a retry occurs, the value is cleared and recalculated. |
| TOTAL_TIME | NUMBER(38) | NO | The total execution time of the current command, in seconds. If a retry occurs, the value will not be cleared. |
| STATE | VARCHAR2(128) | YES | The current session status. |
| INFO | VARCHAR2(262143) | YES | The command that is being executed. |
| PROXY_SESSID | NUMBER(38) | YES | The ODP session ID is displayed if the client is ODP. |
| MASTER_SESSID | NUMBER(38) | YES | The ID of the master session, which is used to concatenate multiple sub-sessions of the same SQL statement. |
| USER_CLIENT_IP | VARCHAR2(46) | YES | The IP address of the user client. |
| USER_HOST | VARCHAR2(128) | YES | The hostname of the user client. |
| RETRY_CNT | NUMBER(38) | NO | The number of retries of the current command. |
| RETRY_INFO | NUMBER(38) | NO | The retry information of the current command, which is usually the error code for the last retry. |
| SQL_ID | VARCHAR2(32) | NO | The ID of the SQL statement. |
| TRANS_ID | NUMBER(38) | NO | The ID of the transaction. |
| THREAD_ID | NUMBER(38) | NO | The ID of the thread. |
| SSL_CIPHER | VARCHAR2(4096) | YES | The name of the Secure Sockets Layer (SSL) cipher. |
| TRACE_ID | VARCHAR2(64) | YES | The trace ID. |
| TRANS_STATE | VARCHAR2(32) | YES | The status of the transaction. Valid values:
|
| ACTION | VARCHAR2(4096) | YES | The name of the operation being executed that is set by calling the DBMS_APPLICATION_INFO.SET_ACTION procedure. |
| MODULE | VARCHAR2(4096) | YES | The name of the module that is set by calling the DBMS_APPLICATION_INFO.SET_MODULE procedure. |
| CLIENT_INFO | VARCHAR2(4096) | YES | The client information set by the DBMS_APPLICATION_INFO.SET_CLIENT_INFO procedure. |
| LEVEL | NUMBER(38) | NO | The diagnostic information monitoring level for end-to-end diagnostics of the session. For example, the value 1 indicates that level-1 diagnostic information is monitored.
NoteThis column is available in OceanBase Database V4.2.1 and later. |
| SAMPLE_PERCENTAGE | NUMBER(38) | NO | The sampling rate for end-to-end diagnostics of the session. For example, the value 50 indicates that diagnostic information is sampled at a rate of 50%.
NoteThis column is available in OceanBase Database V4.2.1 and later. |
| RECORD_POLICY | VARCHAR2(32) | NO | The diagnostic information recording strategy for end-to-end diagnostics of the session. Three strategies are supported:
NoteThis column is available in OceanBase Database V4.2.1 and later. |
| LB_VID | NUMBER(38) | NO | The virtual private cloud (VPC) ID of the load balancing service if you directly connect to the database in the public cloud. Otherwise, the value is NULL.
NoteThis column is available in OceanBase Database V4.2.1 and later. |
| LB_VIP | VARCHAR2(46) | NO | The IP address used by the client to connect to the load balancing service if you directly connect to the database in the public cloud. Otherwise, the value is NULL.
NoteThis column is available in OceanBase Database V4.2.1 and later. |
| LB_VPORT | NUMBER(38) | NO | The port used by the client to connect to the load balancing service if you directly connect to the database in the public cloud. Otherwise, the value is NULL.
NoteThis column is available in OceanBase Database V4.2.1 and later. |
| IN_BYTES | NUMBER(38) | NO | The inbound traffic of the session, in bytes.
NoteThis column is available in OceanBase Database V4.2.1 and later. |
| OUT_BYTES | NUMBER(38) | NO | The outbound traffic of the session, in bytes.
NoteThis column is available in OceanBase Database V4.2.1 and later. |
| USER_CLIENT_PORT | NUMBER(38) | NO | The port number of the client that initiates the session.
Note
|
| TOTAL_CPU_TIME | NUMBER(38) | NO | The CPU time consumed by the current command, in seconds.
Note
|
| PROXY_USER | VARCHAR2(128) | NO |
Note
|
Sample query
Query the information about sessions on the current OBServer node.
obclient [SYS]> SELECT * FROM SYS.V$OB_PROCESSLIST WHERE ROWNUM < = 1 \G
The query result is as follows:
*************************** 1. row ***************************
SVR_IP: 172.xx.xx.xx
SVR_PORT: 2882
SQL_PORT: 2881
ID: 3221487665
USER: SYS
HOST: 100.xx.xx.xx:16564
DB: SYS
TENANT: oracle001
COMMAND: Query
TIME: 0
TOTAL_TIME: 0
STATE: ACTIVE
INFO: SELECT * FROM SYS.V$OB_PROCESSLIST WHERE ROWNUM < = 1
PROXY_SESSID: NULL
MASTER_SESSID: NULL
USER_CLIENT_IP: 100.xx.xx.xx
USER_HOST: %
RETRY_CNT: 0
RETRY_INFO: 0
SQL_ID: EF50802B8426B999EDC33F5F27D0A204
TRANS_ID: 260514
THREAD_ID: 9661
SSL_CIPHER: NULL
TRACE_ID: YB4XXXXXXXXX-000XXXXXXXXXXXXX-0-0
TRANS_STATE: ACTIVE
ACTION: NULL
MODULE: NULL
CLIENT_INFO: NULL
LEVEL: 1
SAMPLE_PERCENTAGE: 10
RECORD_POLICY: SAMPLE_AND_SLOW_QUERY
LB_VID: NULL
LB_VIP: NULL
LB_VPORT: NULL
IN_BYTES: 448
OUT_BYTES: 0
USER_CLIENT_PORT: 16564
PROXY_USER: NULL
1 row in set