Running Linux Mint 17. I have setup smartmontools to monitor my hard drive, that seems to work OK but there is a feature to generate an email when it detects an error and I cannot get the email to work. I have found several hit for it but still cannot fix it. ssmtp.conf looks like this

# Config file for sSMTP sendmail

# Where will the mail seem to come from?

# The full hostname

But when I run it I get

mick@Mint17Desk:~$ sendmail -s 'Hello world'
test mail
sendmail: Cannot open

and maillog shows

Oct  2 16:20:01 localhost CRON[4626]: (smmsp) CMD (test -x /etc/init.d/sendmail && /usr/share/sendmail/sendmail cron-msp)
Oct  2 16:20:01 localhost sSMTP[4644]: Creating SSL connection to host
Oct  2 16:20:01 localhost sSMTP[4644]: SSL connection using (null)
Oct  2 16:20:01 localhost sSMTP[4644]: Cannot open
Oct  2 16:20:01 localhost CRON[4625]: (smmsp) MAIL (mailed 1 byte of output; but got status 0x0001, #012)

I guess my setup is wrong somewhere but I cannot see where.

Recommended Answers


try to change port number to 465, it works fine for me.

Jump to Post

Great! :)

Port 465 is for SSL, 587 for TLS, in order to work with TLS you need to define the certificate through TLScert see:

Jump to Post

All 5 Replies


try to change port number to 465, it works fine for me.

commented: spot-on +14

Wow!! Yes 465 works.

I have a python program that generates mails on that same account and that works on 587, so I couldn't see why this didn't, but hey ho it works now.

Thanks for your help

OK next question, sendmail works from command line but I have set smartmon to generate a mail each time and what I get is subject -
Cron <smmsp@Mint17Desk> test -x /etc/init.d/sendmail && /usr/share/sendmail/sendmail cron-msp
message -
/usr/share/sendmail/sendmail: 899: /usr/share/sendmail/sendmail: /usr/sbin/sendmail-msp: not found

Any idea how I fix that?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.20 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.