Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cron fails to send email #88

Closed
SimonHeimberg opened this issue Aug 28, 2020 · 6 comments
Closed

cron fails to send email #88

SimonHeimberg opened this issue Aug 28, 2020 · 6 comments

Comments

@SimonHeimberg
Copy link

SimonHeimberg commented Aug 28, 2020

In short: Why is the recipient (last argument) not seen in sendmail -i -FCronDaemon -B8BITMIME -oem simon?

It also fails when running * (manually)* sendmail simon or dma simon. When I understand the man page correctly, this should work.
But it works as sendmail aa simon (sends to simon, ignores unknown user aa) or sendmail simon aa. Strange. All arrives to me because of *: simon in /etc/aliases. But why does it need two arguments?

longer:
Since some time (no idea since when), cron does not send emails when a job fails. In /var/log/syslog, I see the message:
Aug 26 10:10:01 myComputer CRON[17238]: (simon) MAIL (mailed 74 bytes of output but got status 0x0042 from MTA#012)
In /var/log/mail.err, I see the error message Aug 26 10:10:01 myComputer dma[c0988]: no recipients

I wrapped the call to sendmail (with a shell script) and found out how dma is called, what it gets as input and what it returns. It always fails with error 66.
The call is sendmail -i -FCronDaemon -B8BITMIME -oem simon. (This also fails when running manualy.)
Why is the last argument not seen as a recipient?

version (of debian package): 0.11-1+b1

@corecode
Copy link
Owner

does the same line work when you call dma manually from the command line? works here on the latest dma.

@SimonHeimberg
Copy link
Author

SimonHeimberg commented Aug 28, 2020

Running manually shows the same problems. Some weeks ago, cron did send emails successfully. No idea what changed on my system.

@SimonHeimberg
Copy link
Author

I reinstalled the debian package (in aptitude), and now it works again. Obvously I should have tried this before...

Thank you very much for your support.

@haarp
Copy link

haarp commented Dec 13, 2023

fwiw, I also had problems with cron sending mail to local users. Also on Debian.

CRON[13362]: (root) MAIL (mailed 58147 bytes of output but got status 0x0041 from MTA

Same here, after reinstalling the package things seem to be working. Or maybe this is related to the content of the mail? Or intermittent? Will know for sure in two weeks, when the big monthly job runs.

dma-0.13-1+b1

@haarp
Copy link

haarp commented Jan 3, 2024

Ok, had this happen again, but only ever with this one cronjob. Now I found dma: bad mail input format in another log file, so I'm pretty sure I'm running into #18.

@corecode
Copy link
Owner

corecode commented Jan 6, 2024

i wonder how sendmail deals with this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants