Delayed Email from Microsoft Services

Hi,
My OX in UCS is doing fine. No problem but email from Microsoft domain (hotmail.com, outlook.com, micorosft.com) is not coming in time. It is taking more than a day to reach my server. Where email from other domain is coming instantly. What should I do?

Thanks in advance.

You’ll have to read the mail log: /var/log/mail.log
When you send an email from a test account at a Microsoft, it shouldn’t take long, for their mail server to contact your server. If there is no connection for a long time, the problem is on their side, and you’ll have to contact their support.

If there is a contact, but your server rejects it temporarily, then greylisting is activated (on by default). Greylisting stalls not-well-behaving mail servers. That is an important spam filter technique. Greylisting is activated if the UCR variable mail/postfix/greylisting is enabled.

To enable popular mail providers to bypass that check, see that the UCR variable mail/postfix/greylisting/client/whitelist contains /etc/postgrey/whitelist_clients.local and then add their mail servers to it. To catch all their server, use the domain. For Microsoft mail that is outlook.com.

so I should put the domain in comma seperated value in whitelist_clients.local file like
*microsoft.com, outlook.com, hotmail.com ?

One server per line.
As Microsoft uses multiple servers, the complete domain catches all. The servers have FQDNs like outlook-com.olc.protection.outlook.com, DC5PR0301MB2358.eurprd03.prod.outlook.com,CL2RAM02HT207.eop-nam02.prod.protection.outlook.com etc.
So use outlook.com on a single line and others as well. For example:

outlook.com
gmail.com
google.com
yahoo.com
univention.de
1 Like

After adding the record should I restart any service?

Yes, Postgrey (https://postgrey.schweikert.ch/) must be restarted:
systemctl restart postgrey.service

Still email is delayed. Should I disable grey listing?

Are you sure greylisting is the reason? have you tried sending a mail from microsoft and observed your mail.log? How long does it take from sending the mail until the first connection from a MS mail server in mail.log?

which part should I look? Lots of log here in mail.log

Nov 26 23:54:01 ds postfix/smtpd[7765]: NOQUEUE: reject: RCPT from mail-oln040092254013.outbound.protection.outlook.com[40.92.254.13]: 450 4.2.0 nirjhar@thedailystar.net: Recipient address rejected: Greylisted, see http://postgrey.schweikert.ch/help/thedailystar.net.html; from=lutfarn@hotmail.com to=nirjhar@thedailystar.net proto=ESMTP helo=<APC01-PU1-obe.outbound.protection.outlook.com>

It is causing by greylisting. Can you please show me a way to white list the whole domain?

As I wrote above, you should whitelist the SMTP client machine (mail-oln040092254013.outbound.protection.outlook.com) in a file listed in the UCR variable mail/postfix/greylisting/client/whitelist. Because MS uses a lot of servers you should whitelist their complete domain by putting outlook.com on a single line in the file.

I have disabled the service as I am using Kaspersky email security. Now it is fantastic. But I need to know how to set UCR values for SMTP.

Please be more specific.

<<<how to do this? I have put the entries on that .local file.

Please make sure the file is listed in the UCRV:
ucr get mail/postfix/greylisting/client/whitelist

If it is, it should be in the command in the file /etc/default/postgrey and thus also when you look at the process:

$ ps xa | grep postgrey
29725 ?        Ss     0:00 postgrey --pidfile=/var/run/postgrey.pid --daemonize --inet=10023 
  --delay=300 --max-age=35 
  --retry-window=48h --auto-whitelist-clients=5 --lookup-by-host --privacy 
  --whitelist-clients=/etc/postgrey/whitelist_clients 
  --whitelist-clients=/etc/postgrey/whitelist_clients.local 
  --whitelist-recipients=/etc/postgrey/whitelist_recipients 
  --whitelist-recipients=/etc/postgrey/whitelist_recipients.local

HI,
I am facing this problem again when I have setup a new server for the mail. No mail is sending and receiving. All are pausing. Please help me.

Nirjhar

Mastodon