This post demonstrates how to recreate oraInventory (Central Inventory) in Oracle RDBMS Homes if the central inventory is corrupted or lost.
Note:
The recreation of the Central Inventory in the RDBMS Homes is supported only from version 10.2.0.1.0 and later.
No downtime is necessary for the recreation of the global inventory (oraInventory).
1. Locate the central inventory in server.
[oracle@prod ~]$ cat /etc/oraInst.loc
inventory_loc=/u01/app/oraInventory
inst_group=oinstall
2. Remove the corrupted central inventory.
[oracle@prod ~]$ cd /u01/app/
[oracle@prod app]$ mv oraInventory oraInventory_orig
3. Attach the ORACLE_HOME.
Navigate to $ORACLE_HOME/oui/bin
[oracle@prod ~]$ cd $ORACLE_HOME/oui/bin
[oracle@prod bin]$ ./runInstaller -silent -ignoreSysPrereqs -attachHome ORACLE_HOME=”/u01/app/oracle/product/19.30/db” ORACLE_HOME_NAME=”ORACLE_HOME_1″
Starting Oracle Universal Installer…
Checking swap space: must be greater than 500 MB. Actual 8191 MB Passed
The inventory pointer is located at /etc/oraInst.loc
You can find the log of this install session at:
/u01/app/oraInventory/logs/AttachHome2026-09-10_06-41-17PM.log
‘AttachHome’ was successful.
Note: If you have more than one Oracle Home, repeat STEP 4 for all remaining Oracle Homes, ensure to provide unique ORACLE_HOME_NAMEs for each Oracle Home.
4. Verify whether oraInventory create or not.
[oracle@prod ~]$ cd /u01/app/
[oracle@prod app]$ ls -ld oraInventory
drwxrwx—. 4 oracle oinstall 4096 Sep 10 18:41 oraInventory
[oracle@prod app]$ cd oraInventory/ContentsXML/
[oracle@prod ContentsXML]$ ls -lrt
total 12
-rw-rw—-. 1 oracle oinstall 472 Sep 10 18:41 inventory.xml
-rw-rw—-. 1 oracle oinstall 292 Sep 10 18:41 libs.xml
-rw-rw—-. 1 oracle oinstall 300 Sep 10 18:41 comps.xml
[oracle@prod ContentsXML]$ cat inventory.xml
<?xml version=”1.0″ standalone=”yes” ?>
<!– Copyright (c) 1999, 2026, Oracle and/or its affiliates.
All rights reserved. –>
<!– Do not modify the contents of this file by hand. –>
<INVENTORY>
<VERSION_INFO>
<SAVED_WITH>12.2.0.7.0</SAVED_WITH>
<MINIMUM_VER>2.1.0.6.0</MINIMUM_VER>
</VERSION_INFO>
<HOME_LIST>
<HOME NAME=”ORACLE_HOME_1″ LOC=”/u01/app/oracle/product/19.30/db” TYPE=”O” IDX=”1″/>
</HOME_LIST>
<COMPOSITEHOME_LIST>
</COMPOSITEHOME_LIST>
</INVENTORY>
The oraInventory has been recreated successfully.
Disclaimer:
Please note the above information is only for educational purpose and practised in personal test database only. Always test in test database before implementing in production database. The pre-requisites and ways of implementing may vary from one environment to another. Hence, not providing guarantee that it will work in your environment.