ld.so.1: sde2shp: fatal: libsde.so: open failed: No such file or directory

441
2
Jump to solution
05-03-2012 07:15 AM
JohnKnight
New Contributor
I am running ArcSDE 9.3.1 on Solaris 10 against Oracle 10gR2.

I have a shell file which uses sde2shp fine - it creates the files as expected. When I try to schedule the shell file via crontab I get the error message:
ld.so.1: sde2shp: fatal: libsde.so: open failed: No such file or directory

I have checked that the SDE directories appear before the Oracle directories in the PATH and LD_LIBRARY_PATH and also that the file libsde.so exists in SDEHOME/lib.

Has anyone got any suggestions on how to resolve this please?

Thanks.

John
0 Kudos
1 Solution

Accepted Solutions
VinceAngelo
Esri Esteemed Contributor
'cron' jobs generally run in a different shell (Bourne or Korn), so they won't run your .cshrc.
It's generally necessary to explicitly set every variable you might need at the top of the
script (in the appropriate syntax) --

#!/bin/sh # myCronJob.sh  # .. set path variables # SDEHOME=/opt/esri/arc100ora10g64 ORACLE_HOME=/opt/oracle/product/.... PATH=$SDEHOME/bin:$ORACLE_HOME/bin:$PATH LD_LIBRARY_PATH=$SDEHOME/lib:$ORACLE_HOME/lib:/usr/lib:/usr/local/lib export SDEHOME ORACLE_HOME PATH LD_LIBRARY_PATH  # .. set connection variables # SDEUSER=foo SDEPASSWORD=bar export SDEUSER SDEPASSWORD  ...


- V

View solution in original post

0 Kudos
2 Replies
VinceAngelo
Esri Esteemed Contributor
'cron' jobs generally run in a different shell (Bourne or Korn), so they won't run your .cshrc.
It's generally necessary to explicitly set every variable you might need at the top of the
script (in the appropriate syntax) --

#!/bin/sh # myCronJob.sh  # .. set path variables # SDEHOME=/opt/esri/arc100ora10g64 ORACLE_HOME=/opt/oracle/product/.... PATH=$SDEHOME/bin:$ORACLE_HOME/bin:$PATH LD_LIBRARY_PATH=$SDEHOME/lib:$ORACLE_HOME/lib:/usr/lib:/usr/local/lib export SDEHOME ORACLE_HOME PATH LD_LIBRARY_PATH  # .. set connection variables # SDEUSER=foo SDEPASSWORD=bar export SDEUSER SDEPASSWORD  ...


- V
0 Kudos
JohnKnight
New Contributor
Hi Vince,

Thanks for your reply.

You were right, by including the settings in the shell file the process now works correctly under cron.

Thank you very much for your speedy reply and help.

Kind regards.

John
0 Kudos