swaks – command line SMTP testing tool

swaks is a command line SMTP testing tool available at

http://www.jetmore.org/john/code/swaks/

On Debian/Ubuntu, you can install it with

swaks mail testing tool

if you just type swaks, it will ask your email, then sent a mail using MX Record to specified email address.

To send email using specific mail sevrer

Deliver a standard test email, requiring CRAM-MD5 authentication as user [email protected] An “X-Test” header will be added to the email body. The authentication password will be prompted for if it cannot be obtained from your .netrc file.

Here is an example command that use a remote SMTP server to sent email. I used this on a backup bash script to sent email alters after backup completed.

See SMTP

Leave a Reply

Your email address will not be published. Required fields are marked *