Tuesday, July 29, 2014

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

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




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


For Installation,


http://oracle-mssql-dba.blogspot.in/2014/07/oracle-11gupgrade-1120x-version-to.html

Step 2.Run Pre-upgrade Information Tool 

SQL>spool /utlu112i.log
SQL>@ORACLE_HOME/rdbms/admin/utlu112i.sql

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
sql>@?/rdbms/admin/utlrp.sql


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.
#oraupg:/u01/oracle/product/11.2.0/dbhome_1:N
oraupg:/u01/oracle/product/11.2.0.4:N

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


Step 7.Upgrade database manually.

a)
[oracle@localhost admin]$ echo $ORACLE_HOME
/u01/oracle/product/11.2.0.4



cd $ORACLE_HOME/rdbms/admin


sql>sqlplus / as sysdba
sql>spool /tmp/catupgrd.log
sql>startup upgrade
sql>set echo on;
sql>@catupgrd.sql
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.

d)SQL>@$ORACLE_HOME/rdbsm/admin/catuppst.sql

e)SQL>@$ORACLE_HOME/rdbms/admin/utlrp.sql

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.


******************************************FINISH*******************************************************