Skip Headers
Oracle® Database Administrator's Guide
11g Release 2 (11.2)

Part Number E25494-02
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Index
Index
Go to Master Index
Master Index
Go to Feedback page
Contact Us

Go to previous page
Previous
Go to next page
Next
PDF · Mobi · ePub

Creating a Simple Resource Plan

You can quickly create a simple resource plan that is adequate for many situations using the CREATE_SIMPLE_PLAN procedure. This procedure enables you to both create consumer groups and allocate resources to them by executing a single procedure call. Using this procedure, you are not required to invoke the procedures that are described in succeeding sections for creating a pending area, creating each consumer group individually, specifying resource plan directives, and so on.

You specify the following arguments for the CREATE_SIMPLE_PLAN procedure:

Parameter Description
SIMPLE_PLAN Name of the plan
CONSUMER_GROUP1 Consumer group name for first group
GROUP1_PERCENT CPU resource allocated to this group
CONSUMER_GROUP2 Consumer group name for second group
GROUP2_PERCENT CPU resource allocated to this group
CONSUMER_GROUP3 Consumer group name for third group
GROUP3_PERCENT CPU resource allocated to this group
CONSUMER_GROUP4 Consumer group name for fourth group
GROUP4_PERCENT CPU resource allocated to this group
CONSUMER_GROUP5 Consumer group name for fifth group
GROUP5_PERCENT CPU resource allocated to this group
CONSUMER_GROUP6 Consumer group name for sixth group
GROUP6_PERCENT CPU resource allocated to this group
CONSUMER_GROUP7 Consumer group name for seventh group
GROUP7_PERCENT CPU resource allocated to this group
CONSUMER_GROUP8 Consumer group name for eighth group
GROUP8_PERCENT CPU resource allocated to this group

You can specify up to eight consumer groups with this procedure. The only resource allocation method supported is CPU. The plan uses the EMPHASIS CPU allocation policy (the default) and each consumer group uses the ROUND_ROBIN scheduling policy (also the default). Each consumer group specified in the plan is allocated its CPU percentage at level 2. Also implicitly included in the plan are SYS_GROUP (a system-defined group that is the initial consumer group for the users SYS and SYSTEM) and OTHER_GROUPS. The SYS_GROUP consumer group is allocated 100% of the CPU at level 1, and OTHER_GROUPS is allocated 100% of the CPU at level 3.

Example: Creating a Simple Plan with the CREATE_SIMPLE_PLAN Procedure

The following PL/SQL block creates a simple resource plan with two user-specified consumer groups:

BEGIN
  DBMS_RESOURCE_MANAGER.CREATE_SIMPLE_PLAN(SIMPLE_PLAN => 'SIMPLE_PLAN1',
   CONSUMER_GROUP1 => 'MYGROUP1', GROUP1_PERCENT => 80,
   CONSUMER_GROUP2 => 'MYGROUP2', GROUP2_PERCENT => 20);
END;
/

Executing the preceding statements creates the following plan:

Consumer Group Level 1 Level 2 Level 3
SYS_GROUP 100% - -
MYGROUP1 - 80% -
MYGROUP2 - 20% -
OTHER_GROUPS - - 100%

See Also: