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

Re: Looking to share cost of MHonArc customisation



On Sun, 14 Dec 2003 13:38:43 -0800 (PST) 
Earl Hood <earl@xxxxxxxxxxxx> wrote:
> --- J C Lawrence <claw@xxxxxxxx> wrote:

>> This doesn't inherently need a modification to MHonArc.  Just wrap
>> your call to MHonArc in a script which runs `du` against the target
>> directory, adds in the computed size of the current message and then
>> does The Right Thing.

> But what exactly is "The Right Thing"?

That was the point.  It is entirely contextual: delete oldest, delete
attachment, refuse to archive, etc.

> Various solutions exist to get the size of messages outside of mhonarc
> (attachments and a little twist, but is manageable).  However, the
> trick is how to tell mhonarc to delete older messages until the total
> archive size is below max bytes size.  I do not see an efficient
> solution to this that does not require hooking into mhonarc itself or
> performing your own bookkeeping of messages (duplicating some of what
> mhonarc does).

If the Right Thing encludes deleting a message already in the archive
the brute force approach would be to delete the archive and regen it.

> BTW, external-based processing would may need to deal synchronization
> issues.  I.e. Some form of external locking is needed on the archive
> to avoid multiple processes from accessing the archive.  Something
> like Procmail's lockfile could be used to manage this.

Yup.  Sometimes I assume too much as this is exactly what I do.

-- 
J C Lawrence
---------(*)                Satan, oscillate my metallic sonatas.
claw@xxxxxxxx               He lived as a devil, eh?
http://www.kanga.nu/~claw/  Evil is a name of a foeman, as I live.


[Index of Archives]     [Bugtraq]     [Yosemite News]     [Mhonarc Home]