postfix dropping SMTP connection when receiving mail

Jonathan Nalley jnalley at fgp.com
Fri May 11 21:29:21 IST 2007


Hi, I'm running MailScanner 4.58.9-1 using postfix 2.3.3 on Centos 5.

I've set our M$ Exchange Server 2007 to use our MailScanner/Postfix box as a "smart host" such that all outbound mail would be sent through the MailScanner/postfix box.  The problem is that when the Exchange box is trying to pass along an e-mail to postfix, the connection and SMTP session gets dropped or something really bizarre is going on. 

Below is a snippet of /var/log/maillog (with postfix's debug_peer_level=1000).  For the purposes of these pasted log files. 192.168.0.207 is the exchange box and 192.168.0.208 is the Postfix box.

May 11 09:40:23 mailscanner postfix/smtpd[18829]: match_hostname: exchange.myinternaldomain.com ~? 192.168.0.0/24
May 11 09:40:23 mailscanner postfix/smtpd[18829]: match_hostaddr: 192.168.0.207 ~? 192.168.0.0/24
May 11 09:40:23 mailscanner postfix/smtpd[18829]: > exchange.myinternaldomain.com[192.168.0.207]: 220 mailscanner.myinternaldomain.com ESMTP Postfix
May 11 09:40:23 mailscanner postfix/smtpd[18829]: watchdog_pat: 0x99266a0
May 11 09:40:23 mailscanner postfix/smtpd[18829]: vstream_fflush_some: fd 9 flush 83
May 11 09:40:23 mailscanner postfix/smtpd[18829]: vstream_buf_get_ready: fd 9 got 29
May 11 09:40:23 mailscanner postfix/smtpd[18829]: < exchange.myinternaldomain.com[192.168.0.207]: EHLO exchange.myinternaldomain.com
May 11 09:40:23 mailscanner postfix/smtpd[18829]: > exchange.myinternaldomain.com[192.168.0.207]: 250-mailscanner.myinternaldomain.com
May 11 09:40:23 mailscanner postfix/smtpd[18829]: > exchange.myinternaldomain.com[192.168.0.207]: 250-PIPELINING
May 11 09:40:23 mailscanner postfix/smtpd[18829]: > exchange.myinternaldomain.com[192.168.0.207]: 250-SIZE 10240000
May 11 09:40:23 mailscanner postfix/smtpd[18829]: > exchange.myinternaldomain.com[192.168.0.207]: 250-VRFY
May 11 09:40:23 mailscanner postfix/smtpd[18829]: > exchange.myinternaldomain.com[192.168.0.207]: 250-ETRN
May 11 09:40:23 mailscanner postfix/smtpd[18829]: > exchange.myinternaldomain.com[192.168.0.207]: 250-AUTH LOGIN PLAIN
May 11 09:40:23 mailscanner postfix/smtpd[18829]: match_list_match: exchange.myinternaldomain.com: no match
May 11 09:40:23 mailscanner postfix/smtpd[18829]: match_list_match: 192.168.0.207: no match
May 11 09:40:23 mailscanner postfix/smtpd[18829]: > exchange.myinternaldomain.com[192.168.0.207]: 250-AUTH=LOGIN PLAIN
May 11 09:40:23 mailscanner postfix/smtpd[18829]: > exchange.myinternaldomain.com[192.168.0.207]: 250-ENHANCEDSTATUSCODES
May 11 09:40:23 mailscanner postfix/smtpd[18829]: > exchange.myinternaldomain.com[192.168.0.207]: 250-8BITMIME
May 11 09:40:23 mailscanner postfix/smtpd[18829]: > exchange.myinternaldomain.com[192.168.0.207]: 250 DSN
May 11 09:40:23 mailscanner postfix/smtpd[18829]: watchdog_pat: 0x99266a0
May 11 09:40:23 mailscanner postfix/smtpd[18829]: vstream_fflush_some: fd 9 flush 178
May 11 09:40:23 mailscanner postfix/smtpd[18829]: smtp_get: EOF
May 11 09:40:23 mailscanner postfix/smtpd[18829]: match_hostname: exchange.myinternaldomain.com ~? 192.168.0.0/24
May 11 09:40:23 mailscanner postfix/smtpd[18829]: match_hostaddr: 192.168.0.207 ~? 192.168.0.0/24
May 11 09:40:23 mailscanner postfix/smtpd[18829]: lost connection after EHLO from exchange.myinternaldomain.com[192.168.0.207]
May 11 09:40:23 mailscanner postfix/smtpd[18829]: disconnect from exchange.myinternaldomain.com[192.168.0.207]


When enabling verbose session logging on the M$ Exchange box, below is the relevant SMTP session snippet:

2007-05-11T18:06:53.714Z,PostFixSendConnector,08C9612DB0BAB77B,0,,192.168.0.208:25,*,,attempting to connect
2007-05-11T18:06:53.714Z,PostFixSendConnector,08C9612DB0BAB77B,1,192.168.0.207:11256,192.168.0.208:25,+,,
2007-05-11T18:06:53.714Z,PostFixSendConnector,08C9612DB0BAB77B,2,192.168.0.207:11256,192.168.0.208:25,<,220 postfixbox.myinternaldomain.com ESMTP Postfix,
2007-05-11T18:06:53.714Z,PostFixSendConnector,08C9612DB0BAB77B,3,192.168.0.207:11256,192.168.0.208:25,>,EHLO exchange.myinternaldomain.com,
2007-05-11T18:06:53.714Z,PostFixSendConnector,08C9612DB0BAB77B,4,192.168.0.207:11256,192.168.0.208:25,<,
2007-05-11T18:06:53.714Z,PostFixSendConnector,08C9612DB0BAB77B,5,192.168.0.207:11256,192.168.0.208:25,-,,Local

The second-to-last line actually has 65 spaces and then the closing comma but i couldn't get my mailer to display that in a desirable fashion.

I know it's tempting to say or to think that the problem might be with the M$ Exchange box, but i can tell Exchange to use other Postfix/MailScanner installations (admittedly running MailScanner version 4.46.2-2 and postfix version 2.1.5) as the smart host and everything works smoothly.

I've seen other posts in the mailing list with people having "smtp_get: EOF" in their logs and other similar entries but many were related to TLS, SSL, SASL and authentication and all that stuff but i'm not trying to do any of that here.  Any thoughts, wisdom, insights, fixes, and solutions greatly appreciated. Thanks In Advance.


Below is postconf -n:

alias_database = hash:/etc/aliases
alias_maps = hash:/etc/aliases
broken_sasl_auth_clients = yes
command_directory = /usr/sbin
config_directory = /etc/postfix
daemon_directory = /usr/libexec/postfix
debug_peer_level = 1000
debug_peer_list = 192.168.0.207
header_checks = regexp:/etc/postfix/header_checks
html_directory = no
inet_interfaces = all
mail_owner = postfix
mailq_path = /usr/bin/mailq.postfix
manpage_directory = /usr/share/man
mydestination = localhost.$mydomain, localhost, $mydomain
mydomain = myinternaldomain.com
myhostname = mailscanner.myinternaldomain.com
mynetworks = 192.168.0.0/24, 127.0.0.0/8
myorigin = $mydomain
newaliases_path = /usr/bin/newaliases.postfix
queue_directory = /var/spool/postfix
readme_directory = /usr/share/doc/postfix-2.3.3/README_FILES
relay_domains = $mydestination
sample_directory = /usr/share/doc/postfix-2.3.3/samples
sendmail_path = /usr/sbin/sendmail.postfix
setgid_group = postdrop
smtpd_banner = $myhostname ESMTP $mail_name
smtpd_recipient_restrictions = permit_mynetworks permit_sasl_authenticated reject_unauth_destination
smtpd_sasl_auth_enable = yes
smtpd_sasl_path = smtpd
transport_maps = hash:/etc/postfix/transport
unknown_local_recipient_reject_code = 550



More information about the MailScanner mailing list