Oracle8i Migration
Release 8.1.5

A67774-01

Library

Product

Contents

Index

Prev Next

7
Upgrading to the New Oracle8i Release

This chapter contains information about upgrading your current release of Oracle to the new Oracle8i release. The information in this chapter only applies to release 8.0 and higher installations of Oracle. If your current release is pre-release 8.0, such as Oracle7 or version 6, and you want to migrate to Oracle8i, follow the instructions at the beginning of this book, starting with Chapter 1, "Overview".

This chapter covers the following topics:

Upgrade Paths

The path that you must take to upgrade your database to the new release depends on the release you are currently using. Table 7-1 contains the upgrade path required for each old release of Oracle. Use the upgrade path and the documentation specified for the release you are running currently.

Table 7-1 Upgrade Paths
Old Release  Upgrade Path 

8.0.1  

Direct upgrade is not supported. Complete the following steps to upgrade to the new release:

  1. Upgrade to release 8.0.2 using the instructions in the release 8.0.2 README.doc file.

  2. Upgrade to release 8.0.5 using the instructions in the release 8.0.5 README.doc file.

  3. Upgrade to the new release using the instructions in "Upgrading the Database to the New Oracle8i Release".

 

8.0.2

8.0.4S  

Direct upgrade is not supported. Complete the following steps to upgrade to the new release:

  1. Upgrade to release 8.0.5 using the instructions in the release 8.0.5 README.doc file.

  2. Upgrade to the new release using the instructions in "Upgrading the Database to the New Oracle8i Release".

 

8.0.3

8.0.4

8.0.5

8.1.3

8.1.4  

Direct upgrade is supported. Upgrade to the new release using the instructions in "Upgrading the Database to the New Oracle8i Release".  

8.1.1

8.1.2  

Upgrading to the new release is not supported.  

Upgrading the Database to the New Oracle8i Release

This section guides you through the process of upgrading your database to the new Oracle8i release.


Note:

If you are upgrading from Oracle8i Enterprise Edition to Oracle8i (formerly Workgroup Server), before you upgrade, modify any applications that use the advanced features of Oracle8i Enterprise Edition so that they do not use these advanced features. See Getting to Know Oracle8i for more information about the differences between the editions.  


Prepare to Upgrade

Complete the following steps to begin the upgrade process:

  1. If you are upgrading from release 8.1.4 and you have Java source, class, or resource objects that you want to preserve, export these Java objects before you upgrade, and then import them after you upgrade.


    Note:

    Exporting and importing Java objects between pre-release 8.1.5 databases and the current release is not guaranteed to be successful.  


    See Also:

    Oracle8i Utilities for information about exporting and importing Java source, class, and resource objects.  

  2. If you are upgrading from release 8.1.3 or 8.1.4 and you created any release 8.1 compatible queue tables using release 8.1.3 or release 8.1.4, drop all 8.1 compatible queue tables before upgrading the database. If you are upgrading from a release other than release 8.1.3 or 8.1.4, skip to Step 4.

    To determine if there are any existing release 8.1 compatible queue tables in the database, issue the following SQL statement:

        SELECT owner, queue_table FROM dba_queue_tables where 
          compatible like '8.1%'; 
      
    

    For example, you might see the following table as a result of issuing the above query:

    OWNER                          QUEUE_TABLE                    
    ------------------------------ ------------------------------ 
    AQUSER1                        RAW_MSG_TABLE                  
    1 row selected. 
    
    

    You can drop the queue tables listed by using DBMS_AQADM.DROP_QUEUE_TABLE, as in the following example:

    EXECUTE dbms_aqadm.drop_queue_table(queue_table=>'AQUSER1.RAW_MSG_TABLE',
                                                          force => TRUE);
    
    
  3. Make sure your DB_DOMAIN initialization parameter is set properly.

    See Also:

    "The DB_DOMAIN Parameter" for more information about setting this initialization parameter.  

  4. Start Server Manager.

  5. Connect to the database instance:

    SVRMGR> CONNECT INTERNAL
    
    
  6. If you are upgrading from an 8.0 release, make sure no user or role has the name OUTLN, because this schema is created automatically when you install Oracle8i. If you have a user or role named OUTLN, you must drop the user or role and recreate it with a different name.


    Note:

    If you are upgrading from an 8.1 release, you do not need to perform this check because the OUTLN user should have been created when you installed the previous 8.1 release. Therefore, if you are upgrading from an 8.1 release, skip to Step 7. Do not drop the OUTLN user if you are upgrading from a previous 8.1 release.  


    To check for a user with the name OUTLN, enter the following SQL statement:

    SELECT username FROM dba_users WHERE username = 'OUTLN';
    
    

    If you do not have a user named OUTLN, zero rows are selected.

    To check for a role with the name OUTLN, enter the following SQL command:

    SELECT role FROM dba_roles WHERE role = 'OUTLN';
    
    

    If you do not have a role named OUTLN, zero rows are selected.

  7. Add space to your SYSTEM tablespace and to the tablespaces where you store rollback segments, if necessary.

    Upgrading to a new release requires more space in your SYSTEM tablespace and in the tablespaces where you store rollback segments. If you have enough space on your system, consider adding more space to these tablespaces. If you run out of space during the upgrade, you will need to perform the upgrade again.

    The following SQL statement illustrates how to add more space to a tablespace:

    ALTER TABLESPACE system
       ADD DATAFILE '/home/user1/mountpoint/oradata/db1/system02.dbf'
       SIZE 50M;
    
    
  8. Run SHUTDOWN IMMEDIATE on the database:

    SVRMGR> SHUTDOWN IMMEDIATE
    
    

    If you are using Oracle Parallel Server, shutdown all instances.

  9. Perform a full offline backup of the database.

    See Also:

    Oracle8i Backup and Recovery Guide for more information.  

Upgrade the Database

Choose an upgrade method and then follow the instructions for upgrading using the method you have chosen.

Choose an Upgrade Method

There are two ways to upgrade your database to release 8.1. You can either use the Oracle Data Migration Assistant to complete the upgrade, or you can perform the upgrade manually.

