Oracle DBA – A lifelong learning experience

Corrupted Oracle inventory

Posted by John Hallas on January 30, 2009

I have already blogged  about how to move an incorrectly placed Oracle Inventory but in this case we had a corrupted Oracle inventory.

>> $ORACLE_HOME/OPatch/opatch lsinventory
Invoking OPatch

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

Oracle Home : /app/oracle/product/11.1.0/db_1
Central Inventory : /app/oracle/oraInventory
from : /var/opt/oracle/oraInst.loc
OPatch version :
OUI version :
OUI location : /app/oracle/product/11.1.0/db_1/oui
Log file location : /app/oracle/product/11.1.0/db_1/cfgtoollogs/opatch/opatch2009-01-29_10-56-52AM.log

list of Homes on this system:

Home name= OraDb11g_home1, Location= “”
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 gets null oracleHomeInfo

OPatch failed with error code 73

 Searching around on the net the best solution for the issue was to attach a new Oracle Home

./runInstaller -silent -attachHome -invPtrLoc /var/opt/oracle/oraInst.loc ORACLE_HOME= “/app/oracle/product/11.1.0/db_1”
Starting Oracle Universal Installer…

Checking swap space: must be greater than 500 MB. Actual 24576 MB Passed
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2009-01-29_11-02-45AM. Please wait …
>> The inventory pointer is located at /var/opt/oracle/oraInst.loc
The inventory is located at /app/oracle/oraInventory
OUI-10197:Unable to create a new Oracle Home at . Oracle Home already exists at this location.

Select another location.


This was rather frustrating because I knew OH already existed, I was just trying to register it into the inventory.


I spent a lot of time detaching and attaching the OH, all with no success. Note that there is an opatch lsineventory –detail option which shows all the installed products as well as patches.


The issue was that the inventory.xml file was corrupted. I did try and remove it and create a new one but it also required a file comps.xml which appeared to be corrupted as well (no idea how).


Once I knew which files were required


/app/oracle/oraInventory/ContentsXML $ls

comps.xml inventory.xml libs.xml


I actually FTP’d them from a server where the Oracle build was identical (just an install, upgraded to and all was well with the world.


However this method is unsupported by Oracle and is not recommended. In my case it was for a test system and was worth the effort over the time lost in de-installing and re-installing.


8 Responses to “Corrupted Oracle inventory”

  1. dbametrix said


    Very interesting. Thanks for such great article.

    Thanks and regards,

  2. Saaki said

    Thanks a lot dude… worked for us.

    We tried changing the Ora Home multiple times too, before we understood that was not solving the problem for us.

    When i read your blog , and checked we found that our ContentsXML and the files within were missing too and we FTPed those from another server which had a fresh and similar build.

    Thanks a lot you made my day.


  3. Tyrone said

    This is key. Should be in the oracle docs. Found corruption in our inventory.xml. Edited the file and dbca works again. This post was a life saver. Thanks.

  4. Azam said

    We had the same issue, it worked great for us!
    Thanks for your post.

  5. Matthew said

    Great man! Thanks!

  6. hulapai said

    Unfortunatly it did not resolve my error “LsInventorySession failed: Unable to create patchObject”;
    I have still same error.

    • John Hallas said

      Not much I can say really. Your best bet is to re-install the inventory. This was only a workaround to save the time spent re-installing

Leave a Reply

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

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

Google+ photo

You are commenting using your Google+ 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 )


Connecting to %s

%d bloggers like this: