Home » Infrastructure » Unix » oracle_home error (AIX 5.3)
oracle_home error [message #312358] Tue, 08 April 2008 11:55 Go to next message
talashil
Messages: 8
Registered: April 2008
Junior Member
I have symbolic link as oracle_home --> /opt/oracle/10.2

and in the ora_env.sh to check for verion , I have code like this

if [ "$version" = "" ]; then
ORACLE_HOME=/opt/oracle/oracle_home;
else
ORACLE_HOME=$version
fi
export ORACLE_HOME

when I run cron job , it is taking oracle home as /opt/oracle/oracle_home ?

any ideas .

Thanks
Re: oracle_home error [message #312359 is a reply to message #312358] Tue, 08 April 2008 12:05 Go to previous messageGo to next message
BlackSwan
Messages: 25046
Registered: January 2009
Location: SoCal
Senior Member
when cron invokes the script, $version is not set.

at the top of any script you can add the following line

env | sort -o /tmp/my.env

after the script runs you can look at the contents of /tmp/my.env
to see which environmental variables exist & to what value they are set.
Re: oracle_home error [message #312361 is a reply to message #312358] Tue, 08 April 2008 12:22 Go to previous messageGo to next message
talashil
Messages: 8
Registered: April 2008
Junior Member
hey Thanks for the reply.

My question is when cron job is running ,why ism't taking symbolic value into /opt/oracle/oracle_home

if I do :

echo $ORACLE_HOME
/opt/oracle/10.2

and cron value is showing as ,

ORACLE_HOME=/opt/oracle/oracle_home

Thanks
Re: oracle_home error [message #312362 is a reply to message #312358] Tue, 08 April 2008 12:27 Go to previous message
BlackSwan
Messages: 25046
Registered: January 2009
Location: SoCal
Senior Member
>I have symbolic link as oracle_home --> /opt/oracle/10.2
This statement makes NO sense.

a symbolic (soft) link is created by

ln -s <real_file> <pseudo_name>

Oracle does NOT know or care about your symbolic link.
cron does NOT invoke .bash_profile or similar file automatically.
In a script invoked by cron, if you want your environmental variables establish source in the appropriate file to do so.
Previous Topic: Tail Command
Next Topic: Performance Issue on Sun Sloaris - Maybe Unix or Hardware Option ?
Goto Forum:
  


Current Time: Thu Dec 08 14:42:55 CST 2016

Total time taken to generate the page: 0.13983 seconds