Vous êtes sur la page 1sur 19

Managing Usage Tracking

Copyright 2010, Oracle and/or its affiliates. All rights reserved.

Objectives
After completing this lesson, you should be able to: Identify the need for usage tracking Set up and administer Oracle BI usage tracking

21 - 2

Copyright 2010, Oracle and/or its affiliates. All rights reserved.

Business Challenges
When it is first deployed, Oracle BI may not be optimized for the querying that actually occurs:
End-user queries may not match what is expected, so the cache is not seeded with appropriate queries. Additional aggregate tables may need to be created to speed up query processing.

Your company may need to track database usage on a user or departmental level:
Users may be charged for database use. Regulatory requirements may require usage tracking.

21 - 3

Copyright 2010, Oracle and/or its affiliates. All rights reserved.

Business Solution: Oracle BI Usage Tracking


Tracks and stores Oracle BI Server usage at the detailed query level Supports the accumulation of usage tracking statistics that can be used in a variety of ways, such as:
Database performance optimization Aggregation strategies Billing users or departments based on the resources they consume

Provides ability to analyze usage results with end-user reporting tools

21 - 4

Copyright 2010, Oracle and/or its affiliates. All rights reserved.

Oracle BI Usage Tracking Methods


There are two methods for enabling usage tracking: Direct insertion (recommended approach)
Oracle BI Server inserts statistics for every query directly into a relational database table.

Log file
Oracle BI Server inserts statistics for every query into a log file.

21 - 5

Copyright 2010, Oracle and/or its affiliates. All rights reserved.

ABC Example
Set up Oracle BI usage tracking to track and store usage statistics at the detailed query level.

Username

Date

Time

Subject area

Logical SQL

Row count

21 - 6

Copyright 2010, Oracle and/or its affiliates. All rights reserved.

Steps to Enable Usage Tracking


1. 2. 3. 4. 5. 6. 7. 8. 9. Create the usage tracking table. Import the usage tracking table. Build a usage tracking business model. Enable usage tracking. Enable direct insertion. Set the physical table parameter. Set the connection pool parameter. Set additional parameters. Test the results.

21 - 7

Copyright 2010, Oracle and/or its affiliates. All rights reserved.

1. Create the Usage Tracking Table


Use the provided SAACCT.<db>.sql script to create the S_NQ_ACCT usage tracking table.

This table stores the usage tracking data when queries are run against Oracle BI Server.

21 - 8

Copyright 2010, Oracle and/or its affiliates. All rights reserved.

2. Import the Usage Tracking Table


Import the usage tracking table into the Physical layer.

21 - 9

Copyright 2010, Oracle and/or its affiliates. All rights reserved.

3. Build a Usage Tracking Business Model


Build a usage tracking business model using the columns in the S_NQ_ACCT table:

21 - 10

Copyright 2010, Oracle and/or its affiliates. All rights reserved.

4. Enable Usage Tracking


Modify the NQSConfig.ini file to enable usage tracking.

21 - 11

Copyright 2010, Oracle and/or its affiliates. All rights reserved.

5. Enable Direct Insertion


Set the DIRECT_INSERT parameter to YES to specify that statistics are inserted directly into a database table.

21 - 12

Copyright 2010, Oracle and/or its affiliates. All rights reserved.

6. Set the Physical Table Parameter


Set the PHYSICAL_TABLE_NAME parameter to specify the table into which to insert records corresponding to the query statistics. The table name is the fully qualified name as it appears in the Physical layer of the Administration Tool.

21 - 13

Copyright 2010, Oracle and/or its affiliates. All rights reserved.

7. Set the Connection Pool Parameter


Set the CONNECTION_POOL parameter to specify the connection pool to use for inserting records into the usage tracking table. The connection pool is the fully qualified name as it appears in the Physical layer of the Administration Tool.

21 - 14

Copyright 2010, Oracle and/or its affiliates. All rights reserved.

8. Set Additional Parameters


BUFFER_SIZE
Amount of memory that is used to store insert statements temporarily

BUFFER_TIME_LIMIT_SECONDS
Maximum amount of time that an insert statement remains in the buffer before it is issued to the usage tracking table

NUM_INSERT_THREADS
Number of threads that remove insert statements from the buffer and issue them to the usage tracking table

MAX_INSERTS_PER_TRANSACTION
Number of records to group together as a single transaction when inserting into the usage tracking table

21 - 15

Copyright 2010, Oracle and/or its affiliates. All rights reserved.

9. Test the Results


Use the Usage Tracking subject area to build and run queries:

21 - 16

Copyright 2010, Oracle and/or its affiliates. All rights reserved.

Analyzing Usage Tracking Data


Watch for long-running queries (typically ad hoc):
End users may need training. You might need to assign query blocking or restrictions on how long queries can run or how many records are returned. The database may require additional indexes or tuning.

Perform usage audits for:


Regulatory compliance Security

Determine whether a query should be used to seed the cache or be removed from the cache-seeding queries. Identify aggregation strategies. Bill users or departments based on the resources that they consume.
Copyright 2010, Oracle and/or its affiliates. All rights reserved.

21 - 17

Summary
In this lesson, you should have learned how to: Identify the need for usage tracking Set up and administer Oracle BI usage tracking

21 - 18

Copyright 2010, Oracle and/or its affiliates. All rights reserved.

Practice 21-1 Overview: Setting Up Usage Tracking


This practice covers setting up and administering usage tracking.

21 - 19

Copyright 2010, Oracle and/or its affiliates. All rights reserved.

Vous aimerez peut-être aussi