I'm having some trouble setting up ssmtp. I want to use logrotate to
compress and email my server's logs to my gmail account. I can echo text
directly to ssmtp and have it send the message ok, but when I try to use
/usr/bin/mail, I get logs in my maillog trying to use sendmail, which is set
to none in rc.conf. How do I set this up so that all mail sends out through

# /etc/ssmtp.conf -- a config file for sSMTP sendmail.

# The person who gets all mail for userids < 1000
# Make this empty to disable rewriting.

# The place where the mail goes. The actual machine name is required
# no MX records are consulted. Commonly mailhosts are named mail.domain.com
# The example will fit if you are in domain.com and your mailhub is so

# Example for SMTP port number 2525
# mailhub=mail.your.domain:2525
# Example for SMTP port number 25 (Standard/RFC)
# mailhub=mail.your.domain
# Example for SSL encrypted connection
# mailhub=mail.your.domain:465

# Where will the mail seem to come from?

# The full hostname

# Set this to never rewrite the "From:" line (unless not given) and to
# use that address in the "from line" of the envelope.

# Use SSL/TLS to send secure messages to server.

# Use SSL/TLS certificate to authenticate against smtp host.

# Use this RSA certificate.

Here's an example:
#mail -s test message [EMAIL PROTECTED] < Some_File
#tail /var/log/maillog
Mar 29 10:58:47 behemoth sendmail[41971]: k2TFwkuV041971: from=root,
size=3948, class=0, nrcpts=2, msgid=<
Mar 29 10:58:47 behemoth sendmail[41971]: k2TFwkuV041971: to=message,
[EMAIL PROTECTED], ctladdr=root (0/0), delay=00:00:01, xdelay=00:00:00,
mailer=relay, pri=63948, relay=[] [], dsn=4.0.0,
stat=Deferred: Connection refused by []
Obviously I don't get anything coming through with this example

#echo test | ssmtp [EMAIL PROTECTED]
#tail /var/log/maillog
Mar 29 11:03:24 behemoth sSMTP[42000]: Sent mail for [EMAIL PROTECTED](221
ibm58aec.myisp.net ESMTP server closing connection)
I do recieve this message

I'd be happy to provide any other information to anyone who can help me set
this up.
freebsd-questions@freebsd.org mailing list
To unsubscribe, send any mail to "[EMAIL PROTECTED]"

Reply via email to