oracle upgrade guide.pdf

52
8/14/2019 oracle upgrade guide.pdf http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 1/52 Database Upgrade Guide Upgrade to Oracle Database 11g Release 2 (11.2): UNIX For Oracle Patch Set Release 11.2.0.2 and 11.2.0.3 Target Audience  ■ Technology Consultants  ■ System Administrators  ■ Database Administrators  ■ Developers CUSTOMER Document version: 3.02 – 2012-10-30

Transcript of oracle upgrade guide.pdf

Page 1: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 1/52

Database Upgrade GuideUpgrade to Oracle Database 11g Release 2 (11.2): UNIXFor Oracle Patch Set Release 11.2.0.2 and 11.2.0.3

Target Audience

 ■ Technology Consultants

 ■ System Administrators

 ■ Database Administrators

 ■ Developers

CUSTOMERDocument version: 3.02 – 2012-10-30

Page 2: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 2/52

Document History 

CAUTION

Before you start the implementation, make sure you have the latest version of this document.

You can find the latest version at the following location:

http://service.sap.com/instguides Database Upgrades Oracle

The following table provides an overview of the most important document changes.

 Version Date Description3.02 2012-10-30 Minor corrections in chapter Updating the Oracle Installation Scripts

3.01 2012-08-08 Various corrections

3.00 2011-12-20 Major update for Oracle Patch Set Release 11.2.0.3

2.10 2011-09-16 Various corrections

2.01 2011-05-19 Various corrections

2.00 2011-04-14 Major update for Oracle Patch Set Release 11.2.0.2

1.14 2010-09-10 Chapter Changing the Location of the JDBC Driver  added

1.13 2010-08-25 Various corrections

1.12 2010-08-03 Various corrections

1.11 2010-06-15 Change to section Updating BR*Tools

1.10 2010-06-09 Major update including upgrade from Oracle 9.2.0.8

1.01 2010-04-27 Various corrections

1.00 2010-04-01 Initial Version

 

2 /52 CUSTOMER 2012-10-30

Page 3: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 3/52

 Table of Contents

Chapter 1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5

1.1 N  ew Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

1.2 SAP Notes for the Upgrade . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

1.3 More Information on SAP Service Marketplace . . . . . . . . . . . . . . . . . . . . . . . . . 7

Chapter 2 Planning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 92.1 Checking the Original Version of Your Database . . . . . . . . . . . . . . . . . . . . . . . . 9

2.2 Checking Hardware and Software Requirements . . . . . . . . . . . . . . . . . . . . . . . 10

2.3 Reviewing the Oracle-Specified Kernel Parameters and Shell

Limits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10

2.4 Checking Additional Requirements for the Upgrade . . . . . . . . . . . . . . . . . . . . 10

2.5 Checking the SAP System Prerequisites . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12

Chapter 3 Preparation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13

3.1 Checking the Correct UNIX Users, Groups, and Authorizations . . . . . . . . . . . 13

3.2 Checking the Directory Structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13

3.3 Updating the Oracle Installation Scripts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15

3.4 Checking the Software Installation Prerequisites . . . . . . . . . . . . . . . . . . . . . . . 16

3.5 Database Software Installation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17

3.5.1 Checking and Setting the Environment Variables . . . . . . . . . . . . . . . . . . . . . . 17

3.5.2 Backing Up the Central Oracle Inventory . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19

3.5.3 Installing the Oracle Database Software . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20

3.5.4 Installing the Required SAP Bundle Patch . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213.5.5 Copying and Adapting the SQL*Net Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22

3.6 Running the Pre-Upgrade Scripts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22

3.7 Running the Pre-Upgrade Scripts (Oracle 9.2.0.8) . . . . . . . . . . . . . . . . . . . . . . 24

Chapter 4 Oracle Database Upgrade . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27

4.1 Backing Up the Oracle Database . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27

4.2 Shutting Down the SAP System and Oracle Listener Process . . . . . . . . . . . . . . 27

4.3 Database Structure Upgrade . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28

4.3.1 Starting the Database Upgrade Assistant . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28

 

2012-10-30 CUSTOMER 3 /52

Page 4: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 4/52

Page 5: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 5/52

1 Introduction

This documentation describes how to upgrade the Oracle database for the SAP system on the UNIX

operating system:

 ■ From source release Oracle 9.2.0.8, Oracle Database 10g Release 2 (10.2.0.4 or 10.2.0.5), Oracle

Database 11g Release 2 (11.2.0.1), or higher

 ■ To target release Oracle Database 11g Release 2 (11.2) (11.2.0.2 or 11.2.0.3 or higher)

This guide is suitable for both major release upgrades (for example, from Oracle 9.2.0.8 or Oracle 10.2.0.5

to Oracle 11.2.0.2 or Oracle 11.2.03) and for patch set upgrades (for example, from Oracle 11.2.0.1 to

11.2.0.2 or 11.2.0.3). In both cases, the upgrade target release is the current 11.2 patch set release.

This guide does not cover upgrades of Oracle databases with Real Application Clusters (RAC)

Automatic Storage Management (ASM), or Exadata. We plan to document these at a later date.

If your source database is Oracle 9.2.0.8, there are some differences in the procedure and these are clearly

marked in the text.

CAUTION

Oracle 11.2 is only supported for SAP systems with an EX2 kernel or higher.

Implementation Considerations

 ■ For more information about implementation considerations, including the most important SAP

Notes for the upgrade, see Planning [page 9].

 ■ Be sure to read the relevant SAP Notes before beginning the upgrade. These notes contain the most

recent information about the upgrade, as well as corrections to the documentation. You can find

the most recent version of the SAP Notes at http://service.sap.com/notes

 ■ You might find useful information for the upgrade in the following Oracle documentation:

 ● Oracle 11gR2 Upgrade Companion [ID 785351.1]

 ● Operating Systems Installation and Configuration Requirements Quick Reference (8.0.5 to 11.2) [ID 169706.1]

 ■ You use the tools Oracle Universal Installer (OUI), MOPatch (Opatch), Oracle SQL*Plus, and Oracle

Database Upgrade Assistant (DBUA) to perform the upgrade.

 ■ To make this documentation easier to read, only the location for 64-bit platforms is used. If your

database runs on a 32-bit platform (Linux 32–bit), replace as appropriate occurrences of 64 with 32.

For example, replace 112_64 with 112_32.

Naming Conventions

We use <DBSID> for the database instance identifier and <SAPSID> for the SAP system identifier. These

can be different if your SAP system uses Multiple Components in One Database (MCOD).

1 Introduction

2012-10-30 CUSTOMER 5 /52

Page 6: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 6/52

1.1 New Features

For the complete list of new features of the Oracle Database 11g Release 2 (11.2), see the New Features

documentation from Oracle.

RECOMMENDATION

Especially when you are performing a major release upgrade – that is, when when you upgrade

from 9i or 10g – we recommend that you check the most important new features in the Oracle

documentation.

You can access the complete Oracle documentation at the Oracle Technology Network (OTN) website

at www.oracle.com/technology.

More InformationConfiguring the New Features for Oracle Database 11g Release 2 (11.2) [page 47]

1.2 SAP Notes for the Upgrade

Make sure that you read the following SAP Notes:

Number Title Remarks

1431800 Oracle 11.2.0: Central Technical

Note

Provides a starting point for information about Oracle

11g with multiple links to notes on Oracle 11g.1454627 Additional Info / Corrections to

Oracle 11g Upgrade Guide

Required late-breaking information

1398634 Oracle Database 11g: Integrationinto the SAP environment

Provides information about integration of Oracle 11gproducts and options within SAP

1431798 Oracle 11.2.0: Database ParameterSettings

Provides information about Oracle initializationparameters that need to be reset to their default valuesor that need to be removed

1431796 Oracle 11.2.0: Troubleshooting the

Software Installation

Describes software installation problems and solutions or

workarounds

1431797 Oracle 11.2.0: Troubleshooting theDatabase Upgrade

Describes database upgrade problems and solutions orworkarounds

1431799 Oracle 11.2.0: Current Patch Set Describes the current Oracle patch set

1503709 Oracle 11.2.0: Patches / Patchcollections for 11.2.0.2

Lists the status of Oracle patches and bundle patches for11.2.0.2

1631931 Oracle 11.2.0: Patches / Patchcollections for 11.2.0.3

Lists the status of Oracle patches and bundle patches for11.2.0.3

1431793 Oracle 11.2.0 Upgrade Scripts Describes the shell and SQL upgrade scripts for 11.2.0

1431794 Oracle 11.2.0: Instant Client Required for upgrading Oracle client software to Oracle11g Release 2 (11.2)

819829 Oracle Instant Client Installation

and Configuration on Unix

Describes the Oracle Instant Client Installation and

Configuration

1 Introduction

1.1 New Features

6 /52 CUSTOMER 2012-10-30

Page 7: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 7/52

Number Title Remarks

850306 Oracle Critical Patch UpdateProgram

Describes the current Oracle security fixes

134592 Importing the SAPDBA role(sapdba_role.sql)

Describes how to update the SAPDBA role after theupgrade

834917 Oracle Database 10g: New databaserole SAPCONN 

Describes the new SAPCONN role, which replaces thenative CONNECT role from Oracle

839182 Using OPatch to install Oraclepatches

Describes how to use OPatch with Oracle – Windows only

1027012 MOPatch – Install Multiple Oracle

Patches in One Run

Describes how to use MOPatch with Oracle – UNIX only

1430669 BR*Tools Support for Oracle 11g Describes the support offered by BR*Tools for Oracle 11g

1519872 SAP Database User ProfileSAPUPROF

Describes the configuration of an SAP installation withthe SAP-specific database user profile SAPUPROF

1524205 Oracle 11.2.0: Software Installation Contains the newest installation scripts

1525025 Oracle Software Deinstallation Describes how to deinstall the Oracle 11g Release 2 (11.2)software

1521371 Oracle 11.2.0: Setting ofORACLE_BASE in SAP

Environments

Describes how to set ORACLE_BASE in an SAPenvironment

1.3 More Information on SA P Service Marketplace

You can find more information as following on SAP Service Marketplace:

Description Internet Address Title

SAP Notes   http://service.sap.com/notes None

Oracle DatabaseAdministration

www.sdn.sap.com/irj/sdn/

ora SAP ON ORACLE

KNOWLEDGE CENTER SAP

Documentation

SAP Database Guide: Oracle

SAP Software

Distribution Center

http://service.sap.com/swdc None

Oracle Database Upgrade

Guide – that is, the guide you arenow reading

http://service.sap.com/

instguides Database UpgradesOracle

Upgrade to Oracle Database <Version>: UNIX 

Oracle download area for

