52
38%/,& 8SJUDGH *XLGH 8 S J U D G H W R 2 U D F O H ' D W D E D V H J 5 H O H D V H : L Q G R Z V 7DUJHW $XGLHQFH n Technology Consultants n System Administrators Document version: 3.0 ‒ 10/10/2006

Oracle 10 2 Upgrade

Embed Size (px)

Citation preview

Page 1: Oracle 10 2 Upgrade

PUBLIC

Upgrade Guide

Upgrade to OracleDatabase 10g Release2 (10.2): WindowsTarget Audience

n Technology Consultants

n System Administrators

Document version: 3.0 ‒ 10/10/2006

Page 2: Oracle 10 2 Upgrade

SAP AGDietmar-Hopp-Allee 16

69190 WalldorfGermany

T +49/18 05/34 34 34F +49/18 05/34 34 20

www.sap.com

© Copyright 2006 SAP AG. All rights reserved.

No part of this publication may be reproduced or transmittedin any form or for any purpose without the express permissionof SAP AG. The information contained herein may be changedwithout prior notice.

Some software products marketed by SAP AG and itsdistributors contain proprietary software components of othersoftware vendors.

Microsoft, Windows, Outlook, and PowerPoint are registeredtrademarks of Microsoft Corporation.

IBM, DB2, DB2 Universal Database, OS/2, Parallel Sysplex,MVS/ESA, AIX, S/390, AS/400, OS/390, OS/400, iSeries, pSeries,xSeries, zSeries, z/OS, AFP, Intelligent Miner, WebSphere,Netfinity, Tivoli, Informix, i5/OS, POWER, POWER5, OpenPowerand PowerPC are trademarks or registered trademarks of IBMCorporation.

Oracle is a registered trademark of Oracle Corporation.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 registeredtrademarks of Citrix Systems, Inc.

HTML, XML, XHTML and W3C are trademarks orregistered trademarks of W3C®, World Wide Web Consortium,Massachusetts Institute of Technology.

Java is a registered trademark of Sun Microsystems, Inc.JavaScript is a registered trademark of SunMicrosystems, Inc.,

used under license for technology invented and implemented byNetscape.

MaxDB is a trademark of MySQL AB, Sweden.SAP, R/3, mySAP, mySAP.com, xApps, xApp, SAP NetWeaver,

and other SAP products and services mentioned herein as well as

their respective logos are trademarks or registered trademarks ofSAP AG in Germany and in several other countries all over theworld. All other product and service names mentioned are thetrademarks of their respective companies. Data contained in thisdocument serves informational purposes only. National productspecifications may vary.

These materials are subject to change without notice. Thesematerials are provided by SAP AG and its affiliated companies(“SAP Group”) for informational purposes only, withoutrepresentation or warranty of any kind, and SAP Group shall notbe liable for errors or omissions with respect to the materials.The only warranties for SAP Group products and services arethose that are set forth in the express warranty statementsaccompanying such products and services, if any. Nothing hereinshould be construed as constituting an additional warranty.

This document was created using stylesheet 2005-12-31(V3.2) and XSLT processor SAXON 6.5.2 from Michael Kay(http://saxon.sf.net/), XSLT version 1.

DisclaimerSome components of this product are based on Java™. Any codechange in these components may cause unpredictable and severemalfunctions and is therefore expressively prohibited, as is anydecompilation of these components.

Any Java™ Source Code delivered with this product is onlyto be used by SAP’s Support Services and may not be modified oraltered in any way.

Documentation in the SAP Service MarketplaceYou can find this document at the following address:service.sap.com/instguides

ii PUBLIC 10/10/2006

Page 3: Oracle 10 2 Upgrade

Typographic Conventions

Example Description

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

® 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 documentation

Example Textual cross-references to a URL, for example, www.sap.com

/example Shortcuts added to the URL of a homepage to enable quick access to specific content on theWeb

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

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

n Cross-references to other documentation or published works

Example n Output on the screen following a user action, for example, messagesn Source code or syntax quoted directly from a programn File and directory names and their paths, names of variables and parameters, and names of

installation, upgrade, and database tools

EXAMPLE Technical names of system objects. These include report names, program names, transactioncodes, database table names, and key concepts of a programming language when they aresurrounded by body text, for example, SELECT and INCLUDE

EXAMPLE Keys on the keyboard

10/10/2006 PUBLIC iii

Page 4: Oracle 10 2 Upgrade

Document History

.Caution

Before you start the implementation, make sure you have the latest version of this document.You can find the latest version in SAP Service Marketplace at the following internet address:service.sap.com/instguides.

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

Version Date Description

3.0 10/10/2006 Initial Version

iv PUBLIC 10/10/2006

Page 5: Oracle 10 2 Upgrade

Table of Contents

Chapter 1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . 11.1 New Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21.2 SAP Notes for the Upgrade . . . . . . . . . . . . . . . . . . . . . . . 21.3 More Information on SAP Service Marketplace . . . . . . . . . . . . . . . . 3

Chapter 2 Planning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52.1 Checking the Original Version of Your Database . . . . . . . . . . . . . . . 52.2 Checking Hardware and Software Requirements . . . . . . . . . . . . . . . 52.3 Checking Additional Requirements for the Upgrade . . . . . . . . . . . . . . 62.4 Using Multiple Oracle Homes . . . . . . . . . . . . . . . . . . . . . . 7

Chapter 3 Preparation . . . . . . . . . . . . . . . . . . . . . . . . . . . . 93.1 Checking the SAP System Prerequisites . . . . . . . . . . . . . . . . . . 93.2 Migrating to Automatic Undo Management . . . . . . . . . . . . . . . . . 103.3 Stopping Statspack Reports . . . . . . . . . . . . . . . . . . . . . . . 103.4 Checking the SYSTEM and SYSAUX Tablespace for Freespace . . . . . . . . . . 113.5 Checking for Invalid Database Objects . . . . . . . . . . . . . . . . . . . 113.6 MSCS Only: Removing the Database from the Fail Safe Group . . . . . . . . . . 123.7 MSCS Only: Upgrading to OFS 3.3.4 . . . . . . . . . . . . . . . . . . . . 12

Chapter 4 Oracle Database Upgrade . . . . . . . . . . . . . . . . . . . . . . . 174.1 Installing the Oracle Database Software . . . . . . . . . . . . . . . . . . 174.1.1 Installing the Oracle 10g Server Software . . . . . . . . . . . . . . . . . . 174.1.2 Installing the Oracle 10g Client Software . . . . . . . . . . . . . . . . . . 194.2 Copying and Adapting the SQL*Net Files . . . . . . . . . . . . . . . . . . 204.3 Saving Archive Log Files . . . . . . . . . . . . . . . . . . . . . . . . 204.4 Changing the Environment for User <dbsid>adm . . . . . . . . . . . . . . 214.5 Performing the Database Upgrade . . . . . . . . . . . . . . . . . . . . 21

Chapter 5 Post-Upgrade Steps . . . . . . . . . . . . . . . . . . . . . . . . . 255.1 Creating the Oracle TNSListener Service . . . . . . . . . . . . . . . . . . 255.2 Changing Environment Variables . . . . . . . . . . . . . . . . . . . . 255.3 MSCS Only: Setting Up a Shared Database-Directory in Oracle Home . . . . . . . 265.4 Changing the Registry Value of Oracle Autostart . . . . . . . . . . . . . . . 275.5 Starting the Oracle Services . . . . . . . . . . . . . . . . . . . . . . . 285.6 Updating BR*Tools . . . . . . . . . . . . . . . . . . . . . . . . . . 285.7 Deleting the Old Oracle Software . . . . . . . . . . . . . . . . . . . . . 295.8 Backing Up the Database . . . . . . . . . . . . . . . . . . . . . . . . 315.9 Performing Post-Upgrade Tasks . . . . . . . . . . . . . . . . . . . . . 31

10/10/2006 PUBLIC v

Page 6: Oracle 10 2 Upgrade

5.10 Creating the orapwd File . . . . . . . . . . . . . . . . . . . . . . . . 335.11 MSCS Only: Adding the Database to the Fail Safe Group . . . . . . . . . . . . 335.12 Changing the Location of the JDBC Driver . . . . . . . . . . . . . . . . . 345.13 Upgrading the SAP Executables to the Latest Version . . . . . . . . . . . . . 375.14 Disabling Database User Locking Mechanism For Failed Logins . . . . . . . . . . 375.15 Configuring the New Features for Oracle Database 10g Release 2 (10.2) . . . . . . . 37

Chapter 6 Common Administration Tasks . . . . . . . . . . . . . . . . . . . . 396.1 Starting and Stopping the Database . . . . . . . . . . . . . . . . . . . . 396.1.1 Starting and Stopping the Database in a Standard Configuration . . . . . . . . . 396.1.2 Starting and Stopping the Database in an MSCS Configuration . . . . . . . . . . 406.2 Checking Oracle Services . . . . . . . . . . . . . . . . . . . . . . . 416.3 Starting and Stopping Services . . . . . . . . . . . . . . . . . . . . . . 416.4 Changing or Deleting Oracle Database Parameters . . . . . . . . . . . . . . 426.5 Determining the Value of SAP System Profile Parameters . . . . . . . . . . . . 436.6 Moving Groups for MSCS . . . . . . . . . . . . . . . . . . . . . . . 446.7 Starting and Stopping the SAP System . . . . . . . . . . . . . . . . . . . 44

vi PUBLIC 10/10/2006

Page 7: Oracle 10 2 Upgrade

1 Introduction

1 Introduction

This documentation explains how to upgrade the Oracle database for the SAP system on theWindowsoperating system:

n From Oracle version 9.2.0.6 or Oracle Database 10g Release 1 (10.1.0.4)n To Oracle Database 10g Release 2 (10.2)

.Caution

SAP certifies Oracle 10.2 only from release 10.2.0.2. SAP does not certify nor support Oracle 10.2.0.1.Make sure that your target release is Oracle 10.2.0.2 or later.

.Note

Oracle offers and supports direct database upgrades from Oracle 8.1.7 to Oracle 10.2, but SAP does notrecommend this.We do not describe direct upgrades in this documentation. SAP has not tested and validated the direct

upgrade path from Oracle 8.1.7 to Oracle 10.2. If you intend to perform a direct upgrade from Oracle 8.1.7to Oracle 10.2, see the Oracle Database 10g Release 2 (10.2) upgrade documentation.

You can obtain the Oracle documentation after registering at the Oracle Technology Network (OTN) website,www.oracle.com/technology.You use the tools Oracle Universal Installer (OUI), Oracle SQL*Plus, and Oracle Database Upgrade Assistant

(DBUA) to perform the upgrade.

.Caution

Make sure you have the latest version of this document. You can always find this as follows:service.sap.com/instguides ® Other Documentation ® Database Upgrades ® Oracle.

.Note

n In this document we use <DBSID> for the database instance identifier and <SAPSID> for the SAP systemidentifier. These can be different if your:l Database system uses Oracle Real Application Cluster (RAC)

l SAP system uses Multiple Components in One Database (MCOD) Implementation Considerations

n To have a common documentation layout for UNIX and Windows in this documentation, we use /(slash) in SQL commands. Do not use / (slash) in command prompts.

Implementation Considerations

n For more information on implementation considerations, including the most important SAP Notes for theupgrade, see Planning [page 5].

10/10/2006 PUBLIC 1

Page 8: Oracle 10 2 Upgrade

1 Introduction

1.1 New Features

n Be sure to read the relevant SAP Notes before beginning the upgrade. These notes contain the most recentinformation about the upgrade, as well as corrections to the documentation. You can find the mostrecent version of the SAP Notes:service.sap.com/notes

n Make sure you are using the Oracle Universal Installer (OUI) shipped with the installation CDs for OracleDatabase 10g Release 2 (10.2).

n MSCS Only: If your system is configured to run with Microsoft Cluster Service (MSCS) you have toperform additional steps. These are necessary to include the additional MSCS node(s) of the system in theupgrade procedure and to deal with cluster-specific features. Steps that must be performed for an MSCSconfiguration are marked withMSCS Only in this documentation.The cluster node(s) that a particular step has to be executed on can be:l First node which is the primary node where the database server is locatedl Additional node for any secondary MSCS node.

n The database server and database client must be in the sameWindows domain. For information onpermitted domain names see SAP Note 314671.

1.1 New Features

For the complete list of new features of the Oracle Database 10g Release 2 (10.2), see the New Featuresdocumentation from Oracle.You can access the complete Oracle documentation as a member of the Oracle Technology Network

(OTN) at:www.oracle.com/documentation

For more information on joining OTN, see:www.oracle.com/technology

.Recommendation

We recommend that you check themost important new features in the Oracle documentation since somenew features might affect the operation of your production system.

1.2 SAP Notes for the Upgrade

Make sure that you read the following SAP Notes, which you can find at service.sap.com/notes:

Number Title Remarks

948305 Oracle Upgrade to 10g Release 2 (10.2)on Windows

Information about the upgrade andcorrections to this guide.

720886 Oracle Database 10g: Integration intothe SAP environment

Provides information aboutintegration of Oracle Database10g products / options within SAP

2 PUBLIC 10/10/2006

Page 9: Oracle 10 2 Upgrade

1 Introduction

1.3 More Information on SAP Service Marketplace

Number Title Remarks

828268 Oracle Database 10g: New Functions Provides information about the OracleDatabase 10g features which can beused within an SAP environment.Also contains links to notes describingthe procedure to activate some of thenew Oracle Database 10g features.

871735 Oracle Database 10g: Current PatchSet

Describes the current Oracle patch set

839182 Oracle Database 10g: OPatch Describes how to use OPatch withOracle Database 10g Release 2 (10.2)

1.3 More Information on SAP Service Marketplace

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

Description Internet Address Title

SAP Notes service.sap.com/notes None

Oracle Database Administration service.sap.com/dbaora ® MediaLibrary ® General

SAP Database Guide: Oracle

SAP Software Distribution Center service.sap.com/swdc None

10/10/2006 PUBLIC 3

Page 10: Oracle 10 2 Upgrade

This page is intentionally left blank.

Page 11: Oracle 10 2 Upgrade

2 Planning

2 Planning

1. You check the original version of your database [page 5].2. You check the hardware and software requirements [page 5].3. You check additional requirements for the upgrade [page 6].4. You decide whether you want to use multiple Oracle homes [page 7].

2.1 Checking the Original Version of Your Database

You need to check the original version of the database you want to upgrade.

.Caution

This SAP upgrade documentation only covers the standard upgrade from Oracle 9.2.0.6 or later to OracleDatabase 10g Release 2 (10.2) using the Oracle Database Upgrade Assistant (DBUA).

ProcessIn the following special cases you need to get more information:

n If you are upgrading from Oracle 8.1.7 or an earlier release, read the Oracle Database 10g Release 2 (10.2)upgrade documentation for information on the special steps required. Although Oracle supports directupgrades from Oracle 8.1.7 to Oracle 10.2.0, SAP recommends customers running Oracle 8.1.7 to firstupgrade to Oracle 9.2.0 and then to Oracle 10.2.0.

n If you are upgrading from Oracle 9.2.0 to Oracle Database 10g Release 2 (10.2) in manual mode.n If the source database runs Oracle 9.2.0.4, 9.2.0.3, 9.2.0.2, or 9.2.0.1, you need to update the source database to

patchset 9.2.0.6 or later.

For more information in these special cases, see the Oracle Database 10g Release 2 (10.2) upgradedocumentation at:

www.oracle.com/technology/documentation

Select the appropriate documentation for Oracle Database 10g Release 2 (10.2).

.Recommendation

If the source database is Oracle 10.1 we strongly recommend that it is at least version Oracle 10.1.0.4.

2.2 Checking Hardware and Software Requirements

You need to check that you meet the hardware and software requirements for running the new Oraclerelease. The complete list of hardware and software requirements for every platform is included in the Oracledocumentation.

10/10/2006 PUBLIC 5

Page 12: Oracle 10 2 Upgrade

2 Planning

2.3 Checking Additional Requirements for the Upgrade

PrerequisitesYou can access the complete Oracle documentation referred to below as a member of the Oracle TechnologyNetwork (OTN) at:

www.oracle.com/documentation

For more information on joining OTN, see:www.oracle.com/technology

Procedure

1. Note the following general hardware requirements:n At least 1024 MB of physical RAMn About 500 MB free space in the %TEMP% directoryn Between 2 GB and 3.5 GB of disk space for the Oracle software

2. Check that your operating system meets the software requirements for running the new Oracle release,including all required patches. You might need to upgrade your operating system before you start. Thecomplete list of software requirements for every operating system is included in the Oracle documentation.

.Recommendation

If you have access to Oracle Metalink we strongly recommend that you read document 169706.1. Thisdocument provides information on all operating system prerequisites and is regularly updated.

3. Get the full and updated list of hardware and software requirements from the relevant Oracle databaseinstallation guide for your operating system, which you can find at one of the following:www.oracle.com/technology/documentation

Select the appropriate documentation for Oracle Database 10g Release 2 (10.2).

2.3 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 2], which you can find at service.sap.com/notes:2. Make sure your operating system and initial database version meets SAP requirements. We approve specific