The Oracle Data Migration Assistant provides a completely automated upgrade of your database. You use a graphical user interface (GUI), which guides you through each step of the process. In addition, the Oracle Data Migration Assistant includes extensive online help. The Oracle Data Migration Assistant runs the appropriate upgrade script for your current release, deletes any obsolete initialization parameters from your initsid.ora file, and optionally configures your listener.ora file. See Appendix B, "Changes to Initialization Parameters" for lists of obsolete initialization parameters.

On the other hand, you lose some flexibility and control by using the Oracle Data Migration Assistant. If you want complete control over the upgrade process, especially with regard to setting initialization parameters, you may want to perform the upgrade manually.


CAUTION:

The Oracle Data Migration Assistant cannot upgrade systems with Oracle Parallel Server installed. If you have Oracle Parallel Server installed, you must upgrade the database manually.  


Decide which method you want to use to upgrade your database, and then complete the steps in one of the following sections accordingly:

Upgrade the Database Using the Oracle Data Migration Assistant

Complete the following steps to upgrade the database using the Oracle Data Migration Assistant:

  1. Follow the instructions in your operating-system specific Oracle documentation to prepare for installation and start the Oracle Universal Installer.

  2. At the Welcome screen of the Oracle Universal Installer, click Next.

    If you need help at any screen or want to consult more documentation about the Oracle Universal Installer, click the Help button to open the online help.

  3. At the File Locations screen, make sure the Destination is the complete path to the directory you want to use for your release 8.1 Oracle home. Then, click Next.


    Note:

    If you are upgrading from an 8.0 release, you must install the new 8.1 release in an Oracle home separate from the 8.0 release. However, if you are upgrading from a previous 8.1 release, this restriction does not apply, and you can install the new release into the same Oracle home as the previous release if you wish.  


  4. At the Available Products screen, select the edition of Oracle8i that you want to install, either Oracle8i Enterprise Edition or Oracle8i. Then, click Next.

  5. At the Installation Types screen, choose an installation type. Then, click Next.

    If you chose Custom, respond to the screens that enable you to specify your custom installation settings until you reach the "Upgrading or Migrating an Existing Database" screen.

    Make sure you install all of the options you installed with the Oracle7 database, assuming you do not want to discontinue use of a particular option. For example, if you installed Advanced Replication in Oracle7, you should install it in Oracle8i.

  6. At the "Upgrading or Migrating an Existing Database" screen, complete the following steps:

    1. Select the "Upgrade or Migrate an Existing Database" check box.

    2. Choose the database to upgrade.

    3. Click Next.

  7. At the Summary screen, make sure all of the settings and choices are correct for your installation. Then, click Install. The Oracle Universal Installer performs the installation, which may take some time.

    When installation is complete, one or more assistants may be started. When the Oracle Data Migration Assistant is started, you are ready to proceed with the upgrade.

  8. At the Welcome screen of the Oracle Data Migration Assistant, click Next. The exact screen may be slightly different than the one shown in Figure 7-1, depending on your operating system.

    Figure 7-1 Welcome Screen of the Oracle Data Migration Assistant


    If you need help at any screen or want to consult more documentation about the Oracle Data Migration Assistant, click the Help button to open the online help.

  9. At the "Before You Migrate or Upgrade" screen, make sure the database that you are upgrading meets the conditions specified. Then, click Next.

  10. At the "Select a Database Instance" screen, select the database instance of the database you are upgrading. Then, click Next.


    Note:

    The database you choose must be release 8.0 or higher. If the database is an Oracle7 or lower database, you must complete a migration of the database, not an upgrade. If the database is an Oracle7 database, exit the Oracle Data Migration Assistant, and see Chapter 1 to start the migration process.  


  11. At the "Database Password and INIT.ORA File" screen, complete the following steps:

    1. Make sure the specified new Oracle home is correct.

    2. Make sure the location of the initsid.ora file specified is the complete path to the initsid.ora file of the database that you are upgrading.

    3. Make sure the old Oracle home specified is the complete path to the Oracle home of the database you are upgrading.

    4. Click Next.

  12. At the "Choose Migration or Upgrade Type" screen, choose a migration type. Then, click Next.

    If you chose Custom, respond to the screens that enable you to specify your custom migration settings until you reach the "Confirm Backup" screen.

  13. At the "Confirm Backup" screen, click Next if you have backed up the database. If you have not, you should do so now and then repeat the upgrade.

  14. At the "Start the Migration or Upgrade" screen, make sure all of the specifications are correct. If anything is incorrect, click Back until you can correct the specification. If everything is correct, click Next.

    The Oracle Data Migration Assistant performs the upgrade. If the COMPATIBLE initialization parameter was not set prior to upgrading, the assistant sets COMPATIBLE to 8.0.5. However, if COMPATIBLE was set prior to upgrading, the original setting is retained after the migration. See Chapter 8, "Compatibility and Interoperability" for information about resetting the COMPATIBLE initialization parameter.

    You may encounter a series of messages similar to the following during the upgrade:

    ORA-00604: error occurred at eecursive SQL level 1
    ORA-00001: unique constraint (SYSTEM.AQ$_QUEUES_CHECK) violated
    ORA-06512: at "SYS.DBMS_AQADM", line 2023
    ORA-06512: at line 2
    
    

    You can ignore these messages.


    CAUTION:

    If you retain the old Oracle software, never start the upgraded database with the old software. Only start the database with the executables in the new release 8.1 installation directory.  


  15. At the "Listener.ora Migration Confirmation" screen, click the Yes button if you want the assistant to modify your listener.ora file automatically, or click the No button if you do not want the assistant to modify the listener.ora file.

    Certain modifications are required to the listener.ora file for your database to work properly with Oracle Enterprise Manager. If you plan to use Oracle Enterprise Manager, you should click the Yes button to automatically modify the listener.ora file. However, if you do not plan to use Oracle Enterprise Manager, click the No button.

    If you click the Yes button, the Oracle Data Migration Assistant modifies the listener.ora file in the following way:

    1. The assistant shuts down the old listener and the new Oracle8i listener.

    2. The assistant modifies the SID_DESC entry for the migrated database in the Oracle8i listener.ora in one of the following ways:

      A simple case: Suppose the old listener.ora has the following SID_DESC entry:

      ... 
         (SID_DESC = 
            (SID_NAME = ORCL) 
         ) 
      ... 
      
      

      If the database name is SAL, the domain name is COM, and the Oracle home is /oracle/product/8.1, the assistant adds the following entry:

      ... 
         (SID_DESC = 
             (GLOBAL_DBNAME = sal.com) 
                (ORACLE_HOME = /oracle/product/8.1) 
                (SID_NAME = SAL) 
          ) 
      ... 
      
      

      A more complicated case: Suppose the old listener.ora has the following SID_DESC entry:

      ... 
         (SID_DESC = 
             (GLOBAL_DBNAME = an_entry) 
             (SID_NAME = ORCL) 
          ) 
      ... 
      
      

      If an_entry does not match the GLOBAL_DBNAME of the migrated database, and if the database name is SAL, the domain name is COM, and the Oracle home is /oracle/product/8.1, the assistant adds the following entry:

      ... 
         (SID_DESC = 
             (GLOBAL_DBNAME = sal.com) 
                (ORACLE_HOME = /oracle/product/8.1) 
                (SID_NAME = SAL) 
          ) 
      ... 
      
      

      This entry is the same as the entry in the simple case, but the assistant also adds the entry an_entry to the SERVICE_NAMES parameter. Therefore, the assistant changes the SERVICE_NAMES parameter to the following:

      SERVICE_NAMES = sal.com, an_entry
      
      
    3. On Windows NT, the assistant removes the entry of the migrated database from the old listener.ora file. The assistant does not perform this action on UNIX operating systems.

    4. The assistant starts up the Oracle8i listener.

Running the Oracle Data Migration Assistant Independently

If you installed Oracle8i without specifying that you are migrating or upgrading an existing database, you can run the Oracle Data Migration Assistant independently after the Oracle8i installation is complete.

Complete the following steps to run the Oracle Data Migration Assistant independently:

  1. Start the Oracle Data Migration Assistant.

    On UNIX, enter the following command at a system prompt:

    odma
    
    

    On Windows NT, select:

    Start > Programs > Oracle - ORACLE_HOME_NAME > Migration Utilities > Oracle 
    Data Migration Assistant
    
    

    When you start the Oracle Data Migration Assistant, its welcome screen appears (see Figure 7-1).

  2. Respond to questions in each Oracle Data Migration Assistant window, and click Next when you are ready to continue to the next window.

    See Also:

    Step 8 to Step 15 in "Upgrade the Database Using the Oracle Data Migration Assistant" for more information.  

Upgrade the Database Manually

Complete the following steps to upgrade the database manually:

See Also:

If you are upgrading an Oracle Parallel Server on Windows NT, see the Oracle Parallel Server Getting Started for Windows NT for important Operating System Dependent (OSD) layer instructions.  

  1. Install Oracle8i using the Oracle Universal Installer.

    1. Follow the instructions in your operating-system specific Oracle documentation to prepare for installation and start the Oracle Universal Installer.

      If you are upgrading a system with Oracle Parallel Server installed, see the Oracle8i Parallel Server Setup and Configuration Guide for additional installation instructions.

    2. At the Welcome screen of the Oracle Universal Installer, click Next.

      If you need help at any screen or want to consult more documentation about the Oracle Universal Installer, click the Help button to open the online help.

    3. At the File Locations screen, make sure the Destination is the complete path to the directory you want to use for your release 8.1 Oracle home. Then, click Next.

    4. At the Available Products screen, select the edition of Oracle8i that you want to install, either Oracle8i Enterprise Edition or Oracle8i. Then, click Next.

    5. At the Installation Types screen, choose either Custom or Minimal. Do no choose Typical unless you want to install a starter database along with your Oracle software. You can avoid installing a starter database if you select Custom or Minimal. Normally, you should not install a starter database if you are upgrading an existing database.

      After you make your selection, click Next.

      If you chose Custom, respond to the screens that enable you to specify your custom installation settings until you reach the "Upgrading or Migrating an Existing Database" screen.

      Make sure you install all of the options you installed with the Oracle7 database, assuming you do not want to discontinue use of a particular option. For example, if you installed Advanced Replication in Oracle7, you should install it in Oracle8i.

    6. If you are installing Oracle Parallel Server, at the Cluster Node Selection screen, select the nodes onto which you want the software installed. Then, click Next.

    7. At the "Upgrading or Migrating an Existing Database" screen, leave the "Upgrade or Migrate an Existing Database" checkbox unselected. Then, click Next.

      If you select the "Upgrade or Migrate an Existing Database" checkbox, the Oracle Data Migration Assistant is started automatically after installation. Because you are following the instructions for upgrading the database manually, you should not start the Oracle Data Migration Assistant.


      Note:

      The Oracle Data Migration Assistant does not support Oracle Parallel Server migrations.  


    8. At the Summary screen, make sure all of the settings and choices are correct for your installation. Then, click Install. The Oracle Universal Installer performs the installation, which may take some time.

      When installation is completed successfully, click the Exit button to close the Universal Installer.

  2. If your initsid.ora file resides within the old environment's Oracle home, copy it to a location outside of the old environment's Oracle home. In past releases, the default location for the initsid.ora file was $ORACLE_HOME/dbs on UNIX and $ORACLE_HOME\database on Windows NT, but in release 8.1, the default location is $ORACLE_BASE/admin/sid/pfile, where sid is the Oracle instance ID. The initsid.ora file can reside anywhere you wish, but it should not reside in the old environment's Oracle home after you upgrade to the new release.

    If your initsid.ora file has an IFILE (include file) entry and the file specified in the IFILE entry resides within the old environment's Oracle home, then copy the file specified by the IFILE entry to a location outside of the old environment's Oracle home. The file specified in the IFILE entry has additional initialization parameters. After you copy this file, make the same edits to it as you do to the initsid.ora file, as specified in the next step.


    Note:

    For Oracle Parallel Server, perform this step on all nodes. Also, if your initdb_name.ora file resides within the old environment's Oracle home, move or copy the initdb_name.ora file to a location outside of the old environment's Oracle home.  


  3. Adjust the initsid.ora file for use with the new release.

    Certain initialization parameters are obsolete in the new 8.1 release. Remove all obsolete parameters from any initialization parameter file that will start a new release 8.1 instance. Obsolete parameters may cause errors. Also, alter any parameter whose syntax has changed in the new 8.1 release; refer to Appendix B, "Changes to Initialization Parameters" for lists of new, renamed, and obsolete parameters. Also, if you are using Oracle Parallel Server, see Oracle8i Parallel Server Concepts and Administration for more information about obsolete Oracle Parallel Server initialization parameters.

    If you are updating snapshots automatically by using the JOB_QUEUE_PROCESSES initialization parameter, comment out this parameter in the initsid.ora file. Also, if you are using Advanced Queuing and have propagation schedules, comment out both the JOB_QUEUE_PROCESSES and AQ_TM_PROCESSES initialization parameters. After upgrading your database, you can remove the comments to use these parameters normally.

    In release 8.1, the LARGE_POOL_SIZE setting may be calculated automatically by Oracle. If the automatic setting is too large, it may increase the time required to perform your upgrade. See "Parallel Execution Allocated from Large Pool" for more information.

    If the initsid.ora file contains an IFILE entry, change the IFILE entry in the initsid.ora file to point to the new location you copied it to in Step 2.

    If you are using Oracle Parallel Server, modify the initdb_name.ora file in the same way that you modified the initsid.ora file.

    Make sure you save all of the files you modified after making these adjustments.


    Note:

    For Oracle Parallel Server, perform this step on all nodes. Also, set the PARALLEL_SERVER initialization parameter to FALSE. You can change it back to TRUE after the upgrade operation is complete.  


  4. Make sure that the following environment variables point to the new release 8.1 directories:

  5. At a system prompt, change to the $ORACLE_HOME/rdbms/admin directory.

  6. Start Server Manager.

  7. Connect to the database instance:

    SVRMGR> CONNECT INTERNAL
    
    
  8. Run STARTUP RESTRICT:

    SVRMGR> STARTUP RESTRICT
    
    

    You may need to use the PFILE option to specify the location of your initsid.ora file.

    You may see error messages listing obsolete parameters. If so, shut down the database, edit the initsid.ora file to remove the parameters listed, and then run STARTUP RESTRICT again.

  9. Set the system to spool results to a log file for later verification of success:

    SVRMGR> SPOOL catoutu.log
    
    

    If you want to see the output of the script you will run on your screen, you also can issue a SET ECHO ON statement:

    SVRMGR> SET ECHO ON
    
    
  10. Run uold_release.sql where old_release refers to the release you had installed prior to upgrading. See Table 7-2 to choose the correct script. Each script provides a direct upgrade from the release specified in the "Old Release" column. The "Old Release" is the release from which you are upgrading.

    To run a script, enter the following:

    SVRMGR> @uold_release.sql
    
    Table 7-2 Upgrade Scripts
    Old Release  Run Script 

    8.0.1  

    Direct upgrade is not supported. See "Upgrade Paths" for more information.  

    8.0.2  

    Direct upgrade is not supported. See "Upgrade Paths" for more information.  

    8.0.3  

    u0800030.sql  

    8.0.4  

    u0800040.sql  

    8.0.4S  

    Direct upgrade is not supported. See "Upgrade Paths" for more information.  

    8.0.5  

    u0800050.sql  

    8.1.1  

    Upgrading to the new release is not supported.  

    8.1.2  

    Upgrading to the new release is not supported.  

    8.1.3  

    u0801030.sql  

    8.1.4  

    u0801040.sql  


    Note:

    If the old release you had installed prior to upgrading is not listed in Table 7-2, see the readme files in the new installation for the correct upgrade script to run.  


    Make sure you follow these guidelines when you run the script:

    • You must use the version of the script supplied with new release 8.1 installation.

    • You must run the script in the new release 8.1 environment.

    • You only need to run ONE script, even if your upgrade spans several releases. For example, if your old release was 8.0.4, then you need to run only u0800040.sql.

    The script you run creates and alters certain dictionary tables. It also runs the catalog.sql and catproc.sql scripts that come with the release to which you are upgrading, which create the system catalog views and all the necessary packages for using PL/SQL.

    If you encounter any problems when you run the script, or any of the scripts in the remaining steps, correct the causes of the problems and rerun the script. You can rerun any of the scripts described in this chapter as many times as necessary.

    See Also:

    "Running Scripts" for information about the types of errors to look for when you run a script.  

    You may encounter a series of messages similar to the following during the upgrade:

    ORA-00604: error occurred at eecursive SQL level 1
    ORA-00001: unique constraint (SYSTEM.AQ$_QUEUES_CHECK) violated
    ORA-06512: at "SYS.DBMS_AQADM", line 2023
    ORA-06512: at line 2
    
    

    You can ignore these messages.


    Note:

    If the upgrade script runs for an inordinately long time, it may be caused by a setting for LARGE_POOL_SIZE that is too large for your installation. Use the V$PARAMETER view to check the setting for LARGE_POOL_SIZE, and if it is too large, set it to a smaller value in your initsid.ora file. See "Parallel Execution Allocated from Large Pool" for more information.  


  11. Turn off the spooling of script results to the log file:

    SVRMGR> SPOOL OFF
    
    

    Then, check the spool file and verify that the packages and procedures compiled successfully. You named the spool file in Step 9; the suggested name was catoutu.log. Correct any problems you find in this file.

    If you specified SET ECHO ON, you may want to SET ECHO OFF now:

    SVRMGR> SET ECHO OFF
    
    
  12. Run ALTER SYSTEM DISABLE RESTRICTED SESSION:

    SVRMGR> ALTER SYSTEM DISABLE RESTRICTED SESSION;
    
    
  13. Run SHUTDOWN on the Oracle8i database:

    SVRMGR> SHUTDOWN IMMEDIATE
    
    


    CAUTION:

    Use SHUTDOWN NORMAL or SHUTDOWN IMMEDIATE. Do not use SHUTDOWN ABORT.  


    Executing this clean shutdown flushes all caches, clears buffers, and performs other DBMS housekeeping activities. These measures are an important final step to ensure the integrity and consistency of the newly upgraded Oracle8i database.

    Your database is now upgraded to the new 8.1 release.


    CAUTION:

    If you retain the old Oracle software, never start the upgraded database with the old software. Only start the database with the executables in the new release 8.1 installation directory.  