patches and software

https://service.sap.com

oracle-download 

Oracle Download Area

1 Introduction

1.3 More Information on SAP Service Marketplace

2012-10-30 CUSTOMER 7 /52

Page 8: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 8/52

 This page is left blank for documents that are printed on both sides.

Page 9: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 9/52

2 Planning

RECOMMENDATION

Before the production upgrade, make sure that you perform a test upgrade on your backup system.

1. You check the original version of your database  [page 9].

2. You check the hardware and software requirements [page 10].

3. You review the Oracle-specified kernel parameters and shell limits [page 10].

4. You check additional requirements for the upgrade [page 10].5. You check the SAP System prerequisites [page 12].

2.1 Checking the Original Version of Your Database

You need to check the original version of the database you want to upgrade and, if necessary, obtain

more information.

Prerequisites

In the following special cases you need to obtain more information: ■ If you are upgrading from Oracle 10.2 to Oracle Database 11g Release 2 (11.2) in manual mode (in

this guide we only describe the database upgrade using the DBUA)

 ■ If the source database runs Oracle 10.2.0.2, you need to first upgrade the source database to at

least patch set 10.2.0.5.

Process

1. To check the original version of your database, do one of the following from the environment of

the source database:

 ■ Enter the following command:sqlplus —version

 ■ Enter the following commands:

sqlplus / as sysdba

SQL> select version from v$instance;

2. For more information in the special cases mentioned above, see the documentation for the Oracle

Database 11g Release 2 (11.2) upgrade at the Oracle Technology Network (OTN) website.

2 Planning

2.1 Checking the Original Version of Your Database

2012-10-30 CUSTOMER 9 /52

Page 10: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 10/52

2.2 Checking Hardware and Software Requirements

Procedure

You need to check that you meet the hardware and software requirements for running the new Oracle

release. The complete list of hardware and software requirements for every platform is included in the

Oracle documentation.

You can access the complete Oracle documentation as a member of the Oracle Technology Network

(OTN).

2.3 Reviewing the Oracle-Specified Kernel Parameters andShell Limits

You need to review the Oracle-recommended kernel parameters and shell limits for your operatingsystem with Oracle Database 11g Release 2 (11.2).

These are only recommendations from Oracle for optimizing the system performance in production

environments. If the recommended settings are not suitable for your system you must tune the kernel

parameters accordingly.

Procedure

Obtain the recommended shell limits and kernel parameters from the relevant Oracle database

installation guide for your operating system, which you can find at:

www.oracle.com/technology/documentationSelect the appropriate documentation for Oracle Database 11g Release 2 (11.2).

2.4 Checking Additional Requirements for the Upgrade

You need to check the additional requirements for the Oracle database upgrade as described in this

section.

Procedure

1. Make sure you have read the SAP Notes for the upgrade [page 6], which you can find athttp://service.sap.com/notes

Download the recommended documents from My Oracle Support (formerly Oracle Metalink) at

https://support.oracle.com. For access to My Oracle Support, see SAP Note 758563.

2. Oracle 11.2 is only released and certified for SAP products running with SAP BASIS 640 and above,

and SAP kernel release 640_EX2 and above. To check for your application or product, see the

Product Availability Matrix (PAM) at http://service.sap.com/pam.

NOTE

There is no general release provided for older SAP releases 3.1I up to and including 4.6C. For

these older releases, only an upgrade certification is provided for valid upgrade paths – for

2 Planning

2.2 Checking Hardware and Software Requirements

10 /52 CUSTOMER 2012-10-30

Page 11: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 11/52

more information, see SAP Note 1398634. For upgrade certification, the SAP kernel needs to

be EXT kernel (for releases 3.1 up to and including 4.5B) or EX2 kernel (for release 4.6C).

If you have a 640_REL kernel, you need to switch to the 640_EX2 kernel immediately

after the database upgrade to Oracle 11.2. We do not support running a 640_REL kernel with

the Oracle 11.2 database.

3. To upgrade from a remote PC, you need X-Windows software on the PC, as described in SAP

Note 432861.

RECOMMENDATION

In some situations the OUI and DBUA screens are not displayed correctly when started

remotely. In such cases we recommend you to start the OUI and the DBUA directly from the

console.

4. Download the Oracle Database 11g Release 2 (11.2) installation guide for your operating systemfrom the Oracle Technology Network (OTN).

You need this document to review the hardware and software requirements and to configure the

kernel parameters and shell limits.

RECOMMENDATION

If you have access to My Oracle Support, we strongly recommend that you read document

169706.1. This document provides information on all operating system prerequisites and is

regularly updated.

5. Download the Oracle Database 11g Release 2 (11.2) software and the latest patch sets and required

patches or patch collection.

The SAP Note with the list of patches is referenced in SAP Note 1431800. You can download the

patches from:

http://service.sap.com/oracle-download

CAUTION

The patches listed in the SAP Note referenced in SAP Note 1431800 are mandatory. To avoid

severe database problems, make sure that you install all these patches.

6. Download the latest version of the Oracle 11.2 Instant Client software from:

http://service.sap.com/oracle-download

7. Download the latest version of the DBATOOLS (BR*Tools) to be used immediately after the

database upgrade from:

http://service.sap.com/swdc

BR*Tools supports the Oracle Database 11g Release 2 (11.2), as of release 7.10 (patch level 30).or

Release 7.20 (patch level 1) . For more information, see SAP Note 1430669.

8. If your source database is Oracle 9.2.0.8 and your SAP kernel is 640_REL kernel, download the

640_EX2 kernel from SAP Service Marketplace. Make sure that you download the complete

640_EX2 kernel: both SAPEXE.SAR and SAPEXEDB.SAR.

2 Planning

2.4 Checking Additional Requirements for the Upgrade

2012-10-30 CUSTOMER 11 /52

Page 12: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 12/52

2.5 Checking the SAP System Prerequisites

Procedure

1. For SAP systems 7.XX when you are performing a major release upgrade, apply SAP Notes

1416108, 1414733, and 1433301 if you are running any of the following support packages:

 ■ SAP_BASIS 7.00 SP21

 ■ SAP_BASIS 7.01 SP06

 ■ SAP_BASIS 7.02 SP02

 ■ SAP_BASIS 7.10 SP10

 ■ SAP_BASIS 7.11 SP05

 ■ SAP_BASIS 7.20 SP02

This resolves an error in an ABAP program that causes it to report problems during the consistency

checks within transaction SE14. This error is seen only after the database has been upgraded toOracle 11.2.

The error is fixed in later support packages.

2. If your SAP system is SAP BASIS 7xx, apply the advanced correction from SAP Note 1417124

This correction resolves an Oracle issue that results in an ABAP short dump during statistics

updates.

3. If your SAP system uses SAP Kernel 711, you need to use DBSL (dboraslib.so) patch level 81 or

higher.

For more information, see SAP Note 1456323.

2 Planning

2.5 Checking the SAP System Prerequisites

12 /52 CUSTOMER 2012-10-30

Page 13: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 13/52

3 Preparation

You have to complete the following preparations:

1. You check the correct UNIX users, groups, and authorizations [page 13].

2. You check the directory structure [page 13].

3. You update the Oracle installation scripts [page 15].

4. You check the software installation prerequisites [page 16].

5. You install the database software [page 17].

6. If your source database is Oracle 10.2.0.4, you run the pre-upgrade scripts [page 22].

7. If your source database is Oracle 9.2.0.8, you run the pre-upgrade scripts (Oracle 9.2.0.8) [page 24].

3.1 Checking the Correct UNIX Users, Groups, and Authorizations

You need to check that the ora<dbsid> user has write authorization for the $ORACLE_BASE directory,

since you perform the database installation as user ora<dbsid>. For information about

$ORACLE_BASE, see SAP Note 1521371.

Procedure

Enter the following commands:

echo $ORACLE_BASE

touch $ORACLE_BASE/write_test

rm $ORACLE_BASE/write_test

If the user ora<dbsid> does not have write authorization, log on to your system with the user root

and enter the command:

chgrp dba $ORACLE_BASEchmod 775 $ORACLE_BASE

Check if you are able to start an XTERM as the Oracle user since this is the user who starts the OUI.

3.2 Checking the Directory Structure

You need to verify the availability and correctness of the following Oracle directories:

 ■  stage directory

 ■ Oracle inventory directory

 ■ Home directory

3 Preparation

3.1 Checking the Correct UNIX Users, Groups, and Authorizations

2012-10-30 CUSTOMER 13 /52

Page 14: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 14/52

Procedure

1. Check the Oracle stage directory, usually called /oracle/stage.

If this directory does not exist, create it manually. If it already exists it might contain software stages

from previous installations or upgrades.1. For the upgrade to Oracle Database 11g Release 2 (11.2.0.2 or 11.2.0.3), create the staging

directory as follows:

 ■ 11.2.0.2: /oracle/stage/11202

 ■ 11.2.0.3: /oracle/stage/11203

2. Ensure that the stage directories contain enough freespace prior to extraction of the SAR files.

For the database upgrade, only the software contained within the component database is

used.

The Oracle Database DVD contains a total of six or seven SAR files (depending on the platform),

which include the various Oracle 11.2 components such as database, client, grid, gateways,

and so on.

If there is not enough space, you can delete previous stage directories.

3. When the RDBMS CDs have been mounted, use the SAP tool SAPCAR to extract all the

RDBMS CDs to /oracle/stage/11202 or /oracle/stage/11203 as user ora<sid>.

EXAMPLE

For example, the following commands extract the database software (on DVDs 1 and 2):

SAPCAR –xvf OR111264.SAR

SAPCAR –xvf OR211264.SAR

After you have finished the extraction of all the RDBMS CDs, the following subdirectories

exist under /oracle/stage/11202 or /oracle/stage/11203:

 ■   database

 ■   client

 ■   grid

 ■   examples

 ■   gateways

 ■   deinstall

NOTE

For a single-instance database upgrade, you only need to extract the database software. The

database components are packed in the files OR111264.SAR and OR211264.SAR. If you only

use a single instance database, these 2 SAR files alone are sufficient. In this case, you do not

need to extract any other SAR files.

2. Check the Oracle inventory directory.

The Oracle inventory directory maintains the inventory of all Oracle software installed on the

system. The path to the Oracle inventory directory is mentioned in the Oracle inventory pointer

3 Preparation

3.2 Checking the Directory Structure

14 /52 CUSTOMER 2012-10-30

Page 15: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 15/52

file oraInst.loc. For more information, see http://docs.oracle.com/cd/E11882_01/em.112/

e12255/oui2_manage_oracle_homes.htm.

3. Before starting the installation of the new Oracle software on the database host, make sure that