combinations of operating system version, database version, SAP Release, and SAP kernel release:n SAP Release 4.6x, see SAP Note 156548n SAP Release 6.x, see SAP Note 407314

3. Get the Oracle Database 10g Release 2 (10.2) installation guide for your operating system from the OracleTechnology Network at:www.oracle.com/technology

You need this document to review the hardware and software requirements and to configure the kernelparameters and shell limits.

6 PUBLIC 10/10/2006

Page 13: Oracle 10 2 Upgrade

2 Planning

2.4 Using Multiple Oracle Homes

.Recommendation

If you have access to Oracle Metalink we strongly recommend that you read document 169706.1. Thisdocument provides information on all operating system prerequisites and is regularly updated.

4. Get the Oracle Database 10g Release 2 (10.2) software and the latest patch sets and required patches.The list of one-off patches is described in SAP Note 871096. You can download the patches from SAPService Marketplace at:service.sap.com/swcenter-3pmain

.Caution

n The one-off patches listed in SAP Note 871096 are mandatory. To avoid severe database problems,make sure that you install all these one-off patches.

n SAP certifies Oracle 10.2 only from release 10.2.0.2. SAP does not certify nor support Oracle10.2.0.1.Make sure that your target release is Oracle 10.2.0.2 or later.

5. Get the latest version of the Oracle 10.2 Instant Client software from SAP Service Marketplace at:service.sap.com/swcenter-3pmain

6. Get the latest version of the DBATOOLS (BR*Tools) Release 7.00 to be used immediately after the databaseupgrade from SAP Service Marketplace at:service.sap.com/swdc

2.4 Using Multiple Oracle Homes

Before the upgrade or migration, you need to decide whether you want to set up multiple Oracle Homes asthis influences the procedure.Oracle allows multiple Oracle Homes for specific database versions. This means that more than one version

of the database software can exist in different Oracle Home directories on the same host.

.Note

MSCS Only:Multiple Oracle Homes for different database instances are not supported in a MSCS configuration.

During the upgrade or migration there are temporarily two Oracle Homes. However, the old OracleHome is deleted at the end of the migration or upgrade procedure. Note however that the Oracle FailSafe software is installed in its own Oracle Home.

Multiple Oracle Homes are necessary, if:

n Two different databases are installed on the same computer and use different Oracle releases that cannot beinstalled in a single Oracle Home directory.

n Amigration or an upgrade to Oracle 10g is being performed. The new Oracle software must be installed in anew Oracle Home directory.

10/10/2006 PUBLIC 7

Page 14: Oracle 10 2 Upgrade

This page is intentionally left blank.

Page 15: Oracle 10 2 Upgrade

3 Preparation

3 Preparation

.Note

You have already planned the database upgrade [page 5].

You have to complete the following preparations:

1. You check the SAP System prerequisites [page 9].2. If required, you migrate to automatic undo management [page 10].3. If required, you stop Statspack reports [page 10].4. You check the SYSTEM and SYSAUX tablespace for freespace [page 11].5. If required, you check for invalid database objects [page 11].6. MSCS Only: You remove the database from the Fail Safe group [page 12].7. MSCS Only: You upgrade to OFS 3.3.4 [page 12].

3.1 Checking the SAP System Prerequisites

You must check the prerequisites for the SAP system (ABAP) release 6.40 and lower. You need to:

1. Check that the Microsoft C Runtime libraries of version 71 are installed.2. Update the database library (lib_dbsl<xxx>.sar) to the latest patch level3. Apply a correction to the ABAP system

This is necessary to make the SAP system compatible for the Oracle Database 10g release checks.4. You need to execute an SQL script that creates a new role on the database. This is necessary due to changes

to the Oracle CONNECT role in Oracle 10.2.5. You must upgrade Java systems to at least Service Pack 13 before you can upgrade to Oracle Database 10g.

Procedure

