LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 06-16-2003, 08:17 PM   #1
Pcghost
Senior Member
 
Registered: Feb 2003
Location: The Real Washington
Distribution: Debian, Android
Posts: 1,819

Rep: Reputation: 46
Postfix-spamassassin mail loop problem


I have Postfix and Spamassassin configured exactly the way the tutorials say to, with the proper entries in master.cf and what I thought was the correct settings in main.cf. When I send a message at the postfix server, it correctly sends the message through the postfixfilter.sh script and if it's spam, it is labeled as such. Here is the problem. After spamassassin checks the message, it sends it back to postfix, who immediatly rejects it as an authentication error, and the log shows the message bouncing back and forth between postfix and spamassassin until it reaches the maximum hops and dies. Can anyone tell me what setting in Postfix controls authentication errors?
 
Old 06-17-2003, 02:23 AM   #2
mcleodnine
Senior Member
 
Registered: May 2001
Location: Left Coast - Canada
Distribution: s l a c k w a r e
Posts: 2,731

Rep: Reputation: 45
any clues in the mail logs as to why you're getting the bounce?
 
Old 06-17-2003, 09:06 AM   #3
Pcghost
Senior Member
 
Registered: Feb 2003
Location: The Real Washington
Distribution: Debian, Android
Posts: 1,819

Original Poster
Rep: Reputation: 46
I get "Authentication Warning: spamassassin changed the from field to user@foo" telling me that spamassassin changed the from to its original state before sending the message back to postfix. Then it goes looping back and forth 27 times and fails. .
 
Old 06-17-2003, 05:35 PM   #4
Pcghost
Senior Member
 
Registered: Feb 2003
Location: The Real Washington
Distribution: Debian, Android
Posts: 1,819

Original Poster
Rep: Reputation: 46
Thumbs up I Got It!!!!

I finally figured it out. It turns out that the spamassassin script "postfixfilter" has a line that looks like this by default

/usr/bin/spamc | /usr/sbin/sendmail -i "$@"

That tells sendmail (yes sendmail) to reinsert the message into the queue. I don't use sendmail on this machine, so I changed it to point at the sendmail compatible postfix program

/usr/bin/spamc | /usr/sbin/sendmail.postfix -i "$@"

And now my postfix server is filtering the crap out of my email.
Woohoo!.

Thanks for your help in this and the other threads Unspawn..
LQ rules as always...
 
Old 06-17-2003, 05:52 PM   #5
mcleodnine
Senior Member
 
Registered: May 2001
Location: Left Coast - Canada
Distribution: s l a c k w a r e
Posts: 2,731

Rep: Reputation: 45
hmm. you may wan to consider renaming your original sendmail binary to something like sendmail.old and then doing a chmod 000 on it. Then create a symlink from postfix.sendmail -> sendmail

This way other apps that depend on sendmail will use your properly configured postfix instead.
 
Old 06-17-2003, 05:55 PM   #6
Pcghost
Senior Member
 
Registered: Feb 2003
Location: The Real Washington
Distribution: Debian, Android
Posts: 1,819

Original Poster
Rep: Reputation: 46
I would except we don't run anything else on this machine except postfix and spamassassin. I am actually uninstalling sendmail as we type. sendmail.postfix comes with postfix and is a compatible script for queue re-entry.

I definently would do as you said if I were running other services..
 
Old 01-09-2016, 05:06 PM   #7
peergum
LQ Newbie
 
Registered: Jan 2016
Posts: 1

Rep: Reputation: Disabled
Thumbs up A thousand thanks!

Wow, this thread is more than 10 years old, and it still solved my problem!

I was running into a loop, for the same reason mentioned. changed to sendmail.postfix and it worked as a charm!

Thanks pcghost, and thanks to Internet
 
Old 09-25-2016, 12:38 PM   #8
DuckMann
LQ Newbie
 
Registered: Sep 2016
Location: Baytown, TX
Posts: 1

Rep: Reputation: Disabled
Smile It Works! It really really works!

Man I have spent countless hours spanning many days to fix this problem. The solution here fixed it good. However, the solution here was a little vague for me, my first time setting up a server, so be gentle.

It took me some time to realize where
Quote:
spamassassin script "postfixfilter"
was located. I'm running CentOS 6.8 with Postfix and Dovecot. I'm not using Sendmail.

I fixed mine in postfix master configuration
Quote:
/etc/postfix/master.cf
I changed this line from
Code:
spamassassin unix - n n - - pipe flags=R user=spamd argv=/usr/bin/spamc -e /usr/sbin/sendmail -oi -f ${sender} ${recipient}
to
Code:
spamassassin unix - n n - - pipe flags=R user=spamd argv=/usr/bin/spamc -e /usr/sbin/sendmail.postfix -oi -f ${sender} ${recipient}
Thanks
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Postfix send mail problem(In RH9, kernal 2.4.20, postfix 2.1.5) minor Linux - General 6 09-23-2019 10:09 PM
Postfix mail forwarding loop lacerto Linux - Networking 1 06-01-2005 06:07 PM
problem receiving pop3 mail from postfix mail server GEN_Electric Linux - Software 2 02-14-2005 02:43 PM
Postfix Mail Loop dlublink Linux - Networking 0 12-30-2004 04:15 PM
Postfix and Spamassassin Phaethar Linux - Networking 0 10-30-2003 08:30 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 01:33 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration