HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials

HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials (http://www.howtoforge.com/forums/index.php)
-   HOWTO-Related Questions (http://www.howtoforge.com/forums/forumdisplay.php?f=2)
-   -   how to run jar file using cron? (http://www.howtoforge.com/forums/showthread.php?t=20238)

shoaibahmedbaig 8th February 2008 09:14

how to run jar file using cron?
 
hi guys ,

i want to run jar file using crontab -e
here is the following :

my jar file is in my home directory which is :

/home/shoaib/my.jar

I m using IBMJava2-142-ia32-SDK-1.4.2-8.0.i386.rpm which is installed in

/opt/IBMJava2-142

now i want to schedule my jar file to run every monday at morning .

here is my cron entry :

30 11 * * * /opt/IBMJava2-142/bin/java -jar /home/shoaib/my.jar

could u please tell me wats wrong with that command and my back-end database sever is IBM DB2 9.0.

this command is run normally but when i schedule it through cron it didn't run, waiting for your response .

Regards,

Shoaib

falko 9th February 2008 19:10

Please try to use full paths in /home/shoaib/my.jar. Cron's environment variables are a bit different from what you have on the shell.


All times are GMT +2. The time now is 15:12.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.