msmtp: cannot send message: Process exited with a non-zero status
2
votes
1
answer
1331
views
I recently set up a new Pi 4 (running Buster) and installed msmtp and mailutils. I previously did this on two other Pi4s (also running Buster) on which this has worked perfectly. On the new machine it fails. I must have done something wrong, but I can't figure out what it is:
Fails:
pi@raspmountain:~ $ mail me@mac.com
Cc:
Subject: sub
body
cannot send message: Process exited with a non-zero status
Works:
pi@raspsky:~ $ mail me@mac.com
Cc:
Subject: sub
body
pi@raspsky:~ $
Here's the log entry for the one that works:
Mar 11 14:53:30 host=smtp.gmail.com tls=on auth=on user=me
from=pi@raspsky recipients=me@mac.com mailsize=132
smtpstatus=250 smtpmsg='250 2.0.0 OK 1615449210
c193sm1615010pfc.180 - gsmtp' exitcode=EX_OK
The one that fails does not result in any log entries.
On the new Pi I used the exact same configuration file as on the older Pi:
This is the one that works:
pi@raspsky:~ $ ls -la .msmtprc
-rw------- 1 pi pi 613 May 29 2020 .msmtprc
This is the one that doesn't:
pi@raspmountain:~ $ ls -la .msmtprc
-rwxr--r-- 1 pi pi 613 Feb 22 05:46 .msmtprc
Mail points to the same binary on both machines:
pi@raspmountain:~ $ ls -la /etc/alternatives/mail
lrwxrwxrwx 1 root root 23 Mar 11 13:34 /etc/alternatives/mail -> /usr/bin/mail.mailutils
pi@raspsky:~ $ ls -la /etc/alternatives/mail
lrwxrwxrwx 1 root root 23 Oct 21 2019 /etc/alternatives/mail -> /usr/bin/mail.mailutils
What have I done wrong here?
Asked by Buadhai
(257 rep)
Mar 11, 2021, 08:23 AM
Last activity: Mar 14, 2021, 01:52 PM
Last activity: Mar 14, 2021, 01:52 PM