You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@spamassassin.apache.org by Greg Allen <sa...@floridacpu.com> on 2005/07/04 00:41:52 UTC
Starting SA with Procmail
I am running SA 3.0.4, and Postfix 2.2 on Redhat 8.0. I am trying to change
the way I start my SA installation in order to be able to filter out high
ranking spam scores.
I am currently sending emails to SA via a filter script similar to what is
described here.
http://advosys.ca/papers/postfix-filtering.html
But I only use Postfix and SA, not any of the other software mentioned.
And this works fine. Postfix hands off to the filter.sh script via the
entries made in master.cf as described above, emails get tagged correctly as
spam, etc. The system has been working fine like this for months.
But what I would like to do, and have failed at so far, is to instead start
SA with procmail as described here.
http://linux.duke.edu/~mstenner/docs/sa-docs/setup.html
In my attempt, I rolled back changes to master.cf to disable the filter.sh
script. My understanding is that all I am supposed to have to do is create a
file /etc/procmailrc with the entries below.
DROPPRIVS=yes
:0fw
| /usr/bin/spamc
And also set my Postfix main.cf as so.
mailbox_command = /usr/bin/procmail
(I verified this is the correct path to procmail)
I have done all of this, even restarted the server and Postfix no longer
sends email through SA when I try to call it from procmail this way, there
is no SA tagging in the headers at all and nothing in the mail logs about
SA. Postfix is working fine and still delivers email, just no SA tags.
Would anyone know anything else that could be causing SA to not start with
procmail?
The only thing that might be unusual about my install is that the server
does not hold email. I pass all email to another server/s downstream, so
there are no mailboxes or user accounts on this server.
Thanks in advance.
Re: Starting SA with Procmail
Posted by Martin Schröder <ma...@oneiros.de>.
On 2005-07-04 02:22:14 -0400, Greg Allen wrote:
> works that way from the little I can find on the subject. Procmail doesn't
> even create a log file for me. So, I am now looking at maybe using
man procmailrc
VERBOSE You can turn on extended diagnostics by setting this variable to `yes' or
`on', to turn it off again set it to `no' or `off'.
LOGABSTRACT Just before procmail exits it logs an abstract of the delivered message in
$LOGFILE showing the `From ' and `Subject:' fields of the header, what
folder it finally went to and how long (in bytes) the message was. By set
ting this variable to `no', generation of this abstract is suppressed. If
you set it to `all', procmail will log an abstract for every successful
delivering recipe it processes.
LOG Anything assigned to this variable will be appended to $LOGFILE.
Best
Martin
--
http://www.tm.oneiros.de
RE: Starting SA with Procmail
Posted by Greg Allen <sa...@floridacpu.com>.
I'm giving up on procmail. It is poorly supported and appears to only work
for local delivery (user mailbox must exist on the box) as far as I can
tell. I am using SA as an email gateway, and I just don't think procmail
works that way from the little I can find on the subject. Procmail doesn't
even create a log file for me. So, I am now looking at maybe using
amavisd-new or mailscanner, as much as I hate stacking somewhat redundant
apps on top of each other. More stuff to break...
How about turning on logging in procmail and examining the logs?
Best
Martin
--
http://www.tm.oneiros.de
Re: Starting SA with Procmail
Posted by Martin Schröder <ma...@oneiros.de>.
On 2005-07-03 18:41:52 -0400, Greg Allen wrote:
> DROPPRIVS=yes
>
> :0fw
> | /usr/bin/spamc
>
> And also set my Postfix main.cf as so.
>
> mailbox_command = /usr/bin/procmail
>
> (I verified this is the correct path to procmail)
>
> I have done all of this, even restarted the server and Postfix no longer
> sends email through SA when I try to call it from procmail this way, there
> is no SA tagging in the headers at all and nothing in the mail logs about
> SA. Postfix is working fine and still delivers email, just no SA tags.
>
> Would anyone know anything else that could be causing SA to not start with
> procmail?
How about turning on logging in procmail and examining the logs?
Best
Martin
--
http://www.tm.oneiros.de
Re: Starting SA with Procmail
Posted by mouss <us...@free.fr>.
Greg Allen wrote:
> Looks like you confirm what I had suspected after searching the entire
> Internet at least 10 times. :--)
>
> So Procmail is indeed for local delivery only, not for email gateways.
> Bummer...
that's why it is called an LDA (local delivery agent) :-)
you could try a nasty setup, where a first postfix instance considers
the domain as local eventhough it's a relay one, then let procmail
submit the message to another instance (or even to the final server if
you use something like mini_sendmail). but that would be looking for
more trouble than one has to cope with ;-p
>
> Ok, so I will try amavisd-new next.
incidentally, you'll save two forks (procmail+spamc) per message, if you
disable calls to utilities (unarchivers, file, ...). on the other hand,
you will use a site wide configuration for bayes and awl. may or may not
be an issue.
RE: Starting SA with Procmail
Posted by Greg Allen <sa...@floridacpu.com>.
Looks like you confirm what I had suspected after searching the entire
Internet at least 10 times. :--)
So Procmail is indeed for local delivery only, not for email gateways.
Bummer...
Ok, so I will try amavisd-new next.
Thank you for your time!
-----Original Message-----
From: mouss [mailto:usebsd@free.fr]
Sent: Tuesday, July 05, 2005 8:21 AM
To: salist@floridacpu.com
Cc: users@spamassassin.apache.org
Subject: Re: Starting SA with Procmail
Greg Allen wrote:
> [snip]
>
> The only thing that might be unusual about my install is that the server
> does not hold email. I pass all email to another server/s downstream, so
> there are no mailboxes or user accounts on this server.
so email will be sent from postfix to the end server, and won't be
delivered locally. as a result, procmail won't even be called.
running SA from an MDA is only feasible if your system does deliver mail
to a local or virtual user. for relay, use "gateway" mode as you did
previously. note that using amavisd-new would be better (that'll avoid
forking smapc for every mail).
Re: Starting SA with Procmail
Posted by mouss <us...@free.fr>.
Greg Allen wrote:
> [snip]
>
> The only thing that might be unusual about my install is that the server
> does not hold email. I pass all email to another server/s downstream, so
> there are no mailboxes or user accounts on this server.
so email will be sent from postfix to the end server, and won't be
delivered locally. as a result, procmail won't even be called.
running SA from an MDA is only feasible if your system does deliver mail
to a local or virtual user. for relay, use "gateway" mode as you did
previously. note that using amavisd-new would be better (that'll avoid
forking smapc for every mail).