Mohamed Saligh
Mohamed Saligh

Reputation: 12349

SMTP : Simple Unix command

What is the command to test a smtp host that whether reachable from my unix machine through port 25 using valid authentication details?

Lets say:

host: smtp.gmail.com 
port: 25
username: someusername
password: somepassword

how to test this is reachable from my machine?

Thanks :)

Upvotes: 1

Views: 3967

Answers (3)

Padmanabha Vn
Padmanabha Vn

Reputation: 624

http://www.simplehelp.net/2008/12/01/how-to-send-email-from-the-linux-command-line/

or try this

openssl s_client -connect smtp.gmail.com:25

Upvotes: 1

Jonathan Leffler
Jonathan Leffler

Reputation: 754450

You could test whether it is reachable with telnet:

telnet smtp.gmail.com 25

You don't really need credentials for that - if you can connect, you'll get a response back from the SMTP server (HELO, or EHLO, I think - check RFC 821 (old) or RFC 5321 (new, but not clear on status)).

Upvotes: 0

Jonathan Day
Jonathan Day

Reputation: 18702

telnet and here is a walkthrough

Upvotes: 0

Related Questions