ITPub博客

首页 > 应用开发 > IT综合 > opatch apply Exception in thread ""main"" java.lang.NullPointerException

opatch apply Exception in thread ""main"" java.lang.NullPointerException

原创 IT综合 作者:praday 时间:2009-03-21 16:07:31 0 删除 编辑

$opatch apply
Performing pre-patch installation checks.

Exception in thread ""main"" java.lang.NullPointerException
at InitialDatabaseCheck.main(InitialDatabaseCheck.java:179)
/u01/orapurc/purcdb/9.2.0/OPatch/opatch.pl version: 1.0.0.0.24
Copyright (c) 2001,2002 Oracle Corporation. All Rights Reserved.

Unknown problem.

[@more@]

$opatch apply
Performing pre-patch installation checks.

Exception in thread ""main"" java.lang.NullPointerException
at InitialDatabaseCheck.main(InitialDatabaseCheck.java:179)
/u01/orapurc/purcdb/9.2.0/OPatch/opatch.pl version: 1.0.0.0.24
Copyright (c) 2001,2002 Oracle Corporation. All Rights Reserved.

Unknown problem.

242993.1 OPATCH FAQ

36) Got exception " Exception in thread "main" java.lang.NullPointerException at
GetSingleInventory.main(GetSingleInventory.java:124" when trying to run the lsinventory command?

The inventory stores the location of each ORACLE_HOME as a string. The ORACLE_HOME it's using (either from the environment or from the "-oh" option) doesn't match any entry in the oracle homes picked up from the inventory. Check if the ORACLE_HOME environment variable has been set correctly and that the central inventory's file ContentsXML/inventory contains the relevant Oraclehome or if this oracle home was cloned from another machine and then use "attachhome" first and then apply the patch.

SOLUTION:

[orapurc@purc]$ls /etc/oraInst.loc
/etc/oraInst.loc
[orapurc@purc]$cat /etc/oraInst.loc
inventory_loc=/u01/orapurc/oraInventory
[orapurc@purc]$cd /u01/orapurc/oraInventory
[orapurc@purc]$ls
Contents ContentsXML install.platform locks logs
[orapurc@purc]$cd ContentsXML
[orapurc@purc]$ls
comps.xml inventory.xml libs.xml
#change $ORACLE_HOME strings
[orapurc@purc]$vi inventory.xml
HOME NAME="APPSDB_purc" LOC="/u01/orapurc/purcdb/9.2.0" TYPE="O" IDX="1"/

来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/807588/viewspace-1019206/ ,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论
  • 博文量
    6
  • 访问量
    103393