Recompiling Invalid Objects

When you upgrade a database to Oracle Database 11g, many of the PL/SQL modules in your database become invalid. As a result, all of the existing PL/SQL modules in an INVALID state, such as packages, procedures, types, and so on, must be recompiled.

About Recompiling Invalid Objects

By default, Oracle Database recompiles the invalid PL/SQL modules as they are used. For example, if an invalid PL/SQL module is called, Oracle first recompiles the module before running it. The time it takes to recompile the module can result in poor performance as you begin to use your newly upgraded database.

To eliminate these performance issues, select Recompile invalid objects at the end of upgrade. When you select this option, Database Upgrade Assistant (DBUA) recompiles all of the invalid PL/SQL modules immediately after the upgrade is performed. This ensures that you do not experience any performance issues later when you begin using your newly upgraded database.

Note: Selecting the Recompile invalid objects at the end of upgrade is equivalent to running the utlrp.sql script, which is used to recompile stored PL/SQL and Java code and is described in the Oracle Database Upgrade Guide.

Taking Advantage of Multiple CPUs

The task of recompiling all of the invalid PL/SQL modules in your database can take a significant amount of time and increase the time that it takes to complete your database upgrade. If there are multiple CPUs, then you can reduce the time that it takes to perform this task by taking advantage of parallel processing on your available CPUs.

If multiple CPUs are available, then DBUA automatically adds an additional section to the Recompile Invalid Objects page and automatically determines the number of CPUs that are available.

DBUA also provides a recommended degree of parallelism, which determines how many parallel processes are used to recompile invalid PL/SQL modules. Specifically, DBUA sets the degree of parallelism to one less than the number of CPUs available. For example, if three CPUs are available for processing, then DBUA selects "2" from the Degree of Parallelism drop-down menu.

You can adjust this default value by selecting a new value from the Degree of Parallelism drop-down menu.

Upgrade Timezone Option

Oracle recommends upgrading the time zone data of the database. Oracle handles semantic errors automatically. If errors occur during the time zone upgrade, you may need to restore the database from the backup.

Select the Upgrade Timezone option to upgrade the timezone of the database. Timezone data cannot be downgraded. You must patch the old home with the new timezone version before downgrading the database. Timezone upgrade restore point and additional time required for timezone upgrade are not supported by DBUA.

If you choose to upgrade TZ data and TZ data upgrade fails, the database must be restored to its original home.

Backup Database Option

Oracle strongly recommends that you back up your database before starting the upgrade. If errors occur during the upgrade, you may need to restore the database from the backup.

Select the Backup Database option to backup the database and enter or browse for the location of the Backup Directory to use during the backup process.

Related Topics

Overview of the Database Upgrade Assistant