Thursday 10 March 2011

Oracle : oraenv gives XPointer evaluation failed

In 11G+ this is due ORACLE_BASE not being set in the course of running oraenv

What is happening is $ORACLE_HOME/bin/orabase is being run to update $ORACLE_HOME/inventory/ContentsXML/oraclehomeproperties.xml and erroring as the particular key it is looking for is not in the file ( PROPERTY NAME="ORACLE_BASE" I guess) - however the error is ignored resulting in $ORACLE_BASE being unset

Made a one line change to oraenv to check the return value and use the OLD_ORACLE_BASE - which will probably work most of the time ;)
ORACLE_BASE=`$ORABASE_EXEC`
[ "$?" -ne 0 ] && { echo "Warning - failure of $ORABASE_EXEC"; ORACLE_BASE=$OLD_ORACLE_BASE; }  # New line


1 comments:

Stellan said...

Thanks! Solved my problem :)