You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@spamassassin.apache.org by Ryan Thoryk <ry...@onshore.com> on 2009/09/14 23:29:31 UTC

Spamc issues with remote userprefs

Hi,

We're rebuilding a mail server and are having some issues with SQL-based
SA preference lookups.  We're running Postfix 2.5.5 and SA 3.2.5 (Debian
Lenny version) - here's our Postfix config from master.cf:
spamassassin unix -     n       n       -       -       pipe
user=spamd argv=/usr/bin/spamc -u ${user} -e /usr/sbin/sendmail -oi -f
${sender} ${recipient}

old non-lookup line:
user=spamd argv=/usr/bin/spamc -f -e /usr/sbin/sendmail -oi -f ${sender}
${recipient}

What's happening is that individual incoming messages get handed off to
SA using the spamc command above, but SA is only processing the first
message and never handing it back to Postfix, while the other messages
never seem to get processed at all (nothing at all about them in the
logs).  The old non-lookup line works fine.  Has anyone here experienced
similar issues?

Ryan Thoryk


-- 
Ryan Thoryk
System Administrator
onShore Networks, LLC
completeIT® services
1407 West Chicago Avenue
Chicago, Illinois 60642-5231
312.850.5200 x146
ryant@onshore.com
www.onshore.com


Re: Spamc issues with remote userprefs

Posted by Ryan Thoryk <ry...@onshore.com>.
Jari Fredriksson wrote:
> "The old non-lookup line works fine"
> 
> spamc has no option -f
> 
> How can that work fine?
> 
> If the old line works fine, why do you try to raplace with a new line?

I noticed the extra "-f", and will remove it.  The new line has the "-u"
option, since we're trying to do per-user preference lookups via SQL.
The old line doesn't have that.

Ryan

Re: Spamc issues with remote userprefs

Posted by d....@yournetplus.com.
Quoting Jari Fredriksson <ja...@iki.fi>:

>> Hi,
>>
>> We're rebuilding a mail server and are having some issues
>> with SQL-based SA preference lookups.  We're running
>> Postfix 2.5.5 and SA 3.2.5 (Debian Lenny version) -
>> here's our Postfix config from master.cf:
>> spamassassin unix -     n       n       -       -
>> pipe
>> user=spamd argv=/usr/bin/spamc -u ${user} -e
>> /usr/sbin/sendmail -oi -f ${sender} ${recipient}
>>
>> old non-lookup line:
>> user=spamd argv=/usr/bin/spamc -f -e /usr/sbin/sendmail
>> -oi -f ${sender} ${recipient}
>>
>> What's happening is that individual incoming messages get
>> handed off to SA using the spamc command above, but SA is
>> only processing the first message and never handing it
>> back to Postfix, while the other messages never seem to
>> get processed at all (nothing at all about them in the
>> logs).  The old non-lookup line works fine.  Has anyone
>> here experienced similar issues?
>>
>> Ryan Thoryk
>
> "The old non-lookup line works fine"
>
> spamc has no option -f
>
> How can that work fine?
>
> If the old line works fine, why do you try to raplace with a new line?

You are correct. It is a sendmail option. This is what I have:

spamass   unix  -       n       n       -       6      pipe
   user=spamd argv=/usr/local/bin/spamc -u ${recipient} -s 524288
   -e /usr/local/sbin/sendmail -oi -f ${sender} ${recipient}

Sorry for the confusion.


Re: Spamc issues with remote userprefs

Posted by Jari Fredriksson <ja...@iki.fi>.
> Hi,
> 
> We're rebuilding a mail server and are having some issues
> with SQL-based SA preference lookups.  We're running
> Postfix 2.5.5 and SA 3.2.5 (Debian Lenny version) -
> here's our Postfix config from master.cf: 
> spamassassin unix -     n       n       -       -      
> pipe 
> user=spamd argv=/usr/bin/spamc -u ${user} -e
> /usr/sbin/sendmail -oi -f ${sender} ${recipient}
> 
> old non-lookup line:
> user=spamd argv=/usr/bin/spamc -f -e /usr/sbin/sendmail
> -oi -f ${sender} ${recipient}
> 
> What's happening is that individual incoming messages get
> handed off to SA using the spamc command above, but SA is
> only processing the first message and never handing it
> back to Postfix, while the other messages never seem to
> get processed at all (nothing at all about them in the
> logs).  The old non-lookup line works fine.  Has anyone
> here experienced similar issues? 
> 
> Ryan Thoryk

