Newsroom Update

Beginning in May, a special Today at Apple series titled “Made for Business” will offer small business owners and entrepreneurs free opportunities to learn how Apple products and services can support their growth and success. Learn more >

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Mail from Gmail Servers is Delayed Hours

I've been having a very peculiar problem for a few months now. Any mail sent to my server, via gmail (whether a gmail.com email address or a gmail-hosted private domain), gets delayed for hours before it gets to my inbox. All other servers are able to send essentially instanatly. But Gmail can take an hour, up to as long as 4 hours. Sometimes they do come in right away. If someone sends me 3 test emails, the sceond one might arrive right away, and the third might arrive 10 minutes later, and the first might arrive hours later. The delay seems to be totally random.


My server is 10.6.8, running Apple's Mail server. My DNS is all proper, my server's IP is a real, non-dymanic one with proper reverse set up. I have all my MX and SPF records configured correctly.


I do use the following four realtime databases on my server, but it doesn't seem like they could be at fault. All the mail does arrive eventually, and only gmail servers are getting delayed.

cbl.abuseat.org

sbl.spamhaus.org

xbl.spamhaus.org

bl.spamcop.net


This is one strange problem, that I'm not really sure how to diagnose.

Xserve, Mac OS X (10.6.8), 8 x 3.0 GHz, 8 GB RAM, Early 2008

Posted on Jun 9, 2013 6:54 PM

Reply
5 replies

Jun 11, 2013 8:14 AM in response to l008com

Check the SMTP mail server logs, as a start. Look for the connection requests for the delayed messages, and also particularly look for 450 try-again-later responses from your mail server.


If you're seeing 450 errors in the logs, you're probably getting delayed by greylisting, as the OS X Server box learns about the various Google mail servers. Greylisting will generate that response for the first few contacts with a "new" mail server, as that greatly reduces the volume of spam. The spam engines don't retry their messages. Real mail servers do.


Here are some details on disabling greylisting, though I generally don't recommend doing that.

Jun 11, 2013 10:54 AM in response to l008com

So I sent myself a test email, from my gmail account, to my main account. The email hasn't arrived, and this is what showed up in the error log (with logging set to "information"):


Jun 11 13:47:08 macfixer postfix/smtpd[1815]: connect from mail-qc0-f174.google.com[209.85.216.174]

Jun 11 13:47:09 macfixer postfix/smtpd[1815]: NOQUEUE: reject: RCPT from mail-qc0-f174.google.com[209.85.216.174]: 450 4.7.1 <derp@not-gmail.com>: Recipient address rejected: Service is unavailable; from=<derp@gmail.com> to=<derp@not-gmail.com> proto=ESMTP helo=<mail-qc0-f174.google.com>

Jun 11 13:47:09 macfixer postfix/smtpd[1815]: disconnect from mail-qc0-f174.google.com[209.85.216.174]


If it's greylisting like you say, why is it being such a problem all of the sudden, and why only for gmail?

Jun 21, 2013 6:17 PM in response to l008com

So disabling graylisting worked, email is now instant. But now I do get WAY more spam. Mostly "online pharmacy" spam, the shittiest kind. So is there some kind of middle ground. Like using greylisting but ONLY on hosts that do not come from a valid source, as dictated by the SPF record? That should give me the best of both worlds?

Mail from Gmail Servers is Delayed Hours

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.