nmh-workers
[Top] [All Lists]

Re: [Nmh-workers] Locking In Scripts and nmh Locking

2012-04-26 17:42:02
lyndon wrote:

On 2012-04-26, at 10:07 AM, Paul Fox wrote:

but unless you use the locker from both the commandline and the
cron-driven script, using it in either place won't help, will it?

Put the cron stuff in a file, then:

2 4 * * * mhlock /usr/local/libexec/cronmhstuff

mhlock grabs the lock, runs whatever command was fed it, then releases the 
lock.  It would be the MH equivalent of FreeBSD's lockf(1).

As long as the mhlocked cron job is running, interactive commands would 
block 
waiting to acquire the lock.

but the example paul gave was:
i am sometimes surprised when my real time human commands that might
be "pick ...  -seq xyz; scan xyz" end up having their folder changed
out from under them.

if the cron job runs in between the pick and the scan, the mhlock you've
added won't help.

paul
=---------------------
 paul fox, pgf(_at_)foxharp(_dot_)boston(_dot_)ma(_dot_)us (arlington, ma, 
where it's 57.7 degrees)

_______________________________________________
Nmh-workers mailing list
Nmh-workers(_at_)nongnu(_dot_)org
https://lists.nongnu.org/mailman/listinfo/nmh-workers

<Prev in Thread] Current Thread [Next in Thread>