Tuesday, July 29, 2014

Oracle 11g:Upgrade 11.2.0.x version to latest patchset:Upgrade

Oracle 11g:Upgrade 11.2.0.x version  to latest patchset:Upgrade 

Once We finish the installation of on different then we will go further for upgrade database.

For Installation,


Step 2.Run Pre-upgrade Information Tool 

SQL>spool /utlu112i.log

Check timezone .Need to upgrade if it is require by tool.

Step 3.Run dbupgdiag.sql.Check any invalid objects in dba_registry.
Valid all Dba_registry object by running utlrp.sql

sql>sqlplus / as sysdba

Step 4.Backup database.

a)take rman backup with latest spfile & controlfile.
b)take cold backup by mount the database after shutdown normal db.

Step 5.Shut down database normal.

SQL>shutdown normal.

Step 6.Set New Oracle_HOME,PATH,LIBRARY_PATH.Copy tnsnames.ora,listener.ora,spfile,pfile & password to new oracle_home location.Update /etc/oratab.

a)update oratab.

b)export ORACLE_HOME=/u01/oracle/product/
   export ORACLE_SID=oraupg
c) Copy pfile,spfile & password files
cp *ora /u01/oracle/product/
d)Copy tnsnames.ora,listener.ora & sqlnet.ora
cp *ora /u01/oracle/product/

Step 7.Upgrade database manually.

[oracle@localhost admin]$ echo $ORACLE_HOME

cd $ORACLE_HOME/rdbms/admin

sql>sqlplus / as sysdba
sql>spool /tmp/catupgrd.log
sql>startup upgrade
sql>set echo on;
sql>spool off;
sql>shutdown normal

catupgrd.sql will take around 5 hours to finish on single database.Do parallel if more than 1 databases.

b)Check catupgrd.sql spool file for errors.

c)Restart database normal.



f)Run dbupgdiag.sql scirpt for invalid objects in dba_registry. and no invalid objects in dba_objects.

Step 8.Gather stats of whole database.