Mail is not working on debian server - Outgoing SMTP "Connection timed out"

0

I have Debian 8 VPS and websites running on PHP 5.6, using Cloudflare DNS servers.

I tried to install sendmail and postfix, but sending mails is not working, even through the CLI.

I can see syslog I can see logs like this: (mydomain is my domain)

Jul  4 17:41:09 vps412690 sm-mta[5957]: x5TK7ad3018816: to=<no-reply@mydomain.net>, delay=4+19:33:33, xdelay=00:00:00, mailer=esmtp, pri=61500000, relay=mydomain.net., dsn=4.0.0, stat=Deferred: Connection timed out with mydomain.net.
Jul  4 17:41:09 vps412690 sm-mta[5957]: x5TJUpU3017091: to=<no-reply@mydomain.net>, delay=4+20:10:18, xdelay=00:00:00, mailer=esmtp, pri=61860000, relay=mydomain.net., dsn=4.0.0, stat=Deferred: Connection timed out with mydomain.net.
Jul  4 17:41:09 vps412690 sm-mta[5957]: x5THvaYB011369: to=<no-reply@mydomain.net>, delay=4+21:43:33, xdelay=00:00:00, mailer=esmtp, pri=62670000, relay=mydomain.net., dsn=4.0.0, stat=Deferred: Connection timed out with mydomain.net.

Any idea how I can debug / fix this issue or point out to what I'm could be missing?

TheUnreal

Posted 2019-07-04T15:45:48.227

Reputation: 137

Looks like your provider mught be blocking port 25 - Have you asked them about this? – davidgo – 2019-07-04T17:06:27.640

I don't think: tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN 0 244500681 11491/sendmail: MTA – TheUnreal – 2019-07-07T05:41:51.467

Your ertor states mydomain.net is nit answering on port 25. Thats what needs to be fixed. Unless mydomain.net resolves to 127.0.0.1 and on thevsame machine , your server listening on tjat port is not relevant. – davidgo – 2019-07-07T07:12:28.830

No answers