The CREATE_PLAN_DIRECTIVE procedure creates a resource plan directive.
Syntax
DBMS_RESOURCE_MANAGER.CREATE_PLAN_DIRECTIVE (
PLAN IN VARCHAR2,
GROUP_OR_SUBPLAN IN VARCHAR2,
COMMENT IN VARCHAR2 DEFAULT '',
MGMT_P1 IN INT DEFAULT 100,
UTILIZATION_LIMIT IN INT DEFAULT 100,
MIN_IOPS IN INT DEFAULT 0,
MAX_IOPS IN INT DEFAULT 100,
WEIGHT_IOPS IN INT DEFAULT 0);
Parameters
| Parameter | Description |
|---|---|
| PLAN | The name of the resource plan. |
| GROUP_OR_SUBPLAN | The name of the resource consumer group or subplan. |
| COMMENT | The comments on the plan directive. |
| MGMT_P1 | The maximum percentage of CPU resources available when the system runs at full load. |
| UTILIZATION_LIMIT | The maximum CPU utilization allowed. Value range: [0, 100]. The value 100 specifies that all CPU resources of the tenant can be used. The value 20 specifies that at most 20% of the CPU resources of the tenant can be used. |
| MIN_IOPS | The percentage of IOPS resources reserved for I/O resource contention. The sum of MIN_IOPS values of all directives cannot exceed 100. Default value: 0. |
| MAX_IOPS | The maximum percentage of IOPS resources. The sum of MAX_IOPS values of all directives may exceed 100. Default value: 100. |
| WEIGHT_IOPS | The weight of IOPS resources in the case of I/O resource contention. The sum of WEIGHT_IOPS values of all directives may be greater than 100, and the weights will be normalized. Default value: 0. |
Examples
obclient> CALL DBMS_RESOURCE_MANAGER.CREATE_PLAN_DIRECTIVE(
PLAN=>'DAY',
GROUP_OR_SUBPLAN=>'group1',
mgmt_p1=>80,
utilization_limit=>100);
Query OK, 0 rows affected
obclient> CALL DBMS_RESOURCE_MANAGER.CREATE_PLAN_DIRECTIVE(
PLAN=>'NIGHT',
GROUP_OR_SUBPLAN=>'group2',
mgmt_p1=>20,
utilization_limit=>40);
Query OK, 0 rows affected
obclient> CALL DBMS_RESOURCE_MANAGER.CREATE_PLAN_DIRECTIVE(
PLAN => 'daytime',
GROUP_OR_SUBPLAN => 'interactive_group' ,
MGMT_P1 => 30,
UTILIZATION_LIMIT =>80,
MIN_IOPS => 30,
MAX_IOPS => 90,
WEIGHT_IOPS => 80);
Query OK, 0 rows affected