How to Upgrade Oracle 19.3 to Oracle 19.9

Introduction

In this article, we will see how to upgrade your Oracle 19.3 installation to Oracle 19.9. I have tried to cover some common issues at the end of this guid.

Prerequisites

The following files are required for upgrading from Oracle 19.3 to Oracle 19.9.

  1. p6880880_190000_Linux-x86-64.zip - Opatch version 12.2.0.1.24 (Anything greater that 12.2.0.1.23 is enough)
  2. p31771877_190000_Linux-x86-64.zip - Oracle 19.9 Patch file.

Step 1: OPatch Version Check and Upgrade

To install Oracle 19.9 patch, we will use an utility called opatch which comes with oracle installation by default. It is present in $ORACLE_HOME/OPatch directory.

cd $ORACLE_HOME/OPatch/

Check the version of opatch

./opatch version
Output:

OPatch Version: 12.2.0.1.17
OPatch succeeded.

Opatch has to be upgraded to 12.2.0.1.24 or later to install Oracle 19.9 patch. Firstly lets move the existing $ORACLE_HOME\Opatch (to roll back if something goes wrong) to a backup location.

mv OPatch/ Opatch_backup

Now unzip the contents of p6880880_190000_Linux-x86-64.zip to $ORACLE_HOME directory.

unzip p6880880_190000_Linux-x86-64.zip -d $ORACLE_HOME

This will re-create the OPatch folder and extract the files to it.

Check the version of new opatch

cd $ORACLE_HOME/OPatch/
./opatch version
Output:

OPatch Version: 12.2.0.1.24
OPatch succeeded.

We are good to go if the version is equal to or greater that 12.2.0.1.23

Step 2 : Shutdown Database and Listener

Before beginning to install the patch lets stop our Database and Listener

Check the lsnrctl status before shutting down.

lsnrctl status
Output:

LSNRCTL for Linux: Version 19.0.0.0.0 - Production on 01-JUN-2021 04:59:25

Copyright (c) 1991, 2019, Oracle.  All rights reserved.

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=XX.XX.XX.XX)(PORT=1521)))
STATUS of the LISTENER
------------------------
Alias                     LISTENER
Version                   TNSLSNR for Linux: Version 19.0.0.0.0 - Production
Start Date                29-APR-2021 10:09:23
Uptime                    32 days 18 hr. 50 min. 2 sec
Trace Level               off
Security                  ON: Local OS Authentication
SNMP                      OFF
Listener Parameter File   /opt/oracle/product/19c/dbhome_1/network/admin/listener.ora
Listener Log File         /opt/oracle/diag/tnslsnr/sgfrhel8oracle/listener/alert/log.xml
Listening Endpoints Summary...
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=rhel8oracle)(PORT=1521)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcps)(HOST=rhel8oracle)(PORT=5500))(Security=(my_wallet_directory=/opt/oracle/admin/SGFDB1/xdb_wallet))(Presentation=HTTP)(Session=RAW))
Services Summary...
Service "DEMODB1" has 1 instance(s).
  Instance "DEMODB1", status READY, has 1 handler(s) for this service...
Service "DEMODB1XDB" has 1 instance(s).
  Instance "DEMODB1", status READY, has 1 handler(s) for this service...
The command completed successfully

Login to sqlus as dba and shutdown the database.

sqplus / as sysdba

In sqplus console

shutdown immediate
Output:

Database closed.
Database dismounted.
ORACLE instance shut down.

To stop listener

lsnrctl stop

Step 3: Backup $ORACLE_HOME

cd $ORACLE_HOME/..
tar -cvf ORACLE_HOME_BKP.tar $ORACLE_HOME

Step 4: Apply patch

Unzip p31771877_190000_Linux-x86-64.zip and run the Opatch utility inside the extracted folder.

unzip p31771877_190000_Linux-x86-64.zip
cd 31771877/
$ORACLE_HOME/OPatch/opatch apply
Output:

