Patching most of my environments with the July 2022 Bundle Patches

It’s brutally hot out there. It must be July. And I sit in my cool basement office and start my quarterly patching journey hoping that you can enjoy the sun and the sea somewhere. It is time to do my usual exercise, this time Patching most of my environments with the July 2022 Patch Bundles.

As usual, an important annotation upfront: I patch in-place due to space issues. But in reality, you please patch always out-of-place with a separate home. Please see this blog post about how to apply the RU directly when you provision a new home with OUI.

 

Security Alert July 2022

You will find the July 2022 Security Alerts for all products here. And as usual, please pay close attention to the Database Server Products Risk Matrix. You will find the usual suspects such as OJVM but more important, a 9.1 database issue. Hence, you won’t need advice. You must apply this RU to your environments since 10.0 would be the high score. Also keep in mind that there may be already exploits circulating at least in the darker corners of the web.

Patching most of my environments with the July 2022 Bundle Patches

Oracle Database risk matrix – July 2022 – see: https://www.oracle.com/security-alerts/cpujul2022.html#AppendixDB

Something very important I’d like to mention since I’ve had numerous discussions in the past weeks about Oracle Database 11.2.0.4.

The column “Supported Versions Affected” do not mention Oracle 11g, 12.2 or 18c anymore for a simple reason: None of these releases is under either Premier nor Extended Support. But you can be almost certain assuming that the first issue will affect those releases as well. So you have two choices: Sign up for Market Driven Support (MDS) or upgrade to 19c. No expert anywhere can help you as there is no such thing as “virtual patching”.

Always be aware that the issues noted in the risk matrix may happen in older releases, too, even though they are not mentioned anymore.

 

Database Patch Bundles

You will find the links to the individual patch bundles in MOS Note: 2867871.1 – Critical Patch Update (CPU) Program Jul 2022 Patch Availability Document (DB-only). But you can use as well MOS Note: 2118136.2 – Assistant: Download Reference for Oracle Database/GI Update, Revision, PSU, SPU(CPU), Bundle Patches, Patchsets and Base Releases to download “your” bundle.

  • Oracle Database 21c
  • Oracle Database 19c
  • Oracle Database 12.1.0.2
    • Database Proactive Bundle Patch 12.1.0.2.220719 Patch 34204559,

      • Patch bundle is not available while I write this blog post
  • Oracle Database 11.2.0.4
    • Not available yet – will update the blog post later

Do I need a new OPatch?

And then it is time again for the opatch check. Without even seeing the number, I can tell you that you MUST refresh your opatch since there are some significant performance improvements in the 30 version on all platforms. But let me double check with the READMEs:

  • 21.7.0 requires opatch 12.2.0.1.30 or later
  • 19.16.0 requires opatch 12.2.0.1.30 or later
  • 12.1.0.2 BP July 2022 requires opatch 12.2.0.1.30 or later
  • 11.2.0.4 PSU July 2022 requires opatch 11.2.0.3.33  or later

The most recent opatch version is already 32. And since I know that there may be some improvements included, I will update opatch in all my homes. The 6880880 link from the readmes takes you directly to the correct download. BUT … you will be directed to the 12.2.0.1.30 version of opatch, not the 29 version. And it may not wonder you, all three opatch releases for 12.1 – 21c are identical even though all sail with different display labels on MOS. So it is fairly enough in my case to download it only once.

For the 11g opatch, it will point you to the 11.2.0.3.34 version as well. Which is fine. I just wanted to mention it.

Hence, action no.1 for all my environments before I will start patching:

  • Either wipe out the current OPatch directory in each home, then unzip the new OPatch bundles – or use unzip -o option instead

 

Applying the RU 21.7.0 to my Oracle 21c home

I always do something you shouldn’t do. I apply the patch to my existing home. This has to do with the available space in my lab environment. You please provide a new home and apply the patch(es) right away as I describe here.