the file oraInst.loc is present in either the directory /etc or directory /var/opt/oracle and

check that it has the following entries:

 ■   inventory_loc=<location of the oracle inventory>

 ■   inst_group=dba

If the Oracle Universal Installer has already been run on this host, make sure that the variable

inventory_loc in the fileoraInst.loc points to the location where the Oracle inventory is located.

If this is the first time that the OUI has been executed on this host, enter the location where you

want the inventory log files to be written to.

By default in Oracle 11.2, the inventory is created in /oracle/oraInventory.

If this is the first installation of Oracle database software on the host and the oraInst.loc file does

not exist, you must create it at the end of the installation by running the orainstRoot.sh script

as super user from the <oraInventory> location.

3.3 Updating the Oracle Installation Scripts

If a newer version is available, we recommend that you update the Oracle Installation scripts, which

are attached to SAP Note 1524205. From there you can download the relevant package for your release.After you have extracted the Oracle software to the staging area, you need to update the installation

scripts.

Prerequisites

The SAP-specific installation scripts RUNINSTALLER, RUNINSTALLER_CHECK, and 11ginstall.sh are

located in directory SAP in the Oracle database software stage:

 ■  RUNINSTALLER

This script installs the software with the following command:

./RUNINSTALLER

For help, enter:

./RUNINSTALLER -help

 ■  RUNINSTALLER_CHECK

This script performs product-specific prerequisite checks with the following command:

./RUNINSTALLER_CHECK

 ■  11ginstall.sh

This is the main script behind RUNINSTALLER and RUNINSTALLER_CHECK. This script supports

installation in response file mode (interactive) and silent mode, generates the response file, and

starts the Oracle installer.

3 Preparation

3.3 Updating the Oracle Installation Scripts

2012-10-30 CUSTOMER 15 /52

Page 16: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 16/52

Procedure

Updating the Installation Scripts

1. Download the file 11ginstall_<release>_<patch_level>_complete.zip, which is attached to

SAP Note 1524205.The zip file contains the current version of the installation scripts.

2. Copy the file to the database directory in the Oracle software stage directory:

$ cp 11ginstall-<release>-<patch-level>-complete.zip /oracle/stage/112_64/database

3. Go to this directory:

$ cd /oracle/stage/112_64/database

4. Rename the existing SAP directory as follows so that you have a saved copy of the previous version:

mv SAP SAP.old

5. Extract the zip file:

$ unzip 11ginstall-<release>-<patch-level>-complete.zip

3.4 Checking the Software Installation Prerequisites

You must check the prerequisites for the Oracle Universal Installer (OUI).

Prerequisites

Make sure that the DISPLAY environment variable is set correctly.

Only valid for: AIX |

On AIX, call the script rootpre.sh:

End of: AIX |

Only valid for: AIX |

1. Change to the relevant directory as follows:

 ■ 11.2.0.2: cd /oracle/stage/11202/database

 ■ 11.2.0.3: cd /oracle/stage/11203/database

2. As the user root, call the script rootpre.sh:

./rootpre.sh

End of: AIX |

Procedure

1. Log on as the Oracle user ora<dbsid>.

2. Change directory:

cd /oracle/stage/11202/database

3. Execute the following commands:

1. Checking prerequisites for the OUI:

./runInstaller –executeSysPrereqs

2. Checking operating system requirements (release, patches, kernel parameters):

3 Preparation

3.4 Checking the Software Installation Prerequisites

16 /52 CUSTOMER 2012-10-30

Page 17: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 17/52

cd SAP

./RUNINSTALLER –check

4. Apply missing OS patches and set OS kernel parameters as recommended by the OUI.

3.5 Database Software Installation

As part of preparations, you install the Oracle 11.2 software.

NOTE

You can install the database software while the SAP system is still running with the existing

database (that is, Oracle 10.2). Therefore, to reduce downtime you can perform the following steps

before you stop your system.

Starting with the Oracle 11.2.0.2 patch set, Oracle Database patch sets are full installations of the Oracle

Database software. This means that you do not need to install Oracle Database 11g Release 2 (11.2.0.1)

before installing the new patch set release. You can install the new database software while the SAP

system is running with a lower patch set version.

Process Flow 

1. You check and set the environment variables [page 17].

2. You back up the central Oracle inventory [page 19].

3. You run the Oracle Universal Installer  [page 20].

4. You install the required SAP bundle patch [page 21].

5. You copy and adapt the old Oracle SQL*Net files [page 22].

3.5.1 Checking and Setting the Environment Variables

To install the database software, you need to check and set the environment variables of user

ora<dbsid> because this user installs the Oracle software.

NOTE

For more information about changes to the environment of the SAP user<sapsid>adm, seeChanging

the Environment for the <sapsid>adm User  [page 41].

Prerequisites

Make sure that you set the environment variables as described below for the duration of this

session only.

3 Preparation

3.5 Database Software Installation

2012-10-30 CUSTOMER 17 /52

Page 18: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 18/52

CAUTION

Do not make the changes to the environment permanent while the old database is still running.

You make them permanent in the database structure upgrade. We recommend you to back up

the old environment files before making the changes permanent.

Procedure

1. Make sure the following environment variables are not set:

 ■  TWO_TASK

 ■  ORA_NLS

 ■  ORA_NLS32

 ■  ORA_NLS33

 ■  ORA_NLS10

2. Make sure that the following environment variables are set as described:

Environment Variable Value

DISPLAY <hostname>:0.0

NOTE

<hostname>:0.0 is the host on which the Oracle UniversalInstaller (OUI) is to be displayed.

ORACLE_BASE /oracle or /oracle/<DBSID>For more information, see SAP Note 1521371.

ORACLE_SID <DBSID>

ORACLE_HOME Make sure that it is set to the value of the current runtime Oraclehome.

EXAMPLE

 ■ When upgrading from 10.2 (10.2.0.4 or 10.2.0.5) to11.2.0.X:

/oracle/<DBSID>/102_64

 ■ When upgrading from 11.2.0.X (where X = 1, 2, or 3) to11.2.0.Y (where Y > X):/oracle/<DBSID>/112_64

NLS_LANG One of the following values:AMERICAN_AMERICA.WE8DEC

AMERICAN_AMERICA.UTF8If your database still runs with the character set US7ASCII, we

strongly recommend moving it to WE8DEC or UTF8 before theupgrade.For more information about WE8DEC, see SAP Note 102402.

SAPDATA_HOME /oracle/<DBSID>

Only valid for: AIX |

LIBPATH

End of: AIX |

Only valid for: AIX |

$ORACLE_HOME/lib:$LIBPATH

End of: AIX |

Only valid for: HP Tru64 UNIX;Linux;Solaris |

LD_LIBRARY_PATH

End of: HP Tru64 UNIX;Linux;Solaris |

Only valid for: HP Tru64 UNIX;Linux;Solaris |

$ORACLE_HOME/lib:$LD_LIBRARY_PATH

End of: HP Tru64 UNIX;Linux;Solaris |

3 Preparation

3.5 Database Software Installation

18 /52 CUSTOMER 2012-10-30

Page 19: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 19/52

Environment Variable Value

Only valid for: HP-UX |

SHLIB_PATH

End of: HP-UX |

Only valid for: HP-UX |

$ORACLE_HOME/lib:$SHLIB_PATH

End of: HP-UX |

PATH PATH includes $ORACLE_HOME/bin of the current activeORACLE_HOME. This means that you have to adapt PATH whenORACLE_HOME is changed. PATH can only include one $ORACLE_HOME/bin.When you perform a major upgrade from 10.2 to 11.2, you need to

modify PATH after the upgrade. When you perform a patch setupgrade from 11.2 -> 11.2, the run-time Oracle home path doesnot change and therefore no change in PATH is required.

The setting of the DISPLAY environment variable is described in SAP Note 432861.

To make sure that the OUI screen can be displayed correctly on your system, you might have to

start an X terminal (xterm) session and run the command:

$ xhost +

3. Check if the temporary directory (usually /tmp) has at least 1024 MB of free space. If not, set up

the TEMP or TMPDIR environment variables to specify a temporary directory on the filesystem.

RECOMMENDATION

You can check the correctness of the new environment with the UNIX env command. Or you

can run the UNIX umask command and check that the returned value is 22.

3.5.2 Backing Up the Central Oracle Inventory 

Before you install the new Oracle database patch set software, you need to back up the central Oracle

inventory.

Procedure

1. If the Oracle inventory exists, check its location by looking at the entry in one of the following

files:

 ■ HP-UX, Solaris: /var/opt/oracle/oraInst.loc

 ■ AIX, Linux: /etc/oraInst.loc

The location is shown as follows:

inventory_loc=<path to Oracle inventory>

For more information about which platform uses which location, see http://docs.oracle.com/

cd/E11882_01/em.112/e12255/oui2_manage_oracle_homes.htm.

2. Make a backup of your existing Oracle inventory before you start the Oracle Database 11g Release

2 (11.2) software installation.

3 Preparation

3.5 Database Software Installation

2012-10-30 CUSTOMER 19 /52

Page 20: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 20/52

3.5.3 Installing the Oracle Database Software

Starting with the first patch set for Oracle Database 11g Release 2 (11.2.0.2), Oracle Database patch sets

are full installations of the Oracle database software. You only need to install the current Oracle database

patch set. For more information about the current patch set, see SAP note 1431799.

For more information about how to install Oracle database 11.2 software, see SAP note 1524205.

CAUTION

Before starting to install the Oracle software, make sure that you have updated the installation

scripts as described in Updating the Oracle Installation Scripts [page 15].

Procedure

1. Log on as user ora<dbsid> or oracle (Oracle software owner).

Since you are already logged on as user root, you can switch to user ora<dbsid> by entering the

following command:

su – ora<dbsid>.

2. Make sure that the DISPLAY environment variable is set to <host_name>:0.0, where

<host_name> is the host on which you want to display the GUI of the Oracle Universal Installer

(OUI).

Shell Used Command

Bourne shell (sh) DISPLAY=<host_name>:0.0

export DISPLAY

C shell (csh) setenv DISPLAY <host_name>:0.0

Korn shell (ksh) export DISPLAY=<host_name>:0.0

3. Start the OUI with the user ora<dbsid> as follows:

 ■ 11.2.0.2:

cd /oracle/stage/11202/database/SAP

./RUNINSTALLER

 ■ 11.2.0.3:

cd /oracle/stage/11203/database/SAP

./RUNINSTALLER

4. Respond to the OUI as follows:

Prompt or Condition Action

Configure Security Updates Do not select the checkbox.The runInstaller issues a warning.Choose OK  and then Next .

Select Installation Option Confirm the default selections by choosing Next .

