Sei sulla pagina 1di 38

Oracle 10.2.0.4 upgrade to 11.2.0.

2
Document version 2.6

Oracle 11GR2 upgrade


Created using the Upgrade to Oracle Database 11g Release 2 (11.2): UNIX Version 1.14 as a reference but following the steps in the SAP note 1524205 - Oracle 11.2.0: Database Software Installation v37. Minimum Oracle 10 source release is 10.2.0.4 due to the automated SAP wrapper around the normal Oracle upgrade process. Notes:
Text in this format is for O/S or SAP commands Text in this format is the output from a command.

112INST: As the user ora<sid> - means with the 112 installation environment 112ENV: As the user ora<sid> - means with the 112 runtime environment 102ENV: As the user ora<sid> - means with the existing 102 environment <SID> or - denotes the upper case SAPSID <sid> - denotes the lower case SAPSID <DBSID> or - denotes the upper case DBSID (Usually the same as the SAPSID) <dbsid> - denotes the lower case DBSID (Usually the same as the SAPSID)

Location of source files


This document uses the UK based SAP CD area and so if you are performing an upgrade on a CPH based system then you will need to replace the text: /sapcdarea with /shared/sapcdarea_cph For example, the command
unzip /sapcdarea/ORACLE/11/ORACLE_RDBMS_11.2.0.2_AIX64bit/11ginstall_11202_rev019.zip

for a CPH system becomes


unzip /shared/sapcdarea_cph/ORACLE/11/ORACLE_RDBMS_11.2.0.2_AIX64bit/11ginstall_11202_rev019 .zip

Page 1/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

Table of contents
Oracle 11GR2 upgrade ........................................................................................ 1 Location of source files .................................................................................... 1 Table of contents ............................................................................................ 2 Preparation..................................................................................................... 3 Checking the Correct UNIX Users, Groups, and Authorizations ......................... 3 O/S Kernel requirements............................................................................... 3 File systems................................................................................................. 3 Extract the software ..................................................................................... 4 UPDATE the SAP Installer SN1524205............................................................ 4 Oracle inventory directory............................................................................. 4 Checking the Prerequisites for the Oracle Universal Installer ............................ 5 Installation ..................................................................................................... 6 RUNINSTALLER............................................................................................ 7 SAP Bundle Patch .......................................................................................... 15 Installation End ............................................................................................. 16 Database Structure Upgrade.............................................................................. 17 pre-upgrade status & flashback ................................................................... 17 Review and correct any errors or warnings................................................... 17 Preupgrade tasks ....................................................................................... 19 Oracle Client update to 11.2.0.2 V5 ............................................................. 19 Now for the upgrade! .................................................................................... 21 Confirm that the following environment variables point to Oracle 11.2 directories: ................................................................................................ 21 Link file to avoid brtools errors .................................................................... 21 listener...................................................................................................... 22 database status ......................................................................................... 22 DBUA ........................................................................................................ 22 Checking DBUA upgrade logfiles for error messages...................................... 31 Post installation............................................................................................. 33 Environment .............................................................................................. 33 Remove old bin.......................................................................................... 33 Listener..................................................................................................... 33 New alert log ............................................................................................. 34 start the database ...................................................................................... 34 Note 1431798 - Oracle 11.2.0: Database Parameter Settings ......................... 34 <sid>adm user changes ................................................................................ 35 Setting 112 environment for <sid>adm ....................................................... 35 Profiles...................................................................................................... 35 BRTOOLS 7.20 update ................................................................................ 36 Statistics ................................................................................................... 36 BACKUP .................................................................................................... 36 Startsap .................................................................................................... 37 Drop flashback restore point ....................................................................... 37 Final steps .................................................................................................... 38 Start SAP................................................................................................... 38 ABAP or DUAL STACK dbcheck parameters................................................... 38 END OF DOCUMENT ...................................................................................... 38

Page 2/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

Preparation
Checking the Correct UNIX Users, Groups, and Authorizations 102ENV: As the user ora<sid> peform the following tests:
touch /oracle/write_test rm /oracle/write_test umask 022

O/S Kernel requirements The UNIX team should perform these three steps: Virtual Memory Manager
/usr/sbin/vmo -p -o minperm%=3 -o maxperm%=90 -o maxclient%=90 -o lru_file_repage=0 -o strict_maxclient=1 -o strict_maxperm=0 -o minfree=960 -o maxfree=1088

Characteristics of SYS0
chdev -l sys0 -a maxuproc=16384 -a maxpout=8193 -a minpout=4096 -a ncargs=128

Network tuning parameters


no -p -o tcp_ephemeral_low=9000; no -p -o tcp_ephemeral_high=65500 no -p -o udp_ephemeral_low=9000; no -p -o udp_ephemeral_high=65500

SAPTCE can check the parameters using the commands: Virtual Memory Manager
vmo -L minperm% -L maxperm% -L maxclient% -L lru_file_repage -L strict_maxclient -L strict_maxperm -L minfree -L maxfree

Characteristics of SYS0
lsattr -El sys0 -a maxuproc -a maxpout -a minpout -a ncargs

Network tuning parameters


no -a | grep ephemeral tcp_ephemeral_high tcp_ephemeral_low udp_ephemeral_high udp_ephemeral_low = = = = 65500 9000 65500 9000

File systems Check that the following file systems have been created by the UNIX team: /oracle/stage/112_64 /oracle/<SID>/11202 /oracle/<SID>/oraflash 15GB owned by ora<sid>:dba with 775 perms 15GB owned by ora<sid>:dba with 755 perms 15GB owned by ora<sid>:dba with 755 perms

Check that you have at least 1GB free in /tmp /oracle If you cannot remove old files in /tmp to free up the required space (such as old install directories or logs) then you can specify a new temp area using the environment commands below. Please note that this will be required to be set wherever you are using the 11GINST environment for the ora<sid> user. So cleaning up /tmp is the easier option!
setenv TEMP /var/opt/sap/11g_upg_tmp setenv TMP $TEMP

Page 3/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

