Quote:
Originally Posted by enes1177
How I can configure cron to use the correct Java library?
|
Cron uses its own PATH which is probably different than the PATH use by root or user. You might need to set up a PATH in the script run by cron which points to the correct version of Java. Something similar to this should be the first two statements in the script that cron executes:
PATH=/usr/local/bin:/usr/bin:/bin:/usr/bin/X11:/usr/games
export PATH
To find the correct files to include in your cron PATH issue this command:
echo $PATH
as a user or root which accesses the correct version of Java.
---------------------
Steve Stites