"The old non-lookup line works fine"

spamc has no option -f

How can that work fine?

If the old line works fine, why do you try to raplace with a new line?





Re: Spamc issues with remote userprefs

Posted by Ryan Thoryk <ry...@onshore.com>.
Duane Hill wrote:
> You named your pipe in master.cf spamassassin. Do you have:
> 
> spamassassin_destination_recipient_limit = 1
> 
> in main.cf? To do individual scoring, you need to feed your spamassassin
> pipe with one message per recipient.
> 
> Someone please correct me if I am wrong. That is, at least, how I am
> doing it here and is working fine.

I just tried that, and it looks like that fixed the issue.  I'll do some
more testing, but it seems fine.  Thanks :)

Ryan Thoryk

Re: Spamc issues with remote userprefs

Posted by Duane Hill <d....@yournetplus.com>.
On Mon, 14 Sep 2009, Ryan Thoryk wrote:

> Hi,
>
> We're rebuilding a mail server and are having some issues with SQL-based
> SA preference lookups.  We're running Postfix 2.5.5 and SA 3.2.5 (Debian
> Lenny version) - here's our Postfix config from master.cf:
> spamassassin unix -     n       n       -       -       pipe
> user=spamd argv=/usr/bin/spamc -u ${user} -e /usr/sbin/sendmail -oi -f
> ${sender} ${recipient}
>
> old non-lookup line:
> user=spamd argv=/usr/bin/spamc -f -e /usr/sbin/sendmail -oi -f ${sender}
> ${recipient}
>
> What's happening is that individual incoming messages get handed off to
> SA using the spamc command above, but SA is only processing the first
> message and never handing it back to Postfix, while the other messages
> never seem to get processed at all (nothing at all about them in the
> logs).  The old non-lookup line works fine.  Has anyone here experienced
> similar issues?

You named your pipe in master.cf spamassassin. Do you have:

spamassassin_destination_recipient_limit = 1

in main.cf? To do individual scoring, you need to feed your spamassassin 
pipe with one message per recipient.

Someone please correct me if I am wrong. That is, at least, how I am doing 
it here and is working fine.

Re: Spamc issues with remote userprefs

Posted by Ryan Thoryk <ry...@onshore.com>.
Patrick Ben Koetter wrote:
> Using it with the Postfix pipe command makes it very slow. Have you considered
> using the Sendmail milter interface integrated in Postfix in combination with
> the SpamAssassin milter?

I haven't tried that - probably should be using that instead :)

Also one other thing I'm trying to figure out is how to get Postfix to
break out email destined to aliases into multiple emails, so that the
preference lookups work properly (otherwise it does a lookup against the
alias name).  Don't know if the milter would deal with that.

Ryan




Re: Spamc issues with remote userprefs

Posted by Patrick Ben Koetter <p...@state-of-mind.de>.
* Ryan Thoryk <ry...@onshore.com>:
> Hi,
> 
> We're rebuilding a mail server and are having some issues with SQL-based
> SA preference lookups.  We're running Postfix 2.5.5 and SA 3.2.5 (Debian
> Lenny version) - here's our Postfix config from master.cf:
> spamassassin unix -     n       n       -       -       pipe
> user=spamd argv=/usr/bin/spamc -u ${user} -e /usr/sbin/sendmail -oi -f
> ${sender} ${recipient}


Using it with the Postfix pipe command makes it very slow. Have you considered
using the Sendmail milter interface integrated in Postfix in combination with
the SpamAssassin milter?

> 
> old non-lookup line:
> user=spamd argv=/usr/bin/spamc -f -e /usr/sbin/sendmail -oi -f ${sender}
> ${recipient}
> 
> What's happening is that individual incoming messages get handed off to
> SA using the spamc command above, but SA is only processing the first
> message and never handing it back to Postfix, while the other messages
> never seem to get processed at all (nothing at all about them in the
> logs).  The old non-lookup line works fine.  Has anyone here experienced
> similar issues?
> 
> Ryan Thoryk
> 
> 
> -- 
> Ryan Thoryk
> System Administrator
> onShore Networks, LLC
> completeIT® services
> 1407 West Chicago Avenue
> Chicago, Illinois 60642-5231
> 312.850.5200 x146
> ryant@onshore.com
> www.onshore.com
>