I have a NAS4Free machine which used to be able to automatically send me emails, like when the system booted, the UPS failed, etc. That feature hasn't been working for me since sometime in the version 10 range, if not longer. How can I fix it?
I'm running version 11.0.0.4 - Sayyadina (revision 3330), 64-bit embedded.
Here are my email settings as shown in the webui, at System > Advanced > Email Setup:
From Email Address: abc123@gmail.com
To Email Address: abc123@gmail.com
SMTP Server: smtp.gmail.com
Port: 465
Security: TLS
TLS Mode: NOT checked
TLS Server Certificate Check: Off
Authentication: CHECKED (enable SMTP auth)
Username: abc123@gmail.com
Password: *******
Authentication Method: Best available
I'm using an app password since I have 2-factor authentication enabled on my Gmail account.
When I click Send Test Email, it shows an error message at the top in red, Failed to send test email. Please check the log files.
Clicking the link, I find Diagnostics > Log shows:
root: msmtp service executed
msmtp: host=smtp.gmail.com tls=on auth=on user=abc123@gmail.com from=abc123@gmail.com recipients=abc123@gmail.com errormsg='cannot read from TLS connection: a protocol violating EOF occured' exitcode=EX_IOERR
root: Failed to send test email to: abc123@gmail.com.
From this I gather that the configuration for msmtp is the problem. However, when I boot from a NAS4Free LiveCD, and configure the email with the same settings through the UI, it works fine.