Database Reference
In-Depth Information
Another important task while performing a manual database upgrade is to copy the source database password
file, init/spfile, from the Oracle 11g home to the Oracle 12c Database home. Also, ensure that the local/remote listener
parameter TNS configuration details are added in the new Oracle 12c tnsnames.ora file to avoid database startup
failures when database is started from the Oracle 12c home. For a RAC database, you must do it for all instances.
The following example demonstrates the copy command on Linux OS:
$cp /u01/app/oracle/product/11.2.0/db_1/dbs/orapwPRDDB1 /u01/app/oracle/product/12.1.0/db_1/dbs
If required, run the preupgrade_fixups.sql script and subsequently shut down and mount the database to
disable the archivelog mode to avoid excessive archive generation during upgrade and to expedite the upgrade process.
srvctl stop database -d PRDDB
export ORACLE_SID=PRDDB1
sqplus / as sysdba
SQL> STARTUP MOUNT
SQL> ALTER DATABASE NOARCHIVELOG;
SQL> ALTER SYSTEM SET CLUSTER_DATABASE=FALSE SCOPE=SPFILE;
SQL> SHUTDOWN IMMEDIATE;
Set the $ORACLE_HOME to Oracle Database 12c version on the server.
export ORACLE_HOME=/u01/app/oracle/product/12.1.0/db_1
export PATH=$ORACLE_HOME/bin:$PATH
cd $ORACLE_HOME
On the SQL prompt, run the following database upgrade command:
SQL> CONNECT / AS SYSDBA
SQL> STARTUP UPGRADE
Exit from the SQL prompt and subsequently initiate the upgrade process in parallel mode, using the new Parallel
Upgrade Utility, as explained here:
$/u01/app/oracle/product/12.0.1/db_1/perl/bin/perl catctl.pl-n 2 -l /tmp catupgrd.sql
If you prefer to perform an upgrade in a serial mode, like in previous releases, do the following at the SQL prompt:
SQL>@?/rdbms/admin/catupgrd.sql parallel=no
Database will be automatically shut down once the preceding command successfully completes. You therefore
have to perform the following steps to enable the CLUSTER_DATABASE, set the database COMPATIBLE parameter to
12c, enable archive log, etc.:
SQL> STARTUP MOUNT
SQL> ALTER DATABASE ARCHIVELOG;
SQL> ALTER SYSTEM SET CLUSTER_DATABASE=TRUE SCOPE=SPFILE;
SQL> ALTER SYSTEM SET COMPATIBLE=12.1.0 scope=spfile;
SQL> SHUTDOWN IMMEDIATE;
SQL> STARTUP
 
Search WWH ::




Custom Search