Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I have a gentoo computer I am using as the household firewall, mail server, etc. It is running Amavis-new with SpamAssissin.
SpamAssissin is filtering spam. The built in rules are being reported and my local rules are also working.
The problem is that no messages get a Bayes score, neither positive nor negative. Can anybody recommend ways to debug this?
The log file shows it is accessing the database:
Code:
jeeves ~ # grep -i bayes /var/log/mail | tail
May 3 12:17:06 jeeves amavis[22342]: (22342-18) SA dbg: locker: safe_lock: created /home/spamtrap/.spamassassin/bayes\.lock.jeeves.gchouse.org.22342
May 3 12:17:06 jeeves amavis[22342]: (22342-18) SA dbg: locker:safe_lock: trying to get lock on /home/spamtrap/.spam\assassin/bayes with 0 retries
May 3 12:17:06 jeeves amavis[22342]: (22342-18) SA dbg: locker:safe_lock: link to /home/spamtrap/.spamassassin/bayes\.lock: link ok
May 3 12:17:06 jeeves amavis[22342]: (22342-18) SA dbg: bayes: tie-ing to DB file R/W /home/spamtrap/.spamassassin/bayes_toks
May 3 12:17:07 jeeves amavis[22342]: (22342-18) SA dbg: bayes: tie-ing to DB file R/W /home/spamtrap/.spamassassin/bayes_seen
May 3 12:17:08 jeeves amavis[22342]: (22342-18) SA dbg: bayes: found bayes db version 3
May 3 12:17:13 jeeves amavis[22342]: (22342-18) SA dbg: bayes: learned '28345cc8de2fbaacc7baee1447b61e27ed2c3514@sa_generated', atime: 1241378209
May 3 12:17:13 jeeves amavis[22342]: (22342-18) SA dbg: bayes: untie-ing
May 3 12:17:14 jeeves amavis[22342]: (22342-18) SA dbg: bayes: files locked, now unlocking lock
May 3 12:17:14 jeeves amavis[22342]: (22342-18) SA dbg: locker: safe_unlock: unlink /home/spamtrap/.spamassassin/bayes.lock
I'm still not seeing anything in /var/log/mail except what I had above about connecting to the database. I suspect that I shouldn't?
However, I now see some messages with BAYES_00=-2.599, and a few with BAYES_20. I think that means it is working at finding ham (it was correct -- the email was indeed ham). But I'm not seeing anything in my junk folder marked with BAYES. Could my database be bad?
There are some messages in the junk folder. These are all messages that matched home-grown rules for forged headers.
First, if you are using amavisd, add_headers will have no effect, since amavisd adds headers, not spamassassin.
Second, I suspect that header checks are taking place before content filtering, and hence not being sent to amavisd.
Try sending yourself a test spam message that won't get caught by your header checks and look at the headers. See http://spamassassin.apache.org/gtube/
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.