Monky wrote:
> Bowie Bailey wrote:
> > 
> > There is a --no-safe-fallback option on spamc which will cause it to
> > exit with an error message in the case of any problems (Normally, it
> > always exits with a 0 exit status).  If you don't want anything to
> > go through unscanned, you can try this setting.
> > 
> > > If I have 5 spamd children available and (just to torture it) I
> > > fire off 50 spamc processes, what happens?
> > 
> > Each spamc process will try to connect to spamd three times at 1
> > second intervals.  Any processes that fail to connect will let
> > their message through unscanned.  The number of retries and the
> > sleep interval between them can be configured on the spamc command
> > line. 
> > 
> Thanks for all the hints. I have now tried the following:
> I added these options to spamd --max-children=4 --timeout-child=100
> and spamc --retry-sleep=20 --no-safe-fallback.

I haven't done any testing to back this up (I use the default settings),
but my feeling would be that you should reduce the sleep time and
increase the number of retries.

Something like this:
spamc --retry-sleep=10 --connect-retries=6

or maybe even this:
spamc --retry-sleep=5 --connect-retries=12

Both of those would give you the same effective timeout (60 seconds),
but would reduce the latency between the time a spamd process becomes
available and when the spamc process connects to it.  However, if there
are 10-20 spamc processes waiting, this may not be a problem.

The increased timeout will, of course, increase the number of spamc
processes hanging around when the server gets overloaded.  That
shouldn't be an issue, but you might want to keep an eye on it just in
case it becomes excessive.  Since the timeout is 20x normal, you should
see 20x more spamc processes if spamd gets bogged down.

> Monky
> I will wait and see if this improves the situation.
> 
> Adding memory is of course tempting, but the server is a rented one
> where I cannot change the hardware but by upgrading to another (more
> costly) server hosting package.

That does complicate things.

-- 
Bowie

Reply via email to