Gaby Vanhegan: > I'm trying to find out the source of a delay in postfix processing > some mail. I have a web app that sends a notification email to users > but there is a delay when PHP calls the mail() function. I remove the > call to mail() and the delay goes away. I turned on debuggering_peer > for localhost to see if I could spot the delay in the logs: > > http://dn.playr.co.uk/delay.log > > Here's a sample log of the transaction. The delay happens towards the > bottom: > > Aug 15 12:22:27 dn postfix/smtpd[13962]: > > localhost.localdomain[127.0.0.1]: 354 End data with <CR><LF>.<CR><LF> > Aug 15 12:22:36 dn postfix/smtpd[13962]: public/cleanup socket: wanted > attribute: status > That 9 second delay is presented to the user as the web page hanging > while the call to mail() completes. There doesn't seem to be anything > wrong in the config but I would like to eliminate the delay if > possible. Where should I start? This might help:
There is a delay of up to $trigger_timeout seconds when the Postfix postdrop command tries to notify the pickup daemon that new mail is ready for delivery. PHP -> sendmail -> postdrop -> pickup Perhaps your pickup daemon is very busy. Perhaps your pickup daemon is not running at all, as seems to be the case on MacOS. Perhaps you use Linux, and have Selinux brain damage turned on. You can ignore the problem and specify "trigger_timeout = 1" in main.cf, or you can try to solve the problem and find out what keeps the pickup server from reading its FIFO. Wietse