RelationalDBDesign
SiteMap
Database Architecture
Database Admin
Managing Users
Managing Objects
Backup Recovery
Admin Tasks
Table Space Management
«Prev
Next»
Database Administration
Managing Storage
Tablespace Resource Management
Large Database Features
Internet Database Configurations
Security Features
Installation Configuration
Universal Installer
Parameter Initialization Changes
Configuration Assistant
Universal Installer Upgrade
Software Packager
Install Conclusion
Intro Table Space
Table Space Management
Locally Managed Tablespaces
Transportable Tablespaces
Read Only Tablespaces
DB Resource Manager
Use Resource Manager
Resource Manager Conclusion
SQL*Loader
SQL Loader Improvements
Load LOB Data SQL Loader
Table Management Enhancements
Relocate | Restructure Table
Create Temporary Table
Remove Unused Column
Oracle Database Limits
Oracle Enhancements
JDBC Client
Multimedia | Oracle
Java Oracle
Oracle JVM
Intermedia Exchange
Text Retrieval
Oracle Internet Directory
Oracle Tools Features
JSP Web Development
Directory Conclusion
Web Enterprise
Use Database Resource Manager - Exercise
Create a plan
Objective:
Create parts of a plan using DB Resource Manager
Background/overview
You saw how to create a plan, some consumer groups, and some plan directives in the SlideShow in this lesson. Now you can practice writing the code in the simulation found here.
Instructions
Follow the instructions on each screen of the simulation.
Hints:
Look at the SlideShow for syntax and examples.
Submitting your exercise
Run the simulation. Instructions only
Simulation name: plan_test
To create the plan directive, you have to create and execute all these PL/SQL commands.
In the simulation you created the first consumer group, the first plan directive, and the validation command.
I have listed all the necessary PL/SQL commands so that you have a complete example for reference later.
BEGIN DBMS_RESOURCE_MANAGER.CREATE_PENDING_AREA; END;
/
BEGIN
DBMS_RESOURCE_MANAGER.CREATE_PLAN (
plan =>'EPETS_PLAN',
comment => 'New plan.');
END;
/
BEGIN
DBMS_RESOURCE_MANAGER.CREATE_CONSUMER_GROUP (
consumer_group => 'LOOKER',
comment => 'View general information');
END;
/
BEGIN
DBMS_RESOURCE_MANAGER.CREATE_CONSUMER_GROUP (
consumer_group => 'SHOPPER',
comment => 'Run shopping cart');
END;
/
BEGIN
DBMS_RESOURCE_MANAGER.CREATE_CONSUMER_GROUP (
consumer_group => 'BUYER',
comment => 'Purchase items.');
END;
/
BEGIN
DBMS_RESOURCE_MANAGER.CREATE_PLAN_DIRECTIVE (
plan => 'EPETS_PLAN',
group_or_subplan => 'SHOPPER',
comment => 'Medium priority',
cpu_p1 => 30,
cpu_p2 => 20,
parallel_degree_limit_p1 => NULL);
END;
/
BEGIN
DBMS_RESOURCE_MANAGER.CREATE_PLAN_DIRECTIVE (
plan => 'EPETS_PLAN',
group_or_subplan => 'LOOKER',
comment => 'Low priority',
cpu_p1 => 10,
cpu_p2 => 10,
parallel_degree_limit_p1 => 4);
END;
/
BEGIN
DBMS_RESOURCE_MANAGER.CREATE_PLAN_DIRECTIVE (
plan => 'EPETS_PLAN',
group_or_subplan => 'OTHER_GROUPS',
comment => 'Low priority',
cpu_p1 => 10,
cpu_p2 => 10,
parallel_degree_limit_p1 => NULL);
END;
/
BEGIN
DBMS_RESOURCE_MANAGER.CREATE_PLAN_DIRECTIVE (
plan => 'EPETS_PLAN',
group_or_subplan => 'BUYER',
comment => 'Top priority',
cpu_p1 => 50,
parallel_degree_limit_p1 => NULL);
END;
/
BEGIN
DBMS_RESOURCE_MANAGER.VALIDATE_PENDING_AREA;
END;
/
BEGIN
DBMS_RESOURCE_MANAGER.SUBMIT_PENDING_AREA;
END;
/