重庆思庄Oracle、Redhat认证学习论坛

 找回密码
 注册

QQ登录

只需一步,快速开始

搜索
查看: 1631|回复: 0
打印 上一主题 下一主题

OPatch报错 "CheckActiveFilesAndExecutables" failed Prereq...

[复制链接]
跳转到指定楼层
楼主
发表于 2020-8-5 18:34:49 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
问题现象:

[oracle@strong ~]$  /u01/app/oracle/product/19.3.0/db_1/OPatch/opatch apply -local /setup/30783543/30805684
Oracle Interim Patch Installer version 12.2.0.1.21
Copyright (c) 2020, Oracle Corporation.  All rights reserved.

Oracle Home       : /u01/app/oracle/product/19.3.0/db_1
Central Inventory : /u01/app/oraInventory
   from           : /u01/app/oracle/product/19.3.0/db_1/oraInst.loc
OPatch version    : 12.2.0.1.21
OUI version       : 12.2.0.7.0
Log file location : /u01/app/oracle/product/19.3.0/db_1/cfgtoollogs/opatch/opatch2020-08-05_17-06-45PM_1.log

Verifying environment and performing prerequisite checks...
Prerequisite check "CheckActiveFilesAndExecutables" failed.
The details are:
Following active executables are not used by opatch process :
/u01/app/oracle/product/19.3.0/db_1/bin/oracle

Following active executables are used by opatch process :
UtilSession failed: Prerequisite check "CheckActiveFilesAndExecutables" failed.
Log file location: /u01/app/oracle/product/19.3.0/db_1/cfgtoollogs/opatch/opatch2020-08-05_17-06-45PM_1.log
OPatch failed with error code 73


查看opatch日志:
[oracle@strong lib]$ cat  /u01/app/oracle/product/19.3.0/db_1/cfgtoollogs/opatch/opatch2020-08-05_17-06-45PM_1.log
[Aug 5, 2020 5:06:46 PM] [INFO]     CUP_LOG: Trying to load HomeOperations object
[Aug 5, 2020 5:06:46 PM] [INFO]     CUP_LOG: HomeOperations object created. CUP1.0 is enabled
[Aug 5, 2020 5:06:46 PM] [INFO]     OPatch invoked as follows: 'apply -local /setup/30783543/30805684 -invPtrLoc /u01/app/oracle/product/19.3.0/db_1/oraInst.loc '
[Aug 5, 2020 5:06:46 PM] [INFO]     Runtime args: [-Xmx3072m, -XX:+HeapDumpOnOutOfMemoryError, -XX:HeapDumpPath=/u01/app/oracle/product/19.3.0/db_1/cfgtoollogs/opatch, -DCommonLog.LOG_SESSION_ID=, -DCommonLog.COMMAND_NAME=apply, -DOPatch.ORACLE_HOME=/u01/app/oracle/product/19.3.0/db_1, -DOPatch.DEBUG=false, -DOPatch.MAKE=false, -DOPatch.RUNNING_DIR=/u01/app/oracle/product/19.3.0/db_1/OPatch, -DOPatch.MW_HOME=, -DOPatch.WL_HOME=, -DOPatch.COMMON_COMPONENTS_HOME=, -DOPatch.OUI_LOCATION=/u01/app/oracle/product/19.3.0/db_1/oui, -DOPatch.FMW_COMPONENT_HOME=, -DOPatch.OPATCH_CLASSPATH=, -DOPatch.WEBLOGIC_CLASSPATH=, -DOPatch.SKIP_OUI_VERSION_CHECK=, -DOPatch.NEXTGEN_HOME_CHECK=false, -DOPatch.PARALLEL_ON_FMW_OH=]
[Aug 5, 2020 5:06:46 PM] [INFO]     Heap in use : 7 MB
                                    Total memory: 30 MB
                                    Free memory : 23 MB
                                    Max memory  : 2969 MB
[Aug 5, 2020 5:06:46 PM] [INFO]     Oracle Home       : /u01/app/oracle/product/19.3.0/db_1
                                    Central Inventory : /u01/app/oraInventory
                                       from           : /u01/app/oracle/product/19.3.0/db_1/oraInst.loc
                                    OPatch version    : 12.2.0.1.21
                                    OUI version       : 12.2.0.7.0
                                    OUI location      : /u01/app/oracle/product/19.3.0/db_1/oui
                                    Log file location : /u01/app/oracle/product/19.3.0/db_1/cfgtoollogs/opatch/opatch2020-08-05_17-06-45PM_1.log
[Aug 5, 2020 5:06:46 PM] [INFO]     Patch history file: /u01/app/oracle/product/19.3.0/db_1/cfgtoollogs/opatch/opatch_history.txt
[Aug 5, 2020 5:06:48 PM] [INFO]     [OPSR-TIME] Loading raw inventory
[Aug 5, 2020 5:06:49 PM] [INFO]     [OPSR-MEMORY] Loaded all components from inventory. Heap memory in use: 15 (MB)
[Aug 5, 2020 5:06:49 PM] [INFO]     [OPSR-MEMORY] Loaded all one offs from inventory. Heap memory in use: 8 (MB)
[Aug 5, 2020 5:06:49 PM] [INFO]     [OPSR-TIME] Raw inventory loaded successfully
[Aug 5, 2020 5:06:49 PM] [INFO]     NApply::no CAS enabled, OPatch runs with legacy process.
[Aug 5, 2020 5:06:49 PM] [INFO]     Verifying environment and performing prerequisite checks...
[Aug 5, 2020 5:06:49 PM] [INFO]     [OPSR-TIME] Running prerequisite checks
[Aug 5, 2020 5:06:49 PM] [INFO]     opatch-external.jar is in /u01/app/oracle/product/19.3.0/db_1/OPatch/jlib/opatch-external.jar
[Aug 5, 2020 5:06:50 PM] [INFO]     [OPSR-TIME] Loading cooked inventory
[Aug 5, 2020 5:06:50 PM] [INFO]     [OPSR-MEMORY] : Loading cooked one offs. Heap memory used 18 (MB)
[Aug 5, 2020 5:06:50 PM] [INFO]     [OPSR-MEMORY] : Loaded cooked oneoffs. Heap memory used : 14 (MB)
[Aug 5, 2020 5:06:50 PM] [INFO]     [OPSR-TIME] Cooked inventory loaded successfully
[Aug 5, 2020 5:06:50 PM] [INFO]     Checking if Oracle Home has components required by patches...
[Aug 5, 2020 5:06:50 PM] [INFO]     CheckMissingComps: Cached file does not exist or is invalid, re-build prereq result.
[Aug 5, 2020 5:06:50 PM] [INFO]     Checking conflict among patches...
[Aug 5, 2020 5:06:50 PM] [INFO]     Running prereq checkConflictAmongPatchesWithDetail
[Aug 5, 2020 5:06:50 PM] [INFO]     Following patches can be applied:  30805684
[Aug 5, 2020 5:06:50 PM] [INFO]     Following patches are not required:
[Aug 5, 2020 5:06:50 PM] [INFO]     Following patches are auto rollbackable:
[Aug 5, 2020 5:06:50 PM] [INFO]     Finished checking prereq checkConflictAmongPatchesWithDetail
[Aug 5, 2020 5:06:50 PM] [INFO]     Conflict checking amongst patches PASSED
[Aug 5, 2020 5:06:50 PM] [INFO]     Checking conflicts against Oracle Home...
[Aug 5, 2020 5:06:50 PM] [INFO]     Running prereq checkConflictAgainstOHWithDetail
[Aug 5, 2020 5:06:50 PM] [INFO]     Following patches can be applied:  30805684
[Aug 5, 2020 5:06:50 PM] [INFO]     Following patches are not required:
[Aug 5, 2020 5:06:50 PM] [INFO]     Following patches are auto rollbackable:
[Aug 5, 2020 5:06:50 PM] [INFO]     Finished checking prereq checkConflictAgainstOHWithDetail
[Aug 5, 2020 5:06:51 PM] [INFO]     Running prerequisite checks...
[Aug 5, 2020 5:06:51 PM] [INFO]     Space Needed : 851.205MB
[Aug 5, 2020 5:06:51 PM] [INFO]     Prereq checkPatchApplicableOnCurrentPlatform Passed for patch : 30805684
[Aug 5, 2020 5:06:51 PM] [INFO]     Start fuser command /sbin/fuser /u01/app/oracle/product/19.3.0/db_1/bin/oracle at Wed Aug 05 17:06:51 CST 2020
[Aug 5, 2020 5:06:51 PM] [INFO]     Finish fuser command /sbin/fuser /u01/app/oracle/product/19.3.0/db_1/bin/oracle at Wed Aug 05 17:06:51 CST 2020
[Aug 5, 2020 5:06:51 PM] [INFO]     Files in use by a process: /u01/app/oracle/product/19.3.0/db_1/bin/oracle PID( 2487  2489  2491  2493  2497  2499  2503  2506  2509  2512  2514  2516  2518  2520  2522  2524  2526  2528  2530  2532  2536  2540  2544  2546  2549  2551  2553  2568  2570  2572  2577  2582  2589  2594  2598  2602  2615  2621  3411 11307 11309 11311 11360 11416 11475 11760 11764 11771 23305 23892 )
[Aug 5, 2020 5:06:51 PM] [INFO]     Following active executables are not used by opatch process :
                                    /u01/app/oracle/product/19.3.0/db_1/bin/oracle
                                    
                                    Following active executables are used by opatch process :
[Aug 5, 2020 5:06:51 PM] [INFO]     Prerequisite check "CheckActiveFilesAndExecutables" failed.
                                    The details are:
                                    
                                    
                                    Following active executables are not used by opatch process :
                                    /u01/app/oracle/product/19.3.0/db_1/bin/oracle
                                    
                                    Following active executables are used by opatch process :
[Aug 5, 2020 5:06:52 PM] [SEVERE]   OUI-67073:UtilSession failed: Prerequisite check "CheckActiveFilesAndExecutables" failed.
[Aug 5, 2020 5:06:52 PM] [INFO]     Finishing UtilSession at Wed Aug 05 17:06:52 CST 2020
[Aug 5, 2020 5:06:52 PM] [INFO]     Log file location: /u01/app/oracle/product/19.3.0/db_1/cfgtoollogs/opatch/opatch2020-08-05_17-06-45PM_1.log
[Aug 5, 2020 5:06:52 PM] [INFO]     Stack Description: java.lang.RuntimeException: Prerequisite check "CheckActiveFilesAndExecutables" failed.
                                        at oracle.opatch.OPatchSessionHelper.runApplyPrereqs(OPatchSessionHelper.java:6752)
                                        at oracle.opatch.opatchutil.NApply.legacy_process(NApply.java:1002)
                                        at oracle.opatch.opatchutil.NApply.legacy_process(NApply.java:372)
                                        at oracle.opatch.opatchutil.NApply.process(NApply.java:352)
                                        at oracle.opatch.opatchutil.OUSession.napply(OUSession.java:1123)
                                        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                                        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
                                        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
                                        at java.lang.reflect.Method.invoke(Method.java:498)
                                        at oracle.opatch.UtilSession.process(UtilSession.java:355)
                                        at oracle.opatch.OPatchSession.process(OPatchSession.java:2660)
                                        at oracle.opatch.OPatch.process(OPatch.java:840)
                                        at oracle.opatch.OPatch.main(OPatch.java:897)
                                    Caused by: java.lang.RuntimeException: Prerequisite check "CheckActiveFilesAndExecutables" failed.
                                        ... 13 more
                                    Caused by: oracle.opatch.PrereqFailedException: Prerequisite check "CheckActiveFilesAndExecutables" failed.
                                        ... 13 more
