Remote spamd errors using pyzor and razor plugins

Hi,

I've recently setup remote scanning emails with spamd and I'm getting some errors that you might be able to help me with .. They seem to be around razor and pyzor plugins. I'm getting these errors on the scanning server for every email scanned:

spamd: connection from myotherserver.comĀ  at port 47917
spamd: handle_user unable to find user: 'user.name'
spamd: still running as root: user not specified with -u, not found, or set to root, falling back to nobody
spamd: processing message (unknown) for user.name:65534
spamd[25008]: pyzor: check failed: internal error, python traceback seen in response
spamd[25008]: plugin: eval failed: bayes: (in learn) locker: safe_lock: cannot create tmp lockfile /nonexistent/.spamassassin/bayes.lock.thisserver.com.25008 for /nonexistent/.spamassassin/bayes.lock: Permission denied

Thanks, Ryan

Status: 
Closed (fixed)

Comments

Howdy -- what distro/version is the remote server running?

And was SpamAssassin installed using the distro's spamassassin package?

Hi,

It's debian wheezy at both ends.

How do I determine the source of the package? Pretty sure I used the virtualmin install script . This is the pkg version info on the remote: 3.3.2-5+deb7u1

Okay, that's good -- what is the output of these two commands on your remote SpamAssassin server:

cat /etc/default/spamassassin
grep spam /etc/passwd
root@cosmo:/home/ryan# cat /etc/default/spamassassin
ENABLED=1
OPTIONS="--create-prefs --max-children 5 --helper-home-dir -i 198.23.227.190 -A 108.61.212.68,108.61.213.197"
PIDFILE=/var/run/spamd.pid
CRON=1
root@cosmo:/home/ryan# grep spam /etc/passwd
debian-spamd:x:114:117::/var/lib/spamassassin:/bin/sh

Okay, what I would suggest is to edit /etc/default/spamassassin, and there, edit the "OPTIONS" line so that it includes this at the end of the parameter list:

-u debian-spamd

That will cause it to run as the user "debian-spamd", rather than the default it's using now.

Once you do that, it will have permission to write to that user's home directory, in /var/lib/spamassassin.

After making that change, you'd want to restart SpamAssassin, which you can do with this command:

/etc/init.d/spamassassin restart

Once you do that, does it work properly for you?

Great .. looks like the pyzor messages have gone.. Thanks so much.

There is this remaining error:

handle_user unable to find user: 'user.name'

That remaining message isn't a problem... it just means that the user from your primary Virtualmin server doesn't exist on your remote SpamAssassin server.

That's okay, as SpamAssassin is going to run as the debian-spamd user.

Thanks a lot for that.

Cheers, Ryan