Upgrading Specific Components

Some components of the Oracle database server require an upgrade operation separate from the general database upgrade operation. This section contains information about upgrading specific components. You should perform the actions described in these sections only after you have upgraded the database by following the instructions in "Upgrading the Database to the New Oracle8i Release".

Some of the upgrading procedures below involve Export/Import. See Oracle8i Utilities for Export/Import instructions.

Upgrading Advanced Replication

If the Oracle system has Advanced Replication installed, complete the following steps:

  1. Shut down the database if it is running:

    SVRMGR> SHUTDOWN IMMEDIATE
    
    


    Note:

    For Oracle Parallel Server, set the PARALLEL_SERVER initialization parameter to FALSE. You can change it back to TRUE after the upgrade operation is complete.  


  2. At a system prompt, change to the $ORACLE_HOME/rdbms/admin directory.

  3. Start Server Manager.

  4. Connect to the database instance:

    SVRMGR> CONNECT INTERNAL
    
    
  5. Run STARTUP RESTRICT:

    SVRMGR> STARTUP RESTRICT
    
    

    You may need to use the PFILE option to specify the location of your initsid.ora file.

  6. Set the system to spool results to a log file for later verification of success:

    SVRMGR> SPOOL catoutrep.log
    
    

    If you want to see the output of the script you will run on your screen, you also can issue a SET ECHO ON statement:

    SVRMGR> SET ECHO ON
    
    
  7. Run catrep.sql:

    SVRMGR> @catrep.sql
         
    
    
    
  8. Run the rold_release.sql script where old_release refers to the release you had installed prior to upgrading. See Table 7-3 to choose the correct script. Each script provides a direct upgrade for Advanced Replication from the release specified in the "Old Release" column. The "Old Release" is the release from which you are upgrading

    To run a script enter the following:

    SVRMGR> @rold_release.sql 
    
    Table 7-3 Upgrade Scripts for Advanced Replication
    Old Release  Run Script 

    8.0.1  

    Direct upgrade is not supported. See "Upgrade Paths" for more information.  

    8.0.2  

    Direct upgrade is not supported. See "Upgrade Paths" for more information.  

    8.0.3  

    r0800030.sql  

    8.0.4  

    r0800040.sql  

    8.0.4S  

    Direct upgrade is not supported. See "Upgrade Paths" for more information.  

    8.0.5  

    r0800050.sql  

    8.1.1  

    Upgrading to the new release is not supported.  

    8.1.2  

    Upgrading to the new release is not supported.  

    8.1.3  

    No upgrade script is required. Advanced Replication will work with the new release 8.1 database.  

    8.1.4  

    No upgrade script required. Advanced Replication will work with the new release 8.1 database.  


    Note:

    If the old release you had installed prior to upgrading is not listed in Table 7-3, see the readme files in the new installation for the correct upgrade script to run for Advanced Replication.  


    Make sure you follow these guidelines when you run the script:

    • You must use the version of the script supplied with new release 8.1 installation.

    • You must run the script in the new release 8.1 environment.

    • You only need to run ONE script, even if your upgrade spans several releases. For example, if your old release was 8.0.4, then you need to run only r0800040.sql.

  9. Turn off the spooling of script results to the log file:

    SVRMGR> SPOOL OFF
    
    

    Then, check the spool file and verify that the packages and procedures compiled successfully. You named the spool file in Step 6; the suggested name was catoutrep.log. Correct any problems you find in this file.

    If you specified SET ECHO ON, you may want to SET ECHO OFF now:

    SVRMGR> SET ECHO OFF
    
    
  10. Run ALTER SYSTEM DISABLE RESTRICTED SESSION:

    SVRMGR> ALTER SYSTEM DISABLE RESTRICTED SESSION
    
    

