Wednesday, April 18, 2012

How to recreate oraInventory (Central Inventory) in Real Application Clusters.

1-Locate the central inventory
cat /etc/oraInst.loc or /var/opt/oracle/oraInst.loc (Platform specific)

2-Take a back up of central inventory or rename in all the nodes.
mv oraInventory oraInventory.orig

3-cd $ORACLE_HOME/oui/bin

4-Execute runInstaller with attachHome option for OraCrsHome.

./runInstaller -silent -ignoreSysPrereqs -attachHome ORACLE_HOME="<10g Ora_Crs_Home Path>" ORACLE_HOME_NAME="<Name of oracleCRSHome>" LOCAL_NODE='node1' CLUSTER_NODES=node1,node2 CRS=true
for ex:
./runInstaller -silent -ignoreSysPrereqs -attachHome ORACLE_HOME="/u01/app/oracle/product/10.2.0/crs_1" ORACLE_HOME_NAME="OraCrs10g_home" LOCAL_NODE='rac1' CLUSTER_NODES=rac1,rac2 CRS=true

5-Execute runInstaller with attachHome option for OraDbHome
./runInstaller -silent -ignoreSysPrereqs -attachHome ORACLE_HOME="<10g Oracle_Home Path>" ORACLE_HOME_NAME="<Name of oracleHome>" LOCAL_NODE='node1' CLUSTER_NODES=node1,node2
for ex:
./runInstaller -silent -ignoreSysPrereqs -attachHome ORACLE_HOME="/u01/app/oracle/product/10.2.0/db_1" ORACLE_HOME_NAME="OraDb10g_home1" LOCAL_NODE='rac1' CLUSTER_NODES=rac1,rac2

6-Verify the inventory creation in all the nodes.

7-Verify and compare XML files size inside oraInventory/ContentsXML across all the nodes.

Caution:
a-Donot try attachHome in all the nodes, which may corrupt the inventory and it results in OUI-10197:Unable to create a new Oracle Home at /u01/app/oracle/product/10.2.0/crs_1. Oracle Home already exists at this location. Select another location. Attaching Home in one node will be propagated to other nodes.
b-Make sure you are having backup of the original inventory in any case without fail.

No comments:

Post a Comment