How to: Test Email flow using SMTP commands
How to: Test Email flow using SMTP commands
you need to test email by these
commands you can test email flow at a very granular level to determine
what's broken and where.Scenario:
Your domain: mydomain.com
Domain you wish to send to: theirdomain.com
Open a CMD prompt
>Type NSLOOKUP
> set q=mx
> theirdomain.com
Response:
Non-authoritative answer:
theirdomain.com MX preference = 50, mail exchanger = mail.theirdomain.com
-> TELNET MAIL.THEIRDOMAIN.COM 25
You should see something like this as a response:
220 mx.google.com ESMTP 6si6253627yxg.6
ehlo mydomain.com
mail from:<martin9700@mydomain.com>
rcpt to:<recipient@someotherdomain.com>
data
This is a test, please do not respond
.
quit
Your domain: mydomain.com
Domain you wish to send to: theirdomain.com
Open a CMD prompt
>Type NSLOOKUP
> set q=mx
> theirdomain.com
Response:
Non-authoritative answer:
theirdomain.com MX preference = 50, mail exchanger = mail.theirdomain.com
2: Connect to their mail server
MTP communicates over port 25. We will now try to use TELNET to connect to their mail server "mail.theirdomain.com"
-> Open a CMD prompt-> TELNET MAIL.THEIRDOMAIN.COM 25
You should see something like this as a response:
220 mx.google.com ESMTP 6si6253627yxg.6
3: Send an Email
ehlo mydomain.com
mail from:<martin9700@mydomain.com>
rcpt to:<recipient@theirdomain.com>
data
This is a test, please do not respond
.
quit
mail from:<martin9700@mydomain.com>
rcpt to:<recipient@theirdomain.com>
data
This is a test, please do not respond
.
quit
4: Test SMTP relay
Testing SMTP relay is very easy, and simply requires a small change to the above commands. See below:
ehlo mydomain.com
mail from:<martin9700@mydomain.com>
rcpt to:<recipient@someotherdomain.com>
data
This is a test, please do not respond
.
quit
Comments
Post a Comment