You still don't tell us what happens when you run your mail sending code outside of your daemon.
Searching the MIME::Lite code for the error message brings me to this snippet:
} else { ### parent $self->print( \*SENDMAIL ); close SENDMAIL || die "error closing $p{Sendmail}: $! (exi +t $?)\n"; $return = 1; }
... which indicates that one workaround could be to use a method other than sendmail. For example, you could attempt direct delivery. But with that, you forego all the niceties of using an MTA, like retries, bounces etc.
Another approach could be to simply paper over the problem by using eval:
my $sent_ok= eval { $mail->send; 1; }; if( my $err= $@ ) { warn "Error while sending mail: '$err'"; };
That way, your daemon will survive. Still, it remains unclear why sendmail would change behaviour in the way it appears.
In reply to Re^3: Mime::Lite Sendmail Dying
by Corion
in thread Mime::Lite Sendmail Dying
by halfbaked
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |