[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

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

From: Lyndon Nerenberg
Subject: Re: [Nmh-workers] Locking In Scripts and nmh Locking
Date: Thu, 26 Apr 2012 10:12:06 -0700

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.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]