Advanced Replication is upgraded to the new release.

Upgrading Oracle Parallel Server

If the Oracle system has Oracle Parallel Server installed, complete the following steps:

  1. Shut down all instances using SHUTDOWN IMMEDIATE:

    SVRMGR> SHUTDOWN IMMEDIATE
    
    


    Note:

    For Oracle Parallel Server, set the PARALLEL_SERVER initialization parameter to FALSE. You can change it back to TRUE after the upgrade operation is complete.  


  2. At a system prompt, change to the $ORACLE_HOME/rdbms/admin directory.

  3. Start Server Manager.

  4. Connect to the database instance:

    SVRMGR> CONNECT INTERNAL;
    
    
  5. Run STARTUP RESTRICT:

    SVRMGR> STARTUP RESTRICT
    
    

    You may need to use the PFILE option to specify the location of your initsid.ora file.

  6. Set the system to spool results to a log file for later verification of success:

    SVRMGR> SPOOL catoutpar.log
    
    

    If you want to see the output of the script you will run on your screen, you also can issue a SET ECHO ON statement:

    SVRMGR> SET ECHO ON
    
    
  7. Run catparr.sql:

    SVRMGR> @catparr.sql
    
    
  8. Turn off the spooling of script results to the log file:

    SVRMGR> SPOOL OFF
    
    

    Then, check the spool file and verify that the packages and procedures compiled successfully. You named the spool file in Step 6; the suggested name was catoutpar.log. Correct any problems you find in this file.

    If you specified SET ECHO ON, you may want to SET ECHO OFF now:

    SVRMGR> SET ECHO OFF
    
    
  9. Run ALTER SYSTEM DISABLE RESTRICTED SESSION:

    SVRMGR> ALTER SYSTEM DISABLE RESTRICTED SESSION
    
    

Oracle Parallel Server is upgraded to the new release.

Upgrading Snapshots