Extract the software 102ENV: As the user ora<sid> peform the following:
cd /oracle/stage/112_64 SAPCAR -xvf /sapcdarea/ORACLE/11/ORACLE_RDBMS_11.2.0.2_AIX64bit/Main/51040091/OR111264.SAR; SAPCAR -xvf /sapcdarea/ORACLE/11/ORACLE_RDBMS_11.2.0.2_AIX64bit/Main/51040091/OR211264.SAR; SAPCAR -xvf /sapcdarea/ORACLE/11/ORACLE_RDBMS_11.2.0.2_AIX64bit/Main/51040091/OR311264.SAR; SAPCAR -xvf /sapcdarea/ORACLE/11/ORACLE_RDBMS_11.2.0.2_AIX64bit/Main/51040091/OR411264.SAR; SAPCAR -xvf /sapcdarea/ORACLE/11/ORACLE_RDBMS_11.2.0.2_AIX64bit/Main/51040091/OR511264.SAR; SAPCAR -xvf /sapcdarea/ORACLE/11/ORACLE_RDBMS_11.2.0.2_AIX64bit/Main/51040091/OR611264.SAR; SAPCAR -xvf /sapcdarea/ORACLE/11/ORACLE_RDBMS_11.2.0.2_AIX64bit/Main/51040091/OR711264.SAR;

Note that the above is one very large command string! Once complete you should have the following directories under /oracle/stage/112_64: database client grid examples gateways deinstall

UPDATE the SAP Installer SN1524205


cd database

Check if this step has already been performed on this server:


ls -ltr SAP.SAVE ls: 0653-341 The file SAP.SAVE does not exist.

If it does not exist then:


mv SAP SAP.SAVE unzip /sapcdarea/ORACLE/11/ORACLE_RDBMS_11.2.0.2_AIX64bit/11ginstall_11202_rev019.zip

Oracle inventory directory For systems that have multiple oracle databases installed you will need to ensure that each has its own inventory. For example husadv09 hosts OCC & XPC As the user ROOT:
cd /oracle ls

This listed a single oraInventory, to correct this:


mv oraInventory oraInventory<SID> chown ora<sid>:dba oraInventory<SID> cp -rip oraInventory<SID1> oraInventory<SID2>

Now check the file /etc/oraInst.loc has at least the following: inventory_loc=<a location of the inventory for your <DBSID>> inst_group=dba This means that databases sharing a physical server cannot be upgraded at the same time due to the nature of the /etc/oraInst.loc file.

102ENV: the ora<sid> user take a backup of the current inventory using the commands: cd /oracle (or wherever the inventory is according to the oraInst.loc)
SAPCAR -cvf <SID>102oraInvBak.SAR oraInventory<SID>

Page 4/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

check it is valid using the list command


SAPCAR -tvf <SID>102oraInvBak.SAR

Checking the Prerequisites for the Oracle Universal Installer (AIX only) As the root user: Change to the directory /oracle/stage/112_64/database using the following command as the user root:
cd /oracle/stage/112_64/database ./rootpre.sh ./rootpre.sh output will be logged in /tmp/rootpre.out_11-03-15.09:53:30 Configuring Asynchronous I/O.... Asynchronous I/O is already defined Configuring POSIX Asynchronous I/O.... Posix Asynchronous I/O is already defined Checking if group services should be configured.... Group "hagsuser" does not exist. Creating required group for group services: hagsuser Please add your Oracle userid to the group: hagsuser Configuring HACMP group services socket for possible use by Oracle. The group or permissions of the group services socket have changed. Please stop and restart HACMP before trying to use Oracle.

Or you may see the HACMP part of the output of this script as:
Checking if group services should be configured.... Please confirm your Oracle Clusterware Userid is a member of the group: hagsuser Configuring HACMP group services socket for possible use by Oracle. Please make sure that the group services subsystem is active. Aborting pre-installation procedure. Installations of Oracle may fail.

Ignore the highlighted error if your system is not clustered. Once complete, you can now switch user. 102ENV: As the user ora<sid> peform the following
setenv DISPLAY ng171tdsaputl12:1.0 cd /oracle/stage/112_64/database ./runInstaller -executePrereqs -ignoreSysPrereqs

The -ignoreSysPrereqs option is used as our AIX systems do not have the required o/s patch installed to allow the check to take place. So you can ignore the highlighted Failed comment below.
Your platform requires the root user to perform certain pre-installation OS preparation. The root user should run the shell script 'rootpre.sh' before you proceed with Oracle installation. rootpre.sh can be found at the top level of the CD or the stage area. Answer 'y' if root has run 'rootpre.sh' so you can proceed with Oracle installation. Answer 'n' to abort installation and then ask root to run 'rootpre.sh'. ******************************************************************************** Has 'rootpre.sh' been run by root? [y/n] (n) y Starting Oracle Universal Installer... Checking Temp space: must be greater than 190 MB. Actual 2550 MB Passed Checking swap space: must be greater than 150 MB. Actual 20992 MB Passed Checking monitor: must be configured to display at least 256 colors >>> Could not execute auto check for display colors using command /usr/bin/xdpyinfo. Check if the DISPLAY variable is set. Failed <<<< >>> Ignoring required pre-requisite failures. Continuing... Preparing to launch Oracle Universal Installer from /tmp/OraInstall2011-03-04_10-0436AM. Please wait ...

Page 5/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

Click CLOSE

Installation
102ENV: As the user ora<sid> perform the following steps to set the 112INST for this session. If possible run your telnet windows on RDP host that has no timeout setting.
setenv ORACLE_HOME /oracle/<DBSID>/11202 setenv ORACLE_HOME_SRC /oracle/<DBSID>/102_64 setenv DISPLAY ng171tdsaputl12:1.0 setenv LIBPATH /usr/lib:/lib:/usr/sap/<SID>/SYS/exe/run:/oracle/<DBSID>/11202/lib setenv PATH /oracle/<DBSID>/11202/bin:.:/oracle/<DBSID>:/usr/sap/<SID>/SYS/exe/run:/usr/bin:/etc:/ usr/sbin:/usr/ucb:/usr/bin/X11:/sbin:/usr/java14_64/jre/bin:/usr/java14_64/bin cd /oracle/stage/112_64/database/SAP ./RUNINSTALLER_CHECK

