How to Upgrade Oracle Database 11g to Oracle 12c using DBUA

Hi,

I will explain how to upgrade Oracle Database from Oracle 11g to Oracle 12c in this article.

Oracle 12c Kurulum 15

 

 

Read previous article to learn Oracle database upgrade methods.

Oracle Database Upgrade Guide and How to Upgrade Oracle Database

 

 

 

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 11.2.0.4.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 11.2.0.4.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
-----------------
11.2.0.4.0
SQL>   

Read following article to install Oracle 12c software. I won’t explain how to install Oracle database 12c software in this post.

Oracle Database 12c Step by Step Installation On Linux -3

 

 

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/12.1.0.1; 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.

Oracle 12c Upgrade 1

 

 

 

 

Step -3: Select Database in this step.

Oracle 12c Upgrade 2

 

Step -4:  Validations steps, Click Next.

Oracle 12c Upgrade 3

 

 

 

 

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.

 

 

Oracle 12c Upgrade 4

 

 

Step -6:  If you have Custom SQL Scripts, type it in this step.

Oracle 12c Upgrade 5

 

Step -7: You can Configure Enterprise manager Database Express or Register with Enterprise Manager Cloud control.

Oracle 12c Upgrade 6

 

 

 

 

Step -8: Don’t select if you don’t move database files to new location.

Oracle 12c Upgrade 7

 

Step -9:  Select listener like following.

Oracle 12c Upgrade 8

 

 

 

Step -10: I have my own backup and restore strategy so I have chosen second option.

 

Oracle 12c Upgrade 9

 

Step -11: Database upgrade summary step. You can check it before upgrade.

 

Oracle 12c Upgrade 10

 

 

 

 

Oracle 12c Upgrade 11

 

Step -12: Upgrade is completed without errors.

 

Oracle 12c Upgrade 12

 

 

 

Step -13:  Connect to database and query version again.

bash-4.1$ sqlplus / as sysdba
SQL*Plus: Release 12.1.0.1.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 12.1.0.1.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
-----------------
12.1.0.1.0
SQL>

 

 

If you want to learn Manual Upgrade method for Oracle 12c, you should read following article.

https://ittutorial.org/manual-upgrade-oracle-database-from-11-2-0-4-to-12-2-0-1-without-dbua/

 

 

 

 

Do you want to learn Oracle Database for Beginners, then read the following articles.

https://ittutorial.org/oracle-database-19c-tutorials-for-beginners/

About Mehmet Salih Deveci

I am Founder of SysDBASoft IT and IT Tutorial and Certified Expert about Oracle & SQL Server database, Goldengate, Exadata Machine, Oracle Database Appliance administrator with 10+years experience.I have OCA, OCP, OCE RAC Expert Certificates I have worked 100+ Banking, Insurance, Finance, Telco and etc. clients as a Consultant, Insource or Outsource.I have done 200+ Operations in this clients such as Exadata Installation & PoC & Migration & Upgrade, Oracle & SQL Server Database Upgrade, Oracle RAC Installation, SQL Server AlwaysOn Installation, Database Migration, Disaster Recovery, Backup Restore, Performance Tuning, Periodic Healthchecks.I have done 2000+ Table replication with Goldengate or SQL Server Replication tool for DWH Databases in many clients.If you need Oracle DBA, SQL Server DBA, APPS DBA,  Exadata, Goldengate, EBS Consultancy and Training you can send my email adress [email protected].-                                                                                                                                                                                                                                                 -Oracle DBA, SQL Server DBA, APPS DBA,  Exadata, Goldengate, EBS ve linux Danışmanlık ve Eğitim için  [email protected] a mail atabilirsiniz.

Leave a Reply

Your email address will not be published. Required fields are marked *