postfix mail delivery

Recently users have been reporting that mail randomly is not delivered from outside SMTP servers to internal accounts.

What's strange with an issue I've tried to track down today, I can see Google's servers connection all the way through to the Postfix/Cleanup process. After this, from what I understand, it should pass off to the Postfix/Qmgr where the mail is delivered (this is probably horribly over simplified)

Sep  3 14:32:17 lamphost2 postfix/smtpd[30238]: connect from[]
Sep  3 14:32:17 lamphost2 postgrey[2478]: action=pass, reason=client whitelist,, client_address=, sender=****, recipient=****
Sep  3 14:32:17 lamphost2 postfix/smtpd[30238]: 9E5718F0C28C:[]
Sep  3 14:32:17 lamphost2 postfix/cleanup[26127]: 9E5718F0C28C: message-id=<4C7EF5F8.4050500@****>

That's the end of the whole process, nothing more. The message simply falls off the radar and the user who originally sent the message is notified that the message was deferred or it timed out, etc. It's very random, though, as stated, I've had more people who are all using different SMTP servers to send to our system that have had issues.

All that has been done thus far was increasing the smtp_connect_timeout in Postfix from the default (which I think it 30s) to 35s. Nothing else has been changed on the system.





Does any sign of the message appear in the /var/log/procmail.log file?

Also, if you check the Postfix mail queue with the mailq command, does the message appear stuck there?

Hi Jamie,

No, the message does not appear in /var/log/procmail.log. I checked the mail queue for postfix in webmin and the message does not appear there either. Should I be checking from the command line instead?


Here's the Procmail conf:

VIRTUALMIN=|/etc/webmin/virtual-server/ $LOGNAME
* ?/usr/bin/test "$VIRTUALMIN" != ""
* ^X-Spam-Status: Yes


That looks OK to me..

Are you sure those are the online lines for the message in the mail log? What if you try seaching for the message ID 9E5718F0C28C ?


That's the strange thing. Those are the only two lines.

Wierd .. I think you might have to ask Postfix experts for help in debugging this, as it seems the mail loss is happening entirely inside Postfix, before the message gets handed off to Virtualmin.

Does this always happen for a specific mail account, or is it intermittant across accounts?

It is intermittent. I'll get in touch with the Postfix people to see what can be figured out.



Interesting bit of trivia I just noticed yesterday while still trying to resolve this problem. The emails that disappear in our system all originate from Gmail (either @gmail accounts or domains using Google Apps to host their domain email). They receive a notice back that their message either the connection timed out or it failed.


Interesting, that might indicate some kind of network problem between your network and Google that is causing the SMTP connection to be dropped before the message can be completely transferred.