This will open a session on your X host (be patient) and should complete without error. Close the X window and then run
cd /oracle/stage/112_64/database/SAP ./RUNINSTALLER -noinstall

This should complete without error, but may have a warning about the already created filesystem:
. . . . . . . . . . 11ginstall.sh - Oracle Database Software Installation Script Version 11.2.0.2.0 Release Date 2011-03-02 Revision 019 (rel) Copyright (c) Oracle Corporation 2010, 2011. All Rights Reserved. Reference SAP note: 1524205 Supported Oracle Database Release: 11.2.0.2.0 Host : husadv21 Platform : AIX 00C7F3444C00 (64-bit) Date : 2011-03-15 11:13:34

Page 6/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6
. User : orajst . Logfile : /oracle/11ginstall_11202.log . . Command line: -oracle_stage /oracle/stage/112_64/database/SAP/.. -ignoreSysPrereqs noinstall . Ignoring system prerequisite checks ... . . Performing pre-installation checks ... . . (OK) - Got location for Oracle stage from '-oracle_stage' option. . (OK) - Default Setting ORACLE_BASE = /oracle. . (WARNING) - Installation location /oracle/JST/11202 already exists. . (OK) - Run-time location /oracle/JST/112_64 does not yet exist. . (OK) - Inventory pointer file /etc/oraInst.loc exists. . (OK) - Group dba is defined. . (OK) - Group oper is defined. . (OK) - OUI version in stage is 11.2.0.2.0. . (OK) - Old response file /oracle/11ginstall_11202.rsp removed. . (OK) - New response file /oracle/11ginstall_11202.rsp created. . . Pre-installation checks completed. . . Environment settings: . ORACLE_BASE = /oracle . ORACLE_STAGE = . DISPLAY = ng171tdsaputl12:1.0 . DB_SID = JST . . Installation settings: . Oracle release = 11.2.0.2.0 . Oracle stage location = /oracle/stage/112_64/database/SAP/.. . OUI version = 11.2.0.2.0 . Installation location = /oracle/JST/11202 (ALREADY EXISTS) . Run-time location = /oracle/JST/112_64 . Inventory group = dba . SYSDBA group = dba . SYSOPER group = oper . temporary directory = /oracle/11ginstall_11202.tmp . response file = /oracle/11ginstall_11202.rsp . log file = /oracle/11ginstall_11202.log . invPtrLoc option = . installer language = . further OUI options = -ignoreSysPrereqs . . . --- Oracle Universal Installer command line --. LANG=C TMP=/oracle/11ginstall_11202.tmp /oracle/stage/112_64/database/SAP/../runInstaller -responseFile /oracle/11ginstall_11202.rsp -waitForCompletion -ignoreSysPrereqs . --- Oracle Universal Installer command line (end) --. . (INFO) - 11ginstall.sh was started with -noinstall option.

RUNINSTALLER 112INST: as ora<sid> still, check your environment to the installation oracle home
env |grep ORACLE_HOME ORACLE_HOME=/oracle/<DBSID>/11202 ORACLE_HOME_SRC=/oracle/<DBSID>/102_64 cd /oracle/stage/112_64/database/SAP ./RUNINSTALLER Has 'rootpre.sh' been run by root? [y/n] (n) y

Page 7/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

NEXT

YES

Page 8/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

NEXT

NEXT

Page 9/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

NEXT

NEXT (do not feel the need to change it to UK english!!)

Page 10/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

NEXT

NEXT

Page 11/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

YES (is just lost+found)

NEXT

Page 12/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

INSTALL

If you see a warning about not enough space:

Page 13/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

this is due to /oracle being too small and/or too full. Check prereqs of 1GB for /oracle

cd /oracle/<DBSID>/11202 huaixts1# ./root.sh Running Oracle 11g root script... The following environment variables are set as: ORACLE_OWNER= oraxps ORACLE_HOME= /oracle/XPS/11202 Enter the full pathname of the local bin directory: [/usr/local/bin]: The file "dbhome" already exists in /usr/local/bin. Overwrite it? (y/n) [n]: y Copying dbhome to /usr/local/bin ... The file "oraenv" already exists in /usr/local/bin. Overwrite it? (y/n) [n]: y Copying oraenv to /usr/local/bin ... The file "coraenv" already exists in /usr/local/bin. Overwrite it? (y/n) [n]: y Copying coraenv to /usr/local/bin ... Entries will be added to the /etc/oratab file as needed by Database Configuration Assistant when a database is created Finished running generic part of root script. Now product-specific root actions will be performed. Finished product-specific root actions.

Page 14/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

OK

CLOSE

SAP Bundle Patch


112INST: as ora<sid> still we install the SAP bundle patch.

Page 15/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6
cd $ORACLE_HOME pwd /oracle/JST/11202 cp -ip /sapcdarea/ORACLE/11/ORACLE_RDBMS_11.2.0.2_AIX64bit/11202_Patches/SAP_112021_201102_AI X.zip . $ORACLE_HOME/bin/unzip -qd $ORACLE_HOME/sapbundle SAP_112021_201102_AIX.zip 'SAP_112021_201102/OPatch/*' mv $ORACLE_HOME/OPatch $ORACLE_HOME/OPatch-pre-SAP_112021_201102 mv $ORACLE_HOME/sapbundle/SAP_112021_201102/OPatch $ORACLE_HOME/OPatch $ORACLE_HOME/bin/unzip -qd $ORACLE_HOME/sapbundle SAP_112021_201102_AIX.zip 'SAP_112021_201102/MOPatch/*' mv $ORACLE_HOME/MOPatch $ORACLE_HOME/MOPatch-pre-SAP_112021_201102 mv: 0653-401 Cannot rename /oracle/JST/11202/MOPatch to /oracle/JST/11202/MOPatch-preSAP_112021_201102: A file or directory in the path name does not exist. mv $ORACLE_HOME/sapbundle/SAP_112021_201102/MOPatch $ORACLE_HOME/MOPatch

