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

Re: restricting process limit



Daniel Pittman <daniel@rimspace.net> writes:

> On Tue, 27 Apr 2004, Dan Christensen wrote:
>> Daniel Pittman <daniel@rimspace.net> writes:
>> 
>>> On Mon, 26 Apr 2004, George Georgalis wrote:
>>>> On Mon, Apr 26, 2004 at 06:44:35PM +0200, LeVA wrote:
>>>> 
>>>>>So when I'm getting a large amount of messages there is approx. 
>>>>>15-20 spamc/spamd running. I want to limit this to ~5.
>>>> 
>>>> I suspect if spamc invokes spamd but spamd reached its max-children
>>>> then spamc will act as if spamd timed out, or report ham.
>>>
>>> That depends on the options you pass to spamc; I pass -x which says
>>> "report a temp failure in that case", and advise that for general
>>> use.
>> 
>> I'm not sure if this is helpful to the original poster, but I invoke
>> spamc from within procmail, and use a lockfile to limit it to one
>> invocation at a time.  
>> 
>> Does anyone see a problem with this setup?  (I use exim as my MTA.)
>
> No, no problem.  This is a pretty high overhead solution, though, and
> the original question was about limiting that overhead. :)

It's low overhead in the sense that only one copy of spamc is ever
running at once, which is similar to what the original question
wanted.  And many people run procmail as a delivery agent anyways,
in which case there are no extra processes spawned.

I guess my question is whether this could lead to temporary failures,
etc, as was mentioned for other solutions.  If exim tries to deliver
20 messages at once, and starts 20 copies of procmail, and each of
those waits in turn to get the lock file, I wonder if exim will time
out and think that delivery has failed...

Dan



Reply to: