spf-discuss
[Top] [All Lists]

[spf-discuss] Re: spfd performance

2007-01-16 10:41:09
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Dan_Mitton(_at_)notes(_dot_)ymp(_dot_)gov wrote:
I am running Exim (4.61) and spfd (Mail::SPF 2.003) on a fairly small
Sun Solaris Ultra 60 server (dual 300 MHz CPUs w/2 GB memory).

Before installing SPF, the server was running under 10% CPU utilization,
after SPF it's more like 30-35% with occasionally high peaks.  It still
doesn't sound to bad, but I'm getting occasional timeouts from the Exim
'readsocket' call when talking to spfd.  These usually occur in
"bursts". I have already increased the timeout to 60s.

That doesn't sound right.  I usually get response times of less than 1s in 
my SPF mail filter, which admittingly doesn't use spfd but calls Mail::SPF 
directly.

Are there limits on the number of simultaneous processes that spfd will
fork?

No.  It will fork for every request, no limits.  (I know that there are 
better ways for handling many requests, e.g. by using a worker thread 
pool, however Mail::SPF's spfd has inherited its forking model from its 
Mail::SPF::Query-based predecessor.  Since I'm not using spfd myself, I 
didn't have an incentive for improving it significantly.)

However, forking is usually very efficient on Unix-based systems, so I'm 
not sure whether the "fork for every request" model actually is the cause 
of your performance problems.  At least, as long as your system doesn't 
run out of memory, response times definitely shouldn't be higher than just 
a few seconds, let alone >60s!

Is there any tuning that can be done in spfd? OS (Solaris 8)? 
Other then upgrading the servers (we're working on it ;-) ), are there
any other suggestions?

Maybe some Exim expert has some ideas?

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFFrQ3zwL7PKlBZWjsRAl9lAKDruZP3x6UOyhU59Y3B5AiVGhR/9QCdH7F/
uc9rin6LNX72s0SWAk9+ku8=
=RTt/
-----END PGP SIGNATURE-----

-------
Sender Policy Framework: http://www.openspf.org/
Archives at http://archives.listbox.com/spf-discuss/current/
To unsubscribe, change your address, or temporarily deactivate your 
subscription, 
please go to http://v2.listbox.com/member/?list_id=735