Grid Installation Options Confirm the default selection Single Instance

Installation and then choose Next .

Select Product Language Confirm the default option English and then chooseNext .

3 Preparation

3.5 Database Software Installation

20 /52 CUSTOMER 2012-10-30

Page 21: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 21/52

Prompt or Condition Action

Select Database Edition Confirm the default option Enterprise Edition and thenchoose Next .

Specify Installation Location This screen displays the value for ORACLE_BASE whichis set in the environment. It also displays the valuefor ORACLE_HOME, which should be /oracle/DBSID/

<release>.See SAP Note 1521371 to set ORACLE_BASE for your

configuration.Select this option and then Next .

Privileged OS Groups This screen displays the operating system groups for

the DBA and the operator. Normally, these are dba

and oper.

Perform Prerequisite Checks This screen checks if all the required system

prerequisites for installation of the database softwarehave been met. If some of the checks are displayed as

Failed , you can fix these problems (either by installingthe missing patches or configuring the kernel

parameters) and run the check again by choosingCheck Again.

RECOMMENDATION

We strongly recommend you to make surethat there are no failed checks bef ore startingthe software installation.

Summary Review the information displayed on this screen and

choose Finish.Finish Finish the software installation by executing the

root.sh script as the root user from another session.

5. To exit the OUI, choose Exit  and confirm the dialog box that appears.

Result

The patch set software is now installed in the installation Oracle home. This is referred to – for example,

in SAP Notes – as <IHRDBMS>.

3.5.4 Installing the Required SAP Bundle Patch

After the Oracle database software installation, you need to install the required SAP bundle patch, using

the Oracle tool MOPatch.

NOTE

You must install the SAP bundle patch using the Oracle tool MOPatch, which you can find at

SAP Note 1027012.

You only need to install the latest SAP bundle patch because these patches are cumulative. After

installing the SAP bundle patch, you do not need to install any critical patch updates (CPUs).

3 Preparation

3.5 Database Software Installation

2012-10-30 CUSTOMER 21 /52

Page 22: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 22/52

The SAP bundle patch also delivers a set of upgrade scripts that automate most of the pre-upgrade and

post-upgrade tasks. For more information, see SAP Note 1431793.

PrerequisitesCheck SAP Note 1431800 to find a cross-reference to the current SAP Note with the list of required

patches to be installed.

Procedure

1. Log on at the operating system level as the ora<dbsid> user.

2. Set ORACLE_HOME to the new installation Oracle Home <IHRDBMS>.

EXAMPLE

setenv ORACLE_HOME /oracle/<DBSID>/11203

3. Install the SAP bundle patch according to the instructions in the SAP bundle patch README file.

3.5.5 Copying and Adapting the SQL*Net Files

After the database software installation, you must copy and modify the old SQL*Net files, that is,

listener.ora, sqlnet.ora, and tnsnames.ora.

NOTE

If you use the dbua.sap.sh wrapper to perform the database upgrade with DBUA, the SQL*Net

files are automatically copied from the source Oracle Home to the target Oracle Home.

Procedure

1. Log on as user ora<dbsid>.

2. Copy the SQL*Net parameter files from <old_ORACLE_HOME>/network/admin to

<new_ORACLE_HOME>/network/admin.

3. Edit the new SQL*Net files by adapting all file paths for the new directory. Be sure to adapt the

value of ORACLE_HOME in the listener.ora file.

4. If not available, add the following entry to the file listener.ora:

ADR_BASE_<listener_name> = /oracle/DBSID/saptrace

Note that this is the same value as set in the database profile parameter diagnostic_dest.

Since your database is still running in the old environment, do not start the listener with the new

listener.ora file at this point.

3.6 Running the Pre-Upgrade Scripts

You run the Oracle pre-upgrade scripts, which automatically perform various tasks and checks on

your database. See SAP Note 1431793.

3 Preparation

3.6 Running the Pre-Upgrade Scripts

22 /52 CUSTOMER 2012-10-30

Page 23: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 23/52

This section only applies if your source database is Oracle 10.2.0.4, 10.2.0.5, 11.2.0.1, or 11.2.0.2. If your

source database is Oracle 9.2.0.8, see Running the Pre-Upgrade Scripts (9.2.0.8) [page 24].

The scripts do the following on your pre-upgrade database:

 ■ Provide information on the database

 ■ Suggest any changes that you need to make to the database before you start the upgrade

 ■ Perform some of the pre-upgrade tasks on the database

NOTE

You always execute these scripts as the ora<dbsid> user connected to the database as sysdba in

the pre-upgrade environment of the database to be upgraded.

Prerequisites

You are logged on as user ora<dbsid> in the Oracle 10.2 environment with the database also startedup.

The directory where the upgrade scripts are installed is called ora_upgrade.

By default, the scripts are installed as part of the SAP bundle patch in the relevant Oracle 11.2 software

home directory:

 ■ 11.2.0.2: /oracle/<DBSID>/11202/sap/ora_upgrade

 ■ 11.2.0.3: /oracle/<DBSID>/11203/sap/ora_upgrade

Procedure

1. Change to the correct directory by entering the relevant command (since the scripts have beenextracted to the Oracle 11.2 software home):

 ■ 11.2.0.2: cd /oracle/<DBSID>/11202/sap/ora_upgrade/pre_upgrade

 ■ 11.2.0.3: cd /oracle/<DBSID>/11203/sap/ora_upgrade/pre_upgrade

2. Execute the following commands to perform pre-upgrade tasks, which can improve the

performance of the upgrade process:

sqlplus / as sysdba

SQL> spool pre_upgrade_tasks.log

SQL> @pre_upgrade_tasks.sql

SQL> spool off

3. Execute the following commands to check the pre-upgrade status of your database:

sqlplus / as sysdba

SQL> @pre_upgrade_status.sql

Result

You can check the results of the pre-upgrade scripts by looking at the following log files:

 ■  pre_upgrade_status.log

 ■  pre_upgrade_tasks.log

You can run the pre-upgrade scripts as often as necessary.

3 Preparation

3.6 Running the Pre-Upgrade Scripts

2012-10-30 CUSTOMER 23 /52

Page 24: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 24/52

CAUTION

Make the changes listed in the log file, otherwise you might have problems during the upgrade.

However, you must ignore the warning regarding the possible setting of the database parameter

remote_os_authent, which is reported as DEPRECATED.

3.7 Running the Pre-Upgrade Scripts (Oracle 9.2.0.8)

You run the Oracle pre-upgrade scripts, which automatically perform checks on your database.

This section only applies if your source database is Oracle 9.2.0.8. If your source database is Oracle 10.2.0.4

or 10.2.0.5, see Running the Pre-Upgrade Scripts [page 22].

NOTE

You always execute these scripts as the ora<dbsid> user connected to the database as sysdba inthe Oracle 9.2 environment.

Prerequisites

 ■ You are logged on as user ora<dbsid> in the Oracle 9.2 environment with the database also started

up.

 ■ The directory where the upgrade scripts are installed is called ora_upgrade. By default, the scripts

are installed as part of the SAP bundle patch in the relevant Oracle 11.2 software home directory:

/oracle/<DBSID>/112_64/sap/ora_upgrade

Procedure

1. Change to the correct directory by entering the relevant command (since the scripts have been

extracted to the Oracle 11.2 software home):

cd /oracle/<DBSID>/112_64/sap/ora_upgrade/pre_upgrade

2. Execute the following commands to check the pre-upgrade status of your database:

sqlplus / as sysdba

SQL> spool utlu112i.log

SQL> @utlu112i.sql

Result

You can check the results of the pre-upgrade script by looking at the following log file

utlu112i.log.

Make sure that you check any warnings and perform the suggested corrective actions mentioned in

the log file.

You can run the pre-upgrade script as often as you like on the pre-upgrade Oracle 9.2 database.

3 Preparation

3.7 Running the Pre-Upgrade Scripts (Oracle 9.2.0.8)

24 /52 CUSTOMER 2012-10-30

Page 25: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 25/52

CAUTION

Make the changes listed in the log file, otherwise you might have problems during the upgrade.

However, you must ignore the warning regarding the database parameter remote_os_authent,

which is reported as DEPRECATED.

3 Preparation

3.7 Running the Pre-Upgrade Scripts (Oracle 9.2.0.8)

2012-10-30 CUSTOMER 25 /52

Page 26: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 26/52

 This page is left blank for documents that are printed on both sides.

Page 27: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 27/52

4 Oracle Database Upgrade

This section describes how to upgrade the Oracle database.

1. You back up the Oracle database [page 27].

2. You shut down the SAP system and Oracle listener process [page 27].

3. You upgrade the database structure [page 28].

NOTE

If you have problems during the upgrade, see SAP Note 1431797.

4.1 Backing Up the Oracle Database

You must have a complete and usable database backup otherwise you might lose data.

Procedure

1. Create a complete database backup.

2. Check that the backup is usable. If for any reason you have problems during the upgrade you must

be able to restore the database from this backup.

4.2 Shutting Down the SAP System and Oracle ListenerProcess

You need to shut down the SAP system and the Oracle listener running process running in the old

ORACLE_HOME, for example, in /oracle/<DBSID>/102_64, /oracle/<DBSID>/112_64, or /oracle/

<DBSID>/920_64.

Procedure

1. Stop the SAP application server by entering the following command as user <sapsid>adm:

stopsap r3

2. Stop the Oracle listener by entering the following command as user ora<dbsid>:

lsnrctl stop

NOTE

Make sure that processes that log on to the database, such as CRON jobs, are not active during

the upgrade. Make sure that you reschedule these processes when the upgrade has finished.

4 Oracle Database Upgrade

4.1 Backing Up the Oracle Database

2012-10-30 CUSTOMER 27 /52

Page 28: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 28/52

4.3 Database Structure Upgrade

As part of the Oracle database upgrade [page 27], you upgrade the database structure.

Prerequisites

You have installed the database software [page 17].

Process Flow 

Perform one of the following, depending on your source database:

 ■ If your source database is not Oracle 9.2.0.8, you start the Database Upgrade Assistant to perform the

upgrade [page 28].

 ■ If your source database is Oracle 9.2.0.8, you start the Database Upgrade Assistant to perform the upgrade (Oracle

9.2.0.8) [page 30].

Result

Now continue with the Post-Upgrade Steps [page 35].

4.3.1 Starting the Database Upgrade Assistant

To upgrade the database structure, you need to start the Oracle Database Upgrade Assistant (DBUA).

The DBUA tool is a graphical tool that leads you step by step through the upgrade.

If your source database is Oracle 9.2.0.8, see Starting the Database Upgrade Assistant (Oracle 9.2.0.8) [page

30].

