Sponsored Content
Full Discussion: Problem with LD_LIBRARY_PATH
Top Forums Shell Programming and Scripting Problem with LD_LIBRARY_PATH Post 302856431 by rafa_fed2 on Tuesday 24th of September 2013 03:11:14 AM
Old 09-24-2013
Problem with LD_LIBRARY_PATH

I am on Solaris .

I have written a script callled T_1.sh
Code:
#!/bin/sh







########################################################################################################
# # Source borne shell env.This is required for crontab to work as bip.sh  uses environmental variables.
########################################################################################################
. /.ss.sh






#######################################################################
# ORACLE/ARBOR ENVIRONMENT VARIABLE DECLARATION
#######################################################################
ORACLE_HOME=/var/opt/oracle/product/10g; export ORACLE_HOME
PATH=$PATH:$ORACLE_HOME/bin:/bin:/usr/bin; export PATH
ARBOR_USR=$ARBORDBU; export ARBORDBU
ARBOR_DB_PASSWD=`cat $ARBORDIR/.arborpw`; export ARBOR_DB_PASSWD
ORACLE_SID=$DSQUERY; export ORACLE_SID





#######################################################################
####MAIN SCRIPT
#######################################################################
today=`date "+%m-%d-%Y  %H:%M:%S"`; export today
CUR_DIR=/arbor/prdqa_ac/scripts ; export CUR_DIR
SCRIPT_DIR=/arbor/integ_fx/scripts
LOG_FILE=$CUR_DIR/error.log; export LOG_FILE

# Direct script output to log


echo "SQLPLUS CONNECTION"

sqlplus -s $ARBOR_USR/$ARBOR_DB_PASSWD@$ORACLE_SID<<EOF>$CUR_DIR/sql_output.txt
set feedback off
set heading off
select distinct account_no from adj  WHERE ADJ_TRANS_CODE=-2401  and request_status=1  and bill_ref_no=0
order by account_no;
EOF






if [  ! -s  "$CUR_DIR/sql_output.txt" ]
then
echo "No account number for bad debt"
else
for i in `cat $CUR_DIR/sql_output.txt`
do
echo "bip $i is running"
sh  $SCRIPT_DIR/bip.sh 01 0 $i >  $CUR_DIR/bip_log_1.txt
sleep 200
done
fi


###Removing temporary log files generated

if [ -f  "$CUR_DIR/bip_log_1.txt" ]
then
 rm  "$CUR_DIR/bip_log_1.txt"
 echo "file bip__log_1.txt removed"
fi

if [ -f "$CUR_DIR/sql_output.txt" ]
then
 rm  "$CUR_DIR/sql_output.txt"
 echo "sql_output.txt removed"
fi

rm  $CUR_DIR/error.log


I am calling bip.sh(it is standardises script.bip.sh further calls a binary file called BIP in its procedure).When i m running the T_1.sh it throws an error


Code:
ld.so.1: BIP: fatal: librc.so: open failed: No such file or directory

Cause of this error is
Code:
This occurs if the environment variable LD_LIBRARY_PATH (Sun), is not set correctly. The value should be $COBDIR/lib:$LD_LIBRARY_PATH\ 
(or the appropriate variant) on Server Express $COBDIR/coblib:$LD_LIBRARY_PATH (or the appropriate variant) on Object COBOL Developer Suite.

Please provide me the solution.I am able to run this code in DEV environment but it is failing in QA environment

---------- Post updated at 12:41 PM ---------- Previous update was at 11:11 AM ----------

Anyone?

Last edited by vbe; 09-24-2013 at 04:59 AM..
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

cc, setuid, and LD_LIBRARY_PATH

Hi, This question deals with Solaris 2.8 and setuid programs. From research I've done so far, setuid programs ignore LD_LIBRARY_PATH; I've proven this and am OK with it. The thing I am not certain of how the C compiler is supposed to behave when it is invoked via a setuid program. Basically,... (0 Replies)
Discussion started by: WolfBoy
0 Replies

2. UNIX for Dummies Questions & Answers

Bash LD_LIBRARY_PATH?

Hello I have just tried to install ns-allineone-2.31 on cygwin cygwin is using the bash shell it asks for somethings to be put into the LD_LIBRAY_PATH, here is a snippet of what it says. (1) You MUST put /home/Chris/ns-allinone-2.31/otcl-1.13, /home/Chris/ns-allinone-2.31/lib, into your... (1 Reply)
Discussion started by: bysonary
1 Replies

3. UNIX for Dummies Questions & Answers

Ld_library_path

Hi, can anyone explain this terrm? should we setup it ? Thanks (1 Reply)
Discussion started by: ccp
1 Replies

4. UNIX for Advanced & Expert Users

Difference between LIB_PATH and LD_LIBRARY_PATH

I would like to know the differences between LIB_PATH and LD_LIBRARY_PATH on Linux and SunOS. I am getting an error while loading shared libraries on Linux (Omni works build environment) as shown below: 1:tradewind/dataaccess/*.pcc... (1 Reply)
Discussion started by: shafi2all
1 Replies

5. HP-UX

SHLIB_PATH or LD_LIBRARY_PATH

hi Im using HP-UX 11i,PARISC .... Where do i find SHLIB_PATH or LD_LIBRARY_PATH , i couldnt find in env, listing...... Moreover im trying to execute file its throwing me error usr/lib/dld.sl: Can't find path for shared library: libgcc_s.sl /usr/lib/dld.sl: No such file or directory... (3 Replies)
Discussion started by: vasanthan
3 Replies

6. Solaris

setenv: cannot add the LD_LIBRARY_PATH

Hi all! I need to add new environment variable. e.g. # setenv LD_LIBRARY_PATH "/usr/ucblib:" # I check:# env LD_LIBRARY_PATH=/usr/ucblib: After rebooting I don't see this variable. Why don't save this variable? Thanks. (5 Replies)
Discussion started by: wolfgang
5 Replies

7. Shell Programming and Scripting

updating LD_LIBRARY_PATH

Inside my csh script, I have the following command: source ${HOME}/.login When I execute my csh script, why do I get the following error message: /cygdrive/c/WINDOWS/system32/export: Permission denied This is what I have inside my .login #!/bin/bash export... (9 Replies)
Discussion started by: casau
9 Replies

8. AIX

Set LD_LIBRARY_PATH to 1 or empty

I have a question on setting environmental variable LD_LIBRARY_PATH. The case is that, i cannot execute wget on my AIX machine. It return the following error: exec(): 0509-036 Cannot load program wget because of the following errors: 0509-022 Cannot load module... (5 Replies)
Discussion started by: cstsang
5 Replies

9. Shell Programming and Scripting

Ld_library_path

Hi., Currently my LD_LIBRARY_PATH setting is, LD_LIBRARY_PATH=/opt/app/product/11.2.0/client_1/lib Now, I need to append the JAVA to this setting... Can I set this way, Please suggest. ... (4 Replies)
Discussion started by: nuthakki
4 Replies

10. UNIX for Advanced & Expert Users

Why LD_LIBRARY_PATH did not work but LDFLAGS did?

Hello, a few moments ago, I tried to compile lynx. It complained about the lack of ncurses. I downloaded it, compiled it and then installed it to non standard directory. Going back to the lynx, I expected to pass ncurses location to it through a .pc file and PKG_CONFIG_PATH. However the version... (5 Replies)
Discussion started by: colt
5 Replies
All times are GMT -4. The time now is 02:24 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy