Telnet your email server

Very often it is necessary to test that your SMTP server is working.
The easiest way to do this is with the telnet command.
This lets you talk directly to the email server in its own SMTP protocol script language.
Here’s how…
telnet server name or IP address 25
HELO aaaa
mail from: <tom@fromdomain.com>
rcpt to: <fred@todomain.com>
data
Enter your message text
.
quit
Along the way [...]