Prerequisi tes

 ■  dbua.sap.sh sets the environment internally.

 ■ Before you start the DBUA make sure that the DISPLAY environment variable is correctly set.

 ■ Ensure that you have write permissions on /etc/oratab.

Procedure

1. Start the DBUA.

dbua.sap.sh is a wrapper script to automate most of the post-upgrade tasks.1. Set ORACLE_HOME_SRC and ORACLE_HOME_TGT.

EXAMPLE

 ■ Enter these commands to upgrade from 10.2.0.x to 11.2.0.3:

setenv ORACLE_HOME_SRC /oracle/<DBSID>/102_64

setenv ORACLE_HOME_TGT /oracle/<DBSID>/11203

 ■ Enter these commands to upgrade from 11.2.0.1 to 11.2.0.3 or from 11.2.0.2 to 11.2.0.3:

setenv ORACLE_HOME_SRC /oracle/<DBSID>/112_64

setenv ORACLE_HOME_TGT /oracle/<DBSID>/11203

2. Change to the correct directory:

4 Oracle Database Upgrade

4.3 Database Structure Upgrade

28 /52 CUSTOMER 2012-10-30

Page 29: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 29/52

cd $ORACLE_HOME_TGT/sap/ora_upgrade/post_upgrade

3. Run this script in query mode initially to verify that the environment is correct:

./dbua.sap.sh -q

During this step, the SQL*Net profiles are copied.

4. Run DBUA as follows:

 ■ For interactive mode, enter the following command:

./dbua.sap.sh

 ■ For silent mode, enter the following command:

./dbua.sap.sh -silent

For more information on how to use dbua.sap.sh, see SAP note 1431793 or run dbua.sap.sh

-help.

2. Respond appropriately to the DBUA dialogs:

The Welcome screen provides information about the upgrade assistant

1. Choose Next  to continue.

The Databases screen lets you select the database to be upgraded.

2. Select the correct database and choose Next .

The DBUA now analyzes the database to be upgraded, performs pre-upgrade checks, and issues

warnings if necessary.

RECOMMENDATION

If the DBUA warns you of issues that need to be fixed before the upgrade, you need to

analyze and act on these warnings. The most common warning or information messages

are as follows:

Message Explanation or Solution

Information message:Database is using a timezone file older than

version 14

Explanation:

Upgrade of TSTZ data is done automatically if the DBUAwas started using dbua.sap.sh.

Warning message:Database contains schemas with stale

optimizer statistics

Solution:Run the following command:

brconnect -u / -c -f stats -t oradict_stats

Warning message:Database contains INVALID objects prior

to upgrade

Solution:

To recompile any invalid objects, use SQL*Plus to executethe script $ORACLE_HOME/rdbms/admin/utlrp.sql.Any invalid SYS/SYSTEM objects found before upgradingthe database are stored in table registry$sys_inv_objs

Any invalid non-SYS/SYSTEM objects found beforeupgrading the database are stored in table registry

$nonsys_inv_objs.After the upgrade, run ORACLE_HOME/rdbms/admin/

utluiobj.sql to identify any new invalid objects due tothe upgrade.

4 Oracle Database Upgrade

4.3 Database Structure Upgrade

2012-10-30 CUSTOMER 29 /52

Page 30: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 30/52

The screen Recompiling Invalid Objects lets you choose whether the DBUA has to automatically

recompile all PL/SQL modules after the upgrade. If the database server has multiple CPUs, the

DBUA automatically proposes the number of parallel processes to be used for the

recompilation.

Since you have already performed the database backup [page 27], you do not need to select the

Backup option on this screen.

3. Accept the default values, select Recompile invalid objects after the upgrade, and choose Next .

The screen M ove Database Files lets you move the database files during the upgrade process.

4. Select Do not move the database files as part of the upgrade  and choose Next .

5. On the screen Recovery and Diagnostic Location, select Specify Flash Recovery Area if you have set up a

restore point on the database to facilitate database recovery in the event of problems.

If you select this option, make sure that you also specify the location and the size of the flashrecovery area and its files.

The screen Management Options lets you set up the database so that it can be managed with the

Enterprise Manager.

6. Make sure that Configure the database with Enterprise Manager  is not selected and choose Next .

Before you start it, the DBUA displays a summary of the changes to be made. This includes the

warnings that you ignored or did not fix, components to be upgraded, parameters to be added,

removed, and changed after the upgrade.

3. Review the summary of changes and choose Back to make any final adjustments, if required.

NOTE

For a complete list of obsolete and deprecated parameters, see the documentation for Oracle

Database 11g Release 2 (11.2).

4. Start the database upgrade by choosing Finish.

The DBUA automatically removes the database initialization parameters that are now obsolete in

Oracle Database 11g Release 2 (11.2).

The upgrade process itself runs for some time, depending mainly on the size of the database and

the capacity of the hardware.

When the DBUA has completed successfully the results of the upgrade are displayed5. Review the changes made and exit the DBUA.

6. Make sure that the database instance has stopped after the upgrade.

7. Optionally, delete the environment variables ORACLE_HOME_SRC and ORACLE_HOME_TGT.

4.3.2 Starting the Database Upgrade Assistant (Oracle9.2.0.8)

To upgrade the database structure, you need to start the Oracle Database Upgrade Assistant (DBUA).

The DBUA tool is a graphical tool that leads you step by step through the upgrade.

4 Oracle Database Upgrade

4.3 Database Structure Upgrade

30 /52 CUSTOMER 2012-10-30

Page 31: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 31/52

This section only applies if your source database is Oracle 9.2.0.8. If your source database is Oracle

10.2.0.4, see Starting the Database Upgrade Assistant  [page 28].

Prerequisites ■ You check the oratab entry [page 33].

 ■ Before you start the DBUA make sure that the DISPLAY environment variable is correctly set.

 ■ Ensure that you have write permissions on /etc/oratab.

Procedure

1. Go to <target Oracle home>/bin.

2. Start the DBUA as follows:

./dbua -diagnosticDest /oracle/<DBSID>/saptrace -recompile_invalid_objects true -

initParam audit_file_dest=/oracle/<DBSID>/saptrace/audit -emConfiguration NONE -

upgradeTimezone -postUpgradeScripts /oracle/<DBSID>/112_64/sap/ora_upgrade/

post_upgrade/post_upgrade_tasks.sql,/oracle/<DBSID>/112_64/sap/ora_upgrade/

post_upgrade/set_remote_os_authent.sql,/oracle/<DBSID>/112_64/sap/ora_upgrade/

post_upgrade/set_compatible.sql,/oracle/<DBSID>/112_64/sap/ora_upgrade/

post_upgrade/sapuprof_profile

3. Respond appropriately to the DBUA dialogs:

The Welcome screen provides information about the upgrade assistant

1. Choose Next  to continue.

The Databases screen lets you select the database to be upgraded.

2. Select the correct database and choose Next .

The DBUA now analyzes the database to be upgraded, performs pre-upgrade checks, and issues

warnings if necessary.

RECOMMENDATION

If the DBUA warns you of issues that need to be fixed before the upgrade, you need to

analyze and act on these warnings. The most common warning or information messages

are as follows:

Message Explanation or Solution

Information message:Database is using a

timezone file older than

version 14

Explanation:Upgrade of TSTZ data is done automatically using one of the post-

upgrade custom scripts. No action is necessary.

Warning message:Database contains schemas

with stale optimizer

statistics

Solution:Run the following commands:

brconnect -u / -c -f stats -t oradict_stats

brconnect -u / -c -f stats -t system_stats

Warning message: Solution:To recompile any invalid objects, use SQL*Plus to execute the script$ORACLE_HOME/rdbms/admin/utlrp.sql.

4 Oracle Database Upgrade

4.3 Database Structure Upgrade

2012-10-30 CUSTOMER 31 /52

Page 32: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 32/52

Message Explanation or Solution

Database contains

INVALID objects prior to

upgrade

Any invalid SYS/SYSTEM objects found before upgrading the databaseare stored in table registry$sys_inv_objs

Any invalid non-SYS/SYSTEM objects found before upgrading the

database are stored in table registry$nonsys_inv_objs.After the upgrade, run ORACLE_HOME/rdbms/admin/utluiobj.sql toidentify any new invalid objects due to the upgrade.

Warning message:Deprecated CONNECT

role granted to some user/ 

roles.

Solution:

The default connect role is deprecated as of Oracle 10g. You need to runthe sapconn_role.sql script after the database upgrade as described inUpdating BR*Tools [page 37].

Information Message:Obsolete/Deprecated

Parameters:

Information Message

Tablespace Size

Explanation:The pre-upgrade check script lists the obsolete or deprecated parameters.No action is necessary as these parameters are automatically removed bythe DBUA. If the check asks for space extension in any particular

tablespace, you need to perform this.

Warning MessageParameter Update

Solution:"compatible" must be set to at least 10.1.0.For this warning, no further action is necessary as the DBUAautomatically switches this parameter after the upgrade.

You need to adapt all other parameters as suggested by the pre-upgradecheck.

Information Message:SYSAUX Tablespace

Explanation:No action is necessary as the tablespace is created automatically by theDBUA.

The screen Recompiling Invalid Objects lets you choose whether the DBUA has to automaticallyrecompile all PL/SQL modules after the upgrade. If the database server has multiple CPUs, the

DBUA automatically proposes the number of parallel processes to be used for the

recompilation.

Since you have already performed the database backup [page 27], you do not need to select the

Backup option on this screen.

3. Accept the default values, select Recompile invalid objects after the upgrade, and choose Next .

The screen Move Database Files lets you move the database files during the upgrade process.

4. Select Do not move the database files as part of the upgrade  and choose Next .

5. On the screen Recovery and Diagnostic Location, select Specify Flash Recovery Area if you have set up a

restore point on the database to facilitate database recovery in the event of problems.

If you select this option, make sure that you also specify the location and the size of the flash

recovery area and its files.

6. On the screen SYSAUX Tablespace, specify the location for the datafiles along with the size and

other attributes by entering the following:

Datafile: /oracle/<SID>/sapdata1/sysaux_1/sysaux.data1

Check Reuse Existing Filename.

Size: 2048 MB

4 Oracle Database Upgrade

4.3 Database Structure Upgrade

32 /52 CUSTOMER 2012-10-30

Page 33: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 33/52

Check AUTOEXTEND ON .

Increment Size 100 MB

Maximum Size: Unlimited

Choose Next  to continue.

7. On the screen Management Options, you can set up the database so that it can be managed with

the Enterprise Manager.

8. Make sure that Configure the database with Enterprise Manager  is not selected and choose Next .

Before you start it, the DBUA displays a summary of the changes to be made. This includes the

