暂无图片
暂无图片
暂无图片
暂无图片
暂无图片

[译文] 使用2022年7月补丁修补Oracle大部分环境

原创 通讯员 2022-07-22
1900

七月,外面酷热难耐,我坐在凉爽的地下室办公室里,开始我的季度修补之旅,希望你能在某个地方享受阳光和大海。是时候做我平时的练习了,这次用 2022 年 7 月的补丁包修补我的大部分环境

国家癌症研究所Unsplash上拍摄的照片

像往常一样,前面有一个重要的注释:由于空间问题,我就地修补。但在现实中,你请总是用一个单独的家来修补不合适的地方。请参阅这篇博文,了解如何在使用 OUI 配置新家时直接应用 RU

 

2022 年 7 月安全警报

您将在此处找到所有产品的2022 年 7 月安全警报和往常一样,请密切关注数据库服务器产品风险矩阵您会发现常见的问题,例如 OJVM,但更重要的是 9.1 数据库问题。因此,您不需要建议。您必须将此 RU 应用于您的环境,因为 10.0 将是高分。另请记住,至少在网络的较暗角落可能已经存在漏洞利用。

使用 2022 年 7 月的捆绑补丁修补我的大部分环境

Oracle 数据库风险矩阵 - 2022 年 7 月 - 请参阅:https://www.oracle.com/security-alerts/cpujul2022.html#AppendixDB

由于过去几周我就 Oracle 数据库 11.2.0.4 进行了多次讨论,因此我想提一下非常重要的事情。

“受影响的受支持版本”一栏不再提及 Oracle 11g、12.2 或 18c,原因很简单:这些版本都不受 Premier 或 Extended Support 的支持。但是您几乎可以肯定地假设第一个问题也会影响这些版本。因此,您有两个选择:注册市场驱动支持 (MDS) 或升级到 19c。任何地方都没有专家可以帮助您,因为没有“虚拟修补”之类的东西。

请始终注意,风险矩阵中指出的问题也可能发生在旧版本中,即使它们不再被提及。

 

数据库补丁包

您将在MOS Note: 2867871.1 – Critical Patch Update (CPU) Program Jul 2022 Patch Availability Document (DB-only)中找到各个补丁包的链接但是您也可以使用MOS Note: 2118136.2 – Assistant: Download Reference for Oracle Database/GI Update, Revision, PSU, SPU(CPU), Bundle Patches, Patchsets and Base Releases来下载“你的”包。

我需要一个新的 OPatch 吗?

然后又到了 opatch 检查的时候了。甚至没有看到数字,我可以告诉你,你必须刷新你的 opatch,因为所有平台上的 30 版本都有一些显着的性能改进。但是让我仔细检查一下自述文件:

  • 21.7.0 需要 opatch 12.2.0.1。30 岁或以后
  • 19.16.0 需要 opatch 12.2.0.1。30 岁或以后
  • 12.1.0.2 BP 2022 年 7 月需要 opatch 12.2.0.1。30 岁或以后
  • 11.2.0.4 PSU 2022 年 7 月需要 opatch 11.2.0.3。33 岁  或以后

最新的 opatch 版本已经是 32而且由于我知道可能包含一些改进,我将在我所有的家中更新 opatch。自述文件中的6880880 链接将您直接带到正确的下载。但是……您将被定向到 12.2.0.1。30版本的 opatch,而不是 29 版本。您可能不会感到奇怪,12.1 – 21c 的所有三个 opatch 版本都是相同的,即使它们在 MOS 上都有不同的显示标签。所以就我而言,只下载一次就足够了。

对于 11g opatch,它将指向 11.2.0.3。34版本也是如此。这很好。我只是想提一下。

因此,在我开始修补之前,我所有环境的第 1 项操作:

  • 要么清除OPatch每个主目录中的当前目录,然后解压缩新的 OPatch 包,要么使用unzip -o选项

 

将 RU 21.7.0 应用到我的 Oracle 21c 主页

我总是做你不应该做的事情。我将补丁应用到我现有的家中。这与我的实验室环境中的可用空间有关。请按照我在此处的描述立即提供新家并应用补丁

将我的 21c 数据库主页修补到 RU 21.6.0 再次非常简单。

  1. 冲突和空间检查


ike Dietrich's Blog About Oracle Database Upgrades… Mostly

Blog
Slides
Hands-On Lab
Events
Videos
Scripts
Links
Oracle Documentation
Privacy
About
Patching most of my environments with the July 2022 Bundle Patches
Posted on July 21, 2022 by Mike.Dietrich Patch Recommendation0
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.

Patching most of my environments with the July 2022 Bundle Patches
Photo by National Cancer Institute on Unsplash

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 asvirtual 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.1Critical 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
Database Release Update 21.7.0.0.220719 Patch 34160444 for UNIX
README
List of fixes: MOS Note: 2814015.1
Oracle Database 19c
Database Release Update 19.16.0.0.220719 Patch 34133642 for UNIX
README
List of fixes: MOS Note: 2523220.1
OJVM Release Update 19.16.0.0.220719 Patch 34086870 for all platforms
README
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.121c 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.

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.


好的。继续往下走。


2. 补丁申请


$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.



看起来不错——没有错误。再次请注意,自 Oracle 21c 以来不再有 OJVM 捆绑补丁,因为它包含在标准 RU 中。


3. 数据补丁


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


看起来也完美无瑕。


4. 启用新的优化器修复


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


  1. 我重复我之前写过的内容:新的优化器修复是有原因的。但是您可以选择是在修补后启用它们还是保持禁用它们。只需确保在升级或创建新数据库时始终启用它们。

将 RU 和 OJVM 19.6.0 2022 年 7 月应用到我的 19c 家

下一个练习是我最常使用的 19c 家。在这里,我还安装了 OJVM 来重现几个不时穿过我的雷达的案例。

  1. 使用此解决方法,无需像上一季度
    那样按摩我的 oui-patch.xml 进行预检查,这部分当然很慢。由于 opatch 文档通常不会提供有关改进的非常丰富的信息,因此我无法告诉您他们想要做的修复是否存在。我猜想,至少在修补过程的这一部分,我的环境没有任何改进。坦率地说,这是整个修补过程中对我来说最烦人的部分。我知道为什么需要这么长时间。而且由于预检会在以后没有明显原因的情况下再次重复,这充其量是令人沮丧的。我知道 opatch 团队已承诺提供解决方案。我坚信这很快就会发生。不过,我不知道任何 ETA 日期。让我们保持手指交叉。
  2. 补丁申请


$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.


好的。


3. 数据补丁


$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


好的。是时候进行下一步了。


4.现在执行 OJVM 以进行更改——这不是一个好主意,因为我现在需要运行两次 datapatch。

$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. 再次数据补丁,现在用于 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. 优化器修复


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')



将 BP 2022 年 7 月应用于我的 Oracle 12.1.0.2 主页

由于这个 BP 有延迟,我会在我去YATRA之后添加它。

 

将 PSU 2022 年 7 月应用到我的 Oracle 11.20.4 家

由于这个 PSU 有延迟,我会在我去YATRA之后添加它。

 

你的补丁现在不可用?

如果您错过了适用于您的版本和平台的补丁包,请阅读这篇博文。

 

最后……清理

哦,是的,不幸的是,我的修补体验并非每次都变得更轻松。由于 opatch 仍然不允许定义“n-1”规则或模式,意思是“从我的盒子中删除除上一个补丁包之外的所有内容”,我需要自己进行清理。

请参阅此处了解如何清理旧捆绑包以释放空间:

 

更多信息和链接


作者:Mike.Dietrich

文章来源:https://mikedietrichde.com/2022/07/21/patching-most-of-my-environments-with-the-july-2022-bundle-patches/


「喜欢这篇文章,您的关注和赞赏是给作者最好的鼓励」
关注作者
【版权声明】本文为墨天轮用户原创内容,转载时必须标注文章的来源(墨天轮),文章链接,文章作者等基本信息,否则作者和墨天轮有权追究责任。如果您发现墨天轮中有涉嫌抄袭或者侵权的内容,欢迎发送邮件至:contact@modb.pro进行举报,并提供相关证据,一经查实,墨天轮将立刻删除相关内容。

评论