Oracle Interim Patch Installer version 12.2.0.1.24
Copyright (c) 2021, Oracle Corporation.  All rights reserved.


Oracle Home       : /opt/oracle/product/19c/dbhome_1
Central Inventory : /opt/oracle/oraInventory
   from           : /opt/oracle/product/19c/dbhome_1/oraInst.loc
OPatch version    : 12.2.0.1.24
OUI version       : 12.2.0.7.0
Log file location : /opt/oracle/product/19c/dbhome_1/cfgtoollogs/opatch/opatch2021-06-01_05-32-17AM_1.log

Verifying environment and performing prerequisite checks...
OPatch continues with these patches:   31771877

Do you want to proceed? [y|n]
y
User Responded with: Y
All checks passed.

Please shutdown Oracle instances running out of this ORACLE_HOME on the local system.
(Oracle Home = '/opt/oracle/product/19c/dbhome_1')


Is the local system ready for patching? [y|n]
y
User Responded with: Y
Backing up files...
Applying interim patch '31771877' to OH '/opt/oracle/product/19c/dbhome_1'
ApplySession: Optional component(s) [ oracle.network.gsm, 19.0.0.0.0 ] , [ oracle.rdbms.ic, 19.0.0.0.0 ] , [ oracle.rdbms.tg4db2, 19.0.0.0.0 ] , [ oracle.tfa, 19.0.0.0.0 ] , [ oracle.options.olap.awm, 19.0.0.0.0 ] , [ oracle.net.cman, 19.0.0.0.0 ] , [ oracle.xdk.companion, 19.0.0.0.0 ] , [ oracle.oraolap.mgmt, 19.0.0.0.0 ] , [ oracle.network.cman, 19.0.0.0.0 ] , [ oracle.options.olap, 19.0.0.0.0 ] , [ oracle.assistants.usm, 19.0.0.0.0 ] , [ oracle.assistants.asm, 19.0.0.0.0 ] , [ oracle.sqlj, 19.0.0.0.0 ] , [ oracle.jdk, 1.8.0.191.0 ]  not present in the Oracle Home or a higher version is found.

Patching component oracle.rdbms.rsf, 19.0.0.0.0...

Patching component oracle.rdbms, 19.0.0.0.0...

Patching component oracle.rdbms.util, 19.0.0.0.0...

Patching component oracle.assistants.acf, 19.0.0.0.0...

Patching component oracle.assistants.deconfig, 19.0.0.0.0...

Patching component oracle.assistants.server, 19.0.0.0.0...

Patching component oracle.buildtools.rsf, 19.0.0.0.0...

Patching component oracle.ctx, 19.0.0.0.0...

Patching component oracle.dbjava.ic, 19.0.0.0.0...

Patching component oracle.dbjava.jdbc, 19.0.0.0.0...

Patching component oracle.dbjava.ucp, 19.0.0.0.0...

Patching component oracle.dbtoolslistener, 19.0.0.0.0...

Patching component oracle.ldap.rsf, 19.0.0.0.0...

Patching component oracle.network.rsf, 19.0.0.0.0...

Patching component oracle.oracore.rsf, 19.0.0.0.0...

Patching component oracle.rdbms.dbscripts, 19.0.0.0.0...

Patching component oracle.rdbms.deconfig, 19.0.0.0.0...

Patching component oracle.sdo, 19.0.0.0.0...

Patching component oracle.sdo.locator.jrf, 19.0.0.0.0...

Patching component oracle.sqlplus, 19.0.0.0.0...

Patching component oracle.usm.deconfig, 19.0.0.0.0...

Patching component oracle.rdbms.crs, 19.0.0.0.0...

Patching component oracle.oraolap, 19.0.0.0.0...

Patching component oracle.precomp.rsf, 19.0.0.0.0...

Patching component oracle.javavm.client, 19.0.0.0.0...

Patching component oracle.precomp.common.core, 19.0.0.0.0...

Patching component oracle.network.client, 19.0.0.0.0...

Patching component oracle.rdbms.scheduler, 19.0.0.0.0...

Patching component oracle.ctx.atg, 19.0.0.0.0...

Patching component oracle.marvel, 19.0.0.0.0...

Patching component oracle.oraolap.dbscripts, 19.0.0.0.0...

Patching component oracle.ovm, 19.0.0.0.0...

Patching component oracle.bali.ice, 11.1.1.7.0...

Patching component oracle.ctx.rsf, 19.0.0.0.0...

Patching component oracle.rdbms.lbac, 19.0.0.0.0...

Patching component oracle.rdbms.oci, 19.0.0.0.0...

Patching component oracle.odbc, 19.0.0.0.0...

Patching component oracle.rdbms.rman, 19.0.0.0.0...

Patching component oracle.nlsrtl.rsf, 19.0.0.0.0...

Patching component oracle.rdbms.install.plugins, 19.0.0.0.0...

Patching component oracle.rdbms.drdaas, 19.0.0.0.0...

Patching component oracle.ldap.rsf.ic, 19.0.0.0.0...

Patching component oracle.ldap.security.osdt, 19.0.0.0.0...

Patching component oracle.network.listener, 19.0.0.0.0...

Patching component oracle.ons, 19.0.0.0.0...

Patching component oracle.rdbms.dv, 19.0.0.0.0...

Patching component oracle.javavm.server, 19.0.0.0.0...

Patching component oracle.xdk, 19.0.0.0.0...

Patching component oracle.ldap.owm, 19.0.0.0.0...

Patching component oracle.dbdev, 19.0.0.0.0...

Patching component oracle.rdbms.install.common, 19.0.0.0.0...

Patching component oracle.sdo.locator, 19.0.0.0.0...

Patching component oracle.duma, 19.0.0.0.0...

Patching component oracle.sqlplus.ic, 19.0.0.0.0...

Patching component oracle.xdk.rsf, 19.0.0.0.0...

Patching component oracle.xdk.parser.java, 19.0.0.0.0...

Patching component oracle.rdbms.rsf.ic, 19.0.0.0.0...

Patching component oracle.precomp.common, 19.0.0.0.0...

Patching component oracle.precomp.lang, 19.0.0.0.0...

Patching component oracle.jdk, 1.8.0.201.0...
Patch 31771877 successfully applied.
Sub-set patch [29517242] has become inactive due to the application of a super-set patch [31771877].
Please refer to Doc ID 2161861.1 for any possible further required actions.
Log file location: /opt/oracle/product/19c/dbhome_1/cfgtoollogs/opatch/opatch2021-06-01_05-32-17AM_1.log

OPatch succeeded.

Step 5: Start Listener and Database

Start the listener control

lsnrctl start

Login to sqlplus console and start the database

sqplus / as sysdba

Step 6: Verify Patch Installation

To view the details of the patch installed, lets use the opatch tool with list patch parameter.

cd $ORACLE_HOME/OPatch
./opatch lspatches
Output:

31771877;Database Release Update : 19.9.0.0.201020 (31771877)
29585399;OCW RELEASE UPDATE 19.3.0.0.0 (29585399)

You can also view the version while logging into sqplus console.

sqlplus / as sysdba
Output:

SQL*Plus: Release 19.0.0.0.0 - Production on Tue Jun 1 07:27:23 2021
Version 19.9.0.0.0

Copyright (c) 1982, 2020, Oracle.  All rights reserved.


Connected to:
Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production
Version 19.9.0.0.0

Common Issues

  1. Prerequisite check "CheckActiveFilesAndExecutables" failed

Conclusion

Oracle 19.9 has introduces many new features in this relase like Transparent Database Encryption (TDE).

Although Oracle 19.9 patch is not publically available for free, paid customers will be able to download the patch from Oracle official repository. If it is available for you, I recommend you to upgrade.

Asha

Asha

I am a self mentored web enthusiast who likes to inspect element everything I see on the web.