1. Make sure that you have installed the latest Microsoft C Runtime dlls of version 71 with R3DLLINS.EXE.The DLLs and the executable are attached to SAP Note 684106.

2. Download the latest version of dboraslib.dll for your release from the SAP Service Marketplace at:service.sap.com/swdc

3. Check the level of your Basis support package using this table:

SAP Release (SAP_BASIS) Basis Support Package Level

46B SAPKB46B57

46C SAPKB46C48

46D SAPKB46D38

10/10/2006 PUBLIC 9

Page 16: Oracle 10 2 Upgrade

3 Preparation

3.2 Migrating to Automatic Undo Management

SAP Release (SAP_BASIS) Basis Support Package Level

6.10 SAPKB61041

6.20 SAPKB62044

6.40 SAPKB64009

n If the level of your Basis support package is higher than or equal to that shown above, no additionalcorrections are necessary.

n If the level of your Basis support Package is lower than the one shown in the table above, you need toapply an additional transport correction to your system as described in SAP Note 868681.

4. Execute the SQL script sapconn_role.sql as follows:cd %ORACLE_HOME%\database

copy <ORACLE_DVD>:\NT\<platform>\SAP\sapconn_role.sql

sqlplus /nolog @sapconn_role

3.2 Migrating to Automatic Undo Management

This step is only relevant if your database still uses manual undo management (rollback tablespace androllback segments).If your database still uses rollback segments for undo management we strongly recommend you to migrate

to automatic undo management before starting the database update to Oracle database 10g. Otherwise youmight run into errors.

Procedure

1. Read SAP Note 600141, which is the central note describing automatic undo management. This note alsogives you an overview of the concepts involved.

2. Follow the step-by-step instructions in the note to migrate to automatic undo management.

3.3 Stopping Statspack Reports

This step deletes the Statspack jobs with DBMS_JOB.REMOVE.

PrerequisitesThis step is only relevant if the Statspack package has been activated on the database for monitoring purposes.For more information on Statspack, see SAP Note 717484.

Procedure

1. Log on as the user under which the statspack jobs run (usually PERFSTAT):SQL> connect PERFSTAT/<pwd>

SQL> select job, what from user_jobs;

This displays a list of the jobs that are currently entered under the user PERFSTAT.

10 PUBLIC 10/10/2006

Page 17: Oracle 10 2 Upgrade

3 Preparation

3.4 Checking the SYSTEM and SYSAUX Tablespace for Freespace

2. Delete all jobs with the print job number <jobnr>:SQL> connect PERFSTAT/<pwd>

SQL> execute dbms_job.remove( <jobnr> );

3.4 Checking the SYSTEM and SYSAUX Tablespace for Freespace

You need to make sure that the SYSTEM and SYSAUX tablespaces have at least 750 MB freespace. This isnecessary due to a bug in the Oracle database that can cause the Oracle Database Upgrade Assistant (DBUA) tounderestimate the required freespace.

.Note

The SYSAUX tablespace is available only if the source database is already Oracle 10.1.If your source database is Oracle 9.2, there is no SYSAUX tablespace. In this case you can ignore references

to the SYSAUX tablespace in this section.

ProcedureCheck if the SYSTEM or SYSAUX tablespace have enough freespace.You can check this by executing one of the following commands as the <dbsid>adm user:

n brspace –f dbshow –c tsinfo –s SYSTEM

n brspace –f dbshow –c tsinfo –s SYSAUX

If the free space is less than 750 MB, use your preferred database administration tool to increase the size by usingone of the following options:

n Setting the AUTOEXTEND option for the existing datafile to ON.n Adding an additional datafile.n Resizing the existing datafile.

3.5 Checking for Invalid Database Objects

This optional step lets you check if there are any invalid database objects before the database upgrade to Oracledatabase 10g starts. After the upgrade it helps you distinguish database objects that have become invalid due tothe upgrade process from those that were already invalid to start with.

Procedure

1. Execute the following commands:SQL> spool invalid_objects

SQL> select unique object_name, object_type, owner from dba_objects where status =

'INVALID';

SQL> @?/rdbms/admin/utlrp.sql

SQL> select unique object_name, object_type, owner from dba_objects where status =

'INVALID';

SQL> spool off

10/10/2006 PUBLIC 11

Page 18: Oracle 10 2 Upgrade

3 Preparation

3.6 MSCS Only: Removing the Database from the Fail Safe Group

A list of invalid objects before the upgrade is now generated.2. Check the list of invalid objects after the upgrade.

If any objects in the list from before the upgrade are also in the list of invalid objects after the upgrade, youcan be sure that this is not due to the upgrade process.

3.6 MSCS Only: Removing the Database from the Fail Safe Group

In an MSCS configuration, you have to remove the SAP database from the Oracle Fail Safe Group before youbegin the upgrade.

Procedure

.Note

Perform the steps on the first MSCS node only. The database must be located on the first MSCS node.

1. In the Cluster Administrator, take the SAP group offline.2. In the Cluster Administrator, move all groups including the Cluster group to the first MSCS node.3. Log on to the Oracle Fail Safe Manager as the user under which the Cluster Service is running4. Choose Groups ® Oracle<DBSID> ® Cluster Resources and select <DBSID>.world. Click the right mouse

button and choose Remove from Group.

.Note

To find out under which account the Cluster Service is running, choose Start < ® Settings> ® ControlPanel ® Administrative Tools ® Services. Select the Cluster Service and click Startup ... The log on account forthe service is displayed. Enter this account for Oracle Fail Safe Account/PasswordFor more information about services, see Checking Services [page 41] .

5. In the dialog box Confirm Remove Database from Fail Safe Group, choose Yes.The Clusterwide operation window displays the steps that are executed to remove the database from the Fail Safegroup. The last line informs you that The clusterwide operation completed successfully.

6. In the Clusterwide operation window, choose Close.7. Exit the Fail Safe Manager.

3.7 MSCS Only: Upgrading to OFS 3.3.4

If the MSCS configuration is still running with Oracle Fail Safe Software (OFS) version lower than 3.3.4, youmust upgrade to version 3.3.4.To do this you first have to deinstall the old Oracle Fail Safe software on all MSCS nodes and then install the

Oracle Fail Safe 3.3.4 software on a local disk on all nodes. The installation procedure differs depending onwhether you install the Oracle Fail Safe software in a 32-bit or a 64-bit system.

12 PUBLIC 10/10/2006

Page 19: Oracle 10 2 Upgrade

3 Preparation

3.7 MSCS Only: Upgrading to OFS 3.3.4

.Caution

n For a domain usermake sure to use the syntax <domain_name>\<user_name>. The Oracle Fail SafeSoftware is not able to handle the syntax <user_name>@<domain>.

n Make sure to install the Oracle Fail Safe 3.3.4 software in the same Oracle Home on all MSCS nodes.

Prerequisites

n You are logged on as user <SAPSID>adm.n The Cluster Service is started on all MSCS nodes.

For more information, see Starting and Stopping Services for MSCS [page 41] .

Deinstalling the Old Oracle Fail Safe Software

.Note

On 64-bit, you have to deinstall the old Oracle Fail Safe client software with the 32-bit version of the OracleUniversal Installer on all MSCS nodes.

1. Make sure that the Oracle Fail Safe Manager is closed2. Uninstall the old OFS software on all MSCS nodes, as follows:

.Note

While you are uninstalling the software on a particular MSCS node, do not reboot the other node.

a) Start the Oracle Universal Installer from the DVD. To do this, double-click setup.exe in the directory<DVD_DRIVE>:\OFS<platform>\install.

b) In theWelcome screen, choose Installed Products.c) In the Inventory window, expand <Fail_Safe_Home> and select Oracle Fail Safe <version_lower_to 3.3.4>d) Choose Remove.e) In the Confirmation dialog box, confirm that you wish to delete the selected productsf) Click Exit to close the Oracle Universal Installer.

3. If you use a 64-bit system, you also have to deinstall the Oracle Fail Safe client software. To do this you usethe 32-bit Oracle Universal Installer from the Oracle RDBMS DVD.a) Start the Oracle Universal Installer by double-clicking the file setup.exe in the directory

<DVD_DRIVE>:\OFS334I386\Install

b) In theWelcome screen, choose Installed Products.c) In the Inventory window, select OFSCLI and choose Remove.d) In the Confirmation dialog box, confirm that you wish to delete the selected product.

Installing the Oracle Fail Safe Software in a 32‒Bit System

1. In the Cluster Administratormake sure that:n The other MSCS node(s) are not set to Pause.n The SAP group is offline on the MSCS node where you are installing.

2. Make sure that the Cluster Server service is started on all MSCS nodes.3. Start the Oracle Universal Installer from the Oracle RDBMS DVD

10/10/2006 PUBLIC 13

Page 20: Oracle 10 2 Upgrade

3 Preparation

3.7 MSCS Only: Upgrading to OFS 3.3.4

To do this, double-click the file setup.exe in the directory <DVD_DRIVE>:\OFS334I386The installer opens and guides you through the installation process in a series of screens

.Note

If the installer aborts and an error is displayed in an Application Error window with the text The exceptionunknown software exception ..., check the TMP and TEMP variables. In the user environment of <SAPSID>adm,make sure that these refer to existing files. If not, reset them.

Screen Entry

Welcome Choose Next.

Specify File Locations Source...For Path:The path to the Oracle software on the DVD is displayed.Do not change the path.Destination...For Name: Enter the name of the Oracle Home for theOracle Fail Safe software. The Fail Safe software mustbe installed in a separate Oracle Home directory, forexample, OFS

.NoteIf the Oracle Fail Safe version 3.3.1 or 3.3.2 waspreviously installed, we strongly recommend thatyou use the old Oracle Fail Safe Home for 3.3.4.

Path: Enter the path of the Oracle Home directory forthe Oracle Fail Safe software. It must be on a local disk,for example: F:\Oracle\OFS

Available Products Select Oracle Fail Safe 3.3.4.0.0 and choose Next.

Installation types Choose Typical.

Reboot Needed After Installation Choose Next.

Summary View the information and choose Install.

Install Wait while the software is installed.

Configuration Tools In the dialog box Oracle Fail Safe Account/Password enter theaccount and password under which the Oracle Fail Safesoftware is to run. This must be the same account as theone under which the Cluster Service is running.To find out which account must be entered, choose Start< ® Settings> ® Control Panel ® Administrative Tools ®Services.Select the Cluster Service and click Startup...

End of Installation Click Exit to leave the installer.

4. Reboot and log on again.

14 PUBLIC 10/10/2006

Page 21: Oracle 10 2 Upgrade

