Lin Hong's TECH Blog! 刀不磨要生锈,人不学习要落后 - Thinking ahead

Oracle 19c OPatch 19.10 Tips


Oracle 19c OPatch 19.10 Tips

OPatch version Up


  • Opatch : ->

  • 19c Patch:p32218454 -> -> Patch 32218454 requires OPatch version

Some Tips in OPatch Apply

[oracle@ol8-19c 32218454]$ export PATH=/u01/app/oracle/product/19.0.0/dbhome_1/OPatch:$PATH
[oracle@ol8-19c 32218454]$ which opatch
[oracle@ol8-19c 32218454]$

[oracle@ol8-19c 32218454]$ sqlplus / as sysdba
SYS@cdb1> shu immediate;

Some error:

[Jul 19, 2021 2:09:42 PM] [INFO]    Prerequisite check "CheckMinimumOPatchVersion" failed.
                                    The details are:

                                    The OPatch being used has version while the following patch(es) require higher versions:
                                    Patch 32218454 requires OPatch version
                                    Please download latest OPatch from My Oracle Support.
[Jul 19, 2021 2:09:42 PM] [SEVERE]  OUI-67073:UtilSession failed: Prerequisite check "CheckMinimumOPatchVersion" failed.
[Jul 19, 2021 2:09:42 PM] [INFO]    Finishing UtilSession at Mon Jul 19 14:09:42 CST 2021
[Jul 19, 2021 2:09:42 PM] [INFO]    Log file location: /u01/app/oracle/product/19.0.0/dbhome_1/cfgtoollogs/opatch/opatch2021-07-19_14-09-17PM_1.log
[Jul 19, 2021 2:09:42 PM] [INFO]    Stack Description: java.lang.RuntimeException: Prerequisite check "CheckMinimumOPatchVersion" failed.

Reason: opatch version is older.

[oracle@ol8-19c 32218454]$ opatch version
OPatch Version:

OPatch succeeded.
[oracle@ol8-19c 32218454]$

OPatch for DB 12.x, 18.x, 19.x and 21.x releases (May 2021)

Oracle Global Lifecycle Management OPatch

[oracle@ol8-19c dbhome_1]$ pwd
[oracle@ol8-19c dbhome_1]$ unzip
[oracle@ol8-19c dbhome_1]$ opatch version
OPatch Version:

OPatch succeeded.
[oracle@ol8-19c dbhome_1]$

OPatch apply


opatch prereq CheckConflictAgainstOHWithDetail -ph ./
opatch apply
----> input: y

Sample Output:

[oracle@ol8-19c 32218454]$ opatch apply
Oracle Interim Patch Installer version
Copyright (c) 2021, Oracle Corporation.  All rights reserved.

Oracle Home       : /u01/app/oracle/product/19.0.0/dbhome_1
Central Inventory : /u01/app/oraInventory
   from           : /u01/app/oracle/product/19.0.0/dbhome_1/oraInst.loc
OPatch version    :
OUI version       :
Log file location : /u01/app/oracle/product/19.0.0/dbhome_1/cfgtoollogs/opatch/opatch2021-07-19_14-29-46PM_1.log

Verifying environment and performing prerequisite checks...
Start OOP by Prereq process.
Launch OOP...

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

Oracle Home       : /u01/app/oracle/product/19.0.0/dbhome_1
Central Inventory : /u01/app/oraInventory
   from           : /u01/app/oracle/product/19.0.0/dbhome_1/oraInst.loc
OPatch version    :
OUI version       :
Log file location : /u01/app/oracle/product/19.0.0/dbhome_1/cfgtoollogs/opatch/opatch2021-07-19_14-30-26PM_1.log

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

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

Please shutdown Oracle instances running out of this ORACLE_HOME on the local system.
(Oracle Home = '/u01/app/oracle/product/19.0.0/dbhome_1')

Is the local system ready for patching? [y|n]
User Responded with: Y
Backing up files...
Applying interim patch '32218454' to OH '/u01/app/oracle/product/19.0.0/dbhome_1'
ApplySession: Optional component(s) [, ] , [ oracle.rdbms.ic, ] , [ oracle.rdbms.tg4db2, ] , [ oracle.tfa, ] , [, ] , [, ] , [ oracle.oid.client, ] , [ oracle.options.olap.api, ] , [ oracle.options.olap, ] , [ oracle.xdk.companion, ] , [ oracle.jdk, ]  not present in the Oracle Home or a higher version is found.
Patching component oracle.rdbms,
Patching component oracle.rdbms.rsf,
Patching component oracle.rdbms.util,
Patching component oracle.assistants.acf,
Patching component oracle.assistants.deconfig,
Patching component oracle.assistants.server,
Patching component oracle.buildtools.rsf,
Patching component oracle.ctx,
Patching component oracle.dbjava.ic,
Patching component oracle.dbjava.jdbc,
Patching component oracle.dbjava.ucp,
Patching component oracle.dbtoolslistener,
Patching component oracle.ldap.owm,
Patching component oracle.ldap.rsf,
Patching component,
Patching component oracle.oracore.rsf,
Patching component oracle.rdbms.dbscripts,
Patching component oracle.rdbms.deconfig,
Patching component oracle.sdo,
Patching component oracle.sdo.locator.jrf,
Patching component oracle.sqlplus,
Patching component oracle.xdk,
Patching component oracle.marvel,
Patching component oracle.xdk.rsf,
Patching component oracle.ctx.atg,
Patching component oracle.rdbms.scheduler,
Patching component oracle.rdbms.lbac,
Patching component oracle.duma,
Patching component oracle.ldap.rsf.ic,
Patching component oracle.odbc,
Patching component oracle.ctx.rsf,
Patching component oracle.oraolap.api,
Patching component,
Patching component oracle.oraolap,
Patching component oracle.sdo.locator,
Patching component oracle.sqlplus.ic,
Patching component oracle.mgw.common,
Patching component oracle.ons,
Patching component oracle.dbdev,
Patching component,
Patching component oracle.nlsrtl.rsf,
Patching component oracle.ovm,
Patching component oracle.oraolap.dbscripts,
Patching component oracle.xdk.xquery,
Patching component oracle.precomp.rsf,
Patching component oracle.javavm.client,
Patching component oracle.precomp.common.core,
Patching component,
Patching component oracle.rdbms.oci,
Patching component oracle.rdbms.rman,
Patching component,
Patching component oracle.rdbms.install.common,
Patching component oracle.javavm.server,
Patching component oracle.rdbms.drdaas,
Patching component oracle.rdbms.install.plugins,
Patching component oracle.rdbms.dv,
Patching component oracle.ldap.client,
Patching component,
Patching component oracle.rdbms.rsf.ic,
Patching component oracle.precomp.common,
Patching component oracle.precomp.lang,
Patching component oracle.jdk,
Patch 32218454 successfully applied.
Sub-set patch [29517242] has become inactive due to the application of a super-set patch [32218454].
Please refer to Doc ID 2161861.1 for any possible further required actions.
Log file location: /u01/app/oracle/product/19.0.0/dbhome_1/cfgtoollogs/opatch/opatch2021-07-19_14-30-26PM_1.log

OPatch succeeded.
[oracle@ol8-19c 32218454]$


startup instance and check via the following sql.

[oracle@ol8-19c 32218454]$ sqlplus / as sysdba
SYS@cdb1> starup;

./datapatch -verbose

-- Check Patches status
SET LONG 2000000
COLUMN action_time FORMAT A12
COLUMN comments FORMAT A30
COLUMN description FORMAT A60
COLUMN namespace FORMAT A20

SELECT TO_CHAR(action_time, 'YYYY-MM-DD') AS action_time,action,status,description,patch_id
FROM sys.dba_registry_sqlpatch
ORDER by action_time;

col comp_id for a10
col version for a11
col status for a10
col comp_name for a37
select comp_id,comp_name,version,status from dba_registry;

-- Identify Invalid Objects before patching

COLUMN object_name FORMAT A30
SELECT owner,object_type,object_name,status
FROM dba_objects
WHERE status = 'INVALID'
ORDER BY owner, object_type, object_name;

SYS@cdb1> SELECT owner,object_type,object_name,status
  2  FROM dba_objects
  3  WHERE status = 'INVALID'
  4  ORDER BY owner, object_type, object_name;

no rows selected

-- If there are some INVALID object and need to execute the following sql.
-- @?/rdbms/admin/utlrp.sql


Oracle Database 19c Release Update & Release Update Revision January 2021 Critical Issues (Doc ID 2725758.1)

Have a good work&life! 2021/07 via LinHong

Similar Posts