120 points · by rfmoz · 4y ago · 82 comments
Nowadays most Linux distros don't install any MTA by default. Which I think is an entirely valid choice, considering home users, laptop warriors etc. that don't run any services (for the external world) on the machine, and setting up even a simple smarthost type configuration requires putting in some config data during the installation process.
- Reads aliases from /etc/aliases like the Flying Spaghetti Monster intended.
- Limited (very limited, but good enough for smarthost type usage) spooling support. So if there's a glitch at the moment you're trying to send mail, it's not lost (as DMA doesn't run any daemons, there's a cronjob which checks the outgoing spool and tries to deliver the email).
- Actively maintained, and available in the distro archives.
I use to be a Sendmail consultant.
I've seen things you people won't believe. Open SMTP relays with zero firewall protection. I've watched people use sendmail to get root without a password. I've seen volumes of email lost in time, like bits into /dev/null. Time to patch.
UUCP with qmail and later Postfix was a great way to shove e-mail over these really unreliable connections. The g protocol worked amazingly well over these unreliable connections because it could pick up where it left off, so as long as you could get a few packets through, eventually your (sometimes large) e-mail messages could make it through, even if they had the spend the night trying.
The company kept that architecture well into the 2010s, even when we all had fairly speedy, reliable Internet connections, because it just worked really well. They eventually went to gmail years after I left.
UUCP had it's issues, but it was (and still is) one of the best was to transfer stuff over really bad connections. We worked at a place where we had really remote locations and UUCP stuff worked without much work.
Plus, I learned a ton in writing something to do reports and monitoring of the UUCP connections. Fun times, but I am still scarred Sendmail. Some wounds are pretty deep.
We did almost all sysadmin expertise in-house, but for this Sendmail, we brought in a consultant.
It was a name I recognized from Usenet, and knowingly meeting a "famous" person was pretty new to me at the time. Turns out he wasn't a Unix graybeard (closer to my young skinny nerd age), and he was working on a Neuroscience PhD, while building/fixing everyone's Sendmail setups.
I didn't know to ask him which discipline was more difficult.
1. https://www.linusakesson.net/programming/sendmail/index.php
I run to the nearest Internet cafe and discovered they're blocking SSH ports. It took quite some time to unblock it, make the changes (it took less than a minute) and pray nobody intercepted my access data and make a mess before I get back. I've never felt so ashamed about my lack of professionalism in my entire life. I literally hated myself for being forced to use a public Internet cafe to configure my server.
https://www.mit.edu/people/eichin/virus/strategies.html:
“Debugging mode has many features, including the ability to send a mail message with a program as the recipient (i.e. the program would run, with all of its input coming from the body of the message).“
I don’t know why that page follows that with “This is inappropriate” /s
Ok, I may be lying, but if the sheer mass of that book was more than sufficient to convince me to never try configuring sendmail.
Or the pain of somebody on the team routinely editing the output files without making the changes on the config files, and never knowing whether it'll work the same when you're done.
I worked in a very Make oriented place. If you need to do any processing on files, which not only includes compiling them, but also pushing them to other servers, and loading them into memory on those servers, that should be done with Make. Because Make makes things :)
Now I'd rather write a Makefile than use whatever language's builder of the week. Make can make things, why do I need anything else?
[1] - https://en.wikipedia.org/wiki/Eric_Allman [2] - https://freebsdfoundation.org/blog/foundation-elects-new-off...
I wonder if there's a name for that general sentiment, and how far back comments on that sort of thing go.
The use of sendmail in FreeBSD isn't exactly a coincidence -- it, too, was developed at Berkeley in the 70s and 80s. And it's probably unsurprising that people meet other people living and working in the same place (grad school).
The currently-supported production versions are 12.3 and 13.1. Which are scheduled to be replaced by 12.4 (Dec'22) and 13.2 (Mar'23).
Let’s respect the software of the past. It’s the past’s software that built today’s software.
Sure, email in 80s was different than in the 90s. The problem with sendmail is that it didn't get replaced when it really wasn't a good fit anymore and instead it got dragged on for extra 30 years.
Here's a nugget from Andrew Lee aka rasengan's past:
https://gauravgiri.com/for-the-record/a.bad.habit.pdf
And his future:
It's always been a horrendously difficult to configure monolith.
Worth remembering that Sendmail was, generally speaking, first. Shoulder of giants and all that.
Later email systems like Postfix and qmail in the 90s had it much easier as they operated in a much simpler ecosystem.
Now (well sometime in the future) I can remove half of my Ansible role for setting up dma on my systems, just skipping disabling sendmail.
I learned about dma here, a great blog btw! https://jpmens.net/2020/03/05/simple-solution-for-outgoing-m...
Seeing this news reminds me of an old quote (which I cannot find a direct reference to at this point):
"There is nothing in human experience when compared to setting up a sendmail config-file which can be considered hard."
Based on this move, I guess this means sendmail haven't really improved much in that regard since, and most people just avoiding it for that reason? I guess... Good riddance, then?
It taught me one important thing; that the elegance and reliability of any program is inversely proportional to the size if the configuration guide.
For more complex use cases - it's kinda obvious that they expect ~everyone to install their favorite MTA and use that.
I'd guess that sendmail is still there because they could never agree on which replacement for it was "the best".
I think local email is dumb in general though.
PS. I use uucico to automate some offline factory processes for 25+ years.
I use FreeBSD for decades and sendmail was my number one and the only choice of MTA all that time. Not only mine, but all others FreeBSD users I know too. I don't get why would something that works excellent should be changed to something that, well, is just a dummy ? I love sendmail. I think I can cook it quite well, and I don't get why I should change my habits. Not changing habits is one of the major reasons I use FreeBSD these days. Otherwise I would switch to Linux long time ago. Now FreeBSD made one more step towards its death.
If someone has prejudice against sendmail adding sendmail_enable="NONE" in rc.conf is easy.
Sendmail is not dead, but its glory days are over. 30 years ago the entire world was running on Sendmail, but this already started shifting 20 years ago, and today Sendmail operates a tiny minority of the world's email servers.
If you want to keep running Sendmail: great! Go for it! But it's just not a sensible default any more. The art of picking defaults is choosing something that will work for most people with a minimal surface for footguns. And Sendmail is clearly not it. I appreciate you don't want to "change your habits" – I usually don't want to either – but FreeBSD does not revolve around you.
Btw if you just used sendmail..always..my condolences.