User's Manual
Doc #: 1ANSU-160004
DNI SGDC-D22 User Manual
i. 29
7.8. Sendmail via SMTP
Sendmail is used to send a mail via SMTP protocol, the following command is an example to send a mail from DCU
to Gmail SMTP server, and Gmail SMTP server will help you to send the mail to the receiver’s mail server.
Use vi to create an example mail:
# vi /var/mailtest
Subject: This is a mail test
CC: xxxx@gmail.com
To: yyyy@gmail.com
From: zzzz@gmail.com
This is a test
After editing the test mail content, please use the following command to send it out. (Noted: make sure that the DCU
can access Internet.)
# sendmail -f zzzz@gmail.com -v -H 'openssl s_client -connect smtp.gmail.com:465 -quiet' -auUSERNANE
-apPASSWORD < /var/mailtest