3 Replies Latest reply: Jun 27, 2013 9:52 AM by Pascal Kreyer-Oracle RSS

    JAVA_HOME not set when running a task via CRON


      On my Solaris 11 server I have created an entry in the root user CRON tab to launch a groovy based application every weekend. The application runs fine under a non-root user. When run by CRON however, the following error message gets emited:



      groovy: JAVA_HOME not set and cannot find javac to deduce location, please set JAVA_HOME



      Which is weird, as I have the following lines at the end of my /etc/profile file:

      export JAVA_HOME


      export GROOVY_HOME


      export PATH


      Please advice me where to look for the cause of this problem.


      Thank you in advance,