Oracle 19c 打19.6 的RU opatchauto 报错OPatchException: Unable to create patchObject 解决方法
1. 错误现象
打19.6 的RU, 报如下错误:
[root@www.cndba.cn2 ~]# /u01/app/oracle/product/19.3.0/db_1/OPatch/opatchauto apply /tmp/30501910 -oh /u01/app/oracle/product/19.3.0/db_1 -nonrolling
OPatchauto session is initiated at Fri Mar 13 22:43:13 2020
System initialization log file is /u01/app/oracle/product/19.3.0/db_1/cfgtoollogs/opatchautodb/systemconfig2020-03-13_10-43-21PM.log.
Session log file is /u01/app/oracle/product/19.3.0/db_1/cfgtoollogs/opatchauto/opatchauto2020-03-13_10-44-21PM.log
The id for this session is JYQ6
Executing OPatch prereq operations to verify patch applicability on home /u01/app/oracle/product/19.3.0/db_1
Patch applicability verification failed on home /u01/app/oracle/product/19.3.0/db_1
Execution of [OPatchAutoBinaryAction] patch action failed, check log for more details. Failures:
Patch Target : rac2->/u01/app/oracle/product/19.3.0/db_1 Type[rac]
Details: [
---------------------------Patching Failed---------------------------------
Command execution failed during patching in home: /u01/app/oracle/product/19.3.0/db_1, host: rac2.
Command failed: /u01/app/oracle/product/19.3.0/db_1/OPatch/opatchauto apply /tmp/30501910 -oh /u01/app/oracle/product/19.3.0/db_1 -target_type rac_database -binary -invPtrLoc /u01/app/oracle/product/19.3.0/db_1/oraInst.loc -jre /u01/app/oracle/product/19.3.0/db_1/OPatch/jre -persistresult /u01/app/oracle/product/19.3.0/db_1/opatchautocfg/db/sessioninfo/sessionresult_analyze_rac2_rac.ser -analyze -online -prepare_home
Command failure output:
==Following patches FAILED in analysis for apply:
Patch: /tmp/30501910/30489227
Log:
Reason: Failed during listing in Analysis: java.lang.Exception: oracle.opatch.opatchsdk.OPatchException: Unable to create patchObject
Possible causes are:
ORACLE_HOME/inventory/oneoffs/30489227 is corrupted. PatchObject constructor: Input file "/u01/app/oracle/product/19.3.0/db_1/inventory/oneoffs/30489227/etc/config/actions" or "/u01/app/oracle/product/19.3.0/db_1/inventory/oneoffs/30489227/etc/config/inventory" does not exist.
Patch: /tmp/30501910/30557433
Log:
Reason: Failed during listing in Analysis: java.lang.Exception: oracle.opatch.opatchsdk.OPatchException: Unable to create patchObject
Possible causes are:
ORACLE_HOME/inventory/oneoffs/30489227 is corrupted. PatchObject constructor: Input file "/u01/app/oracle/product/19.3.0/db_1/inventory/oneoffs/30489227/etc/config/actions" or "/u01/app/oracle/product/19.3.0/db_1/inventory/oneoffs/30489227/etc/config/inventory" does not exist.
After fixing the cause of failure Run opatchauto resume
]
OPATCHAUTO-68061: The orchestration engine failed.
OPATCHAUTO-68061: The orchestration engine failed with return code 1
OPATCHAUTO-68061: Check the log for more details.
OPatchAuto failed.
OPatchauto session completed at Fri Mar 13 22:44:45 2020
Time taken to complete the session 1 minute, 33 seconds
opatchauto failed with error code 42
[root@www.cndba.cn2 ~]#
2. MOS 上的说明
OPatch lsinventory or Apply New Patch With Opatchauto Fails With Error “Unable to create patchObject” Inventory Corrupted (Doc ID 2286025.1)
CAUSE
Applied OJVM patch on Hostname1 which prompted to apply to remote Hostname2.
OJVM patch got applied to both Hostname1 and Hostname2 successfully to Database Home.
Corrupt inventory errors with “opatch lsinventory” or “opatchauto -analyze” comes due to non existing DB PSU patch (25171037 - 12.1.0.2.170418 DBPSU) on Hostname2 Database home which is not yet applied.
SOLUTION
Restore Database home backup for Hostname2.
Validate “Opatch lsinventory” works without any errors on Hostname2 Database Home.
Validate opatch -analyze works on Hostname2 for Grid and DB PSU patch that is part of Combo (25434018).
Apply the Grid and DB PSU using opatchauto to Hostname2.
Apply the OJVM patch with -local option to Hostname2
3. 解决方法
因为之前节点1已经成功打上,所以这里按MOS提供的建议,从节点1上把相同位置的2个补丁复制过来
[oracle@www.cndba.cn1 oneoffs]$ scp 30489227 rac2:`pwd`
30489227: not a regular file
[oracle@www.cndba.cn1 oneoffs]$ scp -r 30489227 rac2:`pwd`
inventory.xml 100% 45KB 18.8MB/s 00:00
actions.xml 100% 95KB 25.2MB/s 00:00
[oracle@www.cndba.cn1 oneoffs]$ scp -r 30557433 rac2:`pwd`
inventory.xml 100% 163KB 28.3MB/s 00:00
actions.xml 100% 1806KB 35.9MB/s 00:00
[oracle@www.cndba.cn1 oneoffs]$ pwd
/u01/app/oracle/product/19.3.0/db_1/inventory/oneoffs
[oracle@www.cndba.cn1 oneoffs]$ ls
29517242 29585399 30489227 30557433
[oracle@www.cndba.cn1 oneoffs]$
再运行正常:
[root@www.cndba.cn2 ~]# /u01/app/oracle/product/19.3.0/db_1/OPatch/opatchauto apply /tmp/30501910 -oh /u01/app/oracle/product/19.3.0/db_1 -nonrolling
OPatchauto session is initiated at Fri Mar 13 22:49:14 2020
System initialization log file is /u01/app/oracle/product/19.3.0/db_1/cfgtoollogs/opatchautodb/systemconfig2020-03-13_10-49-21PM.log.
Session log file is /u01/app/oracle/product/19.3.0/db_1/cfgtoollogs/opatchauto/opatchauto2020-03-13_10-50-20PM.log
The id for this session is GXFF
Executing OPatch prereq operations to verify patch applicability on home /u01/app/oracle/product/19.3.0/db_1
Patch applicability verified successfully on home /u01/app/oracle/product/19.3.0/db_1
Verifying SQL patch applicability on home /u01/app/oracle/product/19.3.0/db_1
SQL patch applicability verified successfully on home /u01/app/oracle/product/19.3.0/db_1
Preparing to bring down database service on home /u01/app/oracle/product/19.3.0/db_1
Successfully prepared home /u01/app/oracle/product/19.3.0/db_1 to bring down database service
Bringing down database service on home /u01/app/oracle/product/19.3.0/db_1
Database service successfully brought down on home /u01/app/oracle/product/19.3.0/db_1
Performing prepatch operation on home /u01/app/oracle/product/19.3.0/db_1
Perpatch operation completed successfully on home /u01/app/oracle/product/19.3.0/db_1
Start applying binary patch on home /u01/app/oracle/product/19.3.0/db_1
Binary patch applied successfully on home /u01/app/oracle/product/19.3.0/db_1
Performing postpatch operation on home /u01/app/oracle/product/19.3.0/db_1
Postpatch operation completed successfully on home /u01/app/oracle/product/19.3.0/db_1
Starting database service on home /u01/app/oracle/product/19.3.0/db_1
Database service successfully started on home /u01/app/oracle/product/19.3.0/db_1
Preparing home /u01/app/oracle/product/19.3.0/db_1 after database service restarted
No step execution required.........
Trying to apply SQL patch on home /u01/app/oracle/product/19.3.0/db_1
SQL patch applied successfully on home /u01/app/oracle/product/19.3.0/db_1
OPatchAuto successful.
--------------------------------Summary--------------------------------
Patching is completed successfully. Please find the summary as follows:
Host:rac2
RAC Home:/u01/app/oracle/product/19.3.0/db_1
Version:19.0.0.0.0
Summary:
==Following patches were SKIPPED:
Patch: /tmp/30501910/30489632
Reason: This patch is not applicable to this specified target type - "rac_database"
Patch: /tmp/30501910/30655595
Reason: This patch is not applicable to this specified target type - "rac_database"
Patch: /tmp/30501910/30489227
Reason: This patch is already been applied, so not going to apply again.
==Following patches were SUCCESSFULLY applied:
Patch: /tmp/30501910/30557433
Log: /u01/app/oracle/product/19.3.0/db_1/cfgtoollogs/opatchauto/core/opatch/opatch2020-03-13_22-51-09PM_1.log
Patching session reported following warning(s):
_________________________________________________
[WARNING] The database instance 'cndba2' from '/u01/app/oracle/product/19.3.0/db_1', in host'rac2' is not running. SQL changes, if any, will not be applied.
To apply. the SQL changes, bring up the database instance and run the command manually from any one node (run as oracle).
Refer to the readme to get the correct steps for applying the sql changes.
OPatchauto session completed at Fri Mar 13 23:00:17 2020
Time taken to complete the session 11 minutes, 4 seconds
[root@www.cndba.cn2 ~]#
版权声明:本文为博主原创文章,未经博主允许不得转载。