Error while running Rsync through Crontab

hi All,

i have implemented Rsync in my source and destination server. while running through command prompt it is working fine:

ksh rsync_bravo_db.ksh usa0300uz1252.apps.mc.xerox.com /uv1402/u207/home/bravodba/bin/rsync-3.0.9/config/mrsx_rsync.cfg

but later on i created a another ksh and called this ksh from Crontab, as a result it gave following error:

LD_LIBRARY_PATH is already defined in .bashrc file and in .profile file, but while using from crontab,it has given above problem. please suggest

cron knows nothing about your environment... so you will have to also define all the variable it uses and find in your env like PATH etc...

that's i have already done and mentioned the same variable in .profile file,like i have mentioned in my previous post.

As vbe says, cron knows nothing about your environment (and it is NOT doing an interactive login) on your account. It's not going to run your .profile or .bashrc at all.

So you need to set any variables you need (eg. the one's you've put in your .profile and .bashrc) at the start of the script that cron runs.

Also, set any path(s) that are needed to find stuff in the script too.

declared the variable in the same .ksh script now, it working..awesome

thanks a lot for this