want to run program every minute, crontab????
I have a java program that talk to database. I want this program to run every minute. I plan to use crontab but worry about the new job will start when the old one is not finish. Should I use crontab for this case? Anyway to make sure that only one process running on system?
|
The easiest way would just be to loop one proccess with a pause after it completes each task.
If you want to launch a new proccess each time then using a check file would probably be sufficient. |
Quote:
|
Quote:
|
As usual, scripting is the answer. You could throw your java start command in a for loop, sleep in between for a bit, and reloop if the last one is done. Sort of like:
Code:
for infinite (or maybe time limit) |
All times are GMT -5. The time now is 07:29 PM. |