Patching my 21c database home to RU 21.6.0 is again pretty straight forward.

  1. Conflict and space checks

    $ORACLE_HOME/OPatch/opatch prereq CheckConflictAgainstOHWithDetail -ph ./
    Oracle Interim Patch Installer version 12.2.0.1.32
    Copyright (c) 2022, Oracle Corporation.  All rights reserved.
    
    PREREQ session
    
    Oracle Home       : /u01/app/oracle/product/21
    Central Inventory : /u01/app/oraInventory
       from           : /u01/app/oracle/product/21/oraInst.loc
    OPatch version    : 12.2.0.1.32
    OUI version       : 12.2.0.9.0
    Log file location : /u01/app/oracle/product/21/cfgtoollogs/opatch/opatch2022-07-20_17-28-09PM_1.log
    
    Invoking prereq "checkconflictagainstohwithdetail"
    
    Prereq "checkConflictAgainstOHWithDetail" passed.
    
    OPatch succeeded.
    
    
    
    $ORACLE_HOME/OPatch/opatch prereq CheckSystemSpace -ph ./
    Oracle Interim Patch Installer version 12.2.0.1.32
    Copyright (c) 2022, Oracle Corporation.  All rights reserved.
    
    PREREQ session
    
    Oracle Home       : /u01/app/oracle/product/21
    Central Inventory : /u01/app/oraInventory
       from           : /u01/app/oracle/product/21/oraInst.loc
    OPatch version    : 12.2.0.1.32
    OUI version       : 12.2.0.9.0
    Log file location : /u01/app/oracle/product/21/cfgtoollogs/opatch/opatch2022-07-20_17-28-53PM_1.log
    
    Invoking prereq "checksystemspace"
    
    Prereq "checkSystemSpace" passed.
    
    OPatch succeeded.
    

    Fine. I’m good to go.

  2. opatch apply
    $ORACLE_HOME/OPatch/opatch apply
    Oracle Interim Patch Installer version 12.2.0.1.32
    Copyright (c) 2022, Oracle Corporation.  All rights reserved.
    
    
    Oracle Home       : /u01/app/oracle/product/21
    Central Inventory : /u01/app/oraInventory
       from           : /u01/app/oracle/product/21/oraInst.loc
    OPatch version    : 12.2.0.1.32
    OUI version       : 12.2.0.9.0
    Log file location : /u01/app/oracle/product/21/cfgtoollogs/opatch/opatch2022-07-20_17-29-52PM_1.log
    
    Verifying environment and performing prerequisite checks...
    OPatch continues with these patches:   34160444  
    
    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 = '/u01/app/oracle/product/21')
    
    
    Is the local system ready for patching? [y|n]
    y
    User Responded with: Y
    Backing up files...
    Applying interim patch '34160444' to OH '/u01/app/oracle/product/21'
    ApplySession: Optional component(s) [ oracle.network.gsm, 21.0.0.0.0 ] , [ oracle.python, 21.0.0.0.0 ] , [ oracle.tfa, 21.0.0.0.0 ] , [ oracle.network.cman, 21.0.0.0.0 ] , [ oracle.rdbms.tg4ifmx, 21.0.0.0.0 ] , [ oracle.sdo.companion, 21.0.0.0.0 ] , [ oracle.rdbms.tg4sybs, 21.0.0.0.0 ] , [ oracle.rdbms.tg4msql, 21.0.0.0.0 ] , [ oracle.rdbms.tg4db2, 21.0.0.0.0 ] , [ oracle.duma, 21.0.0.0.0 ] , [ oracle.oraolap.mgmt, 21.0.0.0.0 ] , [ oracle.rdbms.tg4tera, 21.0.0.0.0 ] , [ oracle.ons.eons.bwcompat, 21.0.0.0.0 ] , [ oracle.rdbms.ic, 21.0.0.0.0 ] , [ oracle.rdbms.tg4ifxm, 21.0.0.0.0 ] , [ oracle.net.cman, 21.0.0.0.0 ] , [ oracle.ons.cclient, 21.0.0.0.0 ] , [ oracle.jdk, 1.8.0.271.00 ]  not present in the Oracle Home or a higher version is found.
    
    Patching component oracle.network.rsf, 21.0.0.0.0...
    
    Patching component oracle.rdbms, 21.0.0.0.0...
    
    Patching component oracle.rdbms.util, 21.0.0.0.0...
    
    Patching component oracle.rdbms.rsf, 21.0.0.0.0...
    
    ...
    
    
    Patching component oracle.rdbms.scheduler, 21.0.0.0.0...
    
    Patching component oracle.sdo.locator, 21.0.0.0.0...
    
    Patching component oracle.xdk.rsf, 21.0.0.0.0...
    
    Patching component oracle.precomp.common, 21.0.0.0.0...
    
    Patching component oracle.precomp.lang, 21.0.0.0.0...
    
    Patching component oracle.jdk, 1.8.0.291.09...
    Patch 34160444 successfully applied.
    Sub-set patch [33516412] has become inactive due to the application of a super-set patch [34160444].
    Please refer to Doc ID 2161861.1 for any possible further required actions.
    Log file location: /u01/app/oracle/product/21/cfgtoollogs/opatch/opatch2022-07-20_17-29-52PM_1.log
    
    OPatch succeeded.
    

    Looks good – no errors. And again, please note that there is no OJVM bundle patch anymore since Oracle 21c since it is included into the standard RU.

  3. datapatch
    SQL*Plus: Release 21.0.0.0.0 - Production on Wed Jul 20 17:42:28 2022
    Version 21.7.0.0.0
    
    Copyright (c) 1982, 2022, Oracle.  All rights reserved.
    
    Connected to an idle instance.
    
    SQL> startup
    ORACLE instance started.
    
    Total System Global Area 1845489680 bytes
    Fixed Size		    9687056 bytes
    Variable Size		  520093696 bytes
    Database Buffers	 1308622848 bytes
    Redo Buffers		    7086080 bytes
    Database mounted.
    Database opened.
    SQL> exit
    Disconnected from Oracle Database 21c Enterprise Edition Release 21.0.0.0.0 - Production
    Version 21.7.0.0.0
    [CDB3] oracle@hol:~/34160444
    $ $ORACLE_HOME/OPatch/datapatch -verbose
    SQL Patching tool version 21.7.0.0.0 Production on Wed Jul 20 17:42:59 2022
    Copyright (c) 2012, 2022, Oracle.  All rights reserved.
    
    Log file for this invocation: /u01/app/oracle/homes/OraDB21Home1/cfgtoollogs/sqlpatch/sqlpatch_6860_2022_07_20_17_42_59/sqlpatch_invocation.log
    
    Connecting to database...OK
    Gathering database info...done
    
    Note:  Datapatch will only apply or rollback SQL fixes for PDBs
           that are in an open state, no patches will be applied to closed PDBs.
           Please refer to Note: Datapatch: Database 12c Post Patch SQL Automation
           (Doc ID 1585822.1)
    
    Bootstrapping registry and package to current versions...done
    Determining current state...done
    
    Current state of interim SQL patches:
      No interim patches found
    
    Current state of release update SQL patches:
      Binary registry:
        21.7.0.0.0 Release_Update 220628175910: Installed
      PDB CDB$ROOT:
        Applied 21.5.0.0.0 Release_Update 220107185933 successfully on 19-JAN-22 02.27.19.938360 PM
      PDB PDB$SEED:
        Applied 21.5.0.0.0 Release_Update 220107185933 successfully on 19-JAN-22 02.27.20.278645 PM
    
    Adding patches to installation queue and performing prereq checks...done
    Installation queue:
      For the following PDBs: CDB$ROOT
        No interim patches need to be rolled back
        Patch 34160444 (Database Release Update : 21.7.0.0.220719 (34160444)):
          Apply from 21.5.0.0.0 Release_Update 220107185933 to 21.7.0.0.0 Release_Update 220628175910
        No interim patches need to be applied
      For the following PDBs: PDB$SEED
        No interim patches need to be rolled back
        Patch 34160444 (Database Release Update : 21.7.0.0.220719 (34160444)):
          Apply from 21.5.0.0.0 Release_Update 220107185933 to 21.7.0.0.0 Release_Update 220628175910
        No interim patches need to be applied
    
    Installing patches...
    Patch installation complete.  Total patches installed: 2
    
    Validating logfiles...done
    Patch 34160444 apply (pdb CDB$ROOT): SUCCESS
      logfile: /u01/app/oracle/homes/OraDB21Home1/cfgtoollogs/sqlpatch/34160444/24850944/34160444_apply_CDB3_CDBROOT_2022Jul20_17_43_13.log (no errors)
    Patch 34160444 apply (pdb PDB$SEED): SUCCESS
      logfile: /u01/app/oracle/homes/OraDB21Home1/cfgtoollogs/sqlpatch/34160444/24850944/34160444_apply_CDB3_PDBSEED_2022Jul20_17_45_14.log (no errors)
    SQL Patching tool complete on Wed Jul 20 17:46:25 2022
    

    Looks flawless as well.

  4. Enabling new optimizer fixes
    SQL*Plus: Release 21.0.0.0.0 - Production on Wed Jul 20 17:47:15 2022
    Version 21.7.0.0.0
    
    Copyright (c) 1982, 2022, Oracle.  All rights reserved.
    
    
    Connected to:
    Oracle Database 21c Enterprise Edition Release 21.0.0.0.0 - Production
    Version 21.7.0.0.0
    
    SQL> set serveroutput on;
    SQL> execute dbms_optim_bundle.getBugsforBundle;
    
    21.7.0.0.220719DBRU:
        Bug: 30771009,  fix_controls: 30771009
        Bug: 29413205,  fix_controls: 29413205
        Bug: 28044739,  fix_controls: 28044739
        Bug: 33089096,  fix_controls: 31545400
    
    PL/SQL procedure successfully completed.
    
    SQL> execute dbms_optim_bundle.enable_optim_fixes('ON','BOTH', 'YES')
    DBMS_OPTIM command:  dbms_optim_bundle.enable_optim_fixes('ON', 'BOTH', 'YES')
    
    Bundle's _fix_control setting as per action:ON
    31988833:1  32800137:0	32408640:1  29738374:1	33325981:1  32913527:0
    32766397:0  31912834:1	33145153:1  31843716:0	32212062:0  31880080:0
    32856375:1  33297275:1	33323903:1  32302470:1	32851615:1  32754044:1
    30771009:1  29413205:1	28044739:1  31545400:1
    
    Taking current instance CDB3 as base, details on _fix_control setting for
    CON_ID 1 :
    
    1) Current _fix_control setting for spfile:
    31988833:1  32800137:0	32408640:1  29738374:1	33325981:1  32913527:0
    32766397:0  31912834:1	33145153:1  31843716:0	32212062:0  31880080:0
    
    2) Final _fix_control setting for spfile considering current_setting_precedence
    is YES
    31988833:1  32800137:0	32408640:1  29738374:1	33325981:1  32913527:0
    32766397:0  31912834:1	33145153:1  31843716:0	32212062:0  31880080:0
    32856375:1  33297275:1	33323903:1  32302470:1	32851615:1  32754044:1
    30771009:1  29413205:1	28044739:1  31545400:1
    
    3) Current _fix_control setting in memory:
    31988833:1  32800137:0	32408640:1  29738374:1	33325981:1  32913527:0
    32766397:0  31912834:1	33145153:1  31843716:0	32212062:0  31880080:0
    32856375:0  33297275:0	33323903:0  32302470:0	32851615:0  32754044:0
    30771009:0  29413205:0	28044739:0  31545400:0
    
    4) Final _fix_control setting for memory considering current_setting_precedence
    is YES
    31988833:1  32800137:0	32408640:1  29738374:1	33325981:1  32913527:0
    32766397:0  31912834:1	33145153:1  31843716:0	32212062:0  31880080:0
    32856375:0  33297275:0	33323903:0  32302470:0	32851615:0  32754044:0
    30771009:0  29413205:0	28044739:0  31545400:0
    
    WARNING: final _fix_control setting for memory is not same as final
    _fix_control setting for spfile. Please look at point 2 and 4 above to see the
    differences.
    
    PL/SQL procedure successfully completed.
    

    Let me repeat what I wrote before already several times: New optimizer fixes are there for a reason. But it is your choice whether you’d like to enable them after patching, or keep them disabled. Just make sure when you upgrade or create a new database to always enable them.

Applying RU and OJVM 19.6.0 July 2022 to my 19c home

Next exercise is my 19c home, the one I am using the most often. And here I have also OJVM installed to reproduce several cases crossing my radar from time to time.

  1. Prechecks
    Without massaging my oui-patch.xml as in the previous quarter with this workaround, this part is very slow of course. Since the opatch documentation usually is not very informative about improvements, I can’t tell you whether the fixes they’d like to do are in, or not. I’d guess, at least for this part of the patching process, there aren’t any improvements I could see/feel in my environment.To be very frank, this is the most annoying part of the entire patching experience to me. I know why it takes so long. And since the prechecks will get repeated for no obvious reason again later, it is frustrating at best. I know that the opatch team has committed to deliver a solution. And I keep the faith that this will happen soon. Still, I don’t know any ETA date. Let’s keep our fingers crossed.
  2. opatch apply
    $ORACLE_HOME/OPatch/opatch apply
    Oracle Interim Patch Installer version 12.2.0.1.32
    Copyright (c) 2022, Oracle Corporation.  All rights reserved.
    
    
    Oracle Home       : /u01/app/oracle/product/19
    Central Inventory : /u01/app/oraInventory
       from           : /u01/app/oracle/product/19/oraInst.loc
    OPatch version    : 12.2.0.1.32
    OUI version       : 12.2.0.7.0
    Log file location : /u01/app/oracle/product/19/cfgtoollogs/opatch/opatch2022-07-20_18-16-01PM_1.log
    
    Verifying environment and performing prerequisite checks...
    
    --------------------------------------------------------------------------------
    Start OOP by Prereq process.
    Launch OOP...
    
    Oracle Interim Patch Installer version 12.2.0.1.32
    Copyright (c) 2022, Oracle Corporation.  All rights reserved.
    
    
    Oracle Home       : /u01/app/oracle/product/19
    Central Inventory : /u01/app/oraInventory
       from           : /u01/app/oracle/product/19/oraInst.loc
    OPatch version    : 12.2.0.1.32
    OUI version       : 12.2.0.7.0
    Log file location : /u01/app/oracle/product/19/cfgtoollogs/opatch/opatch2022-07-20_18-22-41PM_1.log
    
    Verifying environment and performing prerequisite checks...
    OPatch continues with these patches:   34133642  
    
    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 = '/u01/app/oracle/product/19')
    
    
    Is the local system ready for patching? [y|n]
    y
    User Responded with: Y
    Backing up files...
    Applying interim patch '34133642' to OH '/u01/app/oracle/product/19'
    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.rdbms.tg4ifmx, 19.0.0.0.0 ] , [ oracle.options.olap, 19.0.0.0.0 ] , [ oracle.ons.cclient, 19.0.0.0.0 ] , [ oracle.rdbms.tg4tera, 19.0.0.0.0 ] , [ oracle.sdo.companion, 19.0.0.0.0 ] , [ oracle.xdk.companion, 19.0.0.0.0 ] , [ oracle.options.olap.api, 19.0.0.0.0 ] , [ oracle.ons.eons.bwcompat, 19.0.0.0.0 ] , [ oracle.rdbms.tg4msql, 19.0.0.0.0 ] , [ oracle.oid.client, 19.0.0.0.0 ] , [ oracle.rdbms.tg4sybs, 19.0.0.0.0 ] , [ oracle.net.cman, 19.0.0.0.0 ] , [ oracle.network.cman, 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.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.perlint, 5.28.1.0.0...
    
    Patching component oracle.rdbms.locator, 19.0.0.0.0...
    
    ...
    
    Patching component oracle.sdo.locator, 19.0.0.0.0...
    
    Patching component oracle.network.listener, 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 34133642 successfully applied.
    Sub-set patch [33515361] has become inactive due to the application of a super-set patch [34133642].
    Please refer to Doc ID 2161861.1 for any possible further required actions.
    Log file location: /u01/app/oracle/product/19/cfgtoollogs/opatch/opatch2022-07-20_18-22-41PM_1.log
    
    OPatch succeeded.

    Fine.

  3. datapatch
    Just to clarify this – you should run datapatch only once at the very end of your patching exercise. I ran it two times now because I forgot to apply OJVM. I didn’t want to fake the output, hence I applied OJVM and then ran datapatch a second time. Normally you should apply the RU, OJVM is needed, one-offs – all ideally in a new separate home already installed – and then you execute datapatch at the very end only once!

    $ORACLE_HOME/OPatch/datapatch -verbose
    SQL Patching tool version 19.16.0.0.0 Production on Wed Jul 20 20:27:15 2022
    Copyright (c) 2012, 2022, Oracle.  All rights reserved.
    
    Log file for this invocation: /u01/app/oracle/cfgtoollogs/sqlpatch/sqlpatch_24454_2022_07_20_20_27_15/sqlpatch_invocation.log
    
    Connecting to database...OK
    Gathering database info...done
    
    Note:  Datapatch will only apply or rollback SQL fixes for PDBs
           that are in an open state, no patches will be applied to closed PDBs.
           Please refer to Note: Datapatch: Database 12c Post Patch SQL Automation
           (Doc ID 1585822.1)
    
    Bootstrapping registry and package to current versions...done
    Determining current state...done
    
    Current state of interim SQL patches:
    Interim patch 33192694 (OJVM RELEASE UPDATE: 19.13.0.0.211019 (33192694)):
      Binary registry: Not installed
      PDB CDB$ROOT: Rolled back successfully on 19-JAN-22 10.14.44.327180 PM
      PDB PDB$SEED: Rolled back successfully on 19-JAN-22 10.14.44.347566 PM
    Interim patch 33561310 (OJVM RELEASE UPDATE: 19.14.0.0.220118 (33561310)):
      Binary registry: Installed
      PDB CDB$ROOT: Applied successfully on 19-JAN-22 10.14.44.331372 PM
      PDB PDB$SEED: Applied successfully on 19-JAN-22 10.14.44.350816 PM
    
    Current state of release update SQL patches:
      Binary registry:
        19.16.0.0.0 Release_Update 220703022223: Installed
      PDB CDB$ROOT:
        Applied 19.14.0.0.0 Release_Update 211225122123 successfully on 19-JAN-22 09.48.19.540225 PM
      PDB PDB$SEED:
        Applied 19.14.0.0.0 Release_Update 211225122123 successfully on 19-JAN-22 09.48.19.756424 PM
    
    Adding patches to installation queue and performing prereq checks...done
    Installation queue:
      For the following PDBs: CDB$ROOT PDB$SEED
        No interim patches need to be rolled back
        Patch 34133642 (Database Release Update : 19.16.0.0.220719 (34133642)):
          Apply from 19.14.0.0.0 Release_Update 211225122123 to 19.16.0.0.0 Release_Update 220703022223
        No interim patches need to be applied
    
    Installing patches...
    Patch installation complete.  Total patches installed: 2
    
    Validating logfiles...done
    Patch 34133642 apply (pdb CDB$ROOT): SUCCESS
      logfile: /u01/app/oracle/cfgtoollogs/sqlpatch/34133642/24865470/34133642_apply_CDB2_CDBROOT_2022Jul20_20_28_07.log (no errors)
    Patch 34133642 apply (pdb PDB$SEED): SUCCESS
      logfile: /u01/app/oracle/cfgtoollogs/sqlpatch/34133642/24865470/34133642_apply_CDB2_PDBSEED_2022Jul20_20_29_30.log (no errors)
    SQL Patching tool complete on Wed Jul 20 20:30:42 2022
    

    Good. Time for the next step.

  4. Doing OJVM now for a change – not a good idea since I need to run datapatch now twice.
    $ORACLE_HOME/OPatch/opatch apply
    Oracle Interim Patch Installer version 12.2.0.1.32
    Copyright (c) 2022, Oracle Corporation.  All rights reserved.
    
    
    Oracle Home       : /u01/app/oracle/product/19
    Central Inventory : /u01/app/oraInventory
       from           : /u01/app/oracle/product/19/oraInst.loc
    OPatch version    : 12.2.0.1.32
    OUI version       : 12.2.0.7.0
    Log file location : /u01/app/oracle/product/19/cfgtoollogs/opatch/opatch2022-07-20_20-54-21PM_1.log
    
    Verifying environment and performing prerequisite checks...
    
    --------------------------------------------------------------------------------
    Start OOP by Prereq process.
    Launch OOP...
    
    Oracle Interim Patch Installer version 12.2.0.1.32
    Copyright (c) 2022, Oracle Corporation.  All rights reserved.
    
    
    Oracle Home       : /u01/app/oracle/product/19
    Central Inventory : /u01/app/oraInventory
       from           : /u01/app/oracle/product/19/oraInst.loc
    OPatch version    : 12.2.0.1.32
    OUI version       : 12.2.0.7.0
    Log file location : /u01/app/oracle/product/19/cfgtoollogs/opatch/opatch2022-07-20_21-00-20PM_1.log
    
    Verifying environment and performing prerequisite checks...
    OPatch continues with these patches:   34086870  
    
    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 = '/u01/app/oracle/product/19')
    
    
    Is the local system ready for patching? [y|n]
    y
    User Responded with: Y
    Backing up files...
    Applying interim patch '34086870' to OH '/u01/app/oracle/product/19'
    
    Patching component oracle.javavm.server, 19.0.0.0.0...
    
    Patching component oracle.javavm.server.core, 19.0.0.0.0...
    
    Patching component oracle.rdbms.dbscripts, 19.0.0.0.0...
    
    Patching component oracle.rdbms, 19.0.0.0.0...
    
    Patching component oracle.javavm.client, 19.0.0.0.0...
    Patch 34086870 successfully applied.
    Sub-set patch [33561310] has become inactive due to the application of a super-set patch [34086870].
    Please refer to Doc ID 2161861.1 for any possible further required actions.
    Log file location: /u01/app/oracle/product/19/cfgtoollogs/opatch/opatch2022-07-20_21-00-20PM_1.log
    
    OPatch succeeded.
    
  5. datapatch again, now for OJVM
    $ORACLE_HOME/OPatch/datapatch -verbose
    SQL Patching tool version 19.16.0.0.0 Production on Wed Jul 20 21:15:16 2022
    Copyright (c) 2012, 2022, Oracle.  All rights reserved.
    
    Log file for this invocation: /u01/app/oracle/cfgtoollogs/sqlpatch/sqlpatch_30826_2022_07_20_21_15_16/sqlpatch_invocation.log
    
    Connecting to database...OK
    Gathering database info...done
    
    Note:  Datapatch will only apply or rollback SQL fixes for PDBs
           that are in an open state, no patches will be applied to closed PDBs.
           Please refer to Note: Datapatch: Database 12c Post Patch SQL Automation
           (Doc ID 1585822.1)
    
    Bootstrapping registry and package to current versions...done
    Determining current state...done
    
    Current state of interim SQL patches:
    Interim patch 33192694 (OJVM RELEASE UPDATE: 19.13.0.0.211019 (33192694)):
      Binary registry: Not installed
      PDB CDB$ROOT: Rolled back successfully on 19-JAN-22 10.14.44.327180 PM
      PDB PDB$SEED: Rolled back successfully on 19-JAN-22 10.14.44.347566 PM
    Interim patch 33561310 (OJVM RELEASE UPDATE: 19.14.0.0.220118 (33561310)):
      Binary registry: Not installed
      PDB CDB$ROOT: Applied successfully on 19-JAN-22 10.14.44.331372 PM
      PDB PDB$SEED: Applied successfully on 19-JAN-22 10.14.44.350816 PM
    Interim patch 34086870 (OJVM RELEASE UPDATE: 19.16.0.0.220719 (34086870)):
      Binary registry: Installed
      PDB CDB$ROOT: Not installed
      PDB PDB$SEED: Not installed
    
    Current state of release update SQL patches:
      Binary registry:
        19.16.0.0.0 Release_Update 220703022223: Installed
      PDB CDB$ROOT:
        Applied 19.16.0.0.0 Release_Update 220703022223 successfully on 20-JUL-22 08.30.37.698095 PM
      PDB PDB$SEED:
        Applied 19.16.0.0.0 Release_Update 220703022223 successfully on 20-JUL-22 08.30.38.297082 PM
    
    Adding patches to installation queue and performing prereq checks...done
    Installation queue:
      For the following PDBs: CDB$ROOT PDB$SEED
        The following interim patches will be rolled back:
          33561310 (OJVM RELEASE UPDATE: 19.14.0.0.220118 (33561310))
        No release update patches need to be installed
        The following interim patches will be applied:
          34086870 (OJVM RELEASE UPDATE: 19.16.0.0.220719 (34086870))
    
    Installing patches...
    Patch installation complete.  Total patches installed: 4
    
    Validating logfiles...done
    Patch 33561310 rollback (pdb CDB$ROOT): SUCCESS
      logfile: /u01/app/oracle/cfgtoollogs/sqlpatch/33561310/24538862/33561310_rollback_CDB2_CDBROOT_2022Jul20_21_15_51.log (no errors)
    Patch 34086870 apply (pdb CDB$ROOT): SUCCESS
      logfile: /u01/app/oracle/cfgtoollogs/sqlpatch/34086870/24803071/34086870_apply_CDB2_CDBROOT_2022Jul20_21_17_01.log (no errors)
    Patch 33561310 rollback (pdb PDB$SEED): SUCCESS
      logfile: /u01/app/oracle/cfgtoollogs/sqlpatch/33561310/24538862/33561310_rollback_CDB2_PDBSEED_2022Jul20_21_17_02.log (no errors)
    Patch 34086870 apply (pdb PDB$SEED): SUCCESS
      logfile: /u01/app/oracle/cfgtoollogs/sqlpatch/34086870/24803071/34086870_apply_CDB2_PDBSEED_2022Jul20_21_17_02.log (no errors)
    SQL Patching tool complete on Wed Jul 20 21:17:04 2022
    
  6. Optimizer fixes
    SQL*Plus: Release 19.0.0.0.0 - Production on Wed Jul 20 20:48:50 2022
    Version 19.16.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.16.0.0.0
    
    SQL> set serverout on
    SQL> execute dbms_optim_bundle.getBugsforBundle;
    
    19.16.0.0.220719DBRU:
        Bug: 28044739,  fix_controls: 28044739
        Bug: 30771009,  fix_controls: 30771009
        Bug: 33636280,  fix_controls: 33636280
        Bug: 33089096,  fix_controls: 31545400
        Bug: 30618406,  fix_controls: 30618406
        Bug: 32614157,  fix_controls: 32614157
        Bug: 33329027,  fix_controls: 33329027
        Bug: 33311488,  fix_controls: 33311488
        Bug: 32396085,  fix_controls: 32396085
        Bug: 32122197,  fix_controls: 29972495
        Bug: 32363981,  fix_controls: 32363981
    
    PL/SQL procedure successfully completed.
    
    SQL> execute dbms_optim_bundle.enable_optim_fixes('ON','BOTH', 'YES')
    
    

Applying the BP July 2022 to my Oracle 12.1.0.2 home

Since there is a delay with this BP, I will add it after my trip to YATRA.

 

Applying the PSU July 2022 to my Oracle 11.20.4 home

Since there is a delay with this PSU, I will add it after my trip to YATRA.

 

Your patch is not available right now?

In case you miss the patch bundle for your release and platform, please read this blog post.

 

Finally … clean up

Oh yes, my patching experience doesn’t get easier every time unfortunately. Since opatch does still not allow to define a “n-1” rule or pattern meaning “remove everything from my box except the previous patch bundle” I will need to do the cleanup by myself.

See here on how to do the cleanup of older bundles to free up space:

 

Further Information and Links

–Mike

Share this: