Oracle Patch Installation

This section provides the steps for Oracle patch installation.

Oracle Patch Installation (Optional)

To install the Oracle patch:

Before you begin


Note


This is an illustration of the Oracle 19c patch installation (from 19.3.0.0.0 to 19.18.0.0.0).


  1. Check the current Oracle version.

    [root@iot-fnd-oracle ~]# su - oracle
    [oracle@iot-fnd-oracle ~]$ sqlplus / as sysdba
    SQL*Plus: Release 19.0.0.0.0 - Production on Wed Mar 29 20:59:44 2023
    Version 19.3.0.0.0
    
    Copyright (c) 1982, 2019, Oracle.  All rights reserved.
    
    Connected to:
    Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production
    Version 19.3.0.0.0
    
    SQL> exit;
  2. Stop the FND application (if running).

    service cgms stop
  3. Log into Oracle.

    su - oracle
  4. Stop the Oracle service (if running).

    
    cd /opt/cgms-oracle/scripts
    ./stopOracle.sh  
  5. Apply the patch file: p34765931_190000_Linux-x86-64.zip.

Procedure


Step 1

Create a patches directory under the /home/oracle folder to place the patch zip files.

mkdir /home/oracle/patches

Step 2

Download the database patch zip file (p34765931_190000_Linux-x86-64.zip) from Oracle Database 19c Release Update & Release Update Revision January 2023 Known Issues.

Step 3

Copy the patch zip files to the /home/oracle/patches folder.

Step 4

Unzip the patch files (p34765931_190000_Linux-x86-64.zip) in the /home/oracle/patches folder.

su - oracle
cd /home/oracle/patches/
unzip p34765931_190000_Linux-x86-64.zip

Step 5

Go to the patch directory cd /home/oracle/patches/34765931/ and run the following command to check if the prerequisites are passing.

[oracle@iot-fnd-oracle 34765931]$ 
/home/oracle/app/oracle/product/19.0.0/dbhome_1/OPatch/opatch prereq 
CheckConflictAgainstOHWithDetail -ph ./
Oracle Interim Patch Installer version 12.2.0.1.17
Copyright (c) 2023, Oracle Corporation.  All rights reserved.

PREREQ session

Oracle Home       : /home/oracle/app/oracle/product/19.0.0/dbhome_1
Central Inventory : /home/oracle/app/oraInventory
from           : /home/oracle/app/oracle/product/19.0.0/dbhome_1/oraInst.loc
OPatch version    : 12.2.0.1.17
OUI version       : 12.2.0.7.0
Log file location : 
/home/oracle/app/oracle/product/19.0.0/dbhome_1/cfgtoollogs/opatch/opatch2023-02-10_07-15-33AM_1.log

Invoking prereq "checkconflictagainstohwithdetail"

Prereq "checkConflictAgainstOHWithDetail" passed.

OPatch succeeded.

The minimum OPatch version required is 12.2.0.1.34. The patch installation FAILS if the OPatch version is below 12.2.0.1.34. For more information on applying the minimum OPatch version, see Upgrading OPatch.

Step 6

Run the following command to apply the patch.

[oracle@iot-fnd-oracle 34765931]$ 
/home/oracle/app/oracle/product/19.0.0/dbhome_1/OPatch/opatch apply
Oracle Interim Patch Installer version 12.2.0.1.36
Copyright (c) 2023, Oracle Corporation.  All rights reserved.


Oracle Home       : /home/oracle/app/oracle/product/19.0.0/dbhome_1
Central Inventory : /home/oracle/app/oraInventory
from           : /home/oracle/app/oracle/product/19.0.0/dbhome_1/oraInst.loc
OPatch version    : 12.2.0.1.36
OUI version       : 12.2.0.7.0
Log file location : 
/home/oracle/app/oracle/product/19.0.0/dbhome_1/cfgtoollogs/opatch/opatch2023-03-23_11-45-20AM_1.log

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

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 = '/home/oracle/app/oracle/product/19.0.0/dbhome_1')