warnings that you ignored or did not fix, components to be upgraded, parameters to be added,

removed, and changed after the upgrade.

4. Review the summary of changes and choose Back to make any final adjustments, if required.

NOTEFor a complete list of obsolete and deprecated parameters, see the documentation for Oracle

Database 11g Release 2 (11.2).

5. Start the database upgrade by choosing Finish.

The DBUA automatically removes the database initialization parameters that are now obsolete in

Oracle Database 11g Release 2 (11.2).

The upgrade process itself runs for some time, depending mainly on the size of the database and

the capacity of the hardware.

When the DBUA has completed successfully, the results of the upgrade are displayed

6. Review the changes made and exit the DBUA.

4.3.3 Checking the oratab Entry (Oracle 9.2.0.8)

To upgrade the database structure, you need to check the entry for the oratab file.

This section only applies if your source database is Oracle 9.2.0.8.

The oratab file contains information about existing databases and the corresponding Oracle Homes

on the database server. DBUA will update the oratab with the new Oracle Home after or during the

upgrade (dbua must have write permission).

You do not always need to perform this step:

 ■ For manual upgrades, you can skip this step.

 ■ For upgrades with the dbua.sap.sh wrapper script, you can also skip this step.

 ■ You only have to perform this step if DBUA needs to find the database and Oracle Home to be

upgraded from the oratab file.

Prerequisites

You can find theoratab

 file as follows:

4 Oracle Database Upgrade

4.3 Database Structure Upgrade

2012-10-30 CUSTOMER 33 /52

Page 34: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 34/52

 ■Only valid for: AIX;HP-UX;Linux |

/etc

End of: AIX;HP-UX;Linux |

 ■Only valid for: Solaris |

/var/opt/oracle

End of: Solaris |

Procedure

1. Make sure that the oratab file contains the following entry:

<DBSID>:<old_ORACLE_HOME>:N

Where old_ORACLE_HOME stands for the path to the old oracle software installation.

EXAMPLE

The entry for a system with a <DBSID> equal to C11 is as follows:

 ■ Oracle 11.2.0.2 source database:

C11:/oracle/C11/11202:N

 ■ Oracle 11.2.0.1 source database:

C11:/oracle/C11/112_64:N

 ■ Oracle 10.2 source database

C11:/oracle/C11/102_64:N.

 ■ Oracle 9.2 source database

C11:/oracle/C11/920_64:N

2. If this entry does not exist, insert it using a text editor.

4 Oracle Database Upgrade

4.3 Database Structure Upgrade

34 /52 CUSTOMER 2012-10-30

Page 35: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 35/52

5 Post-Upgrade Steps

After the Oracle database upgrade, you need to perform the steps described here.

1. If you are doing a major release upgrade, you finalize the environment of the ora<dbsid> user  [page 35].

2. You create a symbolic link for the runtime Oracle home  [page 36].

3. You check the upgraded database [page 36].

4. You update BR*Tools [page 37].

5. You perform post-upgrade tasks [page 38].

6. You create a symbolic link for the data shared library  [page 39].

7. You back up the database [page 39].

8. You start the listener process [page 40].

9. You rename or delete the old $ORACLE_HOME/bin directory [page 40].

10. You check the read authorization of the <sapsid>adm user  [page 40].

11. You update the Oracle Instant Client  [page 41].

12. If your SAP kernel is 640_REL, you update the SAP kernel to 640_EX2 [page 41].

13. You change the environment for the <sapsid>adm user  [page 41].

14. You update the SQL*Net configuration files for the <sapsid>adm and ora<sid> users [page 42].15. You check the SAP profile parameters [page 43].

16. If your source database is Oracle 9.2, you change the location of the JDBC driver  [page 43].

17. You restart the SAP system [page 46].

18. If necessary, you change the national character set of your database to UTF8  [page 47].

19. You configure the new features for Oracle Database 11g Release 2 (11.2)  [page 47].

5.1 Finalizing the Environmen t of the ora<dbsid> UserYou need to make sure that the changes you made to the Oracle user environment are permanently

stored in the profiles (.cshrc, .dbenv_<hostname>.csh, .dbenv.sh, .dbenv.csh, and so on).

You only need to perform this procedure if you are doing a major release upgrade. It is not necessary

if you are doing a patch set upgrade. For more information about major release upgrades and patch set

upgrades, see the introduction to this guide [page 5].

Procedure

Check the values for the environment variables as described in Checking and Setting the Environment

Variables [page 17].

5 Post-Upgrade Steps

5.1 Finalizing the Environment of the ora<dbsid> User

2012-10-30 CUSTOMER 35 /52

Page 36: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 36/52

NOTE

Make sure that the environment does not contain any variables that still refer to the old database

release. In particular, make sure that ORACLE_HOME is set to the runtime Oracle home:

/oracle/<DBSID>/112_64

5.2 Creating a Symbolic Link for Runtime Oracle Home

This procedure is only necessary for the update from 11.2.0.1 or 11.2.0.2. It links the runtime Oracle

home <OHRDBMS> to the installation Oracle home <IHRDBMS>.

Procedure

Upgrading from source database 11.2.0.1

1. Change to the required directory:

cd /oracle/<DBSID>

2. If no database is still running from the old 11.2.0.1 Oracle home, detach this Oracle home from the

inventory and rename the old Oracle home:

mv 112_64 11201

For more information on this step, see SAP Note 1525025.

3. Create a symbolic link to the new Oracle home:

ln -s 11203 /oracle/<DBSID>/112_64

4. Restart the database.

Upgrading from source database 11.2.0.2

1. Change to the required directory:

cd /oracle/<DBSID>

2. Delete the old symbolic link:

rm 112_64

3. Create a symbolic link to the new Oracle home:

ln -s 11203 /oracle/<DBSID>/112_64

4. Restart the database.

5.3 Checking the Upgraded Database

You need to check the upgraded database.

Procedure

1. Check that the database is now running with Oracle Database 11g Release 2 (11.2) software in an

Oracle Database 11g Release 2 (11.2) environment by entering the following commands:

1. Log on to the database as the ora<sid> user.

5 Post-Upgrade Steps

5.2 Creating a Symbolic Link for Runtime Oracle Home

36 /52 CUSTOMER 2012-10-30

Page 37: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 37/52

2. Change to the correct directory:

cd $ORACLE_HOME/sap/ora_upgrade/post_upgrade

3. Enter the following command to start SQLPLUS:

sqlplus / as sysdba

4. Run post_upgrade_status.sql:

SQL> @post_upgrade_status.sql

Check the log POST_UPGRADE_STATUS.log.

EXAMPLE

This is an example of the output from this command:

COMP ID VERSION STATUS

CATALOG 11.2.0.3.0 VALID

CATPROC 11.2.0.3.0 VALID

Make sure that the command returns the status VALID.

2. Check that the value for the version returned from the above command is the same level as the

installed patchset.

For example, if the installed patchset is Oracle 11.2.0.2, the above command should also report the

version for the CATALOG and CATPROC components as 11.2.0.2.

RECOMMEND ATION

If the old database used an initialization file init<DBSID>.ora, the DBUA automatically creates

an spfile. We recommend that you continue to use the spfile. Do not switch back to theinitialization file after the upgrade.

5.4 Updating BR*Tools

You update BR*Tools to the latest release, with the latest patch level. If your source database was Oracle

9.2.0.8, you need to update the SAPDBA role using the scriptsapdba_role.sql and create the SAPCONN

role using sapconn_role.sql. This is essential so that the new release of BR*Tools works correctly.

The script is automatically extracted when you extract BR*Tools.

Procedure

1. Download the most current version of the BR*Tools from SAP Service Marketplace at:

http://service.sap.com/swdc

CAUTION

Perform the following steps only if your source database was Oracle 9.2.0.8.

2. Execute the following commands as theora<dbsid> user to update the SAPDBA role:

cp /usr/sap/<SAPSID>/SYS/exe/run/sapdba_role.sql $ORACLE_HOME/dbs

cd $ORACLE_HOME/dbs

5 Post-Upgrade Steps

5.4 Updating BR*Tools

2012-10-30 CUSTOMER 37 /52

Page 38: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 38/52

Only valid for: ABAP |

sqlplus /nolog @sapdba_role <SAPSCHEMA_ID>

End of: ABAP |

Only valid for: Java |

sqlplus /nolog @sapdba_role <SAPSCHEMA_ID>DB

End of: Java |

NOTE

If you have an ABAP+Java system, you have to enter both commands.

CAUTION

Make sure that you execute this command for every SAPSCHEMA_ID in your database.

3. Execute the SQL script sapconn_role.sql as follows:

cp /usr/sap/<SAPSID>/SYS/exe/run/sapconn_role.sql $ORACLE_HOME/dbs

cd $ORACLE_HOME/dbs

sqlplus /nolog @sapconn_role

4. If not executed by dbua as part of the post-upgrade scripts, execute the SQL script

sapuprof_profile.sql as follows:

cd $ORACLE_HOME/sap/ora_upgrade/post_upgrade

sqlplus / as sysdba @sapuprof_profile.sql

5.5 Performing Post-Upgrade Tasks

You need to perform certain post-upgrade tasks.

Procedure

1. Check database compatibility by executing the following command:

SQL> show parameter compatible

If not set to 11.2.0, change database compatibility by entering the following as the ora<dbsid>

user:

cd $ORACLE_HOME/sap/ora_upgrade/post_upgrade

SQL> conn / as sysdba

SQL> @set_compatible

2. If your source database is Oracle 9.2.0.8, perform the following tasks before gathering the Oracle

optimizer statistics using brconnect:

1. Apply script dbstatc11.sql from SAP note 403704.

2. Apply script dbcheckora11_olap.sql or dbcheckora11_oltp.sql from the same note

3. Implement SAP delivered statistics from SAP Note 1020260.

3. Gather Oracle optimizer statistics by executing the following commands as theora<dbsid> user:

brconnect -u / -c -f stats -t system_stats

brconnect -u / -c -f stats -t oradict_stats

5 Post-Upgrade Steps

5.5 Performing Post-Upgrade Tasks

38 /52 CUSTOMER 2012-10-30

Page 39: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 39/52

4. Check the Oracle database parameters against SAP Note 1431798 and adjust them if necessary.

You can find an automated script in SAP Note 1171650 to help you check whether your SAP system

complies with the database parameter recommendations at any given point in time.

5. Update the Oracle database statistics with BRCONNECT as follows:

brconnect -c -u / -f stats -t all –f collect -p 4

NOTE

For more information about update statistics, see the documentation SAP Database Guide:

Oracle at:

www.sdn.sap.com/irj/sdn/ora SAP ON ORACLE KNOWLEDGE CENTER SAP

