The UPDATE_PLAN_DIRECTIVE procedure is used to update resource plan directives.
Syntax
DBMS_RESOURCE_MANAGER.UPDATE_PLAN_DIRECTIVE (
PLAN VARCHAR(65535),
GROUP_OR_SUBPLAN VARCHAR(65535),
NEW_COMMENT VARCHAR(65535) DEFAULT NULL,
NEW_MGMT_P1 INT DEFAULT NULL,
NEW_UTILIZATION_LIMIT INT DEFAULT NULL,
NEW_MIN_IOPS INT DEFAULT NULL,
NEW_MAX_IOPS INT DEFAULT NULL,
NEW_WEIGHT_IOPS INT DEFAULT NULL,
NEW_MAX_NET_BANDWIDTH INT DEFAULT NULL,
NEW_NET_BANDWIDTH_WEIGHT INT DEFAULT NULL);
Parameters
Parameter |
Description |
|---|---|
| PLAN | The name of the resource plan. |
| GROUP_OR_SUBPLAN | The name of the resource usage group or subplan. |
| NEW_COMMENT | Comments on plan directives. |
| NEW_MGMT_P1 | Specifies the maximum relative CPU utilization that is available when the system is at full load. |
| NEW_UTILIZATION_LIMIT | The maximum proportion of CPU resources that can be used. The value range is [0, 100]. "100" indicates that the tenant can use all CPU resources. If the value is "20", it means the tenant can use up to 20% of the CPU resources. |
| NEW_MIN_IOPS | Specifies the reserved IOPS resources for the resource group in case of I/O contention, with a total not exceeding 100. |
| NEW_MAX_IOPS | Specify the maximum IOPS resources that a resource group can use. The total can exceed 100. |
| NEW_WEIGHT_IOPS | Specifies the weight value of IOPS. The sum can exceed 100. |
| NEW_MAX_NET_BANDWIDTH | Specify the maximum network bandwidth that a resource group can use. The total value can exceed 100. |
| NEW_NET_BANDWIDTH_WEIGHT | Specifies the weight value of network bandwidth. The sum of all weight values can exceed 100. |
Usage instructions
If the parameter for UPDATE_PLAN_DIRECTIVE is not specified, its value remains unchanged in the data dictionary.
To clear (set to zero or invalid) any numeric parameter in a resource plan directive, use the UPDATE_PLAN_DIRECTIVE procedure to set it to -1.
Examples
Updated the comment on the plan directive for the resource group
interactive_groupbound to the resource planDAY.obclient> CALL DBMS_RESOURCE_MANAGER.UPDATE_PLAN_DIRECTIVE('DAY','group1','Middle Level Group');Update the resource plan directives for resources such as CPU, IOPS, and network bandwidth in the resource group
interactive_groupbound to the resource plandaytime.
obclient [test]> CALL DBMS_RESOURCE_MANAGER.UPDATE_PLAN_DIRECTIVE(
PLAN => 'daytime',
GROUP_OR_SUBPLAN => 'interactive_group',
NEW_COMMENT => 'new',
NEW_MGMT_P1 => 40,
NEW_UTILIZATION_LIMIT => 60,
NEW_MIN_IOPS => 40,
NEW_MAX_IOPS => 80,
NEW_WEIGHT_IOPS => 70,
NEW_MAX_NET_BANDWIDTH => 30,
NEW_NET_BANDWIDTH_WEIGHT => 30);
References
For detailed operations on updating a resource plan directive, see Update the content of a resource management plan.