Re: Dual Postfix

This is a discussion on Re: Dual Postfix within the mailing.postfix.users forums, part of the Mail Servers and Related category; > From: J Thomas Hancock <jthancock@bwsys.net> > Date: Tue, 19 Oct 2004 10:47:41 -0500 &...


Go Back   Usenet Forums > Mail Servers and Related > mailing.postfix.users

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 10-19-2004
m
 
Posts: n/a
Default Re: Dual Postfix

> From: J Thomas Hancock <jthancock@bwsys.net>
> Date: Tue, 19 Oct 2004 10:47:41 -0500
> To: <postfix-users@postfix.org>
> Subject: Dual Postfix
>
> I am setting up a postfix/spamassassin mail proxy. Due to how we want to
> scan incoming emails for spam, the best way for us to implement our system
> is to have postfix running twice and have postfix1 forward emails to
> postfix2 I have postfix1 up and running fine on the primary IP address on
> the machine, 192.168.0.20. Postfix2 is running on a secondary IP address,
> 192.168.0.21, assigned to the same physical Ethernet adapter. I can telnet
> to port 25 of each instance to confirm that postfix is working. When I
> forward a message from postfix1 to 192.168.0.21, the message is bounced back
> with 'mail for 192.168.0.21 loops back to myself'. Is there any way to get
> an instance of postfix to forward a message to a second instance of postfix
> on the same server?


You are complicating things unnecessarily.

You need two SMTP listeners, but not two completely separate instances of
Postfix. The hostnames for each MUST be different (at least, that's my
understanding).

Try the following in /etc/postfix/master.cf:
smtp inet n - n - - smtpd
-o smtpd_proxy_filter=127.0.0.1:10025
-o smtpd_client_connection_count_limit=10
127.0.0.1:10026 inet n - n - - smtpd
-o smtpd_authorized_xforward_hosts=127.0.0.0/8
-o smtpd_client_restrictions=
-o smtpd_helo_restrictions=
-o smtpd_sender_restrictions=
-o smtpd_recipient_restrictions=permit_mynetworks,rej ect
-o smtpd_data_restrictions=
-o mynetworks=127.0.0.0/8
-o receive_override_options=no_unknown_recipient_chec ks
-o myhostname=spamkiller.mydomain.com

The first listing (smtp...) automatically forwards each message to an
instance of spamassassin listening on localhost (127.0.0.1), port 10025.
(Actually, I'm running Maxim Paperno's spampd here, but it should work for
spamc/spamd also). The SA instance, after running its checks, forwards the
message to the smtpd listener on port 10026 of localhost, which completes
delivery.

The -o (override) options are there to skip all the checks I already did on
the first instance (listed in /etc/postfix/main.cf), and to permit mail to
only come from localhost.

Of course, if I'm wrong here, hopefully someone else on the list will
educate me, too!


Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 05:54 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0