Create or attach the central inventory in Oracle Database
1. Find the existing location of Central inventory.
Windows
1. By default Central Inventory location in windows is at “C:\Program Files\Oracle\Inventory”.
2. If you don’t find then you will check the “inst_loc” key in Window registry:
Go to Regedit in research --> Open Registry editor --> HKEY_LOCAL_MACHINE/SOFTWARE/ORACLE --> Find "inst_loc".
3. Find in 64-bit command prompt as follows:
reg query HKLM\SOFTWARE\ORACLE /v inst_loc
4. Find in 32-bit with command prompt:
reg query HKLM\SOFTWARE\WOW6432Node\ORACLE /v inst_loc
Unix or Linux
1. Default Central inventory location present in the file /etc/oraInst.loc (AIX and Linux) or /var/opt/oracle/oraInst.loc (other platform).
2. If you don’t find then you can create the file with oraInst.loc please take care of capital or small letters Linux is case sensitivity.
Example: inventory_loc=/u01/oracle/oraInventory inst_group=oinstall
If it exists, rename the old inventory; if not, create the default location as mentioned earlier.
3. Go to the OUI directory in your command prompt or command shell as follows:
-- Windows:
cd %ORACLE_HOME%\oui\bin
--Linux or Unix:
cd $ORACLE_HOME/oui/bin
4. Use the runInstaller script to attach or create the home.
-- Windows:
setup.exe -silent -ignoreSysPrereqs -attachHome ORACLE_HOME="" ORACLE_HOME_NAME=""
--linux:
./runInstaller -silent -ignoreSysPrereqs -attachHome ORACLE_HOME="" ORACLE_HOME_NAME=""
5. For example, you need to set Oracle_home and Oracle_home_name as values to attach the Oracle Home to the new inventory or existing inventory:
./runInstaller -silent -ignoreSysPrereqs -attachHome ORACLE_HOME="/u01/oracle/product/12.1.0" ORACLE_HOME_NAME="OraDb12c_home1"