You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@spamassassin.apache.org by JP <sa...@b-dub.org> on 2004/09/03 04:19:58 UTC

Baysian Help

I am running postfix with Procmail and Amavisd-new and SA 2.64

Everything is working fine (and has been for about 5 months now).  I
finally got around to see about using Baysian filtering site wide.  And by
sitewide I mean for two domains with a grand total of two actual users.

I set-up the /etc/mail/spamassassin/local.cf as directed on the SA WiKi.

Now I have two users "me" and "you", the Bayes database files live in the
default /etc/mail/spamassassin/

The directory and files have been set to permissions of 665  the owner of
the files is vscan (AMAVISD user) and the group is "users" (the group for
"me" and "you")

Now as user "me" i executed the command:

sa-learn --spam -C /etc/mail/spamassassin --showdots --mbox
/home/me/mail/spams

which ran just fine.

Now when I executed the same command as "you" I recieved a permissions
error?  Upon inspecting the Bayes DB files apparently the file
bayes_toks is now owned by "me" and the permissions have been changed to 600.

What am i missing here?

Thanks,
JP

Re: Baysian Help

Posted by JP <sa...@b-dub.org>.
> At 10:19 PM 9/2/2004 -0400, JP wrote:
>>Now when I executed the same command as "you" I recieved a permissions
>>error?  Upon inspecting the Bayes DB files apparently the file
>>bayes_toks is now owned by "me" and the permissions have been changed to
>> 600.
>>
>>What am i missing here?
>
> What you're missing, and what's missing from the wiki is that if you do a
> site-wide, and SA can be called as several-userID's you need to set
> bayes_file_mode to 777 in your local.cf.
>
> Since some of bayes files, particularly the journal, get deleted and
> recreated on a regular basis, what user owns them will varry, thus you
> need
> to set the world-read/write access.. you need 777 because the mask is
> sometimes used to create directories, and you'll need x on those. (The
> files will never be created 777, they'll be created 666. The "mode" here
> is
> really a mask, not a mode).

Thanks Matt!

JP

Re: Baysian Help

Posted by Matt Kettler <mk...@comcast.net>.
At 10:19 PM 9/2/2004 -0400, JP wrote:
>Now when I executed the same command as "you" I recieved a permissions
>error?  Upon inspecting the Bayes DB files apparently the file
>bayes_toks is now owned by "me" and the permissions have been changed to 600.
>
>What am i missing here?

What you're missing, and what's missing from the wiki is that if you do a 
site-wide, and SA can be called as several-userID's you need to set 
bayes_file_mode to 777 in your local.cf.

Since some of bayes files, particularly the journal, get deleted and 
recreated on a regular basis, what user owns them will varry, thus you need 
to set the world-read/write access.. you need 777 because the mask is 
sometimes used to create directories, and you'll need x on those. (The 
files will never be created 777, they'll be created 666. The "mode" here is 
really a mask, not a mode).