3 Preparation

3.7 MSCS Only: Upgrading to OFS 3.3.4

.Caution

Do not reboot an MSCS node, if the installation of OFS 3.3.4 or the deinstallation of earlier releases is inprogress on another node.

Installing the Oracle Fail Safe Software in a 64‒Bit System

.Note

If you use a 64-bit system you first have to install the 64-bit Fail Safe Server Software, and then the 32-bitFail Safe Client Software.

1. In the Cluster Administratormake sure that the:n Other MSCS node(s) are not set to Pause.n SAP group is offline on the MSCS node where you are installing.

2. Make sure that the Cluster Server service is started on all MSCS nodes.3. Start the Oracle Universal Installer from the Oracle RDBMS DVD to install the 64-bit Fail Safe Server Software.

To do this, double-click the file setup.exe in the directory for your 64-bit platform:<DVD_DRIVE>:\OFS334IA64\install or <DVD_DRIVE>:\OFS334AMD64\install

4. Enter the required information as follows:

Screen Entry

Welcome Choose Next.

File Locations Source...For PathThe path to the Oracle software on the DVD is displayed.Do not change the path.Destination...For Name Enter the name of the Oracle Home for the FailSafe software. The Fail Safe software must be installed ina separate Oracle Home directory, for example OFSSRV.

.NoteIf Oracle Fail Safe version 3.3.1 or 3.3.2 was previouslyinstalled, we strongly recommend to use the oldOracle Fail Safe Home for 3.3.4.

For Path Enter the path of the Oracle Home directoryfor the Fail Safe software. It must be on a local disk, forexample:F:\Oracle\OFS\SRV

Choose Next.

Installation Types Choose Typical.

Reboot Needed After Installation Choose Next.

Summary View the information and choose Install

Install Wait while the software is installed.

10/10/2006 PUBLIC 15

Page 22: Oracle 10 2 Upgrade

3 Preparation

3.7 MSCS Only: Upgrading to OFS 3.3.4

Screen Entry

Configuration Tools On the dialog box Oracle Services for MSCS Account/Passwordenter the account and password under which the Fail Safesoftware is to run. This must be the same account as theone under which the Cluster Server service is running.To find out which account must be entered, choose Start< ® Settings> ® Control Panel ® Administrative Tools ®Services.Select the Cluster Service and click Startup…The log on account for the service is displayed. Enter thisaccount for Oracle Fail Safe Account/Password..

End of Installation Click Exit to leave the installer.

5. Start the Oracle Universal Installer from the Oracle RDBMS DVD to install the Oracle Fail Safe 32-bit clientsoftware.

6. To do this, double-click the file setup.exe in the directory <DVD_DRIVE>:\OFS334I386\install7. Enter the required information as follows:

Screen Entry

Welcome Choose Next.

File Locations Source...For PathThe path to the Oracle software on the DVD is displayed.Do not change the path.Destination...For Name Enter the name of the Oracle Home for the FailSafe software. The Fail Safe software must be installed ina separate Home directory, for example OFSCLI.Use the same Oracle Home for all MSCS nodes.For Path Enter the path of the Oracle Home directoryfor the Fail Safe software. It must be on a local disk, forexample:F:\Oracle\OFS\CLI

Available Products Select Oracle Fail Safe 3.3.4.0.0 and choose Next.

Installation Types Choose Client Only.

Summary View the information and choose Install.

Install Wait while the software is installed.

End of Installation Click Exit to leave the installer.

8. Reboot and log on again.

.Caution

Do not reboot an MSCS node, if the installation of OFS 3.3.4 is in progress on another node.

16 PUBLIC 10/10/2006

Page 23: Oracle 10 2 Upgrade

4 Oracle Database Upgrade

4 Oracle Database Upgrade

The following sections describe how to upgrade the Oracle database.

.Note

You have completed the Planning [page 5] and Preparations [page 9].

1. You install the Oracle 10g software [page 17].2. You copy and adapt the old Oracle SQL*Net files [page 20].3. You save the archive log files [page 20].4. You change the environment for user <dbsid>adm [page 21].5. You upgrade the Oracle database [page 21].

4.1 Installing the Oracle Database Software

The following sections describe how to install the Oracle server software and the Oracle client software.

4.1.1 Installing the Oracle 10g Server Software

.Caution

If you copy the files from the DVD to a local disk, do not use directory names containing blanks.

.Note

n You need 2 GB disk space for the Oracle server software.

n MSCS Only: You have to install the Oracle database server software on allMSCS nodes.

1. On the database server, place the Oracle RDBMS DVD in the DVD drive and change to the directory:<DVD_DRIVE>:\NT\<platform>

2. Start the Oracle Universal Installer as follows:n If you want to install in the same directory where the previous ORACLE_HOME is set, double-click

the file sapserver.cmd.

.Note

If a dos-box appears, specify the drive letter of the local disk where you want to install the Oraclesoftware, and the <DBSID>. The dos-box only appears if you perform a new installation (under adifferent user), or if the ORACLE_HOME and <DBSID> are not set.

10/10/2006 PUBLIC 17

Page 24: Oracle 10 2 Upgrade

4 Oracle Database Upgrade

4.1 Installing the Oracle Database Software

n If you want to specify another installation directory, delete the ORACLE_HOME as environmentvariable, before you double-click sapserver.cmd. This allows you to specify the name and the path ofthe new ORACLE_HOME. When you have finished the database server installation, do not forget to setORACLE_HOME to the previous value again.

3. In the Oracle Universal Installer, enter the information as shown in the following table:

Window Entry

Specify File Locations If this screen appears, do the following:Under Source:n For Path:

Shows the path to the Oracle source software. Donot change the path.

Under Destination:n For Name:

Enter the name of the new Oracle Homedirectory. We recommend that you use the name<SAPSID><ORACLE_VERSION>, for example, PRD102

n For Path:Enter the path of a new Oracle Home directory. Werecommend that you use the path:<DRIVE>:\ORACLE\<DBSID>\<ORA_VERS>, for example,C:\ORACLE\PRD\102

.NoteDo not specify an already existing Oracle Homedirectory. You must specify a new directory.

Choose Next.

Summary Choose Install.

Oracle Net Configuration Assistant: Welcome If this dialog appears, select Perform typical configuration.

Configuration Assistants.NoteIf you get an error message, choose OK.Ignore the upcoming Warning screen and chooseOK.

Choose Next.

End of Installation Choose Exit to close the Oracle Universal Installer.

4. Install the latest patch set and critical patch updates (CPU) or minipatches (if available). For moreinformation, refer to SAP Notes 871735, 850306, and 839182.

.Note

MSCS Only:You have to install the current Oracle patch set and CPUs or minipatches (if available) on all MSCSnodes.

18 PUBLIC 10/10/2006

Page 25: Oracle 10 2 Upgrade

4 Oracle Database Upgrade

4.1 Installing the Oracle Database Software

4.1.2 Installing the Oracle 10g Client Software

To install the Oracle 10g database client software perform one of the following steps on the central and dialoginstance.

n If you have an instance-specific exe directory on the central instance host, you install and replicate theclient software automatically with sapcpe on each application server, every time the system starts:

n If you do not have an instance-specific exe directory on the central instance host, you have to install theclient software manually on the central instance host.

The following describes both procedures.

.Caution

If you want to upgrade from Oracle 10.1.0 to Oracle 10.2. you have to delete the old Oracle instant clientsoftware before you extract the Oracle 10.2. instant client:

1. Enter the following command in theDIR_CT_RUN [page 43] and all $(DIR_INSTANCE)\exe-directories:type dbclient.lst

2. Delete all files and directories listed in dbclient.lst.

Procedure

1. The following step is only relevant on the central instance host:Extract the platform-specific OCL102<xx>.sar archive on the central instance as follows:

.Note

n The archive is located on the Oracle 10g Client Software DVD in the directoryOCL_WINDOWS_<platform>.

n To unpack the archive, use the latest sapcar.exe program, which you find on the Oracle RDBMSDVD in the directory: NT\<platform>\SAP.

n In mixed environments (32-bit and 64-bit) you have to extract the archive in the respectivedirectory on both platforms.

n If you have an instance-specific exe directory on the central instance host, extract the platform-specificOCL102<xx>.sar archive to the DIR_CT_RUN [page 43] directory.Open a command prompt and enter the following commands in a separate line:cd <path_to_DIR_CT_RUN>

sapcar -xvf <path_to OCL_WINDOWS_<platform>>\OCL102<xx>.SAR

n If you do not have an instance-specific exe directory on the central instance host, extract theplatform-specific OCL102<xx>.sar archive to the DIR_EXECUTABLE [page 43] directory.Open a command prompt and enter the following commands in a separate line:cd <path_to_DIR_EXECUTABLE>

sapcar -xvf <path_to OCL_WINDOWS_<platform>>\OCL102<xx>.SAR

2. Define the following parameter in all instance profiles:DIR_CLIENT_ORAHOME=$(DIR_EXECUTABLE)

10/10/2006 PUBLIC 19

Page 26: Oracle 10 2 Upgrade

4 Oracle Database Upgrade

4.2 Copying and Adapting the SQL*Net Files

4.2 Copying and Adapting the SQL*Net Files

After the database software installation, youmust copy andmodify the old SQL*Net files, that is, listener.ora,sqlnet.ora, and tnsnames.ora.

Procedure

1. Log on as user <dbsid>adm.2. Copy the SQL*Net parameter files from the <old_ORACLE_HOME>\network\admin-directory to the

<new_ORACLE_HOME>\network\admin-directory.3. Edit the listener.ora in the <new_ORACLE_HOME>\network\admin-directory.

Identify the parameter ORACLE_HOME that belongs to the database you want to upgrade (SID_NAME insection SID_LIST) and change the value of the parameter ORACLE_HOME to point to the new ORACLE_HOME.

4. Multiple Oracle Homes Only: This step is only necessary, if you want to continue using additionalOracle Homes after the database upgrade.If you have two or more co-existing Oracle Homes, each has its own Listener and its own correspondingconfiguration. Make sure that you do not use the same port number for more than one listener.To check existing numbers in the Net Manager:a) Start the Net Manager that guides you through the Network configuration process.

To do this, choose Start ® Programs ® Oracle - <NEW_ORACLE_HOME_NAME> ® Configuration andMigration Tools ® Net Manager

b) Choose File ® Oracle Net Configurationc) Select the Listener.

The port number for the Listener is displayed. Keep in mind that when you remove or change portnumbers for a Listener, you must do this for both the client and server using theNet Manager as describedearlier.

d) Carry out the previous steps for each active Oracle Homes and make sure that you do not use thesame port number for more than one listener.

4.3 Saving Archive Log Files

You need to save the archive log files in the old user environment.

Procedure

1. Save the current log for archiving by switching to another log file:sqlplus “/ as sysdba“

SQL> alter system switch logfile

2. Shut down the Oracle 9i database instance:SQL> shutdown immediate;SQL> exit

3. Shut down the Oracle 9i Listener to avoid client connections:lsnrctl stop

4. If not already done, save all the archive log files that have been generated using BRARCHIVE.

20 PUBLIC 10/10/2006

Page 27: Oracle 10 2 Upgrade

4 Oracle Database Upgrade

4.4 Changing the Environment for User <dbsid>adm

5. If you want to separate the Oracle 9i from the Oracle Database 10g Release 2 (10.2) alert log file, you canmove the alert log file to a different name:cd %SAPTRACE%\background (if the saptrace environment variable exists)cd %SAPDATA_HOME%\saptrace\background (if the saptrace environment variable does not exist)move alert_<DBSID>.log alert_<DBSID>.log-SV-9.2.0

4.4 Changing the Environment for User <dbsid>adm

1. If you use multiple Oracle Homes, remove from the system environment variable PATH all parts referringto the Oracle executables (%ORACLE_HOME%\bin) as follows:a) Start the Oracle Universal Installer with Start ® Programs ® Oracle - <Home_Name> ® Oracle Installation

Products ® Universal Installerb) In theWelcome screen, choose Installed Products.c) In the Inventory screen, choose the Environment tab.d) Deselect all components and choose Apply.

2. In the environment of the user <dbsid>adm, delete the following variables:

n ORACLE_HOME

n TNS_ADMIN (if it exists)

.Note

MSCS Only: Delete the variables on all nodes.

3. If you use multiple Oracle Homes, update or create, if not available, the user environment PATH of all usersusing the Oracle software to refer to the correct %ORACLE_HOME% as follows:a) ChooseMy Computer ® Properties ® Advanced ® Environment Variables.b) Set the value for PATH to <Old_ORACLE_HOME\bin.

4. Set the database parameter JOB_QUEUE_PROCESSES = 0.For more information on how to set parameters, see Changing Oracle Database Parameters [page 42].

5. Log off and log on again to activate the changes.

4.5 Performing the Database Upgrade

.Caution

Currently you cannot upgrade an Oracle database that uses temporary Tablespaces withallocation_type=’USER’. Therefore, before you start the Oracle Database Upgrade Assistant, check andcorrect your database according to SAP Note 905279.Also apply this SAP Note if you get the following error message:upgrade.xml is not a valid XML file.

10/10/2006 PUBLIC 21

Page 28: Oracle 10 2 Upgrade

4 Oracle Database Upgrade

4.5 Performing the Database Upgrade

Procedure

.Note

MSCS Only:Follow the instructions on the first MSCS node only, where the database is located.In the Cluster Administratormake sure that the database disks are online on the first MSCS node.

1. Stop the SAP system.2. Change the registry entry of ORA_<DBSID>_AUTOSTART as follows:

Enter the command:oradim -edit –sid <dbsid> –startmode manual

3. Start the Oracle Database Upgrade Assistant from the Startmenu with:Start ® Programs ® Oracle - <NEW_ORACLE_HOME_NAME> ® Configuration and Migration Tools ® DatabaseUpgrade AssistantThe Oracle Database Upgrade Assistant (DUA) opens. A sequence of windows guides you through the process.You can navigate between the windows by choosing Next or Back.

.Note

During the upgrade empty DOS-boxes may appear. Ignore them as long as they disappearautomatically.

Screen Input

DUA: Welcome Choose Next.

DUA: Databases a) Select the database you want to upgrade.

.CautionThe following warnings may appear:n If you are asked, to resize the rollback segment SYSTEM,

choose Continue.n If there is not enough space for the SYSTEM tablespace,

increase the space.

b) Choose Next.

DUA: SYSAUX Tablespace.Noten We recommend to change the name of the data file to

conform with the SAP file naming conventions for the Oracledatabase. Therefore change the sysaux Tablespace namefrom <drive>:\….\sapdata1\system_1\sysaux01.dbf into<drive>:\sapdata1\sysaux_1\sysaux.data1.

Make sure that there is enough space on the specified disk.n Note that br*tools can only process one data file per directory.

Change the increment parameter from 1 MB to 10 MB, and then chooseNext .

DUA: Recompile Invalid Objects Leave selection unchanged and choose Next.

22 PUBLIC 10/10/2006

Page 29: Oracle 10 2 Upgrade

4 Oracle Database Upgrade

4.5 Performing the Database Upgrade

Screen Input

DUA: Backup Select I have already backed up my database, and then choose Next.

DUA: Management Options Leave the default settings and choose Next.

DUA: Database Credentials: Change the default passwords for the database users.

Summary Choose Finish to start the upgrade.

DUA: Progress The screen displays the phases of the data upgrade procedure. When theupgrade has finished, choose OK to see the upgrade results.

DUA: Upgrade Results Check the results and any errors.Do not choose Restore Database.

Close Choose Close.

10/10/2006 PUBLIC 23

Page 30: Oracle 10 2 Upgrade

This page is intentionally left blank.

Page 31: Oracle 10 2 Upgrade

5 Post-Upgrade Steps

5 Post-Upgrade Steps

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

1. You create the Oracle TNSListener service [page 25].2. You set the user environment variables [page 25].3. MSCS Only: You set up a shared database directory in the Oracle home [page 26].4. You change the registry value of Oracle Autostart [page 27].5. You start the Oracle services [page 28].6. You update BR*Tools [page 28].7. You delete the old Oracle software [page 29].8. You back up the database [page 31].9. You perform post-upgrade tasks [page 31].10. You create the orapwd file [page 33].11. MSCS Only: You add the database to the Fail Safe group [page 33].12. You change the location of the JDBC driver [page 34].13. You upgrade the SAP executables to the latest version [page 37].14. You disable the database user locking mechanism on failed logins [page 37].15. You configure the new features for Oracle Database 10g Release 2 (10.2) [page 37].

5.1 Creating the Oracle TNSListener Service

PrerequisitesStop the old Oracle listener before you create the Oracle TNSListener Service.

ProcedureOpen a command prompt and enter the following command:

<complete_path_to_new_Oracle_Home>\bin\lsnrctl start

5.2 Changing Environment Variables

.Note

MSCS Only: Edit the variables on allMSCS nodes.

1. In the user environment and system environment <SAPSID>adm, check the PATH variable and, if required,remove all parts referring to the old Oracle version.

10/10/2006 PUBLIC 25

Page 32: Oracle 10 2 Upgrade

5 Post-Upgrade Steps

5.3 MSCS Only: Setting Up a Shared Database-Directory in Oracle Home

.Caution

When you modify the user environment, you must be logged on as the corresponding <SAPSID>admuser.

2. In the user environment of <SAPSID>adm, set the ORACLE_HOME variable to the correct value for Oracle10g, for example to: <DRIVE>:\ORACLE\PRD\102.

3. If you have two or more co-existing Oracle Homes, make sure that the user environment variable PATH ofthe <SAPSID>adm user points to the corresponding %Oracle_Home%\bin-directory.

4. Copy tnsnames.ora and sqlnet.ora from %ORACLE_HOME%\network\admin to\\<sapglobalhost>\sapmnt\<SAPSID>\SYS\profile\oracle.

.Note

This information is required for all ABAP application server you install on a separate host to find thecorrect location of these files.

5. Set the user environment variable TNS_ADMIN to point to the directory\\<sapglobalhost>\sapmnt\<SAPSID>\SYS\profile\oracle.

.Note

Set TNS_ADMIN on all ABAP application server.

6. Reboot the computer.

5.3 MSCS Only: Setting Up a Shared Database-Directory in OracleHome

The following describes how to set up a shared Oracle Home\database-directory with a link or junction if yourdatabase is configured for using a spfileA central Oracle Home\database-directory has the following advantages:

n You can also use sqlplus remotely to make changes to your profile parametersn You have to make the changes in the parameter files only once in the shared Oracle

Home\database-directory.If your database is not configured for using a spfile, you have to apply all changes in the init<DBSID>.orafile in the Oracle Home\database-directories on all MSCS nodes.To check the configuration of your database, see Changing or Deleting Oracle database parameters [page 42].

PrerequisitesYou have one of the following executables available:

n linkd.exe

This executable is part of the Microsoft Windows 2003 Server Resource Kit.You can download the resource kit from www.microsoft.com.

Search forMicrosoft Windows 2003 Server Resource Kit.

26 PUBLIC 10/10/2006

Page 33: Oracle 10 2 Upgrade

5 Post-Upgrade Steps

5.4 Changing the Registry Value of Oracle Autostart

.Note

After you have installed the resource kit, you can copy linkd.exe to any directory.

n junction.exe

You can download this file from www.sysinternals.com

Search for junction.

Procedure

1. Stop the Oracle database and the Oracle Service.2. In the sapdata1 directory create the directory database.

The sapdata1 directory is located on a shared disk in the cluster.3. On the first MSCS node, change to the Oracle Home directory, and enter the following command:

move database\* <path to_sapdata1>\database

4. Delete the Oracle Home\database-directory with the command:rd /q /s database

.Note

You can also use the Windows Explorer to delete the directory.

5. Create the junction or link with the following DOS-command:n For junction, enter:

<path_to_junction.exe> %Oracle_Home%\database <complete_path_to_sapdata1>\database

n For linkd, enter:<path_to_linkd.exe> %Oracle_Home%\database <complete_path_to_sapdata1>\database

.Note

You can also use the 32-bit junction.exe or linkd.exe in a 64-bit Windows operating system.

6. Move the disk where the …\sapdata1\database directory is located to another MSCS node.7. Repeat step 4 and step 5 on the other MSCS node(s).8. Edit or create the file init<DBSID>_OFS.ora in the database directory, and enter the following line:

spfile = <path_to_Oracle_Home>\database\SPFILE<DBSID>.ora

.Note

If the file init<DBSID>_OFS.ora is not available, create the file in the database directory.

5.4 Changing the Registry Value of Oracle Autostart

Change the registry value with the following command: oradim -edit -sid <dbsid> -startmode manual

.Note

Make sure that you use oradim of Oracle 10.2.

10/10/2006 PUBLIC 27

Page 34: Oracle 10 2 Upgrade

5 Post-Upgrade Steps

5.5 Starting the Oracle Services

.Note