You can now install the SAP Bundle patch using the command below:
/bin/sh $ORACLE_HOME/MOPatch/mopatch.sh -v -s SAP_112021_201102_AIX.zip

There are 30 patches to be applied in this SBP.


Patch Installation Status: -------------------------Skipped 4 of 30 patches since they do not seem to be plain OPatch patches or since they are otherwise not appropriate for installing: @ SAP_112021_201102_AIX.zip!9436324!online (patch number 9436324) @ SAP_112021_201102_AIX.zip!10405795!online (patch number 10405795) @ SAP_112021_201102_AIX.zip!10377476!online (patch number 10377476) @ SAP_112021_201102_AIX.zip!10217802!online (patch number 10217802)

Installation End
You have now successfully installed the oracle 11.2.0.2 software. It is likely that the steps you have followed so far will be run sometime before the database upgrade takes place. As a final action to prepare for that day you can check the current oracle environment: 102ENV: As the ora<sid> user
cd /oracle/<DBSID>/11202/sap/ora_upgrade/pre_upgrade sqlplus / as sysdba SQL> @pre_upgrade_status.sql

Review the output to understand what will need to change on the day of the database upgrade. DO NOT alter anything now. This is just a heads up review of what you may have to change on database upgrade day. STOP HERE.

Page 16/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

Database Structure Upgrade


The day of the database upgrade has arrived. Previously you have completed all of the steps in the pages in this guide. CHECK YOU HAVE A BACKUP BEFORE CONTINUING This is based on the automated scripts from Note 1431793 - Oracle 11.2.0: Upgrade Scripts Logon as <sid>adm stopsap pre-upgrade status & flashback 102ENV: As the ora<sid> user
cd /oracle/<DBSID>/11202/sap/ora_upgrade/pre_upgrade sqlplus / as sysdba startup SQL> col name format a30 SQL> col value format a30 SQL> set pagesize 100 SQL> select name, value, isspecified from v$spparameter where name in ('log_archive_dest','log_archive_duplex_dest','log_archive_dest_1'); NAME VALUE ISSPEC ------------------------------ ------------------------------ -----log_archive_dest /oracle/SLP/oraarch/SLParch TRUE log_archive_duplex_dest FALSE log_archive_dest_1 FALSE

Follow the steps below to reset the first 2 parameters above and to set log_archive_dest_1
SQL> alter system reset LOG_ARCHIVE_DEST scope = spfile sid = '*'; SQL> alter system reset LOG_ARCHIVE_DUPLEX_DEST scope = spfile sid = '*';

If these are not set then you will see message


ERROR at line 1: ORA-32010: cannot find entry to delete in SPFILE

Otherwise you should see message


System altered. SQL> alter system set LOG_ARCHIVE_DEST_1 = 'LOCATION=/oracle/<DBSID>/oraarch/<DBSID>arch' scope = spfile; SQL> alter system set db_recovery_file_dest_size = 10G; SQL> shutdown immediate SQL> startup mount SQL> alter system set db_recovery_file_dest = '/oracle/<DBSID>/oraflash'; SQL> CREATE RESTORE POINT BEFORE_ORA11G GUARANTEE FLASHBACK DATABASE; SQL> SELECT NAME from V$RESTORE_POINT; SQL> alter database open; SQL> @pre_upgrade_status.sql

Review and correct any errors or warnings Parameter warnings


WARNING: --> "shared_pool_size" needs to be increased to at least 472 MB

For parameter warnings such as this, use brtools to increase the size to 480MB. Current value = 201326592 (192 MB) New value = 503316480 (480 MB)
Sqlplus alternative = alter system set shared_pool_size = 503316480 scope = both;

Plan table warning


WARNING: ----> Table(s) PLAN_TABLE exist(s) in SAP schema. The table(s) will get dropped after the upgrade and recreated with new structure. SAP<SID>.PLAN_TABLE

This warning is just for information and no action is required by you.

Page 17/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

SAPCONN Role warning This should have been run as a part of the oracle 10 upgrade but we have encountered some systems where this has not been run. Follow the steps to run this. DEPRECIATED warnings --> remote_os_authent --> background_dump_dest "diagnostic_dest" --> user_dump_dest "diagnostic_dest"

11.1 11.1 11.1

DEPRECATED DEPRECATED replaced by DEPRECATED replaced by

The upgrade process takes care of these parameters for you automatically. No action required. Timezone warning
WARNING: --> Database is using a timezone file older than version 14. .... After the release migration, it is recommended that DBMS_DST package .... be used to upgrade the 10.2.0.4.0 database timezone version .... to the latest version which comes with the new release.

This will be updated automatically during the upgrade so no action required. Remove temporary parameters These can be found using the following select statement:
SELECT name from SYS.V$PARAMETER WHERE name LIKE '\_%' ESCAPE '\';

Although the upgrade will remove these for you, we are going to remove them to avoid any unforeseen issues. So use brtools to remove those shown when using the select command above. For example, for the system XPS they were _first_spare_parameter _cursor_features_enabled _fix_control _sort_elimination_cost_ratio _optim_peek_user_binds _optimizer_mjc_enabled _optimizer_better_inlist_costing Sqlplus alternative to brtools commands
alter alter alter alter alter alter alter system system system system system system system reset reset reset reset reset reset reset "_first_spare_parameter" scope = spfile sid = '*'; "_cursor_features_enabled" scope = spfile sid = '*; "_fix_control" scope = spfile sid = '*'; "_sort_elimination_cost_ratio" scope = spfile sid = '*'; "_optim_peek_user_binds" scope = spfile sid = '*'; "_optimizer_mjc_enabled" scope = spfile sid = '*'; "_optimizer_better_inlist_costing" scope = spfile sid = '*';

Whilst most will be similar for your system you are likely to have different parameters set to this example! Review events (optional check) You can review the events defined for the preupgrade system using commands:
SELECT (translate(value,chr(13)||chr(10),' ')) from sys.v$parameter2 WHERE UPPER(name) like '%EVENT%' AND isdefault='FALSE';

