Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'd like to mention that im really new to this so please bear with me. I'm trying to setup a forum software to send emails via postfix but I think my server has the port 25 blocked. I tried running these:

works:

ping alt2.gmail-smtp-in.l.google.com

don't work:

telnet alt2.gmail-smtp-in.l.google.com 25
telnet 66.249.93.114 25

tried flushing iptables and then using these rules but didn't work either:

sudo iptables --flush

sudo iptables -P INPUT ACCEPT
sudo iptables -P OUTPUT ACCEPT
sudo iptables -P FORWARD ACCEPT
sudo iptables -F
sudo iptables -X

doing a telnet on 25 port to localhost url works but nothing when telnet'ing in none local urls.

mail.log:

Oct 17 01:20:24 webhost postfix/smtp[3642]: connect to alt2.gmail-smtp-in.l.google.com[2607:f8b0:400e:c03::1a]:25: Connection timed out

Oct 17 01:20:24 webhost postfix/smtp[3643]: connect to alt2.gmail-smtp-in.l.google.com[2607:f8b0:400e:c03::1a]:25: Connection timed out

Oct 17 01:20:24 webhost postfix/smtp[3642]: 4744380032: to=<targetMail@gmail.com>, relay=none, delay=2892, delays=2741/0.03/150/0, dsn=4.4.1, status=deferred (connect to alt2.gmail-smtp-in.l.google.com[2607:f$
share|improve this question

2 Answers 2

Could be your ISP or hosting provider filtering outbound connections to port 25 to prevent botnet spam. Use

traceroute -n alt2.gmail-smtp-in.l.google.com

and/or

tcptraceroute -n alt2.gmail-smtp-in.l.google.com 25

to check which hop is blocking the connection.

share|improve this answer
    
1st: pastebin.com/i0dPnnmZ 2nd: pastebin.com/hmPm8bCC –  Adonis K. Oct 16 '12 at 23:20
    
Both outputs appear to be from traceroute. Were you running the command on different hosts? –  Ansgar Wiechers Oct 16 '12 at 23:34
    
i think the software automatically used traceroute instead of tcptraceroute cause i didnt have tcptraceroute installed. The outcome is exactly the same though. I just installed and tested it again –  Adonis K. Oct 17 '12 at 8:39
    
I also tried 587 port but didn't reach the destination: pastebin.com/q0VEGuJj –  Adonis K. Oct 17 '12 at 8:46
    
If the output of tcptraceroute is the same as the output of the second trace in your first comment, then it does look to me like your provider is filtering outbound connections (at least to port 25). nmap shows port 587 on that host as "filtered". For submission you have to use a different host. –  Ansgar Wiechers Oct 18 '12 at 8:37

Gmail recommends connecting to smtp.gmail.com on port 587 for TLS/STARTTLS or 465 for SSL. http://support.google.com/mail/bin/answer.py?hl=en&answer=13287

share|improve this answer
    
tried 587, didn't reach the destination: pastebin.com/q0VEGuJj –  Adonis K. Oct 17 '12 at 8:46
1  
You're looking at the wrong host. You're tracing the route to one of GMail's MXs when you should be tracing the route to one of their submission hosts. Compare the output of host -t MX gmail.com and host -t A smtp.gmail.com. –  Ansgar Wiechers Oct 18 '12 at 8:41

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.