Snapshots upgraded from release 8.0 or imported from a release 8.0 database cannot use the new summary management features available in release 8.1. If you want to use these new features, complete the following steps for each upgraded snapshot and for each snapshot imported from release 8.0:

  1. Grant query rewrite privileges to the owner of the snapshot. Only local snapshots are available for query rewrite.

  2. Issue the ALTER SNAPSHOT ... ENABLE QUERY REWRITE command on the snapshot.

    For example, on a snapshot named SSORDERS, issue the following command:

    ALTER SNAPSHOT ssorders ENABLE QUERY REWRITE;
    
    


    Note:

    The word "snapshot" is synonymous with "materialized view".  


Upgrading the Advanced Queuing Option

The following sections describe the actions required to upgrade the Advanced Queuing (AQ) option.

Use the Extended Address Field


Note:

This section only applies to systems that were upgraded from release 8.0.3 of Oracle. If you never ran release 8.0.3 of Oracle on your current system, you do not need to perform the procedure in this section, and you can move on to "Upgrade Your Queue Tables".  


Release 8.0.4 introduced an extended address field in the AQ$_AGENT datatype; the address field was extended to 1024 bytes. If you installed release 8.0.3, you must perform the procedure in this section to use the extended address field.

Also, if you installed release 8.0.3 but performed the steps described in this section to extend the address field when you upgraded to a prior release, such as release 8.0.4, you need not perform the steps below. Or, if you do not plan to use the AQ, you need not perform these steps.

However, if you installed release 8.0.3, you have not performed these steps in a prior release, and you want to use the extended address field, you should perform this procedure now. Oracle Corporation recommends using the extended address field.

To use the extended address field, complete the following steps:

  1. Shut down the database:

    SVRMGR> SHUTDOWN IMMEDIATE
    
    


    Note:

    For Oracle Parallel Server, set the PARALLEL_SERVER initialization parameter to FALSE. You can change it back to TRUE after the upgrade operation is complete.  


  2. In the initsid.ora file, comment out the JOB_QUEUE_PROCESSES and AQ_TM_PROCESSES initialization parameters. You can remove the comments on these parameters after this procedure is complete.

  3. At a system prompt, change to the $ORACLE_HOME/rdbms/admin directory.

  4. Start Server Manager.

  5. Connect to the database instance:

    SVRMGR> CONNECT INTERNAL;
    
    
  6. Run STARTUP RESTRICT:

    SVRMGR> STARTUP RESTRICT
    
    

    You may need to use the PFILE option to specify the location of your initsid.ora file.

  7. Set the system to spool results to a log file for later verification of success:

    SVRMGR> SPOOL catoutaq.log
    
    

    If you want to see the output of the script you will run on your screen, you also can issue a SET ECHO ON statement:

    SVRMGR> SET ECHO ON
    
    
  8. Export the contents of all existing queue tables using the Export utility.

    To determine the existing queue tables in the database, issue the following SQL statement:

    SELECT owner, queue_table FROM dba_queue_tables;
    
    

    You also must export the SYSTEM.DEF$_AQCALL and SYSTEM.DEF$_AQERROR queue tables and then import them in Step 12. These default queue tables are used by Advanced Replication.

    See Also:

    Oracle8i Application Developer's Guide - Advanced Queuing for more information about the required procedure for exporting queue tables.  

  9. Use the DBMS_AQADM.DROP_QUEUE_TABLE procedure to drop all of your queue tables. Make sure you drop the SYSTEM.DEF$_AQCALL and SYSTEM.DEF$_AQERROR queue tables.

    See Also:

    Oracle8i Application Developer's Guide - Advanced Queuing for information about the DBMS_AQADM.DROP_QUEUE_TABLE procedure.  

  10. Run catnoqueue.sql to drop the existing AQ dictionary tables:

    @catnoqueue.sql
    
    
  11. Run catqueue.sql to redefine the new types and dictionary tables:

    @catqueue.sql
    
    
  12. Import the queue tables you exported in Step 8 using the Import utility.

  13. Check that all queue tables exported in Step 8, including the SYSTEM.DEF$_AQCALL and SYSTEM.DEF$_AQERROR queue tables, were properly imported in Step 12 by issuing the following SQL statement:

    SELECT owner, queue_table FROM dba_queue_tables;
    
    

    The following is an example of the output you should see when you issue this SQL statement:

    OWNER                          QUEUE_TABLE
    ------------------------------ ------------------------------ 
    SYSTEM                         DEF$_AQCALL
    SYSTEM                         DEF$_AQERROR
    AQUSER1                        QUEUE_TABLE1
    AQUSER2                        QUEUE_TABLE2
    
    
  14. Turn off the spooling of script results to the log file:

    SVRMGR> SPOOL OFF
    
    

    Then, check the spool file and verify that the packages and procedures compiled successfully. You named the spool file in Step 7; the suggested name was catoutaq.log. Correct any problems you find in this file.

    If you specified SET ECHO ON, you may want to SET ECHO OFF now:

    SVRMGR> SET ECHO OFF
    
    
  15. Run ALTER SYSTEM DISABLE RESTRICTED SESSION:

    SVRMGR> ALTER SYSTEM DISABLE RESTRICTED SESSION;
    
    

You can now use the extended address field.

Upgrade Your Queue Tables

The following release 8.1 AQ enhancements are available only if you upgrade your existing queue tables:

To upgrade an existing queue table, run the DBMS_AQADM.MIGRATE_QUEUE_TABLE procedure, specifying 8.1 for the COMPATIBLE option. For example, for a queue table named TB_QUEUE owned by SCOTT user, run the following procedure:

EXECUTE dbms_aqadm.migrate_queue_table (
    queue_table => 'scott.tb_queue',       
    compatible => '8.1');

To create a new queue table that is release 8.1 compatible, connect as the owner of the queue table and run the DBMS_AQADM.CREATE_QUEUE_TABLE procedure, specifying 8.1 for the COMPATIBLE option, as in the following example:

EXECUTE dbms_aqadm.create_queue_table(
    queue_table => 'scott.tkaqqtpeqt', 
    queue_payload_type =>'message', 
    sort_list => 'priority,enq_time', 
    multiple_consumers => true, 
    comment => 'Creating queue with priority and enq_time sort order', 
    compatible => '8.1'); 


Note:

The COMPATIBLE initialization parameter must be set to 8.1.0 or higher to upgrade your queue tables and to create new release 8.1 compatible queue tables.  


Upgrading User-Defined Datatypes

When you upgrade your database from release 8.0 to release 8.1, the existing user-defined datatypes (such as object types, nested tables, and varrays) retain the release 8.0 representation format. The representation format is changed in release 8.1 to optimize disk space utilization for better performance.

You can continue to use the release 8.0 format in release 8.1, but then you will not benefit from the improved representation format. Therefore, upgrading your existing user-defined datatypes is not required, but it is recommended.

To use the new format for existing user-defined datatypes, complete the following steps:

  1. Export all of the tables (including queue tables) containing release 8.0 user-defined object types, nested tables, and varrays using the Export utility.

  2. Drop the tables you exported.

  3. Make sure the compatibility level of your database is at 8.1.0 or higher by setting the COMPATIBLE initialization parameter.

  4. Import the tables you exported in Step 1 using the Import utility.

Upgrading the Recovery Catalog

Your recovery catalog schema for the upgraded database resides in a database that is separate from the database you upgraded. If you upgraded the Recovery Manager executable to release 8.1, you must upgrade the recovery catalog to release 8.1 as well.

Also, if you have multiple databases of different releases managed by a single recovery catalog, you need to consider compatibility issues between a particular Recovery Manager release and the recovery catalog release. For example, release 8.1.3 and 8.1.4 of Recovery Manager cannot access a release 8.1.5 or higher recovery catalog. Therefore, in this case, you must upgrade all of the databases managed by the recovery catalog to release 8.1.5 or higher. For more information about recovery catalog compatibility with Recovery Manager, see "Recovery Manager".

Complete the following steps to upgrade the recovery catalog:

  1. Log in to Recovery Manager and connect to the recovery catalog.

    For example, if RCAT/RCAT is the user name and password for the recovery catalog owner, and RECDB is the network service name, enter the following:

    rman rcvcat rcat/rcat@recdb 
    
    

    The first time you connect to an older recovery catalog with the 8.1 release of Recovery Manager, you will see message RMAN-06186, indicating that the recovery catalog must be upgraded.

  2. Use the UPGRADE CATALOG command to upgrade the recovery catalog to the most current release. Recovery Manager prompts you to enter the command twice to confirm the catalog upgrade. If any errors are encountered while upgrading, they are displayed in the Recovery Manager log.

    Here is the log from a session that upgrades the recovery catalog from release 8.0.4:

    Recovery Manager: Release 8.1.5.0.0 
    
    RMAN-06008: connected to recovery catalog database 
    RMAN-06186: PL/SQL package rcat.DBMS_RCVCAT version 08.00.04 in RCVCAT 
    database is too old 
    
    RMAN> upgrade catalog 
    
    RMAN-06435: recovery catalog owner is rcat 
    RMAN-06442: enter UPGRADE CATALOG command again to confirm catalog upgrade 
    
    RMAN> upgrade catalog 
    
    RMAN-06408: recovery catalog upgraded to version 08.01.05
    

Recompiling Invalid PL/SQL Modules

The utlrp.sql script recompiles all existing PL/SQL modules that were previously in an INVALID state, such as packages, procedures, types, etc. These actions are optional; however, they ensure that the cost of recompilation is incurred during installation rather than in the future.

To run the utlrp.sql script, complete the following steps:

  1. At a system prompt, change to the $ORACLE_HOME/rdbms/admin directory.

  2. Start Server Manager.

  3. Connect to the database instance:

    SVRMGR> CONNECT INTERNAL;
    
    
  4. Run utlrp.sql:

    SVRMGR> @utlrp.sql
    
    

Oracle Corporation highly recommends running utlrp.sql.

After Upgrading to the New Release

The following sections provide information about actions you may need to perform after you upgrade to the new 8.1 release.

Using the New TO_LOB Operator

In release 8.1, a new SQL operator, TO_LOB, copies data from a LONG column in one table to a LOB in another table.

See Also:

"Copying LONGs to LOBs" for detailed instructions.  

Checking for Bad Date Constraints

A bad date constraint involves invalid date manipulation, which is a date manipulation that implicitly assumes the century in the date, causing problems at the year 2000. The utlconst.sql script runs through all of the check constraints in the database and sets constraints as bad if they include any invalid date manipulation. This script selects all the bad constraints at the end.


Note:

If you already ran utlconst.sql after you migrated or upgraded to a previous release, you need not run it again. However, running the script many times will not damage your system; therefore, if you are unsure about whether it has been run on your system, you should run it now.  


To run the utlconst.sql script, complete the following steps:

  1. At a system prompt, change to the $ORACLE_HOME/rdbms/admin directory.

  2. Start Server Manager.

  3. Connect to the database instance:

    SVRMGR> CONNECT INTERNAL;
    
    
  4. Enter the following:

    SVRMGR> SPOOL utlresult.log
    SVRMGR> @utlconst.sql
    SVRMGR> SPOOL OFF
        
    
    
    

After you run the script, the utlresult.log file includes all the constraints that have invalid date constraints. The utlconst.sql script does not correct bad constraints, but instead disables them. You should either drop the bad constraints or recreate them after you make the necessary changes.

Avoiding Problems with Parallel Execution

Beginning with release 8.1, parallel execution message buffers can be allocated from large pool. In past releases, this allocation was from shared pool. To avoid problems resulting from this change, you may need to adjust the following parameters in your initsid.ora file:

Adjusting Your INITsid.ORA File for the New Release

Each new release of Oracle introduces new initialization parameters, changes some parameters, and obsoletes some parameters. You should adjust your initsid.ora file to account for these changes and to take advantage of new initialization parameters that may be beneficial to your system.

See Also:

Appendix B, "Changes to Initialization Parameters" for lists of the new, changed, and obsoleted initialization parameters in release 8.1, and see Oracle8i Reference for detailed information about each parameter.  