The upgrade will take care of these automatically for you, so it is just a review process with no action required.

Page 18/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

AWR retention warning This consumes space in the SYSAUX tablespace and so would suggest that this is only increased on the Q/V/P systems if not done already. WARNING: ----> AWR retention is too small. Current AWR retention: 7 days. Recommended: 42 or higher See SAP note 1326067. Invalid object warning If you have warnings for invalid objects then run:
SQL> @?/rdbms/admin/utlrp.sql

Restart and rerun 102ENV: Still as the ora<sid> user:


sqlplus / as sysdba shutdown immediate startup SQL> @pre_upgrade_status.sql

The previous warnings should no longer appear Dictionary stats (takes 5-10 mins)
SQL> EXECUTE dbms_stats.gather_dictionary_stats; SQL> exit

Preupgrade tasks 102ENV: Still as the ora<sid> user:


cd /oracle/<DBSID>/11202/sap/ora_upgrade/pre_upgrade sqlplus / as sysdba spool PRE_UPGRADE_TASKS.log @pre_upgrade_tasks.sql spool off exit

Review the PRE_UPGRADE_TASKS.log and fix any issues. The following warning can be ignored:
WARNING: --> Database is using a timezone file older than version 14. .... After the release migration, it is recommended that DBMS_DST package .... be used to upgrade the 10.2.0.4.0 database timezone version .... to the latest version which comes with the new release.

102ENV: Still as the ora<sid> user:


sqlplus / as sysdba alter system switch logfile; exit lsnrctl stop LISTENER_<DBSID> vi /etc/oratab

check there is an entry for your old oracle home <DBSID>:/oracle/<DBSID>/102_64:N: If not, then add it and save the file. Oracle Client update to 11.2.0.2 V5 We will update to 11.2.0.2 V5 as part of this upgrade (if not already done) As the <sid>adm user:
cd /oracle/client ls -ltr

If you see the folder 11x_64 skip down to the next section Client Environment

Page 19/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

If only the 10x_64 folder exists then follow these steps


cd /oracle/client/ mkdir 11x_64 chmod 775 11x_64 cd 11x_64 SAPCAR -xvf /sapcdarea/ORACLE/11/ORACLE_RDBMS_11.2.0.2_AIX64bit/Client11G/OCL_AIX_PPC64/OCL11264.S AR ln -fs instantclient_11202 instantclient huaixts1:xpsadm 17> ls -ltr total 16 drwxr-xr-x 2 astadm sapsys 4096 Nov 26 15:45 instantclient_11202 -r--r--r-1 astadm sapsys 129 Nov 26 15:45 dbclient.lst lrwxrwxrwx 1 astadm sapsys 19 May 05 09:39 instantclient -> instantclient_11202

Client Environment We now have to amend the environment to the new oracle client for both the ora<sid> and <sid>adm users, for example: cd grep 10x .*.* .dbenv.csh: set ADD=/oracle/client/10x_64/instantclient .dbenv.sh: ADD=/oracle/client/10x_64/instantclient .dbenv_husadv22.csh: set ADD=/oracle/client/10x_64/instantclient .dbenv_husadv22.sh: ADD=/oracle/client/10x_64/instantclient Edit these files to replace 10x with 11x. Once done log out and back on as <sid>adm before continuing.
genezi -v Client Shared Library 64-bit - 11.2.0.2.0 System name: Release: Version: Machine: AIX 3 5 00C7F3244C00

Operating in Instant Client mode. Small timezone file = timezone_14.dat Large timezone file = timezlrg_14.dat

BRTOOLS Issue Currently brtools are hard coded to expect the Oracle 10 client. SAP recommend the temporary work around of removing the old 10x_64 client folder and creating a symbolic link:
cd /oracle/client rm 10x_64 ln -fs /oracle/client/11x_64 /oracle/client/10x_64

*** If SAP systems are sharing hardware do not do this until all have been upgraded to 11G and ensure all systems are stopped! ***

Page 20/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

Now for the upgrade!


** run telnet windows on RDP host if possible in case of disconnects** 112INST: As the user ora<sid> with the 112 installation environment (shown below again for convenience) setenv ORACLE_HOME /oracle/<DBSID>/11202 setenv ORACLE_HOME_SRC /oracle/<DBSID>/102_64 setenv DISPLAY ng171tdsaputl12:1.0 setenv LIBPATH /usr/lib:/lib:/usr/sap/<DBSID>/SYS/exe/run:/oracle/<DBSID>/11202/lib setenv PATH /oracle/<DBSID>/11202/bin:.:/oracle/<DBSID>:/usr/sap/<DBSID>/SYS/exe/run:/us r/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin:/usr/java14_64/jre/bin:/usr/java14_6 4/bin

Confirm that the following environment variables point to Oracle 11.2 directories: ORACLE_HOME points to /oracle/<DBSID>/11202 PATH has the 11202 and not 102_64 LIBPATH has the 11202 and not 102_64

Link file to avoid brtools errors


