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 is taking forever to reach the destination - Is it possible to "traceroute" a mail?

During the last weekend I upgraded an old 10.4 Server to new hardware and 10.6.

After some manually fixing it's now working as it should. BUT – Mail from some senders is taking more than an hour to recieve!? Eg, I sent a mail from an Office 365 account, it took a minute. Another mail from a Gmail account took more than an hour...!?


This was *not* the behavior before the upgrade, so I know for sure that something has happened. How can I find out what's wrong?


I'm thinking about some kind of traceroute for emails. Ie, to find out if the error is somewhere on my server, or if Gmail is holding the mail due to greylisting.


It's the same for different domains on the samer server. Eg "trojangames.se"


Any ideas?

Posted on Jan 5, 2016 7:30 AM

Reply
Question marked as Best reply

Posted on Feb 4, 2016 1:31 AM

Well you should start from the basics and exclude variables — so, for example, don't send email from a mail client using a mail provider, but inject an email directly into your SMTP port at mail.trojangames.se/mail.macsystem.se.

https://www.port25.com/how-to-check-an-smtp-connection-with-a-manual-telnet-sess ion-2/

You'll need to do this from a static IP because your server is blocking dynamic IPs via zen.spamhaus.org lookup.

If you inject the email see what messages your server responds with. Then you can know (including the real time) the email has been accepted by your OS X Server.app.

At the same time as doing the manual SMTP email injection look at the SMTP log in server.app on your machine. See what it is saying. If you have a usual setup you should see Postfix handing over to Amavis and then mail being relayed via Dovecot to the target user.

This should give you a clear look at what is happening. If the email is being held up by greylisting on your server (Gmail would greylist its own outgoing email) you should see.

You can also do a direct injection from a client inside your LAN, from one user to another, to see and compare to inbound email from the Internet.

2 replies
Question marked as Best reply

Feb 4, 2016 1:31 AM in response to Andreas Carlsson

Well you should start from the basics and exclude variables — so, for example, don't send email from a mail client using a mail provider, but inject an email directly into your SMTP port at mail.trojangames.se/mail.macsystem.se.

https://www.port25.com/how-to-check-an-smtp-connection-with-a-manual-telnet-sess ion-2/

You'll need to do this from a static IP because your server is blocking dynamic IPs via zen.spamhaus.org lookup.

If you inject the email see what messages your server responds with. Then you can know (including the real time) the email has been accepted by your OS X Server.app.

At the same time as doing the manual SMTP email injection look at the SMTP log in server.app on your machine. See what it is saying. If you have a usual setup you should see Postfix handing over to Amavis and then mail being relayed via Dovecot to the target user.

This should give you a clear look at what is happening. If the email is being held up by greylisting on your server (Gmail would greylist its own outgoing email) you should see.

You can also do a direct injection from a client inside your LAN, from one user to another, to see and compare to inbound email from the Internet.

Mar 3, 2016 4:02 AM in response to Andreas Carlsson

Chances are it is due to greylisting. You can try and disable greylisting to see if it helps. To do so, issue:


sudo serveradmin settings mail:postfix:greylist_enabled = no


to re-enable, issue:


sudo serveradmin settings mail:postfix:greylist_enabled = yes


If that doesn't help, have a look at mail.log while sending from an outside server. Either through Server.app -> Logs or via Terminal by issuing:


tail -f /var/log/mail.log


HTH,

Alex

Mail is taking forever to reach the destination - Is it possible to "traceroute" a mail?

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