[darcs-users] darcs vs sendmail
Trent W. Buck
trentbuck at gmail.com
Fri Mar 13 00:19:02 UTC 2009
Eric Kow <kowey at darcs.net> writes:
> Darcs send relies on your mail transfer agent (sendmail, etc). So the
> question for us darcs hackers is why does this happen? Is it something
> we can fix (darcs isn't listening to sendmail properly), or is it the
> kind of situation where the universe is broken (MTAs silently accept
> messages they can't actually send) and the only thing we can do is post
> some diagnostic steps on the FAQ?
Unfortunately, if you do a stock Debian 4.0 or 5.0 install (i.e. "keep
clicking next"), you will get a host that provides /usr/sbin/sendmail
which accepts mail and KEEPS IT. (In previous releases, you were forced
to configure the MTA at install time.)
On Ubuntu, a stock install will not have a /usr/sbin/sendmail, so you
should get an error (code 127) immediately.
Even if the MTA is correctly configured to relay mail, errors are
reported AS MAIL rather than a non-zero exit status, because there is a
queue between the MTA accepting mail and, later, relaying it. If the
delivery of the error mail is not configured correctly, then it's very
easy to miss it. For example, often the error mail will end up in
/var/mail/root instead of being forwarded to your company's central mail
The mail infrastructure in general is a "best effort" network, and that
people these days expect a message to arrive at its destination in
minutes instead of days (or perhaps not at all) just shows how lucky
they've been so far.
To my mind, there are some proactive steps that can be taken:
- They can configure (and test) a full MTA on their machine. I think
people able and willing to take this option are automatically not
the issue here.
- They can use msmtp-mta as their /usr/sbin/sendmail, with a correctly
configured ~/.msmtprc or /etc/msmtprc.
AFAIK, this is the only "dummy" sendmail implementation that will
not exit until it has either finished, or failed to, deliver the
mail. This means that if darcs sees sendmail succeed, you can be
confident that at least the first hop succeeded.
- Often people have an MTA on their desktop, but don't use it.
Instead they configure their MUA (e.g. Thunderbird) to directly send
and receive from a remote mail server.
If that is the case, their local MTA is bound to be misconfigured.
Ideally they should remove it (as Ubuntu does), and configure Darcs
to send via the MUA, e.g.
darcs send --send-command 'mutt -c %c -a %a %t'
More information about the darcs-users