Talking to SMTP / Mail via telnet to diagnoze mail problems on a server

Mailserver diagnoses can be tricky: I personally find the easiest way to do it still using telnet in combination with the server logs to find out what exactly is wrong.

It is very easy to do:

telnet 25

mail from:
rcpt to:

… type some data …


That is all; it will help to exactly determine where it goes wrong.

The case we had today;

– postfix didn’t send mail ; it gave connection refused
– thoughts; firewall, network, dns etc.
– we tried the above and it worked fine, meaning postfix was the one refusing, not the network/firewall etc
– we fixed the postfix config and all was fine

Be the first to leave a comment. Don’t be shy.

Join the Discussion

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>