I want to schedule a task on linux by icrontab, and the task is written in python and have to
import cx_Oracle module, so I export ORACLE_HOME and LD_LIBRARY_PATH in .bash_profile, but
it raise the error:
libclntsh.so.11.1: cannot open shared object file.
python a.py # ok
# the shell script scheduled in icrontab
Possibly you want to specify
PATH — and also
LD_LIBRARY_PATH — so that
cron(1) knows where to find binaries.
Read "5 Crontab environment" here.