[oracle@strong lib]$



问题分析:
我们通过上面的日志信息可以看到,是报有文件是处于执行状态,具体参考Metalink:148501.1;



问题解决办法:
1、     检查Oracle进程:

[oracle@strong ~]$  ps -ef|grep ora
oracle     2487      1  0 11:39 ?        00:00:02 ora_pmon_orcl
oracle     2489      1  0 11:39 ?        00:00:00 ora_clmn_orcl
oracle     2491      1  0 11:39 ?        00:00:06 ora_psp0_orcl
oracle     2493      1  3 11:39 ?        00:11:34 ora_vktm_orcl
oracle     2497      1  0 11:39 ?        00:00:01 ora_gen0_orcl
oracle     2499      1  0 11:39 ?        00:00:00 ora_mman_orcl
oracle     2503      1  0 11:39 ?        00:00:08 ora_gen1_orcl
oracle     2506      1  0 11:39 ?        00:00:01 ora_diag_orcl
oracle     2509      1  0 11:39 ?        00:00:00 ora_ofsd_orcl
oracle     2512      1  0 11:39 ?        00:00:12 ora_dbrm_orcl
oracle     2514      1  0 11:39 ?        00:00:00 ora_vkrm_orcl
oracle     2516      1  0 11:39 ?        00:00:01 ora_svcb_orcl
oracle     2518      1  0 11:39 ?        00:00:05 ora_pman_orcl
oracle     2520      1  0 11:39 ?        00:00:25 ora_dia0_orcl
oracle     2522      1  0 11:39 ?        00:00:03 ora_dbw0_orcl
oracle     2524      1  0 11:39 ?        00:00:04 ora_lgwr_orcl
oracle     2526      1  0 11:39 ?        00:00:12 ora_ckpt_orcl
oracle     2528      1  0 11:39 ?        00:00:01 ora_smon_orcl
oracle     2530      1  0 11:39 ?        00:00:02 ora_smco_orcl
oracle     2532      1  0 11:39 ?        00:00:00 ora_reco_orcl
oracle     2536      1  0 11:39 ?        00:00:01 ora_lreg_orcl
oracle     2540      1  0 11:39 ?        00:00:00 ora_pxmn_orcl
oracle     2544      1  0 11:39 ?        00:00:18 ora_mmon_orcl
oracle     2546      1  0 11:39 ?        00:00:09 ora_mmnl_orcl
oracle     2549      1  0 11:39 ?        00:00:00 ora_d000_orcl
oracle     2551      1  0 11:39 ?        00:00:00 ora_s000_orcl
oracle     2553      1  0 11:39 ?        00:00:00 ora_tmon_orcl
oracle     2568      1  0 11:40 ?        00:00:00 ora_tt00_orcl
oracle     2570      1  0 11:40 ?        00:00:00 ora_tt01_orcl
oracle     2572      1  0 11:40 ?        00:00:01 ora_tt02_orcl
oracle     2577      1  0 11:40 ?        00:00:00 ora_w002_orcl
oracle     2582      1  0 11:40 ?        00:00:00 ora_w003_orcl
oracle     2589      1  0 11:40 ?        00:00:00 ora_aqpc_orcl
oracle     2594      1  0 11:40 ?        00:01:25 ora_cjq0_orcl
oracle     2598      1  0 11:40 ?        00:00:01 ora_p000_orcl
oracle     2602      1  0 11:40 ?        00:00:01 ora_p001_orcl
oracle     2615      1  0 11:40 ?        00:00:00 ora_qm02_orcl
oracle     2621      1  0 11:40 ?        00:00:00 ora_q003_orcl
oracle     3411      1  0 11:50 ?        00:00:00 ora_w006_orcl
oracle    11307      1  0 13:58 ?        00:00:23 ora_m000_orcl
oracle    11309      1  0 13:58 ?        00:00:27 ora_m001_orcl
oracle    11311      1  0 13:58 ?        00:00:21 ora_m002_orcl
oracle    11360      1  0 13:58 ?        00:00:00 ora_w001_orcl
oracle    11416      1  0 13:58 ?        00:00:00 ora_q001_orcl
oracle    11475      1  0 13:58 ?        00:00:00 ora_w005_orcl
oracle    11760      1  0 13:58 ?        00:00:00 ora_w000_orcl
oracle    11764      1  0 13:58 ?        00:00:00 ora_w007_orcl
oracle    11771      1  0 13:58 ?        00:00:00 ora_w004_orcl
root      13353  12921  0 14:14 pts/3    00:00:00 su - oracle
oracle    13355  13353  0 14:14 pts/3    00:00:00 -bash
oracle    23305      1  0 16:41 ?        00:00:02 ora_m004_orcl
oracle    23892      1  0 16:51 ?        00:00:03 ora_m003_orcl
root      24798  11884  0 17:06 pts/2    00:00:00 su - oracle
oracle    24799  24798  0 17:06 pts/2    00:00:00 -bash
oracle    25069  24799  0 17:07 pts/2    00:00:00 ps -ef
oracle    25070  24799  0 17:07 pts/2    00:00:00 grep --color=auto ora


2、   停止数据库再检查进程
[oracle@strong ~]$ sqlplus / as sysdba
SQL*Plus: Release 19.0.0.0.0 - Production on Wed Aug 5 17:08:36 2020
Version 19.3.0.0.0
Copyright (c) 1982, 2019, Oracle.  All rights reserved.

Connected to:
Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production
Version 19.3.0.0.0

SQL> shutdown immediate;
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL>




再次执行成功:
[oracle@strong lib]$  /u01/app/oracle/product/19.3.0/db_1/OPatch/opatch apply -local /setup/30783543/30805684
Oracle Interim Patch Installer version 12.2.0.1.21
Copyright (c) 2020, Oracle Corporation.  All rights reserved.
Oracle Home       : /u01/app/oracle/product/19.3.0/db_1
Central Inventory : /u01/app/oraInventory
   from           : /u01/app/oracle/product/19.3.0/db_1/oraInst.loc
OPatch version    : 12.2.0.1.21
OUI version       : 12.2.0.7.0
Log file location : /u01/app/oracle/product/19.3.0/db_1/cfgtoollogs/opatch/opatch2020-08-05_17-09-13PM_1.log
Verifying environment and performing prerequisite checks...

--------------------------------------------------------------------------------
Start OOP by Prereq process.
Launch OOP...

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

Oracle Home       : /u01/app/oracle/product/19.3.0/db_1
Central Inventory : /u01/app/oraInventory
   from           : /u01/app/oracle/product/19.3.0/db_1/oraInst.loc
OPatch version    : 12.2.0.1.21
OUI version       : 12.2.0.7.0
Log file location : /u01/app/oracle/product/19.3.0/db_1/cfgtoollogs/opatch/opatch2020-08-05_17-09-36PM_1.log

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

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.3.0/db_1')

Is the local system ready for patching? [y|n]
y
User Responded with: Y
Backing up files...
Applying interim patch '30805684' to OH '/u01/app/oracle/product/19.3.0/db_1'

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...
Patch 30805684 successfully applied.
Log file location: /u01/app/oracle/product/19.3.0/db_1/cfgtoollogs/opatch/opatch2020-08-05_17-09-36PM_1.log

OPatch succeeded.



分享到:  QQ好友和群QQ好友和群 QQ空间QQ空间 腾讯微博腾讯微博 腾讯朋友腾讯朋友
收藏收藏 支持支持 反对反对
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

QQ|手机版|小黑屋|重庆思庄Oracle、Redhat认证学习论坛 ( 渝ICP备12004239号-4 )

GMT+8, 2024-4-26 15:34 , Processed in 0.116287 second(s), 19 queries .

重庆思庄学习中心论坛-重庆思庄科技有限公司论坛

© 2001-2020

快速回复 返回顶部 返回列表