Purpose
You can use this statement to create a resource pool, which defines collection of resource units that can be allocated to a tenant.
You can bind a resource pool only to one tenant. The total amount of resources allocated to a tenant in a zone is calculated as follows: Unit specifications × Unit quantity.
Syntax
CREATE RESOURCE POOL poolname
UNIT [=] unitname,
UNIT_NUM [=] unitnum,
ZONE_LIST [=] ('zone' [, 'zone' ...]);
Parameters
| Parameter | Description |
|---|---|
| poolname | The name of the resource pool to be created. |
| UNIT [=] unitname | The name of the resource unit. |
| UNIT_NUM [=] unitnum | The number of resource units to be created in a zone. A server is automatically selected from each zone for each unit based on the current cluster load. However, multiple units of a resource pool cannot be allocated to the same server. That is, the number of units in a resource pool cannot exceed the number of servers in a zone. |
| ZONE_LIST [=] ('zone' [, 'zone' ...]) | The zone to which the resource pool to be created belongs. |
Examples
Create resource pool pool1 in zone1.
obclient> CREATE RESOURCE POOL pool1 UNIT='unit1', UNIT_NUM=1, ZONE_LIST=('zone1');
Query OK, 0 rows affected