Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> Off Topic: Unix shell problem

Off Topic: Unix shell problem

From: Viraj Luthra <viraj999_at_lycos.com>
Date: Thu, 26 Apr 2001 00:21:21 -0700
Message-ID: <F001.002F2925.20010425231525@fatcity.com>

Hello all,

Ihave the following script, called as tst. When the script is executed as,

tst, then every thing is okay, but when it is executed as . tst, then I get the error:-

 sh: SHLIB_PATH: Parameter not set.

I need to use the following format that is . .profile, as in above case as . tst

The reason why I am doing above is because the SHLIB_PATH is not set properly, I get heaps of problems. If the SHLIB_PATH is not set, I just want to set it to say $HOME.

Please reply as this is urgent.

Thanks and Regards,

Raja


The script follows:-

#!/bin/sh                                                              
#                                                                      
echo                                                                   
echo                                                                   
echo Start Test                                                        
echo                                                                   
echo uname -a = `uname -a`                                             
echo First check what happens if you try and set SHLIB_PATH            
echo and there is no initial setting                                   
unset SHLIB_PATH                                                       
echo First what is its value?                                          
echo SHLIB_PATH = $SHLIB_PATH                                          
echo Now lets set it to default:123                                    
SHLIB_PATH="$SHLIB_PATH:123"                                           
echo OK what is the value now?                                         
echo SHLIB_PATH = $SHLIB_PATH                                          
echo                                                                   
echo Now lets reset the value to nothing                               
unset SHLIB_PATH                                                       
echo Check value                                                       
echo SHLIB_PATH = $SHLIB_PATH                                          
echo Now do what is in our script....                                  
if [ -z "${SHLIB_PATH}" ]; then                                        
   echo It has no current default value          
   SHLIB_PATH="${HOME}"                          
else                                             
    echo It has a default path of $SHLIB_PATH    
    SHLIB_PATH="${HOME}:${SHLIB_PATH}"           
fi                                               
    echo So what is our final result?            
    echo SHLIB_PATH = $SHLIB_PATH                



Get 250 color business cards for FREE!
http://businesscards.lycos.com/vp/fastpath/
--

Please see the official ORACLE-L FAQ: http://www.orafaq.com
--

Author: Viraj Luthra
  INET: viraj999_at_lycos.com

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). Received on Thu Apr 26 2001 - 02:21:21 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US