This content has been marked as final. Show 3 replies
I met the same error when I run ant script in the crontab.
I use "root" account run ant and it work well, but when I put ant into crontab, I got the error message.
It seems your current user doesn't have "execute" rights for java.exe. Try doing chmod for that, it may work.
Grrrr. Been having a similar problem, but with Maven2. Allow me to (hopefully) save someone the gnawing of teeth and several bald patches.
For starters, the Maven documentation gives you a pretty clear example of how to set your PATH. This is as follows:
Simple, eh? Note the colon before $PATH. Then, it states quite presumptuously "4) Make sure JAVA_HOME is set to the location of your JDK". However, you don't set it in exactly the same way. You set it in virtually the same way, except without the colon, like this:
Note that if you get the paths wrong a couple of times, you may reset them with the unset command. So to unset JAVA_HOME you'd use:
After which you may set it again. As is advised, you may try to set the user privileges, but they didn't seem to affect my luck at all. Hope this helps!