V
V
Vanes Ri_Lax2016-04-07 15:04:15
linux
Vanes Ri_Lax, 2016-04-07 15:04:15

How to run a Java program with cron?

Hello,
I wrote a program, I need to run it on the crown, 1 time per day.
Here's how I did it, I
write a command
crontab -e
, it opens the vim text editor for me, in it I write the following:
00023*** java -jar /var/www/prg/programma.jar
then I press esc and enter :wq,
press enter.
Then it gives me:

no crontab for root - using an empty one
crontab: installing new crontab
"/tmp/crontab.XXXXxZHF8Z":1: bad day-of-month
errors in crontab file, can't install.
Do you want to retry the same edit?

I press Y opens the same document. When you enter N, it just closes everything to me, but as I understand it, nothing has been saved.
What am I doing wrong?
Thank you very much in advance!

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
DevMan, 2016-04-07
@vanesxl

you blew all the polymer spaces:0 23 * * * java -jar /var/www/prg/programma.jar

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question