ORACLE TUNING PACK
ORACLE DATA SHEET
ORACLE TUNING PACK
KEY FEATURES AND
For database administrators and application developers,
BENEFITS:
application tuning is a critically important area and a considerable
• Comprehensive solution for
amount of their time is spent performing this very important
application and SQL tuning
that eliminates need for
manual tuning.
• Provides automatic tuning of
SQL statements.
• Enhances system
performance and reliability
and significantly lowers
management costs.
function. A poorly tuned business application can potentially affect
not just a few users but an entire business operation and for this
reason companies invest significant resources to ensure smooth
running of applications vital for their businesses. Oracle Tuning
Pack, a part of Oracle Database 10g product set, offers an
extremely cost effective and easy-to- use solution that automates the
entire application tuning process. Automatic SQL tuning is
exposed to the user through two new components, SQL Tuning
Advisor and SQL Access Advisor, that are seamlessly integrated
with the Enterprise Manager Database Control and Grid Control,
and together provide a comprehensive solution for automating the
complex and time-consuming task of application tuning.
Automatic SQL Tuning
Manual SQL tuning is a complex process that presents many challenges. It
requires expertise in several areas, is very time consuming, and requires an
intimate knowledge of the schema structures and the data usage model of the
application. All these factors make manual SQL tuning a challenging and resource
intensive task that is ultimately very expensive for businesses.
Automatic SQL Tuning, a new solution that is part of the Oracle Tuning Pack 10g,
is Oracle’s answer to all the pitfalls and challenges of manual SQL tuning. It
automates the entire SQL tuning process by comprehensively exploring all the
possible ways of tuning a SQL statement. It is performed by the database engine’s
query optimizer, which has been significantly enhanced in Oracle Database 10g.
Four types of analyses are performed in Automatic SQL Tuning:
•
Statistics Analysis: The query optimizer needs up-to-date object statistics to
generate good execution plans. In this analysis objects with stale or missing
statistics are identified and appropriate recommendations are made to remedy
the problem.
•
SQL Profiling: This is new feature introduced in Oracle Database 10g that
revolutionizes the approach to SQL tuning. Traditional SQL tuning involves
manual manipulation of application code using optimizer hints. SQL
Profiling eliminates the need for this manual process and tunes the SQL
January 2004
1
ORACLE DATA SHEET
statements without requiring any change to the application code. This ability
to tune SQL without changing the application code also helps solve the
problem of tuning packaged applications. Packaged application users now no
longer need to log a bug with the application vendor and wait for several
weeks or months to obtain a code fix for tuning the statement. With SQL
profiling tuning is automatic and immediate.
•
Access Path Analysis: Indexes can tremendously enhance performance of a
SQL statement by reducing the need for full table scans. Effective indexing
is, therefore, a common tuning technique. In this analysis new indexes that
can significantly enhance query performance are identified and
recommended.
•
SQL Structure Analysis: Problems with the structure of SQL statements can
lead to poor performance. These could be syntactic, semantic, or design
problems with the statement. In this analysis relevant suggestions are made to
restructure the SQL statements for improved performance.
Automatic SQL Tuning offers a comprehensive SQL tuning solution that obviates
the need for the slow, tedious and expensive manual tuning. It is exposed to the
user through the use of two new advisors that are part of the Oracle Tuning Pack
10g, the SQL Tuning Advisor and the SQL Access Advisor.
SQL Tuning Advisor
The Automatic SQL Tuning capabilities are exposed through a new server
component called the SQL Tuning Advisor. The SQL Tuning Advisor takes one or
more SQL statements as input and invokes the automatic SQL tuning process on it.
The output of the SQL Tuning Advisor is in the form of recommendations, along
with a rationale for each recommendation and its expected benefit. The
recommendation relates to collection of statistics on objects, creation of new
indexes, restructuring of the SQL statement, or creation of a SQL Profile. A user
can choose to accept the recommendation to complete the tuning of the SQL
statements.
The SQL Tuning Advisor is designed to accept input from several SQL sources,
such as Automatic Database Diagnostic Monitor (ADDM), Automatic Workload
Repository (AWR), cursor cache, and custom SQL as defined by the user. This
enables the tuning of practically all SQL statements that would be of interest to a
user. SQL statements from these input sources are typically first loaded in a new
object called SQL Tuning Set, which is then submitted as input to the advisor.
A SQL Tuning Set (STS) is a new database object used for capturing SQL
workload information. It includes:
January 2004
•
One or more SQL statements
•
Associated execution context, such as user schema, list of bind values, etc.
•
Associated basic execution statistics, such as elapsed time, CPU time, etc.
2
ORACLE DATA SHEET
Figure 1: Managing SQL Tuning Sets using Enterprise Manager.
SQL Tuning Sets provide the basic framework for capturing, managing, and tuning
SQL workloads. They allow selective, on-demand tuning of system generated and
custom (user-defined) workloads and greatly simplify the task of tuning multiple
SQL statements. With SQL Tuning Sets, users can capture any SQL statements of
interest and store them in an STS for future tuning. They no longer need to
manually build and maintain SQL scripts for tuning purposes. Furthermore,
information pertaining to execution context and statistics that is captured in an STS
allows for more superior and efficient tuning than would be possible from any
custom SQL script.
After analyzing the SQL statements, the SQL Tuning Advisor provides advice on
improving the performing of the SQL statements(s), the rationale for the proposed
advice, estimated performance benefit, and the command to implement the advice.
You simply have to choose whether or not to accept the recommendations to
optimize the SQL statements. Figure 2 shows the recommendation page of EM.
Figure 2: SQL Tuning Advisor recommendations page.
The SQL Tuning Advisor offers a powerful, intuitive, and user-friendly way for
January 2004
3
ORACLE DATA SHEET
performing automatic SQL tuning. SQL tuning now no longer has to be the
domain of experts. Oracle has built a tuning expert inside the database engine to
perform this very important function for the database administrators in a fraction of
the time and cost needed to carry out the same task manually.
SQL Access Advisor
The design of the database schema can have a big impact on the overall application
performance. SQL Access Advisor is a new solution in the Oracle Database 10g
that provides comprehensive advice on how to optimize schema design in order to
maximize application performance. SQL Access and SQL Tuning Advisors,
together, provide a complete solution for tuning database applications. These two
advisors together automate all manual tuning techniques currently practiced and
form the core of Oracle’s automatic SQL tuning solution.
The SQL Access Advisor accepts input from all possible sources of interest, such
as the cursor cache, the Automatic Workload Repository (AWR), any user-defined
workload, and will even generate a hypothetical workload if a schema contains
dimensions or primary/foreign key relationships. It comprehensively analyzes the
entire workload and provides recommendations to create new indexes if required,
drop any unused indexes, create new materialized views and materialized view
logs. The analysis considers the cost of insert/update/delete operations in addition
to the queries. The recommendation generated by the SQL Access Advisor is
accompanied by a quantifiable measure of expected performance gain as well as
scripts needed to implement the recommendation.
Figure 3 shows the SQL Access Advisor recommendations page. The
recommendations are ordered by the workload improvement factor. User can
select one or all of the recommendations and implement them by simply clicking
the Implement button.
Figure 3: SQLAccess Advisor Recommendations page.
January 2004
4
ORACLE DATA SHEET
ORACLE TUNING PACK 10G
The SQL Access Advisor takes the mystery out of access structure design process.
It tells the user exactly what the type of indexes and materialized views are
RELATED PRODUCTS
AND SERVICES:
Oracle Tuning Pack 10g
delivers maximum benefits
when used with following
Oracle products:
• Oracle Diagnostics Pack
10g for Database offers a
complete, cost-effective,
and easy to use solution
for managing the
performance of Oracle
Database environments
by providing unique
functionality such as
automatic identification of
performance bottlenecks,
guided problem resolution,
comprehensive system
monitoring and event
management.
• The Oracle Configuration
Management Pack tracks
and analyzes hardware,
OS and software
configurations and lowers
the cost of complex
operations such as
applying software
patches, enforcing
operational policies and
cloning systems.
required to maximize application performance. By automating this very critical
function, SQL Access Advisor obviates the need for the error-prone, lengthy, and
expensive manual tuning process. It is fast, precise, easy to use and, together with
the SQL Tuning Advisor, offers the most accurate and cost-effective solution for
application performance tuning.
Object Reorganization Wizard
Oracle Tuning Pack 10g also provides the ability to reorganize objects. Managing
the space usage of your tablespaces efficiently by removing wasted space is not
only good space management practice but it also enhances performance by
reducing unnecessary disk I/Os. Reorganization is used for:
•
Rebuilding indexes and tables that are fragmented
•
Relocating objects to another tablespace
•
Recreating objects with optimal storage attributes
Oracle Tuning Pack 10g provides a wizard than can perform reorganization at
schema and tablespace levels, and gives the option for both online and offline
reorganization. The wizard also provides an impact analysis report as well as a
review script that contains the exact operations that will be performed. This helps
the users to precisely understand the implications of the operation before
implementing it. Figure 4 shows the Reorganization wizard EM interface.
• The Oracle Change
Management Pack for
Database provides the
ability to evaluate, plan
for, and implement
database schema
changes to support new
application requirements;
eliminates errors/data loss
when making changes,
minimizes downtime.
Figure 4: Object Reorganization Wizard
January 2004
5
Was this manual useful for you? yes no
Thank you for your participation!

* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project

Download PDF

advertisement