View resources available for a business tenant

2023-07-24 09:52:12  Updated

After the successful deployment, OceanBase Database creates a tenant named sys by default. This tenant is used to manage OceanBase Database. We recommend that you do not store business data in the sys tenant. Therefore, you must create a business tenant before you use OceanBase Database. This topic describes how to view resources available for a business tenant.

Procedure

  1. Log on to the sys tenant.

  2. You can query the following views to check the resource information of the current cluster.

    View name Description
    DBA_OB_UNIT_CONFIGS Displays specifications of all resource units.
    GV$OB_SERVERS Displays information of server resources.
    GV$OB_UNITS Displays information of units on each server.
  3. View the remaining resources of OBServers.

    obclient> SELECT SVR_IP,ZONE,(CPU_CAPACITY-CPU_ASSIGNED) cpu_free,round((MEM_CAPACITY-MEM_ASSIGNED)/1024/1024/1024) mem_free_gb FROM GV$OB_SERVERS;
       +------------+-------+----------+-------------+
       | SVR_IP     | ZONE  | cpu_free | mem_free_gb |
       +------------+-------+----------+-------------+
       | 10.10.10.1 | zone1 |     57.5 |          42 |
       | 10.10.10.2 | zone2 |     57.5 |          42 |
       | 10.10.10.3 | zone3 |     57.5 |          42 |
       +------------+-------+----------+-------------+
       3 row in set
    

    Fields

    Field Description
    SVR_IP The IP address of the OBServer.
    ZONE The name of the zone.
    cpu_free The available CPU resources.
    mem_free_gb The available memory space.

Contact Us