Here’s, for future reference, my quick and dirt one liner to test Sendmail:

echo ${MESSAGE BODY} | mail -v -s ${SUBJECT} ${DEST_NAME}@${DEST_DOMAIN.COM}

and here’s a sample output (no comment needed, I guess):

[root@spamhaus ~]# echo TEST | mail -v -s "Test Mail" info@spam-motel.org
info@spam-motel.org... Connecting to [127.0.0.1] via relay...
220 VM11076-6699.spamhaus ESMTP Sendmail 8.14.4/8.14.4; Tue, 19 Jun 2012 17:11:15 +0200
>>> EHLO VM11076-6699.spamhaus
250-VM11076-6699.spamhaus Hello VM11076-6699.spamhaus [127.0.0.1], pleased to meet you
250-ENHANCEDSTATUSCODES
250-PIPELINING
250-8BITMIME
250-SIZE
250-DSN
250-ETRN
250-AUTH GSSAPI DIGEST-MD5 CRAM-MD5
250-DELIVERBY
250 HELP
>>> MAIL From:<root@VM11076-6699.spamhaus> SIZE=225 AUTH=root@VM11076-6699.spam-motel.org
250 2.1.0 <root@VM11076-6699.spamhaus>... Sender ok
>>> RCPT To:<info@spam-motel.org>
>>> DATA
250 2.1.5 <info@spam-motel.org>... Recipient ok
354 Enter mail, end with "." on a line by itself
>>> .
250 2.0.0 q5JFBFtg026246 Message accepted for delivery
info@spam-motel.org... Sent (q5JFBFtg026246 Message accepted for delivery)
Closing connection to [127.0.0.1]
>>> QUIT
221 2.0.0 VM11076-6699.spamhaus closing connection

Mail will be received as from “root@HOSTNAME”. If you want to set a different from-address (eg. info@HOSTNAME), you may follow this guideline:

echo ${MESSAGE BODY} | mail -r info -v -s ${SUBJECT} ${DEST_NAME}@${DEST_DOMAIN.COM}