Please keep this on the list.

On 12/12/2012 8:09 PM, Joseph Acquisto wrote:
It doesn't matter how many messages SA has processed.  What matters is
how many messages Bayes has learned via autolearn or manual sa-learn runs.

You can log in as the user SA runs as and check the bayes database:

$ sa-learn --dump magic

You want to look at the nham and nspam numbers.  You MUST do this as the
same user SA is using or the results will not be useful.  Also, if you
do manual learning via sa-learn, you must do it as the same user as SA.

This is my result:

0.000          0          3          0  non-token data: bayes db version
0.000          0        878          0  non-token data: nspam
0.000          0       1064          0  non-token data: nham
0.000          0     114391          0  non-token data: ntokens
0.000          0 1352511853          0  non-token data: oldest atime
0.000          0 1355310610          0  non-token data: newest atime
0.000          0          0          0  non-token data: last journal sync atime
0.000          0 1355278210          0  non-token data: last expiry atime
0.000          0    2764800          0  non-token data: last expire atime delta
0.000          0      38573          0  non-token data: last expire reduction 
coun

I run sa-learn via script, as root.   spamd runs as root.  spamassassin, in  
/etc/postfix/main.cf has the user defined as spamfilter.
I don't know if that is an issue.

It might be.  Take a look at spamfilter's database.

If spamd is running as root, it may be doing per-user filtering depending on your setup. If this is the case, the spamd will switch users each time it receives a message to scan the message using that user's settings. This means that each user's bayes db must be above the threshold before that user will see bayes scoring.

What should I see in headers if bayes is active?

If bayes is active, you should see a BAYES_XX rule hit on every email.

Tangent - I noticed this in /var/log/messages (probably unrelated)

Dec 12 02:13:55 open-122 echo[665]: Starting spamd:
Dec 12 02:13:58 open-122 echo[645]: Starting the SpamAssassin Proxy Daemon:
Dec 12 06:14:09 open-122 spampd[682]: defined(@array) is deprecated at 
/usr/lib/perl5/vendor_perl/5.16.0/Net/Server.pm line 211.
Dec 12 06:14:11 open-122 spampd[682]: (Maybe you should just omit the 
defined()?)
Dec 12 06:14:50 open-122 systemd[1]: spampd.service: main process exited, 
code=exited, status=1
Dec 12 06:14:50 open-122 systemd[1]: Unit spampd.service entered failed state.

Seen a few times, over month or so.

No idea about this.

--
Bowie

Reply via email to