sending mail from command line in FreeBSD 6.1

rob rob at robhq.com
Thu Aug 24 20:22:54 IST 2006


Not sure if this will work in FreeBSD, but I use this with CentOS

Usage:  sendEmail [options]   or   command | sendEmail [options]

  Required:
    -f <from>            from email address
    -t <to> [<to>]       to email address(es) (space separated list)

  Common:
    -u <subject>         (this will soon be -s, and -s will become -h[ost])
    -m <message>         if -m is absent the message is read from STDIN
    -s <server[:port]>   default is localhost:25

  Optional:
    -a <file> [<file>]   file attachment(s)
    -cc  <to> [<to>]     cc  email address(es)
    -bcc <to> [<to>]     bcc email address(es)

  Paranormal:
    -l <logfile>         log to the specified file
    -v                   verbosity - use multiple times for greater effect
    -q                   be quiet (no stdout output)

http://caspian.dotconf.net/menu/Software/SendEmail/

-----Original Message-----
From: mailscanner-bounces at lists.mailscanner.info
[mailto:mailscanner-bounces at lists.mailscanner.info] On Behalf Of emm1
Sent: Thursday, August 24, 2006 1:55 PM
To: MailScanner discussion
Subject: sending mail from command line in FreeBSD 6.1

Anyone know how i can send a mail to user from command line in FreeBSD
with an attachment ? I tried sendmail -toi user at domain.com < test.txt
but the test.txt doesn't come as an attachment, the contents of the
file comes in the body of the mail.

Thanks!
-- 
MailScanner mailing list
mailscanner at lists.mailscanner.info
http://lists.mailscanner.info/mailman/listinfo/mailscanner

Before posting, read http://wiki.mailscanner.info/posting

Support MailScanner development - buy the book off the website! 



More information about the MailScanner mailing list