Sei sulla pagina 1di 21

Oracle Database 11g new features

Features
Oracle real application testing
1

a) Database reply b) Sql performance analyzer


2 3 4 5 6 7 8 9 10

Automatic memory management RMAN Enhancements Schema Management Security Manageability PL/SQL performance tuning SQL Access Advisor SQL plan management Miscellaneous features

1.Real application testing


Oracle defines real application testing as a combination of two tools:-

a. Database reply

b. SQL performance analyzer

DATABASE REPLY :
Database reply helps in capturing the complete database workload and then replying it on some other database or even on the same database. The capture process captures all the dmls during the capture period and stores them in binary format. These files have to exported to and can be replied on a test database. During the capture process oracle automatically takes AWR snapshots and once the capture is complete the snapshots have to be exported to the test system for comparing these statistics with those in the test system. Some of the important Pre-processing steps before starting the reply process are : Restore Database : Once the PROD backup is restored in the test system, it has be to recovered up to the scn number specified during the capture process Resolve References to External Systems : E.g. A db link in the prod system. Once the reply process is complete various reports are available to compare the reply and capture processes. One of them is the AWR compare report. The AWR compare report compares statistics during capture and reply process highlights metrics such as waits, locks, redo generation, consistent gets, and so on. An example of a AWR compare report is below

Architecture

Other useful reports are: 1. DB reply report the helps in comparing the execution of the captured workload to that of reply workload 2. AWR report that summarizes and analyzes the databases overall performance between the database replay operations starting and ending time periods.

SQL Performance Analyzer (SPA)


In Database Replay, the entire captured workload is replayed against the database. But what if you dont want to do that? What if you want to see how specific sql statements would behave after say, a parameter change or creating a new index? SPA allows you to do that. It Allows you to capture specific SQL statements and replay them and also provides a report to analyze the change.

2. Automatic memory management


In 10g,the total available memory is divided into two components.One is SGA and the other is PGA. Oracle offered SGA_TARGET to automate the individual components inside the SGA. In 11g oracle takes this tradition a little forward to completely automate the available memory. Along with SGA_TARGET,PGA_AGGREGATE_TARGET oracle offers MEMORY_TARGET. If MEMORY_TAGET is set oracle takes care of SGA and PGA automatically. This parameter is a static initialization parameter. Oracle also provides four new dynamic performance views : V$MEMORY_CURRENT_RESIZE_OPS V$MEMORY_DYNAMIC_COMPONENTS V$MEMORY_RESIZE_OPS V$MEMORY_TARGET_ADVICE

3. RMAN Enhancements
Data recovery advisor Parallel backup of same file Virtual catalogs Proactive health checks Flashback Logs to Rescue Also rman features a GUI with full functionality

RMAN Enhancements
Data recovery advisor
A noticeable feature where rman provides the DBA with an automated script incase a datafile is lost or any such error. E.g. In case of a missing datafile the script would look like this Repair script : # restore and recover datafile sql alter database datafile 4 offline; restore datafile 4; recover datafile 4; sql alter database datafile 4 online; This script can also be previewed before executing it using the command : rman > repair failure preview

RMAN Enhancements
Parallel Backup of the Same Datafile
Oracle introduced parallel backups in 10g , where you can define more than one channel and each channel behaves as an rman session backing up the datafiles.But the fact is each channel can backup only a single datafile at a time. In 11g RMAN, the channels can break the datafiles into chunks known as sections and sections can be backed up by different channels. rman allows to define size of each section.This can make backup of large datafiles faster.

RMAN Enhancements
Backup only uncommitted UNDO?
In 11g rman does a clever thing and avoids backing up committed undo data, the uncommitted undo data which is required for recovery will still be backed up.

RMAN Enhancements
Virtual Private Catalog
Oracle 11g allows you to have a single catalog database and create a virtual catalog for each target database. You can have as many as target databases but every thing will have only one catalog database. The private catalog concept can defined as follows First you need to create a base catalog that contains all the target databases. The owner is, say, RMAN. From the target database, connect to the catalog database as the base user and create the catalog. The owner or the base user of the catalog can grant a create catalog privilege to any other database user who wants to register to this catalog database. When you connect to the catalog database as the owner you can view all the databases registered with this catalog database but when any other user tries to list the databases registered with this catalog, he can only see himself and no one else. Oracle 11g also offers Merging Catalogs.

4 Schema Management
DDL Wait Option
The ORA-00054 : resource busy and acquire with NOWAIT specified or timeout expired The ORA is generally observed during busy system time,oracle 11g does not throw a error instead tries it for 10secs until it is successful. ALTER SYSTEM SET DDL_LOCK_TIMEOUT; can also be used to make this default to all sessions

Fine Grained Dependency Tracking


Consider a table is altered by adding a new column and in 10g a view derived from this object will be invalid causing the objects like packages using this view to be invalid. In 11g Oracle takes care of changes like these and will not mark the view as invalid thereby improving the availability of the application.

5.Security
Oracle offers a new view dba_users_with_defpwd which lists all the users having default passwords.

Case sensitive passwords


Oracle offers case sensitive passwords and also allows you to revert back if you do not like it using the parameter SEC_CASE_SENSITIVE_LOGON.One can set the parameter to false to disable this When you upgrade an existing Oracle 10g database to 11g, you can migrate your passwords to the new standard. You can check the status of the password by querying the DBA_USERS view, especially the new column PASSWORD_VERSIONS.

8.SQL Access Advisor


SQL Access advisor in 11g improving schema design by partitioning, indexing, and creating materialized views based on actual frequency and type of usagenot data. Apart from analyzing indexes, materialized views as it does in 10g, sql access advisor in 11g also analyzes tables and queries to identify possible partitioning strategies

9.SQL Plan Management


Oracle introduces a new initialization parameter cursor_sharing. If the parameter is set to force and if your code does not have bind variables and instead you are passing values to the variables in your sql statements, oracle can force all variables to be converted to bind variables. This might be helpful because it does not require that the query is parsed every time it is run but at the same time this execution plan might not be the most optimized one for all queries. Simply put , even if bind variables are good in most cases, they actually fail in cases where the selectivity of the values affects the execution plans, because the optimizer actually freezes the execution plan when you are using a bind variable.

SQL Plan Management


Adaptive cursors
Here comes adaptive cursors Instead of blindly using the cached execution plan whenever the query is executed, they actually decide if a plan has to be recalculated when the bind variable value changes. The V$SQL view is modified to add two more columns IS_BIND_SENSITIVE and IS_BIND_AWARE. Oracle observes if the values have the potential to change plans and marks IS_BIND_SENSITIVE as Y if the can. The column IS_BIND_AWARE is marked as Y where the plan is recalculated with every change in the value Oracle also offers features like SQL Plan Baselining

10.Miscellaneous features
Automatic Health Monitor
Similar to advisors in 10g , oracle 11g introduces automatic health monitor which checks variouscomponents of the database to see that they are not corrupted. The various Checkers include DB Structure Integrity Check, Data Block Integrity Checker, Redo Integrity Check, Undo Segment Integrity Check,Transaction Integrity Check, Dictionary Integrity Check.

Automatic Diagnostic Repository Once if any one of the above mentioned checkers find something, all the information about the incident is placed in Automatic Diagnostic Repository.All the files in the repository for a particular event can be forwarded to oracle support by using the new packaging service in 11g ( Assuming OCM is configured) ADR home The new initialization parameter diagnostic_dest will point to the adr home which will have all the trace files ,alert_log files and other log files.The *_dest parameters parameter from previous oracle versions are ignored in 11g In 11g the alert log will be available in xml format,an older version of the alertlog will still be available in trace directory in the ADR home

Potrebbero piacerti anche