Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Semestr2 / 1 - Oracle / Oracle selected docs / Database concepts.pdf
Скачиваний:
29
Добавлен:
12.05.2015
Размер:
6.96 Mб
Скачать

Introduction to the Database Resource Manager

Introduction to the Database Resource Manager

Traditionally, it has been up to the operating system to regulate resource management among the various applications running on a system, including Oracle databases. Before Oracle8i, there was no way to prioritize one Oracle session over another. The Database Resource Manager gives database administrators more control over resource management decisions, so that resource allocation can be aligned with an enterprise’s business objectives.

Note: The Database Resource Manager is available with Oracle

Enterprise Edition, beginning with Release 8i.

The Database Resource Manager solves many resource allocation problems that an operating system does not manage so well:

Excessive overhead. This results from operating system context switching between Oracle server processes when the number of server processes is high.

Inefficient scheduling. The operating system deschedules Oracle database servers while they hold latches, which is inefficient.

Inappropriate allocation of resources. The operating system distributes resources equally among all active processes and is unable to prioritize one task over another.

Inability to manage database-specific resources

With Oracle’s Database Resource Manager, a database administrator can:

Guarantee certain users a minimum amount of processing resources regardless of the load on the system and the number of users

Distribute available processing resources by allocating percentages of CPU time to different users and applications. In a data warehouse, a higher percentage may be given to ROLAP (relational on-line analytical processing) applications than to batch jobs.

Limit the degree of parallelism of any operation performed by members of a group of users

Create an active session pool. This pool consists of a specified maximum number of user sessions allowed to be concurrently active within a group of users. Additional sessions beyond the maximum are queued for execution, but you can specify a timeout period, after which queued jobs terminate.

9-2 Oracle9i Database Concepts

Introduction to the Database Resource Manager

Allow automatic switching of users from one group to another group based on administrator-defined criteria. If a member of a particular group of users creates a session that runs for longer than a specified amount of time, that session can be automatically switched to another group of users with different resource requirements.

Prevent the execution of operations that are estimated to run for a longer time than a predefined limit

Create an undo pool. This pool consists of the amount of undo space that can be consumed in by a group of users.

Configure an instance to use a particular method of allocating resources. You can dynamically change the method, for example, from a daytime setup to a nighttime setup, without having to shut down and restart the instance.

It is thus possible to balance one user's resource consumption against that of other users and to partition system resources among tasks of varying importance, to achieve overall enterprise goals.

See Also: Oracle9i Database Administrator’s Guide for information about using the Database Resource Manager

Database Resource Manager Overview

Resources are allocated to users according to a resource plan specified by the database administrator. The following terms are used in specifying a resource plan:

A resource plan specifies how the resources are to be distributed among various users (resource consumer groups).

Resource consumer groups allow the administrator to group user sessions together by resource requirements. Resource consumer groups are different from user roles; one database user can have different sessions assigned to different resource consumer groups.

Resource allocation methods determine what policy to use when allocating for any particular resource. Resource allocation methods are used by resource plans and resource consumer groups.

Resource plan directives are a means of assigning consumer groups to particular plans and partitioning resources among consumer groups by specifying parameters for each resource allocation method.

Database Resource Management 9-3

Introduction to the Database Resource Manager

The Database Resource Manager also allows for creation of plans within plans, called subplans. Subplans allow further subdivision of resources among different users of an application.

Levels provide a mechanism to specify distribution of unused resources among available users. Up to eight levels of resource allocation can be specified.

Example of a Simple Resource Plan

To illustrate these concepts, take an example of a fictitious company, ABC Inc. ABC sells electronics consumer goods over the Internet. To ensure the best performance for online customers, at least 85% of the CPU resources should be allocated to them. From the remaining resources, 10% should go to users involved in shipping orders and 5% to billing operations.

To configure an Oracle database to allocate resources in such a way, the database administrator creates three resource consumer groups:

ONLINE for online customers

SHIPPING for shipping users

BILLING for billing users

The database administrator then creates a resource plan such as the one in Table 9–1.

Table 9–1 Simple Resource Allocation Plan, ABCUSERS

Consumer Group

CPU Resource Allocation

 

 

ONLINE

85%

SHIPPING

10%

BILLING

5%

 

 

The plan shown in Table 9–1 specifies that 85% of CPU cycles be allotted to ONLINE group sessions, 10% to those of the SHIPPING group and the remaining 5% to the BILLING group. Although this example describes a very simplistic scenario, the Database Resource Manager provides the database administrator with a powerful mechanism for implementing controlled resource allocation policies within an Oracle database.

See Also: PL/SQL User’s Guide and Reference for information about PL/SQL code to create these plans

9-4 Oracle9i Database Concepts

Соседние файлы в папке Oracle selected docs