Documentation

6. Run post_ugprade_status.sql.

Open a command prompt and change to the directory<new_oracle_home>/sap/ora_upgrade/

post_ugprade.

From this directory start sqlplus.exe and enter the following commands:

SQL>connect / as sysdba

SQL>@post_upgrade_status.sql

This provides an overview of the status of the upgraded database.

5.6 Creating a Symbolic Link for the Data Shared Library 

You need to create this link so that BR*Tools (which is linked to the Oracle 10.2 client) can use thenewer Oracle 11.2 clients.

NOTE

This step is included as part of the software installation as of patch set 11.2.0.3.

Procedure

1. After the software installation has finished, create a symbolic link in$ORACLE_HOME/lib as follows:

cd $ORACLE_HOME/lib

Only valid for: AIX;Linux;Solaris |

ln –s libnnz11.so libnnz10.so

End of: AIX;Linux;Solaris |

Only valid for: HP-UX |

ln –s libnnz11.sl libnnz10.sl

End of: HP-UX |

For more information, see SAP Note 1449619.

5.7 Backing Up the Database

You need to back up your upgraded Oracle Database 11g database.

5 Post-Upgrade Steps

5.6 Creating a Symbolic Link for the Data Shared Library

2012-10-30 CUSTOMER 39 /52

Page 40: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 40/52

CAUTION

You risk losing data if you do not back up your database.

Procedure

Perform a full database backup.

5.8 Starting the Listener Process

You start the listener process.

Prerequisites

Make sure that you have copied the SQL*Net configuration files from the old Oracle installation to the

location of the Oracle Database 10g or 9.2 software, as described in Copying and Adapting the SQL*Net Files

[page 22].

Procedure

1. Start the listener:

lsnrctl start

2. Check that you can remotely connect to the database through the listener:

sqlplus SAP<SAPSCHEMA_ID>/pwd@SID

5.9 Renaming or Deleting the Old $ORACLE_HOME/binDirectory 

Once the database is running correctly, you need to rename the bin directory from the old

$ORACLE_HOME (from release 10.2 or 9.2) to prevent accidental usage of the old binaries.

If you want to delete the old Oracle home, see SAP Note 1525025 (for Oracle release 11.2 and higher).

Procedure

Rename the old Oracle home directory bin with the following command:

mv <old_oracle_home>/bin <old_oracle_home>/bin-old

CAUTION

Do not rename the entire old_oracle_home in case you have SAP systems (SAP kernel release

6.40 and lower) running on the database server. This is because the SAP system running on the

database server might still use the Oracle 9i client software.

5.10 Checking the Read Authorization of the <sapsid>admUser

You check the read authorization of the <sapsid>adm user.

5 Post-Upgrade Steps

5.8 Starting the Listener Process

40 /52 CUSTOMER 2012-10-30

Page 41: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 41/52

Procedure

1. Make sure that the <sapsid>adm user has read authorization for the directory $ORACLE_HOME.

2. If this is not true, enter the following command as the ora<dbsid> user:

chmod 755 $ORACLE_HOME

5.11 Updating the Oracle Instant Client

You need to ensure that the SAP system runs with at least Instant Client release 10.2.0.4 Version 5 (V5)

or Oracle 11.2.0.2.

NOTE

This step also applies to SAP systems running the 640_REL kernel with the Oracle 9.2.0.8 database.

The Instant Client 10.2.0.4 or 11.2.0.2 is used immediately after the kernel switch to 640_EX2 orhigher (including SAP 7.XX kernels).

Procedure

Update the Oracle Database Instant Client for UNIX as described in SAP Note 1431794.

5.12 Updating the SAP Kernel from 640_REL to 640_EX2

If you are running a 640_REL kernel, you must update it to 640_EX2. We do not support running a

640_REL kernel with an Oracle 11.2 database.

Prerequisites

You have an SAP System running with 640_REL kernel and you just upgraded your Oracle 9.2.0.8

database to Oracle 11.2.

Procedure

Update your SAP kernel to 640_EX2, performing the kernel switch as described in SAP Note 1058988.

5.13 Changing the Environment for the <sapsid>adm user

You have to change the environment for the <sapsid>adm user, but only on the database server.

NOTE

You do not need to change the environment for <sapsid>adm on application servers if you are

still using the old Oracle 10g clients.

Procedure

1. On the database server, set the ORACLE_HOME environment variable to point to the location of the

Oracle Database 11g software installation, for example:

5 Post-Upgrade Steps

5.11 Updating the Oracle Instant Client

2012-10-30 CUSTOMER 41 /52

Page 42: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 42/52

/oracle/<DBSID>/112_64

2. Make sure that the change to the user environment is permanently stored in the profiles

(.cshrc, .dbenv_<hostname>.csh, and so on).

3. Log out and log on again as the <sapsid>adm user.

4. Check whether R3trans can connect to the database:

R3trans –d

5.14 Updating the SQL*Net Configuration Files for the<sapsid>adm and ora<sid> Users

You need to update the tnsnames.ora file for the <sapsid>adm and ora<sid> users after the upgrade:

 ■ For the ora<sid> user, you need to adapt the SQL*Net files are located in the directory

$ORACLE_HOME/network/admin.

 ■ For the <sapsid>adm user, you need to adapt the SQL*Net files that are located in the directory

pointed to by the environment variable TNS_ADMIN.

NOTE

DBUA modifies the SQLNET profiles in the directory <new ORACLE_HOME>/network/admin if they

already exist when the upgrade is started.

Procedure Adapting the SQL*Net Files for the ora<sid> User 

1. Add the following entry to the tnsnames.ora file that is used by the <sapsid>adm user:

LISTENER_<DBSSID>.WORLD = (ADDRESS = (COMMUNITY = SAP.WORLD)(PROTOCOL = TCP)(HOST

= <hostname>)(PORT = <listener_port>))

NOTE

Although this entry is only needed on the database server or on central systems where the

startdb or stopdb scripts are used, it is recommended to repeat the change described above

on all application servers. Without this entry, the startdb or stopdb script fails with the

following error message:

ORA-00119: invalid specification for system parameter LOCAL_LISTENER

 Adapting the SQL*Net Files for the <sapsid>adm User 

1. Determine the SQL*Net files used by <sapsid>adm as follows:

 ■ If the environment variable TNS_ADMIN is set, the SQL*Net files are used from the specified

location (even if ORACLE_HOME is set).

 ■ If the environment variable TNS_ADMIN is not set, look for a tnsnames.ora file under /etc and

use this file for the change described below in the next step.

2. Add the following entry to the tnsnames.ora file that is used by the <sapsid>adm user:

5 Post-Upgrade Steps

5.14 Updating the SQL*Net Configuration Files for the <sapsid>adm and ora<sid> Users

42 /52 CUSTOMER 2012-10-30

Page 43: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 43/52

LISTENER_<DBSSID>.WORLD = (ADDRESS = (COMMUNITY = SAP.WORLD)(PROTOCOL = TCP)(HOST

= <hostname>)(PORT = <listener_port>))

NOTE

Although this entry is only needed on the database server or on central systems where the

startdb or stopdb scripts are used, it is recommended to repeat the change described above

on all application servers. Without this entry, the startdb or stopdb script fails with the

following error message:

ORA-00119: invalid specification for system parameter LOCAL_LISTENER

5.15 Checking SAP Profile Parameters

You have to check the following SAP profile parameters:

 ■  DIR_ORAHOME

 ■  DIR_CLIENT_ORAHOME

 ■  DIR_SERVER_ORAHOME

Procedure

1. Set DIR_ORAHOME and DIR_CLIENT_ORAHOME in the instance profiles to the corresponding values of

the ORACLE_HOME environment variable of the <sapsid>adm user.

These variables point to the ORACLE_HOME used by the application server.

2. Set DIR_SERVER_ORAHOME in the default profile to the value of the ORACLE_HOME environment

variable of the ora<dbsid> user on the database server.

Only valid for: ABAP+Java;Java;Java Add-In |

5.16 Changing the Location of the JDBC Driver

If you have an SAP system with Java components, you might have to change the location of the JDBC

driver after you have upgraded the database server or client software. Otherwise the J2EE Engine cannot

start because the location of the JDBC driver might still point to the path of the old Oracle server or

client software home.

NOTE

 ■ You only need to perform this procedure if your source database was Oracle 9.2.

 ■ At the publication time of this guide, the Oracle client major version as used in the procedure

below is Oracle 10. So you need to replace occurrences of the variable

<Oracle_client_major_version> with 10.

You change the location of the JDBC driver as follows:

5 Post-Upgrade Steps

5.15 Checking SAP Profile Parameters

2012-10-30 CUSTOMER 43 /52

Page 44: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 44/52

 ■ In files that are located in the database, you use the J2EE Engine Config Tool to change the JDBC

driver location.

 ■ In files that are not located in the database, you use a text editor to change the JDBC driver location.

CAUTION

Depending on your SAP version, some of the JDBC driver references stated in this procedure

might not exist in your SAP system. Make sure that you nonetheless replace the old driver location

in all locations belonging to your SAP system.

Procedure

1. Change the file config.properties as follows:

1. Change to the correct directory containing the file config.properties:

 ■Only valid for: Java |

/usr/sap/<SAPSID>/JC<instance_number>/j2ee/configtool

End of: Java |

 ■Only valid for: ABAP+Java;Java Add-In |

/usr/sap/<SAPSID>/DVEBMGS<instance_number>/j2ee/configtool

End of: ABAP+Java;Java Add-In |

2. Open the file with your text editor and search for the property rdbms.driverLocation.

3. Replace the old driver location with the new one:

/oracle/client/<Oracle_client_major_version>x_64/instantclient/

<java_class_archive>.jar

where <Oracle_client_major_version> is the major version of the Oracle client that you

are using after this upgrade.

CAUTION

Do not change the file <java_class_archive>.jar, which is one of the following:

 ■  classes12.jar

 ■  ojdbc14.jar

 ■  ojdbc5.jar

 ■  ojdbc6.jar

2. In the same directory as in the first step, start theJ2EE Engine - ConfigTool

 by double-clickingthe configtool.sh file.

1. Change to Configuration Editor mode.

2. Use the Edit mode to replace the driver location in the following property sheets that contain

the string rdbms.driverLocation= followed by the driver location:

 ■   cluster_data/Propertysheet instance.properties.IDXXXXXXX/

IDXXXXXXX.JavaParameters

where XXXXXXX is the instance number

5 Post-Upgrade Steps

5.16 Changing the Location of the JDBC Driver

44 /52 CUSTOMER 2012-10-30

Page 45: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 45/52

NOTE