cd $ORACLE_HOME/lib pwd /oracle/JST/11202/lib ln -s libnnz11.so libnnz10.so cd $ORACLE_HOME/sap/ora_upgrade/post_upgrade ./dbua.sap.sh -query Oracle Database Upgrade Release 11.2.0.2 dbua.sap.sh - DBUA wrapper script for SAP Copyright (c) Oracle Corporation 2010. All Rights Reserved. ls: 0653-341 The file /oracle/cfgtoollogs/dbua/XPS/upgrade* does not exist. Source database to be upgraded is >> XPS << Source Oracle Home is >> /oracle/XPS/102_64 << (release 10.2) Target Oracle Home is >> /oracle/XPS/11202 << (release 11.2.0.2) DBUA log directory is >> /oracle/cfgtoollogs/dbua/XPS/upgrade1 << dbua.sap.sh log file is >> /oracle/XPS/11202/sap/ora_upgrade/post_upgrade/dbua.sap.log << Diagnostic destination is set to >> /oracle/XPS/saptrace << Audit file destination is set to >> /oracle/XPS/saptrace/audit << Database Upgrade Assistant is run in non-silent mode. Database Upgrade Assistant will not be started because dbua.sap.sh was started in query mode (-q). Without query mode option Database Upgrade Assistant would be started with the following command: /oracle/XPS/11202/bin/dbua -sid XPS -oracleBase /oracle -oracleHome /oracle/XPS/102_64 -diagnosticDest /oracle/XPS/saptrace -recompile_invalid_objects true -initParam audit_file_dest=/oracle/XPS/saptrace/audit -emConfiguration NONE upgradeTimezone -postUpgradeScripts /oracle/XPS/11202/sap/ora_upgrade/post_upgrade/post_upgrade_tasks.sql,/oracle/XPS/1120 2/sap/ora_upgrade/post_upgrade/set_remote_os_authent.sql,/oracle/XPS/11202/sap/ora_upg rade/post_upgrade/set_compatible.sql,/oracle/XPS/11202/sap/ora_upgrade/post_upgrade/sa puprof_profile.sql,/oracle/XPS/11202/sap/ora_upgrade/post_upgrade/post_upgrade_checks. sql

Page 21/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

listener The above query will copy the listener files into the new oracle home, check with:
ls -ltr $ORACLE_HOME/network/admin

database status Ensure that the database is started under the old oracle home and environment variables still. (if you have followed this guide then it should be!) You can check that the last command in the alert log was not a shutdown if you wish:
tail -f -10 $SAPDATA_HOME/saptrace/background/alert_<DBSID>.log Thu Mar 24 13:19:58 2011 Thread 1 advanced to log sequence 928 (LGWR switch) Current log# 4 seq# 928 mem# 0: /oracle/SLT/origlogB/log_g14m1.dbf Current log# 4 seq# 928 mem# 1: /oracle/SLT/mirrlogB/log_g14m2.dbf Thu Mar 24 13:23:16 2011 Completed checkpoint up to RBA [0x3a0.2.10], SCN: 35164304

DBUA 112INST: As the user ora<sid> still you can now run
cd $ORACLE_HOME/sap/ora_upgrade/post_upgrade ./dbua.sap.sh

NEXT

Page 22/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

NEXT: Note that the archive option above will appear if flashback is disabled, and the degree of parallelism gives an idea of how performance the server is i.e. 1 is slow!

OK - 1.5GB space for oraarch is more than enough

Page 23/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

NEXT

Check the Fast Recovery Area (flashback) and NEXT

Page 24/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

NEXT

Page 25/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

FINISH

Page 26/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

After 5 mins - 7%

After 15 mins - 20% After 30 mins - 35% After 40 mins - 51% After 70 mins - 80% Click OK to accept the DEPRECIATED parameters - this was hidden behind the main window for me and only found as it seemed to be stuck and I moved screens around.

Page 27/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

You will see this warning:

OK, then after another minute or so it will appear again

OK

Page 28/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

IGNORE (occurs around 87% during upgrade timezone)


You can ignore either of the error messages ORA-32006 / ORA-32004 reported by DBUA. They are related to the parameter setting remote_os_authent=true which is currently still required for SAP.

OK

Page 29/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

Page 30/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

Click on Configure Database Passwords

Enter the password for SYSTEM as 11gSAPTCE Then click OK, then CLOSE

Checking DBUA upgrade logfiles for error messages OS> cd <ora_upgrade>/post_upgrade OS> /bin/sh check_dbua_logs.sh
check_dbua_logs.sh: Check DBUA Logs for Error Messages DBUA upgrade directory: '/oracle/cfgtoollogs/dbua/SLT/upgrade1' DBUA upgrade directory: '/oracle/cfgtoollogs/dbua/SLT/upgrade1' (last)

Page 31/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

===== Last DBUA Log Directory ===== '/oracle/cfgtoollogs/dbua/SLT/upgrade1' Number of Logfiles: 8 ===== DBUA Log DBUA Log file: DBUA Log file: DBUA Log file: DBUA Log file: DBUA Log file: DBUA Log file: DBUA Log file: DBUA Log file: Files ===== 'CustomScript.log' 'Oracle_Server.log' 'PostUpgrade.log' 'PreUpgrade.log' 'UpgradeTimezone.log' 'Upgrade_Directive.log' 'sqls.log' 'trace.log'

===== Checking DBUA Log Files ===== CustomScript.log: ORA-32004: obsolete or deprecated parameter(s) specified for RDBMS instance ORA-32004: obsolete or deprecated parameter(s) specified for RDBMS instance Oracle_Server.log: ORA-01034: ORACLE not ORA-01034: ORACLE not ORA-01034: ORACLE not ORA-01034: ORACLE not PostUpgrade.log: PreUpgrade.log: ORA-01034: ORACLE not available UpgradeTimezone.log: Upgrade_Directive.log: sqls.log: trace.log: ===== DONE =====

available available available available

11GENV: After the database upgrade, the instance is running with ORACLE_HOME still set to the installation location.
cd /oracle/<DBSID>/11202/sap/ora_upgrade/post_upgrade/ sqlplus / as sysdba SQL> @post_upgrade_status.sql .... Component ID Version Status .... CATALOG 11.2.0.2.0 VALID .... CATPROC 11.2.0.2.0 VALID WARNING: ----> AWR retention is too small. Current AWR retention: 7 days. Recommended: 42 or higher See SAP note 1326067.

This can be ignored for non production / important systems. Production systems should already have this value set. If not then follow the steps in the note 1326067.
WARNING: ----> FAILED_LOGIN_ATTEMPTS <> UNLIMITED in DEFAULT PROFILE. See SAP note 951167.

To resolve this warning use the command:


SQL> ALTER PROFILE DEFAULT LIMIT FAILED_LOGIN_ATTEMPTS UNLIMITED; WARNING: ----> PASSWORD_LIFE_TIME <> UNLIMITED in DEFAULT PROFILE.

