, , ,

Each database and clusterware Oracle Home has an inventory directory, and within that directory you’ll find a ContentsXML directory, just like you have in your Central Inventory.

Within ContentsXML directory is an interesting file named oraclehomeproperties.xml.

 <HOME CRS="T"/>
 <LOCAL_NODE NAME="Ora123demo"/>
 <NODE NAME="Ora123demo"/>
 <NODE NAME="Ora987demo"/>

If you preinstall and patch your Oracle binaries on a VM template and then use a copy of that template as a starting place to build a new database server the Oracle Home GUID remains unchanged.  It creates a situation very much like failing to run nid after creating a cloned database:  Oracle tools that rely on those unique identifiers become confused.  Automation dies.

Oracle Enterprise Manager relies on the Oracle Home GUID as a unique identifier for the oracle_home target types.  Each of those targets must be uniquely identified by Oracle Home GUID for automated patching through OEM.

You can reset the Oracle Home GUID only be recreating the inventory entries for the Oracle Home in inventory.xml using the OUI runInstaller tool.  The home must be detached and then reattached using the generateGUID option.

This script attached (when modified for your environment) captures each Oracle Home entry in the inventory.xml for the database binary home and the clusterware home.

CAUTION:  You must change the Oracle Home GUIDs before host discovery in OEM.

If you’ve tried to work with the editor tool for blogs you’ll appreciate why I chose to insert the shell script as a file: