[SOLVED] Postfix/smtp Connection timed out

5 posts / 0 new
Last post
#1 Fri, 10/09/2015 - 17:57
softwarecomunitario

[SOLVED] Postfix/smtp Connection timed out

Hello,

Since I have update Webmin to version 1.770 I can't no more send email:

tail -500 /var/log/maillog | grep 'postfix' ->

Oct  9 21:42:01 ns postfix/smtp[32638]: connect to smtp-in.neuf.fr[93.17.128.123]:25: Connection timed out
Oct  9 21:42:01 ns postfix/smtp[32642]: connect to spool.mail.gandi.net[217.70.184.6]:25: Connection timed out
Oct  9 21:42:01 ns postfix/smtp[32641]: connect to smtp-in.orange.fr[80.12.242.9]:25: Connection timed out
[...]
Oct  9 21:42:38 ns postfix/smtp[32629]: B2AC0428401: to=<thierry.s@gmx.de>, relay=none, delay=1745, delays=1685/0.08/60/0, dsn=4.4.1, status=deferred (connect to mx00.emig.gmx.net[212.227.15.9]:25: Connection timed out)
Oct  9 21:42:39 ns postfix/smtp[32624]: B2AC0428401: to=<richard.roy48@dbmail.com>, relay=none, delay=1745, delays=1685/0.05/60/0, dsn=4.4.1, status=deferred (connect to 194019900.pamx1.hotmail.com[65.54.188.109]:25: Connection timed out)
[...]
traceroute -n -T -p 25 gmail-smtp-in.l.google.com ->

traceroute to gmail-smtp-in.l.google.com (173.194.67.26), 30 hops max, 60 byte packets
1  188.165.235.252  0.400 ms  0.536 ms  0.630 ms
2  213.186.32.173  0.700 ms  0.555 ms  0.733 ms
3  * * *
4  * * *
5  * * *
[...]
30  * * *


telnet gmail-smtp-in.l.google.com 25 ->

Trying 2a00:1450:400c:c05::1b...
Connected to gmail-smtp-in.l.google.com.
Escape character is '^]'.
220 mx.google.com ESMTP r9si1131419wiv.59 - gsmtp

And something strange, mydestination in main.cf was remove, and when I put "mydestination = $myhostname, localhost.$mydomain, localhost" with webmin, and re-open config I have nothing for mydestination, to keep it I have to write "mydestination = $myhostname, localhost.$mydomain, localhost" directly on the file main.cf

Help please!!!

Sat, 10/10/2015 - 20:09
andreychek

Howdy,

Webmin wouldn't actually be preventing connections to remote hosts... is it possible your ISP has begun blocking connections to some or all mail servers?

That's not an uncommon thing for ISP's to do... however, usually in that case you wouldn't be able to access any hosts on port 25, and it looks like you were able to access Gmail.

Another possibility is that it could be related to a firewall or route ... are there any tools on your network that could be blocking certain connections?

Lastly, if none of that helps, what is the output of this command:

iptables -: -n

Sat, 10/10/2015 - 21:26 (Reply to #2)
softwarecomunitario

Hello,


iptables -L -n

Chain INPUT (policy DROP)
target prot opt source destination
ACCEPT all -- 0.0.0.0/0 0.0.0.0/0
ACCEPT tcp -- 0.0.0.0/0 0.0.0.0/0 tcp flags:0x10/0x10
ACCEPT all -- 0.0.0.0/0 0.0.0.0/0 state ESTABLISHED
ACCEPT all -- 0.0.0.0/0 0.0.0.0/0 state RELATED
ACCEPT udp -- 0.0.0.0/0 0.0.0.0/0 udp spt:53 dpts:1024:65535
ACCEPT icmp -- 0.0.0.0/0 0.0.0.0/0 icmp type 0
ACCEPT icmp -- 0.0.0.0/0 0.0.0.0/0 icmp type 3
ACCEPT icmp -- 0.0.0.0/0 0.0.0.0/0 icmp type 4
ACCEPT icmp -- 0.0.0.0/0 0.0.0.0/0 icmp type 11
ACCEPT icmp -- 0.0.0.0/0 0.0.0.0/0 icmp type 12
ACCEPT tcp -- 0.0.0.0/0 0.0.0.0/0 tcp dpt:22
ACCEPT tcp -- 0.0.0.0/0 0.0.0.0/0 tcp dpt:113
ACCEPT icmp -- 0.0.0.0/0 0.0.0.0/0 icmp type 8
ACCEPT tcp -- 0.0.0.0/0 0.0.0.0/0 tcp dpt:53
ACCEPT udp -- 0.0.0.0/0 0.0.0.0/0 udp dpt:53
ACCEPT tcp -- 0.0.0.0/0 0.0.0.0/0 tcp dpt:80
ACCEPT tcp -- 0.0.0.0/0 0.0.0.0/0 tcp dpt:8080
ACCEPT tcp -- 0.0.0.0/0 0.0.0.0/0 tcp dpt:443
ACCEPT tcp -- 0.0.0.0/0 0.0.0.0/0 tcp multiport dports 25,587
ACCEPT tcp -- 0.0.0.0/0 0.0.0.0/0 tcp dpts:20:21
ACCEPT tcp -- 0.0.0.0/0 0.0.0.0/0 tcp multiport dports 110,995
ACCEPT tcp -- 0.0.0.0/0 0.0.0.0/0 tcp multiport dports 143,220,993
ACCEPT tcp -- 0.0.0.0/0 0.0.0.0/0 tcp dpts:10000:10010
ACCEPT tcp -- 0.0.0.0/0 0.0.0.0/0 tcp dpt:20000
REJECT all -- 0.0.0.0/0 0.0.0.0/0 reject-with icmp-port-unreachable

Chain FORWARD (policy ACCEPT)
target prot opt source destination
REJECT all -- 0.0.0.0/0 0.0.0.0/0 reject-with icmp-port-unreachable

Chain OUTPUT (policy ACCEPT)
target prot opt source destination

From the server I can telnet gmail on port 25:


telnet alt4.gmail-smtp-in.l.google.com 25

Trying 2404:6800:4008:c01::1b...
Connected to alt4.gmail-smtp-in.l.google.com.
Escape character is '^]'.
220 mx.google.com ESMTP oq4si14719874pbc.68 - gsmtp
ehlo ns.softwarecomunitario.com
250-mx.google.com at your service, [2001:41d0:2:b607::]
250-SIZE 35882577
250-8BITMIME
250-STARTTLS
250-ENHANCEDSTATUSCODES
250-PIPELINING
250-CHUNKING
250 SMTPUTF8
quit
221 2.0.0 closing connection oq4si14719874pbc.68 - gsmtp
Connection closed by foreign host.

So, I think the problem is not port 25?

Sat, 10/10/2015 - 23:47
softwarecomunitario

It was OVH detected spam on my server and block smtp!!

In the control Panel OVH you can disable spam blocking.

Sun, 10/11/2015 - 01:03
Diabolico
Diabolico's picture

You should checkwhy your emails was marked as spam if not your IP could be blacklisted and then you are with bigger problem then not able to send email.

- I often come to the conclusion that my brain has too many tabs open. -
Failing at desktop publishing & graphic design since 1994.

Topic locked