Prerequisite check "CheckActiveFilesAndExecutables" failed
问题背景:
我们在进行数据库打补丁Optatch的时候,突然报错CheckActiveFilesAndExecutables,导致补丁无法进行应用下去。
问题现象:
[oracle@db01 18522509]$ /home/oracle/OPatch/opatch apply
Oracle Interim Patch Installer version 11.2.0.3.6
Copyright (c) 2013, Oracle Corporation. All rights reserved.
Oracle Home : /DBSoft/Product/11.2.4/db_1
Central Inventory : /DBSoft/oraInventory
from : /DBSoft/Product/11.2.4/db_1/oraInst.loc
OPatch version : 11.2.0.3.6
OUI version : 11.2.0.4.0
Log file location : /DBSoft/Product/11.2.4/db_1/cfgtoollogs/opatch/opatch2014-10-09_05-06-13AM_1.log
Verifying environment and performing prerequisite checks...
Prerequisite check "CheckActiveFilesAndExecutables" failed.
The details are:
Following executables are active :
/DBSoft/Product/11.2.4/db_1/bin/oracle
/DBSoft/Product/11.2.4/db_1/lib/libclntsh.so.11.1
UtilSession failed: Prerequisite check "CheckActiveFilesAndExecutables" failed.
Log file location: /DBSoft/Product/11.2.4/db_1/cfgtoollogs/opatch/opatch2014-10-09_05-06-13AM_1.log
OPatch failed with error code 73
查看OPatch日志:
[oracle@db01 OPatch]$ cat /DBSoft/Product/11.2.4/db_1/cfgtoollogs/opatch/opatch2014-10-09_05-06-13AM_1.log
[Oct 9, 2014 5:06:13 AM] OPatch invoked as follows: 'apply -invPtrLoc /DBSoft/Product/11.2.4/db_1/oraInst.loc '
[Oct 9, 2014 5:06:13 AM] OUI-67077:
Oracle Home : /DBSoft/Product/11.2.4/db_1
Central Inventory : /DBSoft/oraInventory
from : /DBSoft/Product/11.2.4/db_1/oraInst.loc
OPatch version : 11.2.0.3.6
OUI version : 11.2.0.4.0
OUI location : /DBSoft/Product/11.2.4/db_1/oui
Log file location : /DBSoft/Product/11.2.4/db_1/cfgtoollogs/opatch/opatch2014-10-09_05-06-13AM_1.log
[Oct 9, 2014 5:06:13 AM] Patch history file: /DBSoft/Product/11.2.4/db_1/cfgtoollogs/opatch/opatch_history.txt
[Oct 9, 2014 5:06:16 AM] Verifying environment and performing prerequisite checks...
[Oct 9, 2014 5:06:16 AM] Ignoring file "/home/oracle/18522509/README.html" in the patch directory.
[Oct 9, 2014 5:06:16 AM] Ignoring file "/home/oracle/18522509/README.txt" in the patch directory.
[Oct 9, 2014 5:06:16 AM] Ignoring file "/home/oracle/18522509/patchmd.xml" in the patch directory.
[Oct 9, 2014 5:06:17 AM] Checking conflict among patches...
[Oct 9, 2014 5:06:17 AM] Patch ID 18522509
[Oct 9, 2014 5:06:17 AM] Patches that conflict: [ ]
[Oct 9, 2014 5:06:17 AM] Checking conflicts for patch : 18522509
[Oct 9, 2014 5:06:17 AM] Checking if Oracle Home has components required by patches...
[Oct 9, 2014 5:06:17 AM] Check if patch "17478514" is a no-op patch.
[Oct 9, 2014 5:06:18 AM] Check if patch "18031668" is a no-op patch.
[Oct 9, 2014 5:06:18 AM] Check if patch "18522509" is a no-op patch.
[Oct 9, 2014 5:06:18 AM] Running prerequisite checks...
[Oct 9, 2014 5:06:18 AM] Patch "17478514" is ignored as it is not a "Fusion Applications patch".
[Oct 9, 2014 5:06:18 AM] Patch "18031668" is ignored as it is not a "Fusion Applications patch".
[Oct 9, 2014 5:06:18 AM] Patch "18522509" is ignored as it is not a "Fusion Applications patch".
[Oct 9, 2014 5:06:18 AM] Check if patch "17478514" is a no-op patch.
[Oct 9, 2014 5:06:18 AM] Check if patch "18031668" is a no-op patch.
[Oct 9, 2014 5:06:18 AM] Check if patch "18522509" is a no-op patch.
[Oct 9, 2014 5:06:18 AM] None of the selected patches are no-op. patches..
[Oct 9, 2014 5:06:19 AM] Space Needed : 328.875MB
[Oct 9, 2014 5:06:19 AM] Prereq checkPatchApplicableOnCurrentPlatform Passed for patch : 17478514
[Oct 9, 2014 5:06:19 AM] Prereq checkPatchApplicableOnCurrentPlatform Passed for patch : 18031668
[Oct 9, 2014 5:06:19 AM] Prereq checkPatchApplicableOnCurrentPlatform Passed for patch : 18522509
[Oct 9, 2014 5:06:19 AM] Start fuser command /sbin/fuser /DBSoft/Product/11.2.4/db_1/bin/oracle at Thu Oct 09 05:06:19 CST 2014
[Oct 9, 2014 5:06:20 AM] Finish fuser command /sbin/fuser /DBSoft/Product/11.2.4/db_1/bin/oracle at Thu Oct 09 05:06:20 CST 2014
[Oct 9, 2014 5:06:20 AM] Start fuser command /sbin/fuser /DBSoft/Product/11.2.4/db_1/bin/amdu at Thu Oct 09 05:06:20 CST 2014
[Oct 9, 2014 5:06:20 AM] Finish fuser command /sbin/fuser /DBSoft/Product/11.2.4/db_1/bin/amdu at Thu Oct 09 05:06:20 CST 2014
[Oct 9, 2014 5:06:20 AM] Start fuser command /sbin/fuser /DBSoft/Product/11.2.4/db_1/bin/kfed at Thu Oct 09 05:06:20 CST 2014
[Oct 9, 2014 5:06:20 AM] Finish fuser command /sbin/fuser /DBSoft/Product/11.2.4/db_1/bin/kfed at Thu Oct 09 05:06:20 CST 2014
[Oct 9, 2014 5:06:20 AM] Start fuser command /sbin/fuser /DBSoft/Product/11.2.4/db_1/bin/kfod at Thu Oct 09 05:06:20 CST 2014
[Oct 9, 2014 5:06:20 AM] Finish fuser command /sbin/fuser /DBSoft/Product/11.2.4/db_1/bin/kfod at Thu Oct 09 05:06:20 CST 2014
[Oct 9, 2014 5:06:20 AM] Start fuser command /sbin/fuser /DBSoft/Product/11.2.4/db_1/bin/renamedg at Thu Oct 09 05:06:20 CST 2014
[Oct 9, 2014 5:06:20 AM] Finish fuser command /sbin/fuser /DBSoft/Product/11.2.4/db_1/bin/renamedg at Thu Oct 09 05:06:20 CST 2014
[Oct 9, 2014 5:06:20 AM] Start fuser command /sbin/fuser /DBSoft/Product/11.2.4/db_1/bin/orion at Thu Oct 09 05:06:20 CST 2014
[Oct 9, 2014 5:06:20 AM] Finish fuser command /sbin/fuser /DBSoft/Product/11.2.4/db_1/bin/orion at Thu Oct 09 05:06:20 CST 2014
[Oct 9, 2014 5:06:20 AM] Start fuser command /sbin/fuser /DBSoft/Product/11.2.4/db_1/bin/rman at Thu Oct 09 05:06:20 CST 2014
[Oct 9, 2014 5:06:20 AM] Finish fuser command /sbin/fuser /DBSoft/Product/11.2.4/db_1/bin/rman at Thu Oct 09 05:06:20 CST 2014
[Oct 9, 2014 5:06:20 AM] Start fuser command /sbin/fuser /DBSoft/Product/11.2.4/db_1/lib/libclntsh.so.11.1 at Thu Oct 09 05:06:20 CST 2014
[Oct 9, 2014 5:06:20 AM] Finish fuser command /sbin/fuser /DBSoft/Product/11.2.4/db_1/lib/libclntsh.so.11.1 at Thu Oct 09 05:06:20 CST 2014
[Oct 9, 2014 5:06:20 AM] Start fuser command /sbin/fuser /DBSoft/Product/11.2.4/db_1/lib/liborasdk.so.11.1 at Thu Oct 09 05:06:20 CST 2014
[Oct 9, 2014 5:06:20 AM] Finish fuser command /sbin/fuser /DBSoft/Product/11.2.4/db_1/lib/liborasdk.so.11.1 at Thu Oct 09 05:06:20 CST 2014
[Oct 9, 2014 5:06:20 AM] Following executables are active :
/DBSoft/Product/11.2.4/db_1/bin/oracle
/DBSoft/Product/11.2.4/db_1/lib/libclntsh.so.11.1
[Oct 9, 2014 5:06:20 AM] Prerequisite check "CheckActiveFilesAndExecutables" failed.
The details are:
Following executables are active :
/DBSoft/Product/11.2.4/db_1/bin/oracle
/DBSoft/Product/11.2.4/db_1/lib/libclntsh.so.11.1
[Oct 9, 2014 5:06:20 AM] Start fuser command /sbin/fuser /DBSoft/Product/11.2.4/db_1/bin/proc at Thu Oct 09 05:06:20 CST 2014
[Oct 9, 2014 5:06:20 AM] Finish fuser command /sbin/fuser /DBSoft/Product/11.2.4/db_1/bin/proc at Thu Oct 09 05:06:20 CST 2014
[Oct 9, 2014 5:06:20 AM] OUI-67073:UtilSession failed: Prerequisite check "CheckActiveFilesAndExecutables" failed.
[Oct 9, 2014 5:06:20 AM] Finishing UtilSession at Thu Oct 09 05:06:20 CST 2014
[Oct 9, 2014 5:06:20 AM] Log file location: /DBSoft/Product/11.2.4/db_1/cfgtoollogs/opatch/opatch2014-10-09_05-06-13AM_1.log
[Oct 9, 2014 5:06:20 AM] Stack Description: java.lang.RuntimeException: Prerequisite check "CheckActiveFilesAndExecutables" failed.
[Oct 9, 2014 5:06:20 AM] StackTrace: oracle.opatch.OPatchSessionHelper.runApplyPrereqs(OPatchSessionHelper.java:6420)
[Oct 9, 2014 5:06:20 AM] StackTrace: oracle.opatch.opatchutil.NApply.process(NApply.java:1614)
[Oct 9, 2014 5:06:20 AM] StackTrace: oracle.opatch.opatchutil.OUSession.napply(OUSession.java:1136)
[Oct 9, 2014 5:06:20 AM] StackTrace: sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[Oct 9, 2014 5:06:20 AM] StackTrace: sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
[Oct 9, 2014 5:06:20 AM] StackTrace: sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
[Oct 9, 2014 5:06:20 AM] StackTrace: java.lang.reflect.Method.invoke(Method.java:592)
[Oct 9, 2014 5:06:20 AM] StackTrace: oracle.opatch.UtilSession.process(UtilSession.java:322)
[Oct 9, 2014 5:06:20 AM] StackTrace: oracle.opatch.OPatchSession.main(OPatchSession.java:2343)
[Oct 9, 2014 5:06:20 AM] StackTrace: oracle.opatch.OPatch.main(OPatch.java:614)
问题分析:
我们通过上面的日志信息可以看到,是报有文件是处于执行状态,具体参考Metalink:148501.1;
问题解决办法:
1、 检查Oracle进程:
2、 停止数据库再检查进程
[oracle@db01 18522509]$ /DBSoft/Product/11.2.4/db_1/OPatch/opatch apply
Oracle Interim Patch Installer version 11.2.0.3.4
Copyright (c) 2012, Oracle Corporation. All rights reserved.
Oracle Home : /DBSoft/Product/11.2.4/db_1
Central Inventory : /DBSoft/oraInventory
from : /DBSoft/Product/11.2.4/db_1/oraInst.loc
OPatch version : 11.2.0.3.4
OUI version : 11.2.0.4.0
Log file location : /DBSoft/Product/11.2.4/db_1/cfgtoollogs/opatch/opatch2014-10-09_07-53-05AM_1.log
Verifying environment and performing prerequisite checks...
Prerequisite check "CheckMinimumOPatchVersion" failed.
The details are:
The OPatch being used has version 11.2.0.3.4 while the following patch(es) require higher versions:
Patch 17478514 requires OPatch version 11.2.0.3.5.
Patch 18031668 requires OPatch version 11.2.0.3.5.
Patch 18522509 requires OPatch version 11.2.0.3.5.
Please download latest OPatch from My Oracle Support.
UtilSession failed: Prerequisite check "CheckMinimumOPatchVersion" failed.
Log file location: /DBSoft/Product/11.2.4/db_1/cfgtoollogs/opatch/opatch2014-10-09_07-53-05AM_1.log
OPatch failed with error code 73
[oracle@db01 18522509]$ /home/oracle/OPatch/op apply
opatch opatch.bat opatchdiag opatchdiag.bat opatch.ini opatch.pl opatchprereqs/ oplan/
[oracle@db01 18522509]$ /home/oracle/OPatch/opatch apply
Oracle Interim Patch Installer version 11.2.0.3.6
Copyright (c) 2013, Oracle Corporation. All rights reserved.
Oracle Home : /DBSoft/Product/11.2.4/db_1
Central Inventory : /DBSoft/oraInventory
from : /DBSoft/Product/11.2.4/db_1/oraInst.loc
OPatch version : 11.2.0.3.6
OUI version : 11.2.0.4.0
Log file location : /DBSoft/Product/11.2.4/db_1/cfgtoollogs/opatch/opatch2014-10-09_07-53-39AM_1.log
Verifying environment and performing prerequisite checks...
OPatch continues with these patches: 17478514 18031668 18522509
Do you want to proceed? [y|n]
y
User Responded with: Y
All checks passed.
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/20674423/viewspace-1383104/ ,如需转载,请注明出处,否则将追究法律责任。