Opatch Inventory load failed with error code 73.

Inventory load failed… OPatch cannot load inventory for the given Oracle Home.

In many cases, opatch does not understand the oracle home,So we identified the reason why opatch command is not identified.We need to check the Opatch inventory location that we are pointing to correct inventory if we are correct inventory then we need to attach the oracle home with inventory.

Opatch lsinventory command
Note: on executing below command for inventory not effect the database running state

Example:

Opatch lsinventory

Invoking OPatch 10.2.0.3.0
Oracle interim Patch Installer version 10.2.0
Copyright (c) 2005, Oracle Corporation. All rights reserved..
Below error got:
Oracle Home : /u01/app/oracle/10203
Central Inventory : /u01/app/oracle/oraInventory
from : /etc/oraInst.loc
OPatch version : 10.2.0.3.0
OUI version : 10.2.0.3.0
OUI location : /u01/app/oracle/10203/oui
Log file location : /u01/app/oracle/10203/cfgtoollogs/opatch/opatch2012-12-18_12-44-41PM.log
List of Homes on this system:
Home name= OraDb11g_home1, Location= "/u01/app/oracle/11g"
Home name= OraDb11g_home2, Location= "/u01/app/oracle/11202"
Home name= OraDb10g_home1, Location= "/u04/app/oracle/product/10203"
Home name= MRHOME_101202, Location= "/u04/app/oracle/product/MRHOME_101202"
Home name= mrcahome1, Location= "/u04/app/oracle/product/MRCA_101203"
Inventory load failed... OPatch cannot load inventory for the given Oracle Home.
Possible causes are:
Oracle Home dir. path does not exist in Central Inventory
Oracle Home is a symbolic link
Oracle Home inventory is corrupted
LsInventorySession failed: OracleHomeInventory::load() gets null oracleHomeInfo
OPatch failed with error code 73

Solution for error OPatch cannot load inventory

Step 1. Check the oraInst.loc file
Check the inventory is exist in the location and file entries in particular sequence

cat /etc/oraInst.loc
inventory_loc=/u01/app/oracle/oraInventory
inst_group=dba

Step 2. If first step is ok, Then you need to register the Oracle Home in the inventory

For OracleHome version 10.2.0.2 or higher :
% cd $ORACLE_HOME/oui/bin
% ./attachHome.sh

OR

For OracleHome version 10.1.0.2 to 10.2.0.1:
% cd $ORACLE_HOME/oui/bin
% ./runInstaller -silent -attachHome \
ORACLE_HOME=$ORACLE_HOME \
ORACLE_HOME_NAME=

Step 3. If not able to register in Step 2, then tried to create the repository in new location

1. Create a new file oraInst.loc and make below entries in file

-- Create new file orainst.loc file
inventory_loc=/newlocation/oraInventory
inst_group=dba

2. Run the following command for create new oraInst.loc file.

./runInstaller -silent -invPtrLoc "/u01/app/oracle/10203/oraInst.loc" -attachHome ORACLE_HOME="/u01/app/oracle/10203" ORACLE_HOME_NAME="ORAHOME10G"

It will create new OraInventory for the database.

Check opatch command with inventory location
<code
Opatch lsinventory -detail -invproloc /u01/app/oracle/10203/oraInst.loc

Note: invproloc is parameter used to specify the inventory path

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s