I will explain how to upgrade Oracle Database from Oracle 11g to Oracle 12c in this article.
Read previous article to learn Oracle database upgrade methods.
I have chosen DBUA ( Database Upgrade Assistant ) in this upgrade.
Before upgrade, connect to the Oracle 11g database and query the database name and version as follows.
I’ll show you new version after the upgrade is completed.
bash-4.1$ sqlplus / as sysdba SQL*Plus: Release 126.96.36.199.0 Production on Sun Nov 17 10:07:24 2014 Copyright (c) 1982, 2013, Oracle. All rights reserved. Connected to: Oracle Database 11g Enterprise Edition Release 188.8.131.52.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options SQL> select instance_name from v$instance; INSTANCE_NAME ---------------- POCDB SQL> select version from v$instance; VERSION ----------------- 184.108.40.206.0 SQL>
Read following article to install Oracle 12c software. I won’t explain how to install Oracle database 12c software in this post.
After Oracle 12c Software Only installation is completed, then Set New Oracle 12c Profile. Content of Oracle 12c bash Profile is like following.
bash-4.1$ vim 12cProfile_db ORACLE_HOSTNAME=Kuheylan; export ORACLE_HOSTNAME ORACLE_BASE=/oracle; export ORACLE_BASE ORACLE_HOME=$ORACLE_BASE/product/220.127.116.11; export ORACLE_HOME ORACLE_SID=POCDB; export ORACLE_SID ORACLE_TERM=xterm; export ORACLE_TERM PATH=/usr/sbin:$PATH; export PATH PATH=$ORACLE_HOME/bin:$PATH; export PATH LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib; export LD_LIBRARY_PATH CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib; export CLASSPATH if [ $USER = "oracle" ]; then if [ $SHELL = "/bin/ksh" ]; then ulimit - p 16384 ulimit -n 65536 else ulimit -u 16384 -n 65536 fi fi
Step -1: Set 12cProfile_db Profile and execute dbua tool like following.
bash-4.1$ . 12cProfile_db bash-4.1$ dbua
Step -2: Choose Upgrade Oracle Database option.
Step -3: Select Database in this step.
Step -4: Validations steps, Click Next.
Step -5: This step is very important to specify options how to uprade.
1- In the First option, select parallelism count for upgrade. Here we need to determine the parallelism as the number of CPUs the server has. Server CPU Count> = Parallel count.
2- Check ” Recompile invalid objects during post upgrade ” option and select 3 parallelism.
4- Gather stats before upgrade, If your database is very big, then you can unselect it.
Step -6: If you have Custom SQL Scripts, type it in this step.
Step -7: You can Configure Enterprise manager Database Express or Register with Enterprise Manager Cloud control.
Step -8: Don’t select if you don’t move database files to new location.
Step -9: Select listener like following.
Step -10: I have my own backup and restore strategy so I have chosen second option.
Step -11: Database upgrade summary step. You can check it before upgrade.
Step -12: Upgrade is completed without errors.
Step -13: Connect to database and query version again.
bash-4.1$ sqlplus / as sysdba SQL*Plus: Release 18.104.22.168.0 Production on Sun Nov 17 17:39:21 2014 Copyright (c) 1982, 2013, Oracle. All rights reserved. Connected to: Oracle Database 12c Enterprise Edition Release 22.214.171.124.0 - 64bit Production With the Partitioning, OLAP, Advanced Analytics and Real Application Testing options SQL> select instance_name from v$instance; INSTANCE_NAME ---------------- POCDB SQL> select version from v$instance; VERSION ----------------- 126.96.36.199.0 SQL>
If you want to learn Manual Upgrade method for Oracle 12c, you should read following article.
Do you want to learn Oracle Database for Beginners, then read the following articles.
232 views today, 12 views in last 3 hour