安装35042068补丁

发布时间 2023-04-26 17:52:40作者: slnngk

环境:
OS:Centos 8
DB:19.3.0.0

 

1.解压
[root@slnngk soft]#unzip p35042068_190000_Linux-x86-64.zip

 

2.修改目录权限
[root@slnngk soft]# chown -R oracle:oinstall ./patch/

 

3.检查

[oracle@slnngk 35042068]$ /u01/app/oracle/product/19.3.0.0/db_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       : /u01/app/oracle/product/19.3.0.0/db_1
Central Inventory : /u01/app/oraInventory
   from           : /u01/app/oracle/product/19.3.0.0/db_1/oraInst.loc
OPatch version    : 12.2.0.1.17
OUI version       : 12.2.0.7.0
Log file location : /u01/app/oracle/product/19.3.0.0/db_1/cfgtoollogs/opatch/opatch2023-04-25_05-06-16AM_1.log

Invoking prereq "checkconflictagainstohwithdetail"

Prereq "checkConflictAgainstOHWithDetail" passed.

OPatch succeeded.

 

3.关闭数据库和监听程序
[oracle@slnngk 35042068]$ lsnrctl stop
SQL> connect / as sysdba
Connected.
SQL> shutdown immediate
Database closed.
Database dismounted.

 

4.打补丁

[oracle@slnngk 35042068]$cd /soft/patch/35042068
[oracle@slnngk 35042068]$/u01/app/oracle/product/19.3.0.0/db_1/OPatch/opatch apply

The OPatch being used has version 12.2.0.1.17 while the following patch(es) require higher versions: 
Patch 35042068 requires OPatch version 12.2.0.1.36.
Please download latest OPatch from My Oracle Support.

UtilSession failed: Prerequisite check "CheckMinimumOPatchVersion" failed.
Log file location: /u01/app/oracle/product/19.3.0.0/db_1/cfgtoollogs/opatch/opatch2023-04-25_05-13-03AM_1.log

OPatch failed with error code 73

 

这里需要升级补丁安装程序,可以参考:
https://www.cnblogs.com/hxlasky/p/15624579.html

查看补丁情况
/u01/app/oracle/product/19.3.0.0/db_1/OPatch/opatch lsinventory>a.txt

 

5.安装完19.3后,然后打完补丁35042068,使用rman有如下的提示报错误:

[oracle@slnngk ~]$ rman target /

Recovery Manager: Release 19.0.0.0.0 - Production on Tue Apr 25 20:39:46 2023
Version 19.19.0.0.0

Copyright (c) 1982, 2019, Oracle and/or its affiliates.  All rights reserved.

PL/SQL package SYS.DBMS_BACKUP_RESTORE version 19.03.00.00 in TARGET database is not current
PL/SQL package SYS.DBMS_RCVMAN version 19.03.00.00 in TARGET database is not current
connected to target database: SLNNGK (DBID=3553282077)

解决办法:
connect / as sysdba
@$ORACLE_HOME/rdbms/admin/dbmsrman.sql
@$ORACLE_HOME/rdbms/admin/prvtrmns.plb   
@$ORACLE_HOME/rdbms/admin/dbmsbkrs.sql 
@$ORACLE_HOME/rdbms/admin/prvtbkrs.plb

 

rman重新登录

[oracle@slnngk ~]$ rman target /

Recovery Manager: Release 19.0.0.0.0 - Production on Tue Apr 25 20:42:41 2023
Version 19.19.0.0.0

Copyright (c) 1982, 2019, Oracle and/or its affiliates.  All rights reserved.
connected to target database: SLNNGK (DBID=3553282077)