SAP Oracle Upgrade 11G to 12C on AIX
Summary:-
This document contains the steps that how to do the oracle upgrade 11 G to 12 C. I have gathered the information from some SAP Notes and upgrade document from SAP site. The following method will reduce the downtime of SAP application.First install the oracle database software only and then do the upgrade using DBUA method.
Author: Brindavan Mookaiah
Designation: SAP BASIS Consultant
Table of content:-
1) Take full backup of database ......................................................
2) Download the software required for the upgrade............................
3) Check and, if necessary, set the DISPLAY environment variable ..
4) Configure Secure Storage in File System.....................................
5) Migrate to the Oracle Database Software Owner oracle................
6) Extract the Oracle software........................................................
7) Install the Oracle database software ...........................................
😎 Run the pre-upgrade scripts........................................................
9) Upgrade from 11g to 12G with using DBUA method.....................
10) Performa the post upgrades scripts...........................................
11) Perform the post upgrade steps.................................................
Oracle 12c Architecture:-
Information on eye :-
There are two main SAP note need to go through before upgrading oracle database.
Oracle Upgrade requirements to meet the software:-
1) Database Direct upgrade 10.2.0.5.0/11.2.0.2.0 / 11.2.0.3.0/11.2.0.4.0 upgrade to 12.1.0.2.0
2) Oracle Database 12c Release 1 (12.1) is only released and certified for SAP products running with SAP BASIS 7.00 and above,
and SAP kernel release 7.21 EXT and above
3) OS level fix required to fix during upgrade or before.
4) create filesystem like " /oracle/SID/121"
1) Take full backup of database
2) Download the software required for the upgrade
3) Check and, if necessary, set the DISPLAY environment variable
4) Configure Secure Storage in File System
5) Migrate to the Oracle Database Software Owner oracle
Create the directory to place the extracted software:
● Oracle software stage directory
● Oracle inventory directory
Procedure 1.
For the extraction of the software for Oracle Database 12c Release 1 (12.1.0.2)
create the staging directory:
$ mkdir -p /oracle/stage/12102
$ chmod 755 /oracle/stage/12102
Example
$ cd /oracle/stage/12102
$ SAPCAR -xvf /OR112164.SAR
$ SAPCAR -xvf /OR212164.SAR
Process Flow
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
For AIX, HP-UX, Solaris SPARC:
/var/opt/oracle/oraInst.loc ○
For Linux: /etc/oraInst.loc
inventory_loc= <path_to_oracle_inventory>
Make a copy of the inventorty
$ cp -r oraInventory oraInventory..SAVE
Note: check the patch level of the RUNINSTALLER and check in SAP Note 1915301 whether a higher version is available. Update the higher version if required.
7) Update the SAP RUNINSTALLER installation scripts.
Note: check the patch level of the RUNINSTALLER and check in SAP Note 1915301 whether a higher version is available. Update the higher version if required.
Login to the OS level with ora_sid or X-manager and go the directory where the media file available.Install Oracle Database Release 12.1 software, see SAP Note 1915301.
For Example:
$ cd /oracle/stage/121/database/SAP
$ ./RUNINSTALLER –version
During installation step it will ask to apply missing OS patches and OS packages and set OS kernel parameters as recommended by the OUI
On AIX, call the script rootpre.sh as user root:
$ /oracle/stage/12102/database/rootpre.sh.
You can find the oracle installation software screen shot in following link this might be same.
Oracle12c Database Installation steps
3) You need to install the current (or latest) SAP bundle patch (SBP) into the new Oracle home once the patch done. You must install the SBP using the Oracle tool MOPatch. For more details see SAP Note 1027012. To install the generic patch, see also SAP Note 1915315.
Procedure
The installation of the SBP consists of these steps: 1. The installation of the SBP software into the Oracle home. 2. The change of the database structure and database properties (dictionary, parameter, properties)
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Note : Once the installation binary done then run the Oracle pre-upgrade scripts check in SAP Note: 1915315.
Check the environmental ORACLE_HOME, ORACLE_SID and ORACLE_BASE. Make sure that ORACLE_HOME is set to the value of the current Oracle home.
😎 Run the pre-upgrade scripts
Login into the OS level with ora_sid user.
For example:
$ cd /oracle//12102/sap/ora_upgrade/pre_upgrade
$ sqlplus / as sysdba
SQL> @pre_upgrade_tasks.sql
@pre_upgrade_checks.sql
Recommendation set parameter before upgrade:
remote_os_authent=TRUE.
COMPATIBLE is set to a value < 11, do not change this parameter before the upgrade from 10.2 to 12c although this is recommended by the pre-upgrade script.
Stop SAP Application
Loginto OS level with ORA_ADM and stop SAP
$ stopsap r3
You can also stop the SAP application server with the sapcontrol tool:
$ sapcontrol -nr -function Stop
Make sure that the software owner <ora_swo> has write permissions (664) on the oratab file, which is
either /etc/oratab or /var/opt/oracle/oratab, depending on your operating system.
● Make sure that oratab contains the entry <DBSID>:<Oracle_home>:N
Example:-
Oracle 11g: OQ1:/oracle/OQ1/112_64: N
Oracle 10g: OQ1:/oracle/OQ1/102_64: N
Set the environment variables ORACLE_HOME_SRC and ORACLE_HOME_TGT, DB_SID, and ORACLE_BASE before you run the scrpit.
Set ORACLE_HOME_SRC and ORACLE_HOME_TGT.
9) Upgrade from 11g to 12G with using DBUA method
Start the DBUA. dbua.sap.sh is a wrapper script for 11g To 12C, once the upgrade done then run the post-upgrade tasks.
Loginto the OS level with ora_sid user
$ ./dbua.sap.sh
Note : This is only reference screen shot.
This will tell the source database and target database for upgrade. If the location path are ok then click --> Next
Click --> Next
On the Upgrade Options screen, select the following fields:
The next screen will ask to select the database type like EM cloud control or EM express and then click --> Next
Do not select any of the checkboxes for Moving database and then click --> Next
The Network Configuration screen ignore and go for default selection and then click --> Next
The Recovery Options screen select the option “I have my own backup” and chose --> Next
On the Summary screen, review the Database Upgrade Summary and if you satisfied the click --> Finish
8. The upgrade will start and once it finished then Click on Upgrade Results to see the results of the upgrade. 11. On the Results screen, after reviewing the upgrade results.
Click Close to close the DBUA.
11) Perform the post upgrade steps
1. You update the SQL*Net configuration files
Logininto the OS level with ora_sid
"The easiest method to do this is to just copy the complete LISTENER_ entry from the file /network/admin/tnsnames.ora and add this entry unchanged to the file in /network/admin and $TNS_ADMIN/tnsnames.ora on the SAP side"
2. You check the symbolic link for the runtime Oracle home.
Create symbolic link go the directory
$ cd /oracle/DBSID
$ ln -s /oracle/DBSID/12102 /oracle//121
3. You adapt the environment of the adm user.
Log on as user adm and adapt the variables listed below in the .dbenv* files. 2. Set the ORACLE_HOME environment variable to new Oracle home,
$ export ORACLE_HOME=/oracle/SID/121
$ export ORACLE_BASE
Check the environment with:
$ env | grep ORACLE_HOME
$ env | grep ORACLE_BASE
$ env | grep PATH (this should no longer contain a reference to 112_64)
4. You adapt the environment of the ora user.
5. You start the database and listener process as user.
5.1. Log on as the Oracle database software owner ora, for example, oracle.
5.2. For user oracle, set the environment via oraenv or coraenv.
5.3. Start the listener and then start the database: lsnrctl start
sqlplus / as sysdba
SQL> startup
5.4. After the database upgrade, change the entry :/oracle//12102:N in /etc/oratab or /var/opt/oracle/oratab so that it now looks as follows: :/oracle//121:N
6. You perform post-upgrade checks. Refer Note : SAP Note 1915315
1. Logon into the OS level with ora_sid .
$sqlplus / as sysdba
SQL> @?\rdbms\admin\utlu121s.sql
SQL> @post_upgrade_tasks.sql (if you have not already executed this with DBUA)
SQL> @post_upgrade_checks.sql
7. You perform post-upgrade tasks.
Login into os level with sapsid_adm user and run the below command You can perform this later if required.
$brconnect -u / -c -f stats -t system_stats
$ brconnect -u / -c -f stats -t oradict_stats
$ brconnect -u / -c -f stats -t all -f collect -p 4
8. You update the Oracle Instant Client.
Create the new client directory:
$ mkdir -p /oracle/client/12x
$ cd /oracle/client/12x
unpack the client software:
$ SAPCAR -xvf <oracle_client_DVD>/OCL/OCL12164.SAR
$ cd /oracle/client/12x ln -s instantclient_12102 instantclient
Create the symbolic link for BR*Tools 7.40: 1.
$ cd /oracle/client
mv 11x_64 11x_64_save
$ ln -s /oracle/client/12x /oracle/client/11x_64
9. Update BR*Tools.
You need to update the Brtool for more information see SAP Note : 2087004, 12741, and 1598594.
10. You back up the database.
Perform the full backup of database.
brbackup –u / –type offline –mode all –device disk –compress yes –language E
11. If required and not yet done, update the SAP executables.
SAP kernel supported for Oracle 12c kernel should 7.21EXT
12. If not yet done, configure the Secure Storage in the File System (SSFS).
13. For systems with Java components – AS Java or AS ABAP+Java – update the JDBC driver references.
If your SAP software is version 7.0 or below, follows SAP Note 867976 to change the JDBC driver.
If your SAP software is version 7.1 or higher, change the reference to the JDBC driver in the instance profile as described below. Open the file with your text editor and search for property j2ee/dbdriver.
Replace the old driver location with the new one:
/oracle/client/<Oracle_client_major_version>x/instantclient/
<java_class_archive>.jar
Where <Oracle_client_major_version> is the major version of the Oracle client that you are using after
this upgrade. So for example, if you are now using Oracle 12.1, set the new driver location to /oracle/
client/12x/instantclient/<java_class_archive>.jar.
14. You restart the SAP system.
Stopsap r3
15. You configure the new features for Oracle Database 12c Release 1 (12.1). see SAP note : 1914631.
16. If not already done, migrate from software owner ora to software owner oracle, as described in Migrating to the Oracle Database Software Owner oracle.
17. You deinstall the old Oracle Home: SAP Note 1915314
18. You make sure that you have installed the required support packages for the SAP kernel supported for Oracle 12c. For AS Java or AS ABAP+Java, see also SAP Note 1777021.
Note : You may get some issue with Operating system like DBA groug or something please get tocuh with AIX team to fix the issue.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
10 | |
7 | |
5 | |
5 | |
4 | |
4 | |
3 | |
3 | |
3 |