The COMPATIBLE initialization parameter controls the compatibility level of your database. Set the COMPATIBLE initialization parameter in your initsid.ora file based on the compatibility level you want for your upgraded database.

See Also:

"Setting the COMPATIBLE Parameter" for information.  

Changing the Password for the OUTLN User

The OUTLN user is created automatically during installation of Oracle8i. This user has DBA privileges. Use the ALTER USER command to change the password for this user. Oracle8i adds the OUTLN user schema to support Plan Stability. The OUTLN user acts as a place to centrally manage metadata associated with stored outlines.

Modify Your listener.ora File

If you are using Oracle Enterprise Manager to manage database objects, your listener.ora file must be configured with information about the database in the following manner:

sid_list_listener_name = 
  (sid_list = 
    (sid_desc = 
      (global_dbname = global_database_name) 
      (oracle_home = oracle_home) 
      (sid_name = sid) 
    ) 
  ) 

GLOBAL_DBNAME identifies the global database name, which is a name comprised of the database name and domain name of the database. ORACLE_HOME identifies the directory where your Oracle software is installed, and SID_NAME identifies the Oracle System Identifier of the database instance.

For example, the following information is for a database with a listener name of LISTENER. The global database name of SAL.COM is referenced by an instance with a SID of SAL, using the software installed in the /oracle/product/8.1 directory:

sid_list_listener = 
  (sid_list = 
    (sid_desc = 
      (global_dbname = sal.com) 
      (oracle_home = /oracle/product/8.1) 
      (sid_name = sal) 
    ) 
  ) 

If you are not using Oracle Enterprise Manager, you do not need to configure information about the database, because an Oracle8i database instance registers itself with the listener automatically.

See Also:

Net8 Administrator's Guide for more information about configuring the listener.ora file and the SID_LIST parameter.  

Drop Java Objects

If you upgraded from release 8.1.4, and you created Java objects before upgrading, you must drop these objects. The Java format changed in release 8.1.5, causing incompatibilities between release 8.1.4 Java objects and release 8.1.5 and higher Java objects. If you upgraded from an 8.0 release, you do not need to complete this procedure.

To drop the Java objects created in release 8.1.4, complete the following steps:

  1. At a system prompt, change to the $ORACLE_HOME/rdbms/admin directory.

  2. Start SQL*Plus and connect as a user with SYS privileges.

  3. Enter the following:

    SQL> SPOOL utljavaout.log
    SQL> @utljavarm.sql
    SQL> SPOOL OFF
    
    

    Check the spool file and verify that the statements executed successfully.

  4. At a system prompt, change to the $ORACLE_HOME/javavm/install directory.

  5. Start SQL*Plus and connect as a user with SYS privileges.

  6. Enter the following:

    SQL> SPOOL initjvmout.log
    SQL> @initjvm.sql
    SQL> SPOOL OF
    
    Check the spool file and verify that the statements executed successfully. 
    
    

If you exported your Java source, class, and resource objects before you upgraded, you can import them using the Import utility after you have completed all of the steps in the above procedure.


Note:

Exporting and importing Java objects between pre-release 8.1.5 databases and the current release is not guaranteed to be successful.  


See Also:

Oracle8i Utilities for information about exporting and importing Java source, class, and resource objects.  

Changing the Word-Size of Your Current Release

The instructions in this section guide you through changing the word-size of your current release (switching from 32-bit software to 64-bit software or vice versa).

See Also:

"Changing Word-Size" for more information about changing word-size.  

Complete the following steps to change the word-size of your current release:

  1. Start Server Manager.

  2. Connect to the database instance:

    SVRMGR> CONNECT INTERNAL;
    
    
  3. Run SHUTDOWN IMMEDIATE on the database:

    SVRMGR> SHUTDOWN IMMEDIATE
    
    


    Note:

    For Oracle Parallel Server, issue this command for all instances. Also, set the PARALLEL_SERVER initialization parameter to FALSE. You can change it back to TRUE after the upgrade operation is complete.  


  4. Perform a full offline backup of the database.

    See Also:

    Oracle8i Backup and Recovery Guide for more information.  

  5. If you currently have a 32-bit installation, install the 64-bit version of the same release. Or, if you currently have a 64-bit installation, install the 32-bit version of the same release.


    Note:

    Installation is operating-system specific. For installation instructions, see your Oracle8i operating-system specific installation documentation and the Oracle8i README for your platform.  


  6. At a system prompt, change to the $ORACLE_HOME/rdbms/admin directory.

  7. Start Server Manager.

  8. Connect to the database instance:

    SVRMGR> CONNECT INTERNAL;
    
    
  9. Run STARTUP RESTRICT:

    SVRMGR> STARTUP RESTRICT
    
    

    You may need to use the PFILE option to specify the location of your initsid.ora file.

  10. Set the system to spool results to a log file for later verification of success:

    SVRMGR> SPOOL catoutw.log
    
    

    If you want to see the output of the script you will run on your screen, you also can issue a SET ECHO ON statement:

    SVRMGR> SET ECHO ON
    
    
  11. Run utlirp.sql:

    SVRMGR> @utlirp.sql
    
    

    The utlirp.sql script recompiles existing PL/SQL modules in the format required by the new database. This script first alters certain dictionary tables. Then, it reloads package STANDARD and DBMS_STANDARD, which are necessary for using PL/SQL. Finally, it triggers a recompile of all PL/SQL modules, such as packages, procedures, types, etc.

  12. Turn off the spooling of script results to the log file:

    SVRMGR> SPOOL OFF
    
    

    Then, check the spool file and verify that the packages and procedures compiled successfully. You named the spool file in Step 10; the suggested name was catoutw.log. Correct any problems you find in this file.

    If you specified SET ECHO ON, you may want to SET ECHO OFF now:

    SVRMGR> SET ECHO OFF
    
    
  13. Run ALTER SYSTEM DISABLE RESTRICTED SESSION:

    SVRMGR> ALTER SYSTEM DISABLE RESTRICTED SESSION
    
    

The word-size of your database is changed. You can open the database for normal use.




Prev

Next
Oracle
Copyright © 1999 Oracle Corporation.

All Rights Reserved.

Library

Product

Contents

Index