If you have several Oracle Homes, ORA_<DBSID>_AUTOSTART, is available in one Oracle Home only. Set thevalue for ORA_<DBSID>_AUTOSTART from TRUE to FALSE.

5.5 Starting the Oracle Services

Start the Oracle services, if not yet started.In a standard conguration, set the startup type of OracleService<DBSID> and

Oracle<ORACLE_HOME_NAME>TNSListener to automatic to ensure that they are automatically restarted afterbooting. For more information on how to start services, see Starting or Stopping Services [page 41].

.Caution

MSCS Only:Set the startup type of OracleService<DBSID> and Oracle<ORACLE_HOME_NAME>TNSListener to manual

to ensure that they are not automatically restarted after booting.

5.6 Updating BR*Tools

You update BR*Tools to the latest release, BR*Tools Release 700, with the latest patch level. After extractingBR*Tools Release 700 you need to update the SAPDBA role using the script sapdba_role.sql. This is essentialso that the new release of BR*Tools works correctly. The script is automatically extracted when you extractBR*Tools.

Procedure

1. Download the most current version of the BR*Tools from SAP Service Marketplace at:service.sap.com/swdc

2. Unpack BR*Tools to the DIR_CT_RUN [page 43] directory.

.Note

MSCS Only: Install BR*Tools in the following directories:n DIR_CT_RUN [page 43] on oneMSCS node only.

n %windir%\SapCluster on allMSCS nodes.

3. After you have extracted the newest BR*Tools you also need to copy the BR*Tools configuration filesinit<DBSID>.sap and init<DBSID>.utl from the <old_ORACLE_HOME>\database directory to the new one:cd <old_ORACLE_HOME>\database

copy init<DBSID>.sap %ORACLE_HOME%\database

copy init<DBSID>.utl %ORACLE_HOME%\database (This file is only available only if you use a 3rd partybackup solution)

28 PUBLIC 10/10/2006

Page 35: Oracle 10 2 Upgrade

5 Post-Upgrade Steps

5.7 Deleting the Old Oracle Software

.Note

n init<DBSID>.dba is no longer needed because BR*Tools release 6.40 SAPDBA is no longer available.

n The init<DBSID>.utl file is only available if you use external backup software based on an backintinterface.

4. Update the SAPDBA role as <dbsid>adm user as follows:a) Copy sapdba_role.sql from the DIR_CT_RUN directory to the %ORACLE_HOME%\database directory.b) Execute the following SQL command(s):

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 the command(s) for every SAPSCHEMA_ID in your database.

5.7 Deleting the Old Oracle Software

You use the Oracle Universal Installer to delete the old Oracle software.

.Caution

MSCS Only:Carry out this procedure only after you have added the database to the Fail Safe group [page 33]. Perform

the steps on all MSCS nodes.

.Caution

n Do not delete the old software, if it still has to be accessed by another SAP instance running with thisversion. For example, this may be the case if an SAP dialog or central instance belonging to a differentSAP system is running on the same database host.

n Database client only:In a distributed system, where your central instance is installed on a separate host than the databaseinstance, you must delete the old Oracle database client 9.2 software at least on the central instancehost before you start upgrading your SAP system.If you cannot delete the old Oracle client software because it is used by other programs or SAP instanceson the same host you have to modify the environment variable path for user <SAPSID>adm andSAPService<SAPSID> so that it does not contain any reference to the old ORACLE_HOME\bin directory.In a central system only delete the database client after you have finished upgrading your system.

10/10/2006 PUBLIC 29

Page 36: Oracle 10 2 Upgrade

5 Post-Upgrade Steps

5.7 Deleting the Old Oracle Software

Procedure

1. Stop the database.2. MSCS Only: Set the Oracle Services for MSCS offline.3. MSCS Only: Stop the Cluster Service on all MSCS nodes.4. Stop the service Distributed Transaction Coordinator.5. Stop the services of the old Oracle Home.6. Start the Oracle Universal Installer from your Startmenu as follows:n If you find the Universal Installer under Start ® Programs ® <New_Oracle_Home_Name> ® Oracle Installation

Products ® Universal Installer, youmust start it from this path.n Otherwise, start it from Start ® Programs ® Oracle Installation Products ® Universal Installer

.Note

Note that on a database client, you start the Universal Installer from the Oracle RDBMS DVD.Double-click the file setup.exe in the directory <DVD-DRIVE>:\NT\<platform>\install

7. Follow the instructions for your Oracle Home you want to remove.a) In theWelcome screen, choose Deinstall Products.b) In the Inventory dialog box, expand the node representing your old Oracle Home and remove it.

On a database client, you expand the node representing the old Oracle Home and remove it.c) Confirm the removal of the products in the popup that appears

.Note

Note that it is not possible to delete all old Oracle products. These are deleted in the following steps.

8. Delete the services whose name contains the old Oracle Home name.To delete a service, open a command prompt and enter:sc delete <service_name>

Make sure that you do not delete the services listed under Oracle Services [page 41].

.Note

Multiple Oracle Homes only: On a database server with multiple Oracle Homes, do not delete theservice OracleService<DBSID>. If more than one Listener is configured, do not delete these either.

9. In theWindows Explorer delete the Oracle Home directory of old software.10. Delete the entry Oracle for Windows NT, if it exists, in the Windows Startmenu, as follows:

a) Choose Start ® Programsb) Right-click Oracle ‒ <OLD_ORACLE_HOME_NAME> and choose Delete.

.Caution

Make sure that you delete the registry key for the earlier Oracle version, for example:HKEY_LOCAL_MACHINE ® SOFTWARE ® ORACLE ® HOME<n> only, if there is only oneOracle client installed. Otherwise do not delete it.

30 PUBLIC 10/10/2006

Page 37: Oracle 10 2 Upgrade

5 Post-Upgrade Steps

5.8 Backing Up the Database

5.8 Backing Up the Database

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

.Caution

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

ProcedurePerform a full database backup.

5.9 Performing Post-Upgrade Tasks

You need to perform certain post-upgrade tasks.

Procedure

1. Change database compatibility by executing the following SQL command as the <dbsid>adm user:sqlplus /nolog

SQL>connect / as sysdba

SQL> alter system set compatible='10.2.0' scope = spfile;

2. Restart the Oracle database.3. Deactivate the Oracle recycle bin by executing the following SQL command as the <dbsid>adm user:

SQL> purge dba_recyclebin;

SQL> alter system set recyclebin = 'off' scope = spfile;

For more information, see SAP Note 838982.4. Gather Oracle optimizer statistics as follows:

a) Execute the following commands as the <dbsid>adm user:SQL> spool %ORACLE_HOME%/cfgtoollogs/dbstats.log

SQL> execute dbms_scheduler.disable('GATHER_STATS_JOB');

SQL> execute dbms_stats.gather_system_stats;

SQL> execute dbms_stats.gather_dictionary_stats

(ESTIMATE_PERCENT => NULL,

METHOD_OPT => 'FOR ALL COLUMNS SIZE AUTO',

GRANULARITY => 'ALL',

CASCADE => TRUE,

OPTIONS => 'GATHER',

NO_INVALIDATE => FALSE);

SQL> execute dbms_stats.gather_fixed_objects_stats;

b) Check the log file dbstats.log created at %ORACLE_HOME%\cfgtoollogs for any errors during thegathering of statistics.

5. Identify the objects that are invalid after the upgrade as follows:a) Execute the following commands as the <dbsid>adm user:

SQL> @?/rdbms/admin/utlrp.sql;

SQL> spool %ORACLE_HOME%/cfgtoollogs/invalid_post.log

10/10/2006 PUBLIC 31

Page 38: Oracle 10 2 Upgrade

5 Post-Upgrade Steps

5.9 Performing Post-Upgrade Tasks

SQL> select count(*) from dba_objects where status = 'INVALID';

SQL> select substr(owner,1,12) owner, substr(object_name,1,30)

object, substr(object_type,1,30) type, status from

dba_objects where status <>'VALID' order by owner;

SQL> spool off;

b) Check the log file invalid_post.log. created at %ORACLE_HOME%\ cfgtoollogs\invalid_post.log tocompare the invalid objects before the start of the upgrade.

6. Check the Oracle database parameters against SAP Note 830576 and adjust them if necessary.Make sure that the following database parameters, if set, are removed;COMMIT_WRITE

CURSOR_SPACE_FOR_TIME

DB_FILE_MULTIBLOCK_READ_COUNT

HASH_JOIN_ENABLED

LOG_ARCHIVE_START

OPTIMIZER_INDEX_COST_ADJ

OPTIMIZER_MODE

STATISTICS_LEVEL

TIMED_STATISTICS

TRACE_ENABLED

7. Restart the database to activate the changes:a) Log on to the database with SQL*Plusb) Execute the following commands:

sqlplus / as sysdba

shutdown immediate

startup

8. Gather statistics for SAP schemas:a) With Oracle Database 10g all tables have statistics, which means that you need to update some entries in

the DBSTATC table before starting BRCONNECT, as follows:sqlplus SAP<SAPSCHEMA_ID>/<password>

SQL> update DBSTATC set activ = 'A' where activ in ('N, 'R');

SQL> commit;

.Caution

Perform this action separately for each SAP schema on the database, but not for Java systems.

b) Update the Oracle database statistics with BRCONNECT as follows:brconnect -c -u / -f stats -t all –f collect -p 4

.Note

For more information on update statistics, see the documentation SAP Database Guide: Oracle onSAP Service Marketplace at:service.sap.com/dbaora ® Media Library

32 PUBLIC 10/10/2006

Page 39: Oracle 10 2 Upgrade

5 Post-Upgrade Steps

5.10 Creating the orapwd File

5.10 Creating the orapwd File

You create the orapwd file to use for the Oracle Enterprise Manager. This allows you to connect to the Oracledatabase as sysdba without using the operating system users.

.Note

This procedure is only required if you upgraded an Oracle 9.2.0.6 database to Oracle 10.2.

Procedure

1. In sqlplus, set the parameter remote_login_passwordfile to EXCLUSIVE.For more information on how to set parameters, see Changing Oracle Database Parameters [page 42].

2. Open a command prompt and create the pwd<DBSID>.ora file with the following command:orapwd file=%Oracle_Home%\database\pwd<DBSID>.ora password=<pwdFilePassword> entries=100

force=y

Enter a password for <pwdFilePassword>.3. Stop and restart the Oracle database.4. To allow a database user, for example sap<sapsid>, or a system to connect to the Oracle database as sysdba

or sysoper (connect dbusername/dbpassword as sysdba) although the database is not started, enter thefollowing commands:sqlplus /nolog