Make sure that you change all occurrences. There might be several

IDXXXXXX.JavaParameters properties in the property sheet.

 ■   cluster_data/dispatcher/IDXXXX/kernel/propertysheet ConfigurationManager

 ■   cluster_data/server/IDXXXX/kernel/propertysheet ConfigurationManager

where XXXX is the instance number

NOTE

If you have more than one server or dispatcher you must modify all relevant

property sheets.

3. Close the J2EE Engine - ConfigTool.

3. Change the driver location in the instance profile as follows:

1. Change to the correct directory containing the instance profile

<SAPSID>_JC<instance_number>_<host>:

/usr/sap/<SAPSID>/SYS/profile

2. Open the file with your text editor and search for the property j2ee/dbdriver.

3. Replace the old driver location with the new one:

/oracle/client/<Oracle_client_major_version>x_64/instantclient/

<java_class_archive>.jar

4. Change the file bootstrap.properties as follows:

1. Change to the correct directory containing the file bootstrap.properties:

 ■ Only valid for: Java |

/usr/sap/<SAPSID>/JC<instance_number>/j2ee/cluster/bootstrap

End of: Java |

 ■Only valid for: ABAP+Java;Java Add-In |

/usr/sap/<instance_ID>/DVEBMGS<instance_number>/j2ee/cluster/bootstrap

End of: ABAP+Java;Java Add-In |

2. Open the file with your text editor and search for the property rdbms.driverLocation.

3. Replace the old driver location with the new one:

/oracle/client/<Oracle_client_major_version>x_64/instantclient/

<java_class_archive>.jar

5. Change the file sdmrepository.sdc as follows:

1. Change to the correct directory containing the file sdmrepository.sdc:

 ■Only valid for: Java |

/usr/sap/<SAPSID>/JC<instance_number>/SDM/program/config

End of: Java |

 ■Only valid for: ABAP+Java;Java Add-In |

/usr/sap/<SAPSID>/DVEBMGS<instance_number>/SDM/program/config

End of: ABAP+Java;Java Add-In |

2. Search for the following text:

5 Post-Upgrade Steps

5.16 Changing the Location of the JDBC Driver

2012-10-30 CUSTOMER 45 /52

Page 46: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 46/52

<Param type="String" hide="false" name="jarPaths" encrypted="false"

displayName="Driver Paths (separated by ;)">

3. If required, replace the old driver location with the new one:

/oracle/client/<Oracle_client_major_version>x_64/instantclient/

<java_class_archive>.jar

6. Change the file rdb.properties as follows:

1. Change to the correct directory containing the file rdb.properties:

 ■Only valid for: Java |

/usr/sap/<SAPSID>/JC<instance_number>/j2ee/deploying

End of: Java |

 ■Only valid for: ABAP+Java;Java Add-In |

/usr/sap/<SAPSID>/DVEBMGS<instance_number>/j2ee/deploying

End of: ABAP+Java;Java Add-In |2. Open the file with your text editor and search for the property rdbms.driverLocation.

3. Replace the old driver location with the new one:

/oracle/client/<Oracle_client_major_version>x_64/instantclient/

<java_class_archive>.jar

7. Change the file templateconfigurator.properties as follows:

1. Change to the correct directory containing the file templateconfigurator.properties:

 ■Only valid for: Java |

/usr/sap/<SAPSID>/JC<instance_number>/j2ee

End of: Java |

 ■Only valid for: ABAP+Java;Java Add-In |

/usr/sap/<SAPSID>/DVEBMGS<instance_number>/j2ee

End of: ABAP+Java;Java Add-In |

2. Open the file with your text editor and search for the property RDBMS_DRIVER_LOCATION.

3. Replace the old driver location with the new one:

/oracle/client/<Oracle_client_major_version>x_64/instantclient/

<java_class_archive>.jar

End of: ABAP+Java;Java;Java Add-In |

5.17 Starting the SAP System

You need to restart the SAP system.

Procedure

1. If R3trans connects without problems, start the SAP system:

startsap

2. Check the new Oracle version using SAP transaction ST04.

5 Post-Upgrade Steps

5.17 Starting the SAP System

46 /52 CUSTOMER 2012-10-30

Page 47: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 47/52

5.18 Checking the National Character Set

If your database still runs with a national character set (NLS_NCHAR_CHARACTERSET) different

from UTF8, you need to change it to UTF8. You can expect to experience severe problems during SAP

upgrades if the database national character set is not set to UTF8. If you already use a Java system or

plan to use one in the future, the national character set must be UTF8.

Procedure

If necessary, follow SAP Note 669902 to change the national character set to UTF8.

5.19 Configuring the New Features for Oracle Database 11gRelease 2 (11.2)

You need to configure the new Oracle Database 11g Release 2 (11.2) features.

Procedure

For more information about new features with Oracle Database 11g Release 2 (11.2) see SAP Note

1431800. This note provides links to other SAP notes that describe how to configure or activate each

new feature.

5 Post-Upgrade Steps

5.18 Checking the National Character Set

2012-10-30 CUSTOMER 47 /52

Page 48: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 48/52

 Typographic Conventions

Example Description

<Example> Angle brackets indicate that you replace these words or characters with appropriateentries to make entries in the system, for example, “Enter your <User Name>”.

Example

Example

Arrows separating the parts of a navigation path, for example, menu options

Example Emphasized words or expressions

Example Words or characters that you enter in the system exactly as they appear in the

documentationhttp://www.sap.com Textual cross-references to an internet address

/example Quicklinks added to the internet address of a homepage to enable quick access to specific

content on the Web

123456 Hyperlink to an SAP Note, for example, SAP Note 123456

Example  ■ Words or characters quoted from the screen. These include field labels, screen titles,pushbutton labels, menu names, and menu options.

 ■ Cross-references to other documentation or published works

Example  ■ Output on the screen following a user action, for example, messages

 ■ Source code or syntax quoted directly from a program

 ■ File and directory names and their paths, names of variables and parameters, andnames of installation, upgrade, and database tools

EXAMPLE Technical names of system objects. These include report names, program names,transaction codes, database table names, and key concepts of a programming languagewhen they are surrounded by body text, for example, SELECT and INCLUDE

EXAMPLE Keys on the keyboard

 

48 /52 CUSTOMER 2012-10-30

Page 49: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 49/52

SAP AGDietmar-Hopp-Allee 16

69190 WalldorfGermany 

T +49/18 05/34 34 34

F +49/18 05/34 34 20 www.sap.com

© Copyright 2012 SAP AG. All rights reserved.

No part of this publication may be reproduced or transmitted in any form or for any purpose without the express permission

of SAP AG. The information contained herein may be changed without prior notice.

Some software products marketed by SAP AG and its distributors contain proprietary software components of other software

vendors.

Microsoft, Windows, Excel, Outlook, PowerPoint, Silverlight, and Visual Studio are registered trademarks of MicrosoftCorporation.

IBM, DB2, DB2 Universal Database, System i, System i5, System p, System p5, System x, System z, System z10, z10, z/VM, z/ 

OS, OS/390, zEnterprise, PowerVM, Power Architecture, Power Systems, POWER7, POWER6+, POWER6, POWER, PowerHA,

pureScale, PowerPC, BladeCenter, System Storage, Storwize, XIV, GPFS, HACMP, RETAIN, DB2 Connect, RACF, Redbooks,

OS/2, AIX, Intelligent Miner, WebSphere, Tivoli, Informix, and Smarter Planet are trademarks or registered trademarks of

IBM Corporation.

Linux is the registered trademark of Linus Torvalds in the United States and other countries.

Adobe, the Adobe logo, Acrobat, PostScript, and Reader are trademarks or registered trademarks of Adobe Systems

Incorporated in the United States and other countries.

Oracle and Java are registered trademarks of Oracle and its affiliates.

UNIX, X/Open, OSF/1, and Motif are registered trademarks of the Open Group.

Citrix, ICA, Program Neighborhood, MetaFrame, WinFrame, VideoFrame, and MultiWin are trademarks or registered

trademarks of Citrix Systems Inc.

HTML, XML, XHTML, and W3C are trademarks or registered trademarks of W3C®, World Wide Web Consortium,

Massachusetts Institute of Technology.

Apple, App Store, iBooks, iPad, iPhone, iPhoto, iPod, iTunes, Multi-Touch, Objective-C, Retina, Safari, Siri, and Xcode are

trademarks or registered trademarks of Apple Inc.

IOS is a registered trademark of Cisco Systems Inc.

RIM, BlackBerry, BBM, BlackBerry Curve, BlackBerry Bold, BlackBerry Pearl, BlackBerry Torch, BlackBerry Storm,

BlackBerry Storm2, BlackBerry PlayBook, and BlackBerry App World are trademarks or registered trademarks of Research

in Motion Limited.

Google App Engine, Google Apps, Google Checkout, Google Data API, Google Maps, Google Mobile Ads, Google Mobile

Updater, Google Mobile, Google Store, Google Sync, Google Updater, Google Voice, Google Mail, Gmail, YouTube, Dalvik

and Android are trademarks or registered trademarks of Google Inc.

INTERMEC is a registered trademark of Intermec Technologies Corporation.Wi-Fi is a registered trademark of Wi-Fi Alliance.

Bluetooth is a registered trademark of Bluetooth SIG Inc.

Motorola is a registered trademark of Motorola Trademark Holdings LLC.

Computop is a registered trademark of Computop Wirtschaftsinformatik GmbH.

SAP, R/3, SAP NetWeaver, Duet, PartnerEdge, ByDesign, SAP BusinessObjects Explorer, StreamWork, SAP HANA, and other

SAP products and services mentioned herein as well as their respective logos are trademarks or registered trademarks of SAP

AG in Germany and other countries.

Business Objects and the Business Objects logo, BusinessObjects, Crystal Reports, Crystal Decisions, Web Intelligence, Xcelsius,

and other Business Objects products and services mentioned herein as well as their respective logos are trademarks or registered

trademarks of Business Objects Software Ltd. Business Objects is an SAP company.

Sybase and Adaptive Server, iAnywhere, Sybase 365, SQL Anywhere, and other Sybase products and services mentioned herein

as well as their respective logos are trademarks or registered trademarks of Sybase Inc. Sybase is an SAP company.

2012-10-30 CUSTOMER 49 /52

Page 50: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 50/52

Page 51: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 51/52

Page 52: oracle upgrade guide.pdf

8/14/2019 oracle upgrade guide.pdf

http://slidepdf.com/reader/full/oracle-upgrade-guidepdf 52/52

SAP AGDietmar-Hopp-Allee 1669190 WalldorfGermany T +49/18 05/34 34 34F +49/18 05/34 34 20

 www.sap.com