On 12/17/2012 6:11 PM, RW wrote:
On Mon, 17 Dec 2012 18:37:51 +0100
Bruno Costacurta wrote:

Hello,

a question about increasing / decreasing children process.
I got following message in log file. Please note timing as
increasing and decreasing actions are consecutive.

Dec 17 13:00:25 vps622 spamd[1335]: prefork: adjust: 0 idle children
less than 1 minimum idle children. Increasing spamd children: 9358
start
Dec 17 13:00:28 vps622 spamd[1335]: prefork: adjust: 2 idle children
more than 1 maximum idle children. Decreasing spamd children: 9358
killed.
Dec 17 13:00:28 vps622 spamd[1335]: spamd: handled cleanup of child
pid [9358] due to SIGCHLD: interrupted, signal 2 (0002)

Looks normal or my config is wrongly setup ?

spamc configuration is the following:

# /etc/default/spamassassin
ENABLED=1
OPTIONS="--create-prefs --min-spare 1 --max-spare 1 --max-children 5
If you set min-spare == max-spare you are likely to get children
created and deleted in rapid succession, the default is 1 and 2.

Right.  Consider this situation starting with an idle server:

1 idle child
email comes in
1 busy child
too few spares, so create one
1 busy child, 1 idle child
email processing finishes
2 idle children
too many idle children, kill one
1 idle child
another email comes in...

Every time an email comes in, the server will have to start a new child process and every time a child process goes idle, the server will have to kill one. You need a range so that the server can work more efficiently.

--
Bowie

Reply via email to