This can be ignored as the sap user does not use the default profile, which as of 11.2.0.2 now has a password expiry of 180 days. Instead it uses the SAPUPROF profile which still has unlimited. Other users such as SYSTEM will be affect by this change.
WARNING: ----> Parameter COMPATIBLE is not set correctly. COMPATIBLE must be set to 11.2.0. Current value is: 10.2.0 See SAP note 1431798.

Page 32/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

We cannot fix this compatible warning just yet due to our Flashback restore point so we will fix it later in this document. If all else is well, shutdown the database.
sqlplus / as sysdba SQL> shutdown immediate SQL> exit ps -ef|grep -i ora

If there are no oracle processes running then exit the O/S session. If there are then stop them.

Post installation
Environment 102ENV:Logon to a new session as ora<sid> Show all the env files that have the old oracle home specified.
grep 102_64 .* .dbenv.csh .dbenv.sh .dbenv_huaixts1.csh .dbenv_huaixts1.sh

Amend the files to the new oracle home --IMPORTANT-- use the symbolic link destination of /oracle/<DBSID>/112_64 and not the installation location of /oracle/<DBSID>/11202. For example:
vi .dbenv.csh :g/102/s//112/g :wq

Once all have been edited and saved, log out of ora<sid> session. 112ENV:Logon to a new session as ora<sid> Use the command env to check the environment shows the new oracle home.

Remove old bin 112ENV: As ora<sid>


cd /oracle/<DBSID>/102_64 mv bin bin.old cd which unzip /oracle/JST/112_64/bin/unzip

Listener 112ENV: As ora<sid>


vi /oracle/<DBSID>/112_64/network/admin/listener.ora

Change any 102_64 to 112_64 in this file. Also check that the name of the listener contains the <SID>, for example:
################ ADMIN_RESTRICTIONS_LISTENER = on LISTENER_JST = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = IPC) (KEY = JST.WORLD)

Once edited start the listener:


lsnrctl start LISTENER_<SID>

Page 33/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6
LSNRCTL for IBM/AIX RISC System/6000: Version 11.2.0.2.0 - Production on 16-MAR-2011 08:32:24 Copyright (c) 1991, 2010, Oracle. All rights reserved.

Starting /oracle/JST/112_64/bin/tnslsnr: please wait... TNSLSNR for IBM/AIX RISC System/6000: Version 11.2.0.2.0 - Production System parameter file is /oracle/JST/112_64/network/admin/listener.ora Log messages written to /oracle/diag/tnslsnr/husadv21/listener_jst/alert/log.xml Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=JST.WORLD))) Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=JST))) Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=husadv21)(PORT=60000))) Connecting to (ADDRESS=(PROTOCOL=IPC)(KEY=JST.WORLD)) STATUS of the LISTENER -----------------------Alias LISTENER_JST Version TNSLSNR for IBM/AIX RISC System/6000: Version 11.2.0.2.0 Production Start Date 16-MAR-2011 08:32:26 Uptime 0 days 0 hr. 0 min. 1 sec Trace Level off Security ON: Local OS Authentication SNMP ON Listener Parameter File /oracle/JST/112_64/network/admin/listener.ora Listener Log File /oracle/diag/tnslsnr/husadv21/listener_jst/alert/log.xml Listening Endpoints Summary... (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=JST.WORLD))) (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=JST))) (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=husadv21)(PORT=60000))) The listener supports no services The command completed successfully

New alert log 112ENV: As ora<sid> The new alert log is located in: /oracle/<DBSID>/saptrace/diag/rdbms/<dbsid>/<SID>/trace The old alert log and traces can be removed: cd /oracle/<DBSID>/saptrace/background rm * cd /oracle/<DBSID>/saptrace/usertrace rm * start the database 112ENV: As ora<sid>
sqlplus / as sysdba SQL*Plus: Release 11.2.0.2.0 Production on Wed Mar 16 08:38:53 2011 Copyright (c) 1982, 2010, Oracle. All rights reserved.

Connected to an idle instance. SQL> startup ORA-32004: obsolete or deprecated parameter(s) specified for RDBMS instance ORACLE instance started. Total System Global Area 1787138048 bytes Fixed Size 2220488 bytes Variable Size 905973304 bytes Database Buffers 872415232 bytes Redo Buffers 6529024 bytes Database mounted. Database opened.

Note 1431798 - Oracle 11.2.0: Database Parameter Settings Review - but in applying the sap patch bundle all relevant parameters seem to have been applied correctly. Further information can also be found in : Note 1289199 - Information about Oracle parameters Page 34/38 SAPTCE RMG 30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6

<sid>adm user changes


Logon as <sid>adm Setting 112 environment for <sid>adm Logon as <sid>adm. Show all the env files that have the old oracle home specified.
grep 102_64 .* .dbenv.csh .dbenv.sh .dbenv_huaixts1.csh .dbenv_huaixts1.sh

Amend the files to the new oracle home --IMPORTANT-- use the runtime symbolic link destination of /oracle/<DBSID>/112_64 and not the installation location of /oracle/<DBSID>/11202. For example:
vi .dbenv.csh :g/102/s//112/g :wq

Once all have been edited and saved, log out of <sid>adm session and back on again. Use the command env to check the environment shows the new oracle home.
husadv21:jstadm 3> env |grep PATH PATH=/oracle/JST/112_64/bin:.:/home/jstadm:/usr/sap/JST/SYS/exe/run:/usr/bin:/etc:/usr /sbin:/usr/ucb:/usr/bin/X11:/usr/java14_64/jre/bin:/usr/java14_64/bin LOCPATH=/usr/lib/nls/loc NLSPATH=/usr/lib/nls/msg/%L/%N:/usr/lib/nls/msg/%L/%N.cat LIBPATH=/usr/lib:/lib:/usr/sap/JST/SYS/exe/run:/oracle/client/10x_64/instantclient which unzip /oracle/JST/112_64/bin/unzip

Profiles 112ENV: Logon as <sid>adm cdpro Profiles may contain reference to oracle home - if they do then amend it. DIR_ORAHOME DIR_CLIENT_ORAHOME DIR_SERVER_ORAHOME Set DIR_ORAHOME and DIR_CLIENT_ORAHOME in the instance profiles to the corresponding values of the ORACLE_HOME environment variable of the <sid>adm user. These variables point to the ORACLE_HOME used by the application server. 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. Also check the tnsnames.ora file in /sapmnt/<SID>/profile/oracle In case it has references to the old oracle home. You must also add in a line for the LISTENER into the tnsnames.ora file, for example:
LISTENER_NWD.WORLD = (ADDRESS = (COMMUNITY = SAP.WORLD)(PROTOCOL = TCP)(HOST = husadv07)(PORT = 61570))

The entry for your system can be copied from the oracle home tnsnames.ora file. View this file using
pg $ORACLE_HOME/network/admin/tnsnames.ora # tnsnames.ora Network Configuration File: /oracle/NWD/11202/network/admin/tnsnames.ora # Generated by Oracle configuration tools.

Page 35/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6
NWD.WORLD = (DESCRIPTION = (ADDRESS = (COMMUNITY = SAP.WORLD)(PROTOCOL = TCP)(HOST = husadv07)(PORT = 61570)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = NWD) ) ) LISTENER_NWD.WORLD = (ADDRESS = (COMMUNITY = SAP.WORLD)(PROTOCOL = TCP)(HOST = husadv07)(PORT = 61570))

Copy the LISTENER_<SID> line into the /sapmnt/<SID>/profile/oracle/tnsnames.ora file. BRTOOLS 7.20 update As root: Use either the Unicode (UC) or Non-Unicode update depending on your system: Filenames either: UC_DBATL720O10_13-20005243.SAR or NUC_DBATL720O10_13-20005193.SAR Ive used the Unicode filename in the example below.
cd /sapmnt/<SID>/exe ./SAPCAR -xvf /sapcdarea/ORACLE/11/ORACLE_RDBMS_11.2.0.2_AIX64bit/BRTOOLS720/UC_DBATL720O10_1320005243.SAR SAPCAR: processing archive /sapcdarea/ORACLE/11/ORACLE_RDBMS_11.2.0.2_AIX64bit/BRTOOLS720/UC_DBATL720O10_1320005243.SAR (version 2.01) x brarchive x brbackup x brconnect x brrecover x brrestore x brspace x brtools x dbatoolsora.lst x dbatoolsora.mf x initSID.sap x libsbt.o x sapconn_role.sql x sapdba_role.sql x sapuprof_profile.sql SAPCAR: 14 file(s) extracted ./saproot.sh <SID> Preparing /usr/sap/JST/SYS/exe/run/brbackup ... Preparing /usr/sap/JST/SYS/exe/run/brarchive ... Preparing /usr/sap/JST/SYS/exe/run/brconnect ... Preparing saposcol ... Preparing icmbnd ... done

Statistics Gather Oracle optimizer statistics by executing the following commands as the 112ENV: As ora<sid>: brconnect -u / -c -f stats -t system_stats ## Takes < 5 mins brconnect -u / -c -f stats -t oradict_stats ## Takes < 15 mins brconnect -c -u / -f stats -t all -f collect -p 4 ## Takes < 10 mins unless stats have not been run on this system for a while in which case it could take +4 hours! BACKUP 112ENV: As ora<sid> You will first need to copy in the dbs backup files

Page 36/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6
cd cp cp cp cp cd 102_64/dbs *.utl ../../112_64/dbs/ init<DBSID>.online.sap ../../112_64/dbs/ init<DBSID>.offline.sap ../../112_64/dbs/ init<DBSID>.archive.sap ../../112_64/dbs/ ../../112_64/dbs

edit the .sap & .utl files you just copied and use the command
:g/102/s//112/g

to amend to the new home. Next we need to edit the files in /etc/opt/sap
cd /etc/opt/sap cp -ip <sid>_backup.conf <sid>_backup.conf.ora10 vi <sid>_backup.conf

search for -u in this file and check that when shown in a command it does not have u system/manager but instead just -u / For example, this is correct:
OFFLINE_BRBACKUP() { EX_CMD_LINE="brbackup -p ${OFFLINE_PROF} -u / -c -d util_file -t offline _force -m all"

Then as root
cd /var/opt/sap/logs/<SID>_LOGS ls -ltr total 16 drwxr-xr-x 2 root system drwxr-xr-x 2 root system drwxr-xr-x 2 root system mkdir OFFLINE

4096 Mar 23 19:10 ONLINE 4096 Mar 24 14:02 ARCHIVE 256 Mar 24 16:41 OFFLINE

If there is no OFFLINE directory then create one using then run


/opt/sap/bin/<SID>_VERITAS_offline_bup

Startsap Once the backup and stats are complete, startsap. Check the systeminfo page for java / dual stack and ST04 for abap / dual stack

Drop flashback restore point Once you are happy all is well AND you have a backup then the flash restore point should be dropped. 112ENV: As ora<sid>
sqlplus / as sysdba SQL> SELECT NAME from V$RESTORE_POINT WHERE guarantee_flashback_database = 'YES'; NAME -------------------------------------------------------------------------------BEFORE_ORA11G SQL> DROP RESTORE POINT <NAME>; Restore point dropped. SQL> create pfile from spfile; SQL> alter system set compatible='11.2.0' scope = spfile;

Page 37/38

SAPTCE RMG

30 Mar 2011

Oracle 10.2.0.4 upgrade to 11.2.0.2


Document version 2.6
SQL> shutdown immediate

Final steps
Start SAP As the user <sid>adm, run the command:
startsap

ABAP or DUAL STACK dbcheck parameters Using transaction DB17 amend the parameters: COMPATIBLE <> 11.2.0 LOG_BUFFER >< 6062080 MAX_DUMP_FILE_SIZE < 100000,10000 OPTIMIZER_INDEX_COST_ADJ <> 100 Example screenshot:

Once complete run a CHECKDB using transaction DB13

END OF DOCUMENT

Page 38/38

SAPTCE RMG

30 Mar 2011

Potrebbero piacerti anche