I have an SMTP-server, for this question let's call it: smtp.mydomain.com.
How do I check if the SMTP-server is working? Can I send emails manually from the Linux command line?
The syntax for establishing a raw network connection using telnet is this:
telnet {domain_name} {port_number}
So telnet to your SMTP server like
telnet smtp.mydomain.com 25
And copy and paste the below
helo client.mydomain.com
mail from:<[email protected]>
rcpt to:<[email protected]>
数据
From:[email protected]
Subject: test mail from the command line
this is test number 1
sent from the linux box
.
quit
Note:Do not forget the "." at the end which represents the end of the message. The "quit" line exits to end the session