----- Original Message ----- From: "Chris" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Friday, February 13, 2004 10:50 PM Subject: Newbie setting up Bayes
I'm really new to SA and just upgraded last night to 2.63. I'm trying to get Bayes filtering setup. I have the following in my local.cf which is located in /etc/mail/spamassassin: # Enable Bayes auto-learning auto_learn 1 bayes_path /etc/mail/spamassassin/bayes I took this from the spamassassin wiki for site wide Bayes filtering. The problem is, and maybe its not a problem, that my bayes_seen and bayes_toks files are in /home/chris/.spamassassin. Will they be read correctly from this directory since all my rule files are in /etc/mail/spamassassin? If not, what do I need in my local.cf file to put them in there and have them read? Thanks Chris ---------------------------------------- Chris, I just went through this as a newbie too! It is not straightforward, as you've learned. It seems to matter what directory you're in when you run sa-learn. As someone told me, "bayes_path" does not seem to be well-respected. Mine works now - THANKS GUYS! I agree with what Raquel said. What I did was set up a directory where I wanted to put the toks and seen files. I set permissions there to 0777. I also used the bayes_file_mode 0700 statement in local.cf. Furthermore, I made sure I (as root) was -IN- the desired directory where I wanted the data files to go when I ran sa-learn! (/var/.spamassassin in my case) That worked. It was the combination of actually getting the files where the bayes_path statement expected and getting the permissions that made it finally work for me - and it works GREAT BTW! Here's my local.cf snippet: use_bayes 1 bayes_path /var/.spamassassin/bayes bayes_file_mode 0777 bayes_auto_learn_threshold_nonspam 0.1 bayes_auto_learn_threshold_spam 10.0 bayes_auto_learn 1 The other thing that wasn't clear to me as a newbie is that if your bayes path is as above, the toks and seen files are put in /var/.spamassassin as bayes_toks and bayes_seen. The "bayes" in that path statement just tells it to APPEND the toks and seen names to bayes_ -IN- the .spamassassin file. (I originally expected them to be in the /var/.spamassassin/bayes directory!) Does that help you? I was dying trying to get this going as a newbie, but it was well worth the effort. If you want to compare notes more off-list, do not hesitate to email me. Finally, if you haven't already, print and read the man pages! I found those more helpful than some of the other information available on the Net. Good luck - John
