I have the same issue also.  No matter how I configure bayes in my config files spamd 
continues to look in the user directories for
the bayes database.  I have sa-learn updating to /var/spool/spamassassin/ but spamd 
keeps trying to create user files in my home
directory.  I have tried the -x flag for spamd but now spamd is looking for 
/usr/local/post.office/.spamassassin.
/usr/local/post.office is the install location of my mail server (Post.Office) and my 
mail user that I am running spamd under (mta).
This whole bayes database location issue hurts my brain :^\

Can someone on the list answer a few questions in an efforst to resolve this?

Example:

I am running spamd as follows:

sudo /usr/bin/spamd -u mta -d -r /var/run/spamd.pid

I have specified my bayes path as:

/var/spool/bayes/bayes

in my local.cf file.

My /var/spool/bayes/bayes* are being updated as I run sa-learn and sudo sa-learn 
--dump outputs lots of data.

My maillog show spamd looking in various places for the bayes database even when bayes 
is disabled:

command: sudo /usr/bin/spamd -u mta -d -D -r /var/run/spamd.pid
user state path: /var/root/.spamassassin

command: sudo /usr/bin/spamd -u mta -x -d -D -r /var/run/spamd.pid
user state path: /usr/local/post.office/.spamassassin

Here are some spamassassin outputs:

### use_bayes = 0

[firewall:~] admin% spamassassin --lint -D
debug: using "/Users/admin/.spamassassin" for user state dir
debug: bayes: 4087 tie-ing to DB file R/O /Users/admin/.spamassassin/bayes_toks
debug: bayes: 4087 tie-ing to DB file R/O /Users/admin/.spamassassin/bayes_seen
debug: bayes: found bayes db version 2
debug: bayes: Not available for scanning, only 0 spam(s) in Bayes DB < 200

[firewall:~] admin% sudo spamassassin --lint -D
debug: using "/Users/admin/.spamassassin" for user state dir
debug: Score set 1 chosen.
debug: Initialising learner
## there is no calls to the bayes db here???

[firewall:~] admin% sudo -u mta spamassassin --lint -D
debug: using "/Users/admin/.spamassassin" for user state dir
debug: bayes: 4106 tie-ing to DB file R/O /Users/admin/.spamassassin/bayes_toks
        Cannot open bayes databases /Users/admin/.spamassassin/bayes_* R/O: tie
        failed: Permission denied
debug: Score set 1 chosen.
debug: Initialising learner
debug: bayes: Not available for scanning, only 0 spam(s) in Bayes DB < 200
[firewall:~] admin%

### use_bayes = 1

[firewall:~] admin% spamassassin --lint -D
debug: using "/Users/admin/.spamassassin" for user state dir
debug: bayes: 5757 tie-ing to DB file R/O  /Users/admin/.spamassassin/bayes_toks
debug: bayes: 5757 tie-ing to DB file R/O  /Users/admin/.spamassassin/bayes_seen
debug: bayes: found bayes db version 2
debug: bayes: Not available for scanning, only 0 spam(s) in Bayes DB <  200

[firewall:~] admin% sudo spamassassin --lint -D
debug: using "/Users/admin/.spamassassin" for user state dir
debug: bayes: 5764 tie-ing to DB file R/O /var/spool/bayes/bayes_toks
debug: bayes: 5764 tie-ing to DB file R/O /var/spool/bayes/bayes_seen
debug: bayes: found bayes db version 2
debug: bayes: Not available for scanning, only 26 ham(s) in Bayes DB < 200

[firewall:~] admin% sudo -u mta spamassassin --lint -D
debug: using "/Users/admin/.spamassassin" for user state dir
debug: bayes: 5768 tie-ing to DB file R/O  /Users/admin/.spamassassin/bayes_toks
        Cannot open bayes databases /Users/admin/.spamassassin/bayes_* R/O: tie
        failed: Permission denied
debug: Score set 1 chosen.
debug: Initialising learner
debug: bayes: Not available for scanning, only 0 spam(s) in Bayes DB <  200

It seems very inconsistant where SA is looking for the database.  The use_bayes = 1 
option # 2 shows 26 ham(s) in Bayes which seems
about right given the amount of e-mail I have fed sa-learn.

I am guessing this has something to do with my user permissions.

Any ideas out there??

Thanks,

Dan

> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] Behalf Of
> Nichols, William
> Sent: Friday, December 05, 2003 10:43 AM
> To: SA Mailing list
> Subject: RE: [SAtalk] Changing user spamd runs as
>
> I also see that it is not able to update the bayes database - permission
> denied.  I have spamd running as the same user that the spamassassin
> process was, but it cannot get access to bayes.
>
> It looks like:
>
> Dec  5 09:29:08 spamhatbu spamd[2012]: cannot write to
> /var/spool/filter/.spamassassin/bayes_journal, Bayes db update ignored
> Dec  5 09:29:08 spamhatbu spamd[2012]: Cannot open bayes databases
> /var/spool/filter/.spamassassin/bayes_* R/W: tie failed: Permission
> denied
> Dec  5 09:29:08 spamhatbu spamd[2012]: Cannot open bayes databases
> /var/spool/filter/.spamassassin/bayes_* R/W: tie failed: Permission
> denied
> Dec  5 09:29:11 spamhatbu spamd[2012]: identified spam (21.1/6.6) for
> filter:501 in 3.7 seconds, 3338 bytes.



-------------------------------------------------------
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
_______________________________________________
Spamassassin-talk mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/spamassassin-talk

Reply via email to