Excellent point, Matt!

I have tried a modification based on your suggestion:

[EMAIL PROTECTED] Junk]# su -c "sa-learn --forget" pwaldo < ./7128.
Learned from 1 message(s) (1 message(s) examined).
[EMAIL PROTECTED] Junk]# su -c "sa-learn --spam" pwaldo < ./7128.
Learned from 1 message(s) (1 message(s) examined).
[EMAIL PROTECTED] Junk]# su -c "spamc" pwaldo  < ./7128. |grep X-Spam-Status
X-Spam-Status: No, score=3.4 required=5.0 tests=AWL,BAYES_99,

As you can see, the score increased from the previous method, but it is still 
not categorized as spam.

FYI, what I am trying to do is automate learning of spam that I drag to my 
Junk IMAP folder.  

Thanks for your help!

Paul

On Monday 07 March 2005 05:15 pm, Matt Kettler wrote:
> At 03:57 PM 3/7/2005, Paul Waldo wrote:
> >I am trying to get sa-learn to learn some spam.  From my cyrus-imap Junk
> >directory, I perform the following:
> >
> >[EMAIL PROTECTED] Junk]# sa-learn --forget ./7128.
> >Learned from 1 message(s) (1 message(s) examined).
> >[EMAIL PROTECTED] Junk]# sa-learn --spam ./7128.
> >Learned from 1 message(s) (1 message(s) examined).
> >[EMAIL PROTECTED] Junk]# spamc < ./7128. |grep X-Spam-Status
> >X-Spam-Status: No, score=2.4 required=5.0 tests=AWL,DNS_FROM_AHBL_RHSBL,
> >
> >Am I missing something here?
>
> You're doing your learning as root, but using spamd. However, spamd *never*
> runs as root when processing mail. If it finds itself running as root, it
> will setuid itself to nobody.
>
> If you don't have a fixed site-wide bayes_path, spamd will use the bayes DB
> in nobody's home directory, but sa-learn is training the one in root's home
> dir.

Reply via email to