Re: [Tutor] Lock File Usage

2017-01-30 Thread Ben Finney
"ad^2" writes: > So, IF: no lock file, create a lock file, execute, delete lock file > when finished successfully. ElSE: the script is running, exit. Then, > cron will try again an hour later. > > I do not necessarily require a "lock file" just looking for a > recommendation on a best practice w

Re: [Tutor] Lock File Usage

2017-01-30 Thread Alan Gauld via Tutor
On 30/01/17 14:45, ad^2 wrote: > So, IF: no lock file, create a lock file, execute, delete lock file when > finished successfully. ElSE: the script is running, exit. Then, cron will > try again an hour later. That's probably the most common way of doing what you want. But you need to make absolu

[Tutor] Lock File Usage

2017-01-30 Thread ad^2
Hello all, I have more more todo on a script I just finished. Prevent it from executing again if the process is running from the last job. Can't go to production without it. Ex. it runs in cron every hour to process batches of large size files. Potentially the processing could take longer than on