SQL>connect / as sysdba

SQL>grant sysdba to <dbusername>;

SQL>grant sysoper to <dbusername>;

5.11 MSCS Only: Adding the Database to the Fail Safe Group

To enable a database to fail over with all the resources it requires, you must add it to the Fail Safe group.

PrerequisitesThe Cluster Service is running on all MSCS nodes.

Procedure

1. Copy the file sqlnet.ora from the directory %ORACLE_HOME%\network\admin from the first MSCS node tothe same directory on the additional MSCS node.

2. Start the Cluster Administrator and bring the Oracle Services for MSCS resource online.3. Start the Oracle services.4. Start the database.5. Start the Oracle Fail Safe Manager with Start ® Programs ® Oracle - <Fail_Safe_Home_Name> ® Oracle Fail

Safe Manager.6. In theWelcome dialog box choose Verify Cluster.

10/10/2006 PUBLIC 33

Page 40: Oracle 10 2 Upgrade

5 Post-Upgrade Steps

5.12 Changing the Location of the JDBC Driver

.Note

All MSCS nodes must be up and running for this step.

The window Clusterwide Operation: Verifying Fail Safe Cluster shows the steps that are executed to verify thecluster. When you are informed that the operation has completed successfully, close the window.

7. Add the SAP database to the Fail Safe group Oracle<DBSID>.

a) In the tree on the left, choose Nodes ® <First MSCS Node> ® Standalone Resources and then select thedatabase <DBSID>.world.

b) Choose Resources ® Add to Group.8. In the dialog box Add Resource to Group ‒ Resource: Step 1, for Resource Type select Oracle Database.

For Group name, select Oracle <DBSID>.9. Choose Next.10. In the dialog box Add Resource to Group ‒ Database Identity: Step 2, verify the information and choose Finish.

You may need to specify the database name.11. In the dialog box Finish Adding the Database to the Group, choose OK to add the database resource to the group.12. In the dialog box Confirm Add database to Group, choose Yes.

The Adding resource <DBSID>.world to group window, shows the steps that are executed to add the databaseto the Fail Safe group.

13. Copy tnsnames.ora from %ORACLE_HOME%\network\admin to\\<sapglobalhost>\sapmnt\<SAPSID>\SYS\profile\oracle.

14. On the additional MSCS node, set the user environment variable TNS_ADMIN to point to the directory\\<sapglobalhost>\sapmnt\<SAPSID>\SYS\profile\oracle.

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

5.12 Changing the Location of the JDBC Driver

If you have an SAP system with Java components, you may have to change the location of the JDBC driver afteryou have upgraded the database. Otherwise the J2EE Engine cannot start because the location of the JDBCdriver still points to the path of the old ORACLE HOME.You change the location of the JDBC driver as follows:

n In files that are located in the database you use the J2EE Engine Config Tool to change the JDBC driverlocation.

n In files that are not located in the database you use Note Pad or another text editor to change the JDBCdriver location.

.Caution

n Make sure when you change the driver location that you use a forward slash "/" or backward slash "\"as appropriate.

n Make sure that you replace the old driver location in all locations stated in the following procedure.

34 PUBLIC 10/10/2006

Page 41: Oracle 10 2 Upgrade

5 Post-Upgrade Steps

5.12 Changing the Location of the JDBC Driver

Procedure

1. Change to the config.properties file, which is located in the following directory:

n

Only valid for: Java

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

End of: Java

n

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

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

End of: ABAP+Java;Java Add-In

a) Open the file with your text editor and search for the property rdbms.DriverLocation.b) Replace the old driver location with the new one:

<drive>:\\usr\\sap\\<SAPSID>\\JC<instance_number>\\exe\\<java_class_archive>.jar (if itexists) or:<drive>:\\usr\\sap\\<SAPSID>\\SYS\\exe\\run\\<java_class_archive>.jar

where <java_class_archive>.jar is classes12.jar or ojdbc14.jar2. In the same directory as in the first step, start the J2EE Engine - ConfigTool by double-clicking the

configtool.bat file.a) Change to Configuration Editormode.b) Use the Editmode to replace the driver location in the following property sheets that contain the string

rdbms.driverLocation= followed by the driver location:

n cluster_data/Propertysheet instance.properties.IDXXXXXXX/IDXXXXXXX.JavaParameters

where XXXXXXX is the instance number

.Note

Make sure that you change all occurrences. There might be several IDXXXXXX.JavaParametersproperties in the property sheet.

n cluster_data/dispatcher/IDXXXX/kernel/propertysheet ConfigurationManager

n 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.

c) Close the J2EE Engine - ConfigTool.3. Change to the bootstrap.properties file, which is located in the following directory:

n

Only valid for: Java

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

End of: Java

n

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

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

a) Open the file with your text editor and search for the property rdbms.DriverLocation.b) Replace the old driver location with the new one:

10/10/2006 PUBLIC 35

Page 42: Oracle 10 2 Upgrade

5 Post-Upgrade Steps

5.12 Changing the Location of the JDBC Driver

<drive>:\\usr\\sap\\<SAPSID>\\JC<instance_number>\\exe\\<java_class_archive>.jar (if itexists) or:<drive>:\\usr\\sap\\<SAPSID>\\SYS\\exe\\run\\<java_class_archive>.jar

.Caution

If you have more than one J2EE Engine server installed, you must repeat steps 2 and 3 forall servers.

End of: ABAP+Java;Java Add-In

4. Change to the sdmrepository.sdc file, which you can find in the following directory:

n

Only valid for: Java

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

End of: Java

n

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

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

a) Search for the following text:<Param type="String" hide="false" name="jarPaths" encrypted="false"

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

b) If required, replace the old driver location with the new one, such as one of the following:<drive>:\<Oracle_Home>\jdbc\lib\<java_class_archive>

<drive>:\\usr\\sap\\<SAPSID>\\JC<instance_number>\\exe\\<java_class_archive>.jar (if itexists), or:<drive>:\\usr\\sap\\<SAPSID>\\SYS\\exe\\run\\<java_class_archive>.jar

End of: ABAP+Java;Java Add-In

5. Change to the rdb.properties file, which is located in the following directory:/usr/sap/<SID>/<INSTANCE>/j2ee/deploying

a) Open the file with your text editor and search for the property rdbms.DriverLocation.b) Replace the old driver location with the new one:

<drive>:\\usr\\sap\\<SAPSID>\\JC<instance_number>\\exe\\classes12.jar (if it exists), or:<drive>:\\usr\\sap\\<SAPSID>\\SYS\\exe\\run\\<java_class_archive>.jar

6. Change to the templateconfigurator.properties file, which is located in the following directory:/usr/sap/<SID>/<INSTANCE>/j2ee

a) Open the file with your text editor and search for the property RDBMS_DRIVER_LOCATION.b) Replace the old driver location with the new one:

<drive>:\\usr\\sap\\<SAPSID>\\JC<instance_number>\\exe\\<java_class_archive>.jar (if itexists), or:<drive>:\\usr\\sap\\<SAPSID>\\SYS\\exe\\run\\<java_class_archive>.jar

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

36 PUBLIC 10/10/2006

Page 43: Oracle 10 2 Upgrade

5 Post-Upgrade Steps

5.13 Upgrading the SAP Executables to the Latest Version

5.13 Upgrading the SAP Executables to the Latest Version

Before you start your SAP system [page 44], make sure that you have applied the latest available packages for:

n disp+work

n libdbsl

n sapcpe

5.14 Disabling Database User Locking Mechanism For Failed Logins

When upgrading an Oracle database to Oracle version 10g, user locking is automatically activated so that, if yourepeatedly enter invalid login information, the user is locked. By default, ten invalid login attempts are allowedbefore the user is locked. Since old SAP systems first try to log in with a standard user (sapr3) and password,this locking mechanism might lock the user when starting the system.For more information, see SAP Note 951167.

ProcedureTo deactivate user locking after invalid logon attempts, enter the following information in sqlplus:

sqlplus /as sysdba

sqlplus> ALTER PROFILE DEFAULT LIMIT FAILED_LOGIN_ATTEMPTS UNLIMITED;

sqlplus> exit

5.15 Configuring the New Features for Oracle Database 10gRelease 2 (10.2)

You need to configure the new Oracle Database 10g Release 2 (10.2) features.

ProcedureFor more information about new features with Oracle Database 10g Release 2 (10.2) see SAP Note 828268. Thisnote provides links to other SAP notes that describe how to configure or activate each new feature.

10/10/2006 PUBLIC 37

Page 44: Oracle 10 2 Upgrade

This page is intentionally left blank.

Page 45: Oracle 10 2 Upgrade

6 Common Administration Tasks

6 Common Administration Tasks

The following sections provide information on common administration tasks that have to be performedrepeatedly during the upgrade procedure. Some of these tasks are standard tasks, others are only relevant for aMicrosoft Cluster Service (MSCS) configuration.

n Starting and stopping the database [page 39]n Checking Oracle services [page 41]n Starting and stopping services [page 41]n Changing or deleting Oracle database parameters [page 42]n Determining the value of SAP system profile parameters [page 43]n Moving groups for MSCS [page 44]n Starting and stopping the SAP system [page 44]

6.1 Starting and Stopping the Database

The following sections provide information on:

n Starting and stopping the database in a standard configuration [page 39]n Starting and stopping the database in an MSCS configuration [page 40]

6.1.1 Starting and Stopping the Database in a StandardConfiguration

In a standard configuration you use sqlplus to start or stop the database.

ProcedureEnter the following commands in sqlplus:

n To start the database, enter:sqlplus /nolog

SQL>connect / as sysdba

SQL>startup

SQL>exit

n To stop the database, enter:sqlplus /nolog

SQL>connect / as sysdba

SQL>shutdown immediate

SQL>exit

10/10/2006 PUBLIC 39

Page 46: Oracle 10 2 Upgrade

6 Common Administration Tasks

6.1 Starting and Stopping the Database

6.1.2 Starting and Stopping the Database in an MSCS Configuration

This section describes how to start or stop the database in an MSCS configuration.You have the following options

n You use sqlplusYou use this option if:l The database disks are online and the OracleService<DBSID> is started.

l You start the database in a certain mode, for example you use the commands startup upgrade orstartup migrate during an upgrade or a migration.

.Note

If want to start the database in a certain mode (for example, you use the commands startup migrate,

startup upgrade, startup nomount, or if you have installed a patch set or hotfix), perform thefollowing steps:1. In the Oracle Fail Safe Manager, right-click the database <DBSID>.world in the Fail Safe group

ORACLE<DBSID>.2. Choose Place offline.3. Choose the specific modus.4. On the node, where the Oracle group is partially online, start the service OracleService<DBSID>5. Perform administrative tasks including start up or shutdown6. In the Oracle Fail Safe Manager, take the cluster resource <DBSID>.world online.

For more information on how to start and stop your database with sqlplus, see Starting and Stopping the Database ina Standard Configuration [page 39].

n You use the Oracle Fail Safe ManagerYou use this option, if the database is under control of the Oracle Fail Safe Manager.

.Caution

If the Oracle database resource is online, youmust use the Oracle Fail Safe Manager to stop thedatabase. If you do not use the Oracle Fail Safe Manager, the cluster functionality automaticallyattempts to restart the database.

PrerequisitesYou are logged on as user <SAPSID>adm.

ProcedureThe following procedure describes how to start and stop the database with the Oracle Fail Safe Manager.

n Starting the database1. In the Oracle Fail Safe Manager, right-click the database <DBSID>.world in the Fail Safe group

ORACLE<DBSID>.2. Choose Place online.

n Stopping the database

40 PUBLIC 10/10/2006

Page 47: Oracle 10 2 Upgrade

6 Common Administration Tasks

6.2 Checking Oracle Services

1. In the Oracle Fail Safe Manager, right-click the database resource <DBSID>.world in the Fail Safe groupORACLE<DBSID>

2. Choose Take offline.

.Note

If a pop-up appears, asking you how to take the database offline, choose Immediate.

6.2 Checking Oracle Services

This section describes how to check the status of the Oracle services.

Oracle Services

The following services are available in an Oracle 10g installation:

n Oracle<Oracle_Home_Name>iSQL*Plus

n OracleService<DBSID>

n OracleCSService

n OracleDBConsole<DBSID>

n OracleJobScheduler<DBSID>

n Oracle<Oracle_Home_Name>TNSListener

n Oracle<Oracle_Home_Name>SNMPPeerEncapsulator

n Oracle<Oracle_Home_Name>SNMPPeerMasterAgent

n MSCS Only: OracleMSCSServices

n MSCS Only: Oracle<Oracle_Home_Name>TNSListenerFsl<virtual DB host name>

ProcedureTo check the status of an service, perform the following steps:

1. Choose Start ® Programs ® Administrative Tools ® Services2. Double-click on the required service.n The Status column shows whether a service has been started.

n The Startup Type column shows whether a service is started automatically after booting or whether ithas to be started manually.l To change the startup type, right-click Properties. Select the General tab and choose the startup type

from the dropdown box.l To change the user that is assigned to a service, select the Log On tab andmake the appropriate entries.

6.3 Starting and Stopping Services

This section describes how to stop services in a standard configuration and in an MSCS configuration.

Starting and Stopping Services in a Standard Configuration

1. Right-click onMy Computer and chooseManage.

10/10/2006 PUBLIC 41

Page 48: Oracle 10 2 Upgrade

6 Common Administration Tasks

6.4 Changing or Deleting Oracle Database Parameters

2. Double-click on Services and Applications and select Services.3. Right-click on the service you want to start or stop.4. Choose Start or Stop as required.

Starting and Stopping Services in an MSCS Configuration

n Starting or Stopping the Cluster Service with the Cluster Administrator1. Start the Cluster Administrator.2. Select the node where you want to start or stop the Cluster Service.3. To stop the cluster service, choose File ® Stop Cluster Service.4. To start the service, choose File ® Start Cluster Service

n Starting and Stopping Services with the Cluster Administrator or Fail Safe ManagerYou can start or stop the services listed in the table below with the Cluster Administrator or Fail Safe Manager.To start a resource, set it online. To stop a resource set it offline.

.Caution

If during the migration process the Cluster Service is stopped, you cannot use the Fail Safe Manager orCluster Administrator to stop services. In this case, you have to stop them as described above under Startingand Stopping Services in a Standard Configuration.However, when the Cluster Service is running, youmust use the Cluster Administrator or Fail Safe Manager,otherwise the cluster functionality automatically attempts to restart the services you have stopped.

The following table shows how to start the services.

Service Resource

SAP<SAPSID>_<Instance_No.> Set the SAP cluster resource to online. The SAP systemis started.

OracleService<DBSID> Choose one of the following:l Set the resource <DBSID>.world in the group

ORACLE<DBSID> to online.l In the Oracle Fail Safe Manager, set the Fail Safe Database

<DBSID>.world to online.

Oracle<Oracle_Home_Name>TNSListenerFsl<virtual DB hostname>

Set the corresponding resource in the groupORACLE<DBSID> to online.

OracleMSCSServices Set the resource Oracle Services for MSCS in the Clustergroup to online.

6.4 Changing or Deleting Oracle Database Parameters

Depending on the configuration of the Oracle database, you must use one of the following files to change ordelete the Oracle database parameters:

n If your database is not configured for using a spfile you use the init<DBSID>.ora file.n If your database is configured for using a spfile you use the spfile.

42 PUBLIC 10/10/2006

Page 49: Oracle 10 2 Upgrade

6 Common Administration Tasks

6.5 Determining the Value of SAP System Profile Parameters

Procedure

1. Check the configuration of your Oracle database with the following sqlplus commands:sqlplus /nolog

SQL>connect / as sysdba

SQL>show parameter spfile

2. Check the value of the spfile parameter and perform one of the following steps:n If the value of the parameter spfile is empty, your database is not configured for using a spfile.

Edit the init<DBSID>.ora file to change the parameters.n If a value for the parameter spfile is displayed, your database is configured for using a spfile.

Change the parameters in the spfile as follows:l To set the parameter, enter one of the following:

u If <parameter_value> consists of a string, for example 10.2.0, enter:SQL> alter system set <parameter_name>=’<parameter_value>’ scope = spfile;

u Otherwise enter:SQL> alter system set <parameter_name>=<parameter_value> scope = spfile;

.Note

To find out if your parameter value is a string or a number, use the command: showparameter <parameter_name>

l To delete a parameter, enter:SQL> alter system reset <parameter_name> scope = spfile sid = '*';

.Note

If you get an error during the ‘alter system reset’ command like ORA-32010 : cannot find

entry to delete in SPFILE, you can ignore it, as it only indicates that the entry did notexist in the SPFILE.

6.5 Determining the Value of SAP System Profile Parameters

This section describes how to determine the value of SAP system profile parameters, for example of DIR_CT_RUNand DIR_EXECUTABLE.

ProcedureThe following procedure shows an example how to determine the value of the DIR_CT_RUN parameter.

n To find out the value of DIR_CT_RUN, do one of the following:l If your SAP system is started, use transaction SE38.

Run report rsparam and search for the parameter DIR_CT_RUN.l If your SAP system is not started, open a command prompt and enter: sappfpar pf=<full_path_to

instance_profile> DIR_CT_RUN

10/10/2006 PUBLIC 43

Page 50: Oracle 10 2 Upgrade

6 Common Administration Tasks

6.6 Moving Groups for MSCS

6.6 Moving Groups for MSCS

You can use the Cluster Administrator or the Fail Safe Manager. This sections describes the procedure for both.

Moving Groups with the Cluster AdministratorUse the Cluster Administrator for groups that do not belong to the Oracle database groups:

1. Start the Cluster Administrator with Start < ® Settings> ® Control Panel ® Administrative Tools ® Cluster Administrator.2. On the left-hand pane, under Groups right-click the cluster group you want to move.3. ClickMove group on the context menu.

The group is now moved to another node.

Moving Groups with the Fail Safe ManagerUse the Fail Safe Manager to move the Oracle resources, for example, the database group Oracle<DBSID>:

1. Start the Fail Safe Manager 3.3.4with Start ® Programs ® Oracle <Home_Name_fail safe> ® Oracle Fail Safe Manager2. On the left-hand pane, select the group you want to move.3. Press the right mouse button and clickMove to a Different Node on the context menu.

The group is now moved to another node.

6.7 Starting and Stopping the SAP System

This section describes how to start or stop an SAP system in a:

n Standard Configurationn Microsoft Cluster Service (MSCS) Configuration

If you use MSCS, you start or stop your SAP system with one of the following tools:l The SAP Microsoft Management Console (SAP MMC)l The Cluster Administrator

Starting and Stopping the SAP System in a Standard ConfigurationFor a standard configuration, you use the SAP Microsoft Management Console (SAP MMC) to start or stop your SAPsystem. With a newly installed MMC you can start or stop installed SAP instances locally on the host that youare logged on to. If the MMC is configured for central system administration, you can start the entire systemfrom a single host. To stop the system, you first have to stop all dialog instances before you can stop the otherinstances. For more information on the start or stop order of an SAP system, see SAP Note 897933.

.Note

When you boot the Windows operating system in a standard configuration, the SAP ServiceSAP<SAPSID>_<Instance_number> (for example SAPPRD_00) is always started automatically.

Perform the following steps:

1. Start the SAP MMC on the SAP system host by choosing Start ® Programs ® SAP Management Console.2. Right-click the SAP system node and choose Start or Stop.

All instances listed under the system node, will start or stop in the correct order.

44 PUBLIC 10/10/2006

Page 51: Oracle 10 2 Upgrade

6 Common Administration Tasks

6.7 Starting and Stopping the SAP System

3. If the SAP system is installed on multiple hosts (distributed system), you have the following optionsto start or stop your system:n You start or stop the SAP instances using the SAP MMC on each host.n You add the remote instances to theMMC configuration to start or stop all instances from a singleMMC.

To do so, do one of the following:l You configure the SAP MMCmanually. For more information, see Changing the Configuration of the

MMC in the MMC documentation.l You use the automatic LDAP registration. For more information, see ConfiguringMMC for Active

Directory Service in the MMC documentation.

Starting and Stopping the SAP System in an MSCS ConfigurationIn an MSCS configuration, you start or stop your SAP system using one of the following options:

n The SAP Microsoft Management Console (SAP MMC)To start or stop your SAP system with the SAP MMC, see above.

n The Cluster Administratorl To start the SAP system with the Cluster Administrator, open the Cluster Administrator and set the SAP cluster

resource in the SAP cluster group online.l To stop the SAP system with the Cluster Administrator, set the SAP cluster resource in the SAP cluster

group offline.

10/10/2006 PUBLIC 45

Page 52: Oracle 10 2 Upgrade

SAP AGDietmar-Hopp-Allee 1669190 WalldorfGermanyT +49/18 05/34 34 34F +49/18 05/34 34 20www.sap.com

© Copyright 2006 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 bechanged without prior notice.