[imp] Report as Spam

Edwin Culp eculp at encontacto.net
Sun Sep 12 05:09:25 PDT 2004

Quoting Geoff Sweet <lists at whootis.com>:

> This is an odd question and as such I am not sure where to begin so I am
> delicately posting this in a couple mailing lists because I feel it is a
> culmination of several things.
> In my Imp I turned on the "Report as Spam".  I have the Imp config setup
> to use spam like so:
> /**
>  ** Spam Reporting
>  **/
> // Should we display a "report this message as spam" link in the
> // message view?
> $conf['spam']['reporting'] = true;
> // If so, should we report them via email?
> $conf['spam']['email'] = 'postmaster at whootis.net';
> // Should we report them via an external program?
> $conf['spam']['program'] = '/usr/local/bin/spamassassin -r';
> Now however when I use this feature I get this in my Apache logs:
> Cannot write to //.spamassassin/user_prefs: No such file or directory
> Failed to create default user preference file //.spamassassin/user_prefs
> lock: 58007 cannot create tmp lockfile
> //.spamassassin/bayes.lock.serv.whootis.com.58007 for
> //.spamassassin/bayes.lock: No such file or directory
> So just out of curiosity I create /.spamassassin to see what gets
> created and who created it.  As I suspected the files are owned by my
> apache user.  So here is my question, isn't calling that spamassassin
> command suppose to be invoked as the authenticated vpopmail user?  Is
> the behavior I am seeing normal?  Can anyone offer me a better solution
> to what I am doing?  I like the idea of allowing all my users to build
> on the Bayes system.

AFAIK, the file that you are looking for should be automatically
created by spamassassin in each user's home directory based on
your configuration and the way it is invoked.  In my personal
case I have:

# ls -l /home/virtual/encontacto.net/eculp/.spamassassin
total 4578
-rw-------  1 www  www   655360 Sep 12 04:32 bayes_seen
-rw-------  1 www  www  5292032 Sep 12 04:32 bayes_toks
-rw-rw----  1 www  www     1165 Aug 11 07:33 user_prefs

I've never had to touch mine but it is invoked with maildrop and
the file is based on the local configuration file.  In my case
it is the following:

ls -l /usr/local/etc/mail/spamassassin/local.cf
-rw-r--r--  1 root  wheel  1227 Sep  7 20:02

I should also warn that since my courier/maildrop/IMP has always
worked, so I haven't taken the time to figure out how it works.
I'm basically guessing.  I do make changed in the point system in
local.cf ocassionally and that is about it.  I only seem to have
time for problems ;)  I hope this will give you another
perspective and make your finding a solution easier.


More information about the imp mailing list