Problem with sa-learn and virtual user
Hi, My mail system use virtual user. I use spamd like this spamd --virtual-config-dir=/srv/spamassassin/%d/%l -x -u dovecot -c -i 127.0.0.1 -d -r /var/run/spamd.pid I run spamc with /usr/pkg/bin/spamc -u ${recipient} -f -e ... This work fine, each user can use it's own sa config. But i would like to be able to run sa-learn for spefic users I tryed sa-lean --username [EMAIL PROTECTED] --spam files But as I can see with debug (-D) it use bayes file of the unix user running the command. So i'm wondering how i sould do, I'm especially wondering how sa-learn can now that it should use /srv/spamassassin/%d/%l for bayes file but did not find the answer.
Re: Problem with sa-learn and virtual user
Jean-Edouard Babin wrote: On Jan 17, 2008 1:38 PM, Jonathan Armitage [EMAIL PROTECTED] wrote: Jean-Edouard Babin wrote: But i would like to be able to run sa-learn for spefic users I tryed sa-lean --username [EMAIL PROTECTED] --spam files But as I can see with debug (-D) it use bayes file of the unix user running the command. Try su - username -c sa-learn --spam spamdir Jon User are virtual. I think there is another way, but can't remember offhand. Look back through the mailing list. It was discussed a few months ago. Jon
Re: Problem with sa-learn and virtual user
Jean-Edouard Babin wrote: Hi, My mail system use virtual user. I use spamd like this spamd --virtual-config-dir=/srv/spamassassin/%d/%l -x -u dovecot -c -i 127.0.0.1 http://127.0.0.1 -d -r /var/run/spamd.pid I run spamc with /usr/pkg/bin/spamc -u ${recipient} -f -e ... This work fine, each user can use it's own sa config. But i would like to be able to run sa-learn for spefic users I tryed sa-lean --username [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] --spam files But as I can see with debug (-D) it use bayes file of the unix user running the command. Yes, the --username in sa-learn *ONLY* works with SQL backends, as per the docs. So i'm wondering how i sould do, I'm especially wondering how sa-learn can now that it should use /srv/spamassassin/%d/%l for bayes file but did not find the answer. you'd have to use the --dbpath option to over-ride SA's default idea of where the bayes database lives.
Re: Problem with sa-learn and virtual user
On Jan 17, 2008 2:31 PM, Matt Kettler [EMAIL PROTECTED] wrote: Jean-Edouard Babin wrote: Hi, My mail system use virtual user. I use spamd like this spamd --virtual-config-dir=/srv/spamassassin/%d/%l -x -u dovecot -c -i 127.0.0.1 http://127.0.0.1 -d -r /var/run/spamd.pid I run spamc with /usr/pkg/bin/spamc -u ${recipient} -f -e ... This work fine, each user can use it's own sa config. But i would like to be able to run sa-learn for spefic users I tryed sa-lean --username [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] --spam files But as I can see with debug (-D) it use bayes file of the unix user running the command. Yes, the --username in sa-learn *ONLY* works with SQL backends, as per the docs. Yes thanks, that what i see in the doc after upgrading So i'm wondering how i sould do, I'm especially wondering how sa-learn can now that it should use /srv/spamassassin/%d/%l for bayes file but did not find the answer. you'd have to use the --dbpath option to over-ride SA's default idea of where the bayes database lives. Ok, -p seem to be fine also, but it's of course a less automatic solution. thanks,