Is the local system ready for patching? [y|n] y
User Responded with: Y
Backing up files...
Applying interim patch '34765931' to OH '/home/oracle/app/oracle/product/19.0.0/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.sdo.companion, 19.0.0.0.0 ] , 
[ oracle.options.olap.api, 19.0.0.0.0 ] , [ oracle.oid.client, 19.0.0.0.0 ] , 
[ oracle.xdk.companion, 19.0.0.0.0 ] , [ oracle.network.cman, 19.0.0.0.0 ] , 
[ oracle.rdbms.tg4msql, 19.0.0.0.0 ] , [ oracle.ons.eons.bwcompat, 19.0.0.0.0 ] , 
[ oracle.net.cman, 19.0.0.0.0 ] , [ oracle.rdbms.tg4tera, 19.0.0.0.0 ] , 
[ oracle.options.olap, 19.0.0.0.0 ] , [ oracle.rdbms.tg4sybs, 19.0.0.0.0 ] , 
[ oracle.ons.cclient, 19.0.0.0.0 ] , [ oracle.rdbms.tg4ifmx, 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.slax.rsf, 19.0.0.0.0...
Patching component oracle.ordim.jai, 19.0.0.0.0...
Patching component oracle.bali.jewt, 11.1.1.6.0...
Patching component oracle.bali.ewt, 11.1.1.6.0...
Patching component oracle.help.ohj, 11.1.1.7.0...
Patching component oracle.rdbms.locator, 19.0.0.0.0...
Patching component oracle.perlint.expat, 2.0.1.0.4...
Patching component oracle.rdbms.util, 19.0.0.0.0...
Patching component oracle.rdbms, 19.0.0.0.0...
Patching component oracle.rdbms.rsf, 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.blaslapack, 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.dbdev, 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.duma, 19.0.0.0.0...
Patching component oracle.javavm.client, 19.0.0.0.0...
Patching component oracle.ldap.owm, 19.0.0.0.0...
Patching component oracle.ldap.rsf, 19.0.0.0.0...
Patching component oracle.ldap.security.osdt, 19.0.0.0.0...
Patching component oracle.marvel, 19.0.0.0.0...
Patching component oracle.network.rsf, 19.0.0.0.0...
Patching component oracle.odbc.ic, 19.0.0.0.0...
Patching component oracle.ons, 19.0.0.0.0...
Patching component oracle.ons.ic, 19.0.0.0.0...
Patching component oracle.oracore.rsf, 19.0.0.0.0...
Patching component oracle.perlint, 5.28.1.0.0...
Patching component oracle.precomp.common.core, 19.0.0.0.0...
Patching component oracle.precomp.rsf, 19.0.0.0.0...
Patching component oracle.rdbms.crs, 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.rdbms.oci, 19.0.0.0.0...
Patching component oracle.rdbms.rsf.ic, 19.0.0.0.0...
Patching component oracle.rhp.db, 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.sqlplus.ic, 19.0.0.0.0...
Patching component oracle.wwg.plsql, 19.0.0.0.0...
Patching component oracle.ldap.rsf.ic, 19.0.0.0.0...
Patching component oracle.network.listener, 19.0.0.0.0...
Patching component oracle.rdbms.lbac, 19.0.0.0.0...
Patching component oracle.nlsrtl.rsf, 19.0.0.0.0...
Patching component oracle.rdbms.hs_common, 19.0.0.0.0...
Patching component oracle.network.client, 19.0.0.0.0...
Patching component oracle.sdo.locator, 19.0.0.0.0...
Patching component oracle.xdk.rsf, 19.0.0.0.0...
Patching component oracle.rdbms.drdaas, 19.0.0.0.0...
Patching component oracle.oraolap, 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.ldap.ssl, 19.0.0.0.0...
Patching component oracle.ctx.atg, 19.0.0.0.0...
Patching component oracle.rdbms.hsodbc, 19.0.0.0.0...
Patching component oracle.xdk, 19.0.0.0.0...
Patching component oracle.mgw.common, 19.0.0.0.0...
Patching component oracle.oraolap.dbscripts, 19.0.0.0.0...
Patching component oracle.xdk.xquery, 19.0.0.0.0...
Patching component oracle.rdbms.rman, 19.0.0.0.0...
Patching component oracle.odbc, 19.0.0.0.0...
Patching component oracle.rdbms.install.plugins, 19.0.0.0.0...
Patching component oracle.oraolap.api, 19.0.0.0.0...
Patching component oracle.rdbms.scheduler, 19.0.0.0.0...
Patching component oracle.rdbms.install.common, 19.0.0.0.0...
Patching component oracle.xdk.parser.java, 19.0.0.0.0...
Patching component oracle.ovm, 19.0.0.0.0...
Patching component oracle.ctx.rsf, 19.0.0.0.0...
Patching component oracle.ldap.client, 19.0.0.0.0...
Patching component oracle.install.deinstalltool, 19.0.0.0.0...
Patching component oracle.dbtoolslistener, 19.0.0.0.0...
Patching component oracle.precomp.lang, 19.0.0.0.0...
Patching component oracle.precomp.common, 19.0.0.0.0...
Patching component oracle.jdk, 1.8.0.201.0...
Patch 34765931 successfully applied.
Sub-set patch [29517242] has become inactive due to the application of a super-set patch [34765931].
Please refer to Doc ID 2161861.1 for any possible further required actions.
og file location: 
/home/oracle/app/oracle/product/19.0.0/dbhome_1/cfgtoollogs/opatch/opatch2023-03-23_11-45-20AM_1.log

OPatch succeeded.

Step 7

Check if the upgraded patch version is 19.18.0 in the interim patches.

[oracle@iot-fnd-oracle ~]$ 
/home/oracle/app/oracle/product/19.0.0/dbhome_1/OPatch/opatch lsinventory -details

Patch  34765931     : applied on Thu Mar 23 11:51:24 EDT 2023
Unique Patch ID:  25098466
Patch description:  
"DATABASE RELEASE UPDATE : 19.18.0.0.230117 (REL-JAN230131) (34765931)"
Created on 27 Jan 2023, 11:25:14 hrs UTC

Step 8

Confirm the upgraded patch.

[root@iok-oracle ~]# su - oracle 
[oracle@iok-oracle ~]$ sqlplus / as sysdba
SQL*Plus: Release 19.0.0.0.0 - Production on Wed Mar 29 15:34:04 2023
Version 19.18.0.0.0

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

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

SQL> exit;
Disconnected from Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production
Version 19.18.0.0.0
[oracle@iok-oracle ~]$exit

What to do next

Start Oracle.
su - oracle
 cd /opt/cgms-oracle/scripts
 ./startOracle.sh 

Upgrading OPatch

To apply the Oracle patch 19.18, the minimum required OPatch version is 12.2.0.1.34. If the OPatch version is low, you will see the following error. You can resolve this issue by applying the minimum OPatch version 12.2.0.1.34.
[oracle@iot-fnd-oracle 34765931]$ 
/home/oracle/app/oracle/product/19.0.0/dbhome_1/OPatch/opatch apply
Oracle Interim Patch Installer version 12.2.0.1.17
Copyright (c) 2023, Oracle Corporation.  All rights reserved.
Oracle Home       : /home/oracle/app/oracle/product/19.0.0/dbhome_1
Central Inventory : /home/oracle/app/oraInventory
from           : /home/oracle/app/oracle/product/19.0.0/dbhome_1/oraInst.loc
OPatch version    : 12.2.0.1.17
OUI version       : 12.2.0.7.0
Log file location : 
/home/oracle/app/oracle/product/19.0.0/dbhome_1/cfgtoollogs/opatch/opatch2023-02-10_07-16-05AM_1.log
Verifying environment and performing prerequisite checks...
Prerequisite check "CheckMinimumOPatchVersion" failed.
The details are:
The OPatch being used has version 12.2.0.1.17 while the following patch(es) require higher versions:
Patch 34765931 requires OPatch version 12.2.0.1.34.
Please download latest OPatch from My Oracle Support.
UtilSession failed: Prerequisite check "CheckMinimumOPatchVersion" failed.
Log file location: 
/home/oracle/app/oracle/product/19.0.0/dbhome_1/cfgtoollogs/opatch/opatch2023-02-10_07-16-05AM_1.log
OPatch failed with error code 73

The steps are an illustration for requesting the minimum OPatch version 12.2.0.1.34 to apply the 19.18 patch on an old OPatch version 12.2.0.1.17.

Procedure


Step 1

To upgrade the OPatch version, download the 12.2.0.1.36 OPatch version from the Oracle support Patch 6880880 (oracle.com) .

Step 2

Place the zip file in the $ORACLE_HOME directory and follow the steps that are given below.

The OPatch file is: p6880880_190000_Linux-x86-64.zip

  1. Change directory to $ORACLE_HOME/OPatch/

    [oracle@iot-fnd-oracle 34765931]$ 
    cd $ORACLE_HOME/OPatch/
  2. Check the current version of OPatch.

    [oracle@iot-fnd-oracle OPatch]$ ./opatch version
    OPatch Version: 12.2.0.1.17
    OPatch succeeded.
        
  3. Take backup of the present OPatch in the following directory.

    [oracle@iot-fnd-oracle ]$ 
    cd /home/oracle/app/oracle/product/19.0.0/dbhome_1
    [oracle@iot-fnd-oracle dbhome_1]$ 
    tar -cvzPpf OPatch_backup.tar OPatch/
    
  4. Remove the OPatch folder.

    [oracle@iot-fnd-oracle dbhome_1]$ 
    rm -rf OPatch
  5. Unzip 12.2.0.1.36 the OPatch version and check if the OPatch folder is created under the dbhome_1 directory.

    [oracle@iot-fnd-oracle dbhome_1]$ 
    unzip p6880880_190000_Linux-x86-64.zip
  6. Check the upgraded OPatch version.

    [oracle@iot-fnd-oracle dbhome_1]$ cd OPatch
    [oracle@iot-fnd-oracle OPatch]$ ./opatch version
    OPatch Version: 12.2.0.1.36
    OPatch succeeded.