turbocharge your database: use the oracle database 10 g sqlaccess advisor

44

Upload: easter

Post on 06-Jan-2016

56 views

Category:

Documents


6 download

DESCRIPTION

Session id: 40150. Turbocharge your Database: Use the Oracle Database 10 g SQLAccess Advisor. Dr. Lilian Hobbs Summary Management Product Manager Oracle Corporation. Database Performance. Could your database run faster? Do you have the best set of indexes? - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor
Page 2: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Turbocharge your Database: Use the Oracle Database 10g SQLAccess Advisor

Dr. Lilian HobbsSummary Management Product Manager

Oracle Corporation

Session id: 40150

Page 3: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 3

Database Performance

Could your database run faster?

Do you have the best set of indexes?

Have you created any materialized views?

Page 4: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 4

Want to do this – But

Don’t have the time to gather the data

Page 5: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 5

Want to do this – But

Don’t have the time to gather the data

Workloads change so not sure what is best

Page 6: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 6

Want to do this – But

Don’t have the time to gather the data

Workloads change so not sure what is best

Not sure which indexes and mv’s to create

Page 7: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 7

Want to do this – But

Don’t have the time to gather the data

Workloads change so not sure what is best

Not sure which indexes and mv’s to create

Little experience creating mv’s but happy creating indexes

Page 8: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 8

SQL Access Advisor Overview

What indexes, MVs do I need to optimize my

entire workload?

SQL Access Advisor

Solution

Component of CBO

Provides implementation

script

No expertrequiredDBA

Page 9: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 9

What does it Recommend

Workload

Indexes Materialized ViewsMaterialized Views Log

SQL Access Advisor

Page 10: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 10

Based upon the Oracle 9i Advisor Part of Oracle Database 10g Server Mangeability Generates recommendations

– fast process, no long waits for information– choose recommendations to implement

automatically using OEM generate a SQL script

Interfaces– completely new GUI interface– command line

Try the SQLAccess Advisor

Page 11: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 11

Steps to use SQLAccess Advisor

Create a Task (transparent in Enterprise Manager)– optionally define parameters

Create a Workload– optionally define workload parameters

Generate Recommendations

Optionally implement recommendations

Page 12: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 12

Start Here - Advisor Central

Page 13: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 13

What is the Task

Task is where all results are stored Can keep tasks and their results In Enterprise Manager the task is

transparent– can give it a name

Configure a task as a template for new tasks (command line only)

Page 14: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 14

Workload

SQLAccess Advisor can use the following workload sources

– Current contents of the SQL cache– Hypothetical (specify schema(s) in the database)– User-Defined (in a table) – Add SQL statements to a workload

(command line only)

– Oracle 9i Advisor workload– SQL Tuning Sets

Page 15: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 15

Workload Source using Wizard

Page 16: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 16

SQL Tuning Sets

Page 17: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 17

Filtering

Don’t have to use the entire workload Filter by

– Application or module name– Number of SQL statements– Queries during a specified time window– Username– Tables

must be in this list not in this list

Page 18: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 18

Advanced Workload Options

Page 19: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 19

Recommendation Options

Page 20: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 20

Other Options

Page 21: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 21

Tuning Options

SQL statements will be tuned according to the resources they use

Page 22: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 22

Schedule the Job

Page 23: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 23

Final Review

Page 24: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 24

Monitor the Job

Page 25: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 25

Recommendations

SQLAccess Advisor wizard view by– Recommendations– SQL statements

Do not have to accept all recommendations Can modify object names and locations

Page 26: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 26

Review the Recommendations

Page 27: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 27

Review Recommendations Pt 2

Workload cost will not equal 100 because the cost is specific to a query

Page 28: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 28

View a Recommendation

Page 29: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 29

See the Statement

Page 30: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 30

Recommendations by SQL

Page 31: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 31

Recommendations by SQL Pt 2

Page 32: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 32

Tuning this SQL Statement

Page 33: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 33

Accepting Recommendations

Page 34: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 34

Show SQL Script

Page 35: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 35

Implement Recommendations

Page 36: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 36

The Command Line Interface

Page 37: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 37

Housekeeping

Don’t forget to – Change the expiration dates for tasks

and workloads if you want to keep them over 30 days

– Remove tasks and workloads when no longer required

Page 38: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 38

Features only available in the command line

Template tasks and workloads– Using or creating them

Adding/changing/deleting/searching SQL statements in a workload

Using an Oracle 9i workload Quick Tune of a single SQL statement

Page 39: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

D E M O N S T R A T I O N

SQLAccess Advisor

Page 40: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 40

Want to do this now?

Try the Oracle 9i Advisor Functionality is very similar

– Only recommends materialized views

Different interface GUI available in OEM Can use 9i workloads with SQLAccess

Advisor

Page 41: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 41

Conclusion

SQLAccess Advisor can tune parts of the database that your DBA never knew was a problem

Easy and quick to use Build up a pattern of usage over time You choose what to implement See what the SQLAccess Advisor could do to

improve your system performance

Page 42: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

Page: 42

Reminder – please complete the OracleWorld online session survey

Thank you.

Page 43: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor

AQ&Q U E S T I O N SQ U E S T I O N S

A N S W E R SA N S W E R S

Page 44: Turbocharge your Database: Use the Oracle Database 10 g  SQLAccess Advisor