Note
- For OceanBase Database V4.3.x, this view was introduced in OceanBase Database V4.3.1.
- For OceanBase Database V4.2.x, this view was introduced in OceanBase Database V4.2.4.
Purpose
The GV$OB_TENANT_RESOURCE_LIMIT view displays the usage, upper limits, and effective limits of the logical resources on all OBServer nodes in the current tenant, as well as the maximum historical usage of the logical resources after a restart upon downtime.
Columns
| Column | Type | Nullable? | Description |
|---|---|---|---|
| SVR_IP | varchar(46) | NO | The IP address of the OBServer node. |
| SVR_PORT | bigint(20) | NO | The remote procedure call (RPC) port number of the OBServer node. |
| TENANT_ID | bigint(20) | NO | The ID of the tenant. |
| ZONE | varchar(128) | NO | The name of the zone. |
| RESOURCE_NAME | varchar(128) | NO | The name of the resource. |
| CURRENT_UTILIZATION | bigint(20) | NO | The current usage of the resource. |
| MAX_UTILIZATION | bigint(20) | NO | The maximum usage of the resource after the server starts. |
| RESERVED_VALUE | bigint(20) | NO | The amount of reserved resources. It ensures the stable operation of the server. |
| LIMIT_VALUE | bigint(20) | NO | The maximum usage of the resource allowed. |
| EFFECTIVE_LIMIT_TYPE | varchar(128) | NO | The effective limit type, such as parameter, memory, CPU, or disk. |
Sample query
Query the usage, upper limits, and effective limits of the logical resources on all OBServer nodes in the current tenant, as well as the maximum historical usage of the logical resources after a restart upon downtime.
obclient[oceanbase]> SELECT * FROM oceanbase.GV$OB_TENANT_RESOURCE_LIMIT;
The query result is as follows:
+----------------+----------+-----------+-------+---------------+---------------------+-----------------+----------------+-------------+----------------------+
| SVR_IP | SVR_PORT | TENANT_ID | ZONE | RESOURCE_NAME | CURRENT_UTILIZATION | MAX_UTILIZATION | RESERVED_VALUE | LIMIT_VALUE | EFFECTIVE_LIMIT_TYPE |
+----------------+----------+-----------+-------+---------------+---------------------+-----------------+----------------+-------------+----------------------+
| xx.xx.xx.xx | 2882 | 1002 | zone1 | ls | 3 | 3 | 0 | 8 | memory |
| xx.xx.xx.xx | 2882 | 1002 | zone1 | tablet | 736 | 826 | 0 | 80000 | configuration |
| xx.xx.xx.xx | 2882 | 1002 | zone2 | ls | 3 | 3 | 0 | 8 | memory |
| xx.xx.xx.xx | 2882 | 1002 | zone2 | tablet | 736 | 826 | 0 | 80000 | configuration |
| xx.xx.xx.xx | 2882 | 1002 | zone3 | ls | 3 | 3 | 0 | 8 | memory |
| xx.xx.xx.xx | 2882 | 1002 | zone3 | tablet | 736 | 826 | 0 | 80000 | configuration |
+----------------+----------+-----------+-------+---------------+---------------------+-----------------+----------------+-------------+----------------------+
6 rows in set (0.019 sec)