Somebody recently pointed me towards a blog post by a small business owner who proclaimed to the world that using Devuan (and not Debian) is better, because it's cheaper.
Hrm.
Looking at creating Devuan, which means splitting of Debian, economically, you caused approximately infinite cost.
Well, no. I'm immensely grateful to the Devuan developers, because when they announced their fork, all the complaints about systemd on the debian-devel mailinglist ceased to exist. Rather than a cost, that was an immensely gratifying experience, and it made sure that I started reading the debian-devel mailinglist again, which I had stopped for a while before that. Meanwhile, life in Debian went on as it always has.
Debian values choice. Fedora may not be about choice, but Debian is. If there are two ways of doing something, Debian will include all four. If you want to run a Linux system, and you're not sure whether to use systemd, upstart, or something else, then Debian is for you! (well, except if you want to use upstart, which is in jessie but not in stretch). Debian defaults to using systemd, but it doesn't enforce it; and while it may require a bit of manual handholding to make sure that systemd never ever ever ends up on your system, this is essentially not difficult.
you@your-machine:~$ apt install equivs; equivs-control your-sanity; $EDITOR your-sanity
Now make sure that what you get looks something like this (ignoring comments):
Section: misc
Priority: standard
Standards-Version: <whatever was there>
Package: your-sanity
Essential: yes
Conflicts: systemd-sysv
Description: Make sure this system does not install what I don't want
The packages in the Conflicts: header cannot be installed without
very difficult steps, and apt will never offer to install them.
Install it on every system where you don't want to run systemd. You're done, you'll never run systemd. Well, except if someone types the literal phrase "Yes, do as I say!", including punctuation and everything, when asked to do so. If you do that, well, you get to keep both pieces. Also, did you see my pun there? Yes, it's a bit silly, I admit it.
But before you take that step, consider this.
Four years ago, I was an outspoken opponent of systemd. It was a bad idea, I thought. It is not portable. It will cause the death of Debian GNU/kFreeBSD, and a few other things. It is difficult to understand and debug. It comes with a truckload of other things that want to replace the universe. Most of all, their developers had a pretty bad reputation of being, pardon my French, arrogant assholes.
Then, the systemd maintainers filed bug
796633, asking me to provide a systemd
unit for nbd-client
, since it provided an rcS init script (which is
really a very special case), and the compatibility support for that in
systemd was complicated and support for it would be removed from the
systemd side. Additionally, providing a systemd template unit would make
the systemd nbd experience much better, without dropping support for
other init systems (those cases can still use the init script). In order
to develop that, I needed a system to test things on. Since I usually
test things on my laptop, I installed systemd on my laptop. The intent
was to remove it afterwards. However, for various reasons, that never
happened, and I still run systemd as my pid1. Here's why:
- Systemd is much faster. Where my laptop previously took 30 to 45 seconds to boot using sysvinit, it takes less than five. In fact, it took longer for it to do the POST than it took for the system to boot from the time the kernel was loaded. I changed the grub timeout from the default of five seconds to something more reasonable, because I found that five seconds was just ridiculously long if it takes about half that for the rest of the system to boot to a login prompt afterwards.
- Systemd is much more reliable. That is, it will fail more often, but it will reliably fail. When it fails, it will tell you why it failed, so you can figure out what went wrong and fix it, making sure the system never fails again in the same fashion. The unfortunate fact of the matter is that there were many bugs in our init scripts, but they were never discovered and therefore lingered. For instance, you would not know about this race condition between two init scripts, because sysvinit is so dog slow that 99 times out of 100 it would not trigger, and therefore you don't see it. The one time you do see it, something didn't come up, but sysvinit doesn't log about such errors (it expects the init script to do so), so all you can do is go "damn, wtf happened?!?" and manually start things, allowing the bug to remain. These race conditions were much more likely to trigger with systemd, which caused it a lot of grief originally; but really, you should be thankful, because now that all these race conditions have been discovered by way of an init system that is much more verbose about such problems, they have also been fixed, and your sysvinit system is more reliable, too, as a result. There are other similar issues (dependency loops, to name one) that systemd helped fix.
- Systemd is different, and that requires some re-schooling. When I
first moved my laptop to systemd, I remember running into some kind of
issue that I couldn't figure out how to fix. No, I don't remember the
specifics of that issue, but they don't really matter. The point is
this: at first, I thought "this is horrible, you can't debug it, how
can you use such a system". And while it's true that undebuggable
systems are not very useful, the systemd maintainers know this too,
and therefore systemd is debuggable. It's just that you don't debug
it by throwing some imperative init script code through a debugger
(or, worse, something like
sh -x
), because there is no imperative init script code to throw through such a debugger, and therefore that makes little sense. Instead, there is a wealth of different tools to inspect the systemd state, and a lot of documentation on what the different things mean. It takes a while to internalize all that; and if you're not convinced that systemd is a good thing then it may mean some cursing while you're fighting your way through. But in the end, systemd is not more difficult to debug than simple init scripts -- in fact, it sometimes may be easier, because the system is easier to reason about. - While systemd comes with a truckload of extra daemons (systemd-networkd, systemd-resolved, systemd-hostnamed, etc etc etc), the systemd in their name do not imply that they are required by systemd. In fact, it's the other way around: you are required to run systemd if you want to run systemd-networkd (etc), because systemd-networkd (etc) make extensive use of the systemd infrastructure and public APIs; but nothing inside systemd requires that systemd-networkd (etc) are running. In fact, on my personal laptop, beyond systemd and udev themselves, I'm not using anything that gets built from the systemd source.
I'm not saying these reasons are universally true, and I'm not saying that you'll like systemd as much as I have. I am saying, however, that you should give it an honest attempt before you say "I'm not going to run systemd, ever," because you might be surprised by the huge gap of difference between what you expected and what you got. I know I was.
So, given all that, do I think that Devuan is a good idea? It is if you want flamewars. It gives those people who want vilify systemd a place to do that without bothering Debian with their opinion. But beyond that, if you want to run Debian and you don't want to run systemd, you can! Just make sure you choose the right options, and you're done.
All that makes me wonder why today, almost half a year after the initial release of Debian 9.0 "Stretch", Devuan Ascii still hasn't released, and why it took them over two years to release their Devuan Jessie based on Debian Jessie. But maybe that's just me.
I dispute the following somewhat:
"Debian defaults to using systemd, but it doesn't enforce it"
This may be true, but soon enough one discovers that systemd is "needed" by some package that didn't need it before. So, when installing a system that should only be running sysvinit, I now find that something (MATE probably) has pulled in systemd which is then running. What it is doing is a minor mystery, though. Pretending to be init, perhaps. After a while, people who had good reasons to stay with what they know end up having to accept the "inevitable" when they shouldn't be put in that position.
I imagine that your solution using a package conflict will just cause lots of packages to become uninstallable. And I also imagine that the appetite for changing packages to not depend on systemd is less than has been advertised, mostly because maintainers don't want the hassle of having to support things they don't use themselves. So the "choice" of multiple init systems becomes more and more superficial.
Personally, sticking with a fairly traditional init mechanism has been beneficial for making foreign architecture installations. Sadly, what worked before no longer works so well, and in the world of systemd my approach using existing Debian tools is probably seen as archaic, to be superseded by something needing its own tooling (whatever that is). These needless technology transitions mostly serve to persuade people like me not to keep bothering doing stuff.
That may not be seen as a big loss, of course, but it should at least help people understand where the Devuan people are coming from. (I could also make some remarks about how easy or otherwise it is to get into building and thus maintaining and updating Devuan, but none of the major distributions are particularly coherent about that, either.)
Speed: I run Debian Stretch with sysvinit. Shutting down my firewall and having it reboot takes less than 30 seconds from shutdown to all-interfaces-up.
Conclusion: systemd is not a requirement for speed.
Also speed: on the servers I run, POST and other pre-OS system startup bits take several minutes before any OS is loaded. If systemd cut OS boot from 60 seconds to 2 seconds, it would not be noticeable.
However, systemd is prone to going into explicit wait states where it checks for some resource to become available. As a result, systemd is unpredictably, sometimes much slower than sysvinit.
Reliability: nothing broke on the systems where I upgraded to Stretch with sysvinit. All sorts of things broke and needed to be changed on the systems where I upgraded to Stretch with systemd, so I changed them back.
My major objection to systemd is that it appears to solve all sorts of problems that happen on laptops and desktops, and only does negative or neutral things for large server deployments.
I won't bug you further about it.
I am all for their fork and all, but it is kinda pitiful that the loud, obnoxious portion of the community can barely scrape their one release together.
I am suspicious that Debian may very well depend on systems components for most modern packages, but honestly, that isn't a Debian problem.
Thanks for your hard work.
I resonate with this post, except that I was less sceptical at the start: I actually liked AIX and the whole smitty-and-utilities environment.
+1 the whole way
Thank you for this post. I agree entirely. I wasn't particularly invested in any of the options when the Great Init Debate was taking place, with regards systemd I had (and still have) some reservations about some aspects of the way the project is run. But I've been perfectly happy with systemd on my desktops and servers, and I've even managed to implement systems using it that I hadn't before.
For me, the other good thing about Devuan is it is living proof of our free software principles. Users have the right to modify the software and redistribute it; and that's exactly what Devuan are trying to do. So asides from drawing the fire (and you're right about debian-devel; sadly not debian-user) it's also a reaffirmation of our project succeeding at our goals.
@Paul, I appreciate your frustration about other packages growing dependencies on systemd. If you want to run a systemd-free machine and also use those packages, this is obviously a big problem. Unfortunately, there's not much that Debian can do about it. The decisions to start using systemd are made upstream, and patching the upstream software to either reverse those decisions, or to support both the new systemd-depending code and an alternative, is not generally practical.
It's not fair though, to characterise this situation as a "needless technology transition". Whilst it hasn't for you, systemd has solved lots of problems for lots of people, which is both why it was created in the first place, and why some upstreams are rebuilding their software around it.
I agree with this...
... but not with this, and I think it's a harmful meme. Yes, Debian values choice enough that we are willing to support a broader range of user choices than Fedora (or less able to make decisions than Fedora, if you prefer to think of it that way round), but that's just a matter of drawing the line in a different place.
Non-Linux kernels aren't release architectures, non-GNU libc isn't something we make any attempt to support, pre-i686 x86 CPUs are not something we make any attempt to support, OSS is no longer supported by Debian kernels, and so on. sysvinit is supported in jessie and stretch (but perhaps not forever, and initscripts suffers from a release-critical bug at the moment); Upstart is supported in jessie, but not stretch.
Free Software guarantees the right to modify, which provides a wealth of choices, but nobody is obliged to support the result. Choices have consequences, and a very common consequence in Free Software is "after making that choice, we are no longer willing to support you; good luck with your fork".
Paul Boddie says:
"I imagine that your solution using a package conflict will just cause lots of packages to become uninstallable."
People who complain about systemd often have very active imagination, but rarely any concrete facts.
"However, systemd is prone to going into explicit wait states where it checks for some resource to become available. As a result, systemd is unpredictably, sometimes much slower than sysvinit."
It does so because the next service is configured to depend on that resource to become available. If it starts before that point it either will break or there's a bug / unwarrantedly-conservative assumption in your unit file.
I dislike random failures – and buggy init scripts that lurk behind corners, waiting for the least convenient moment to hit me – a whole lot more than randomly waiting for whatever systemd tells me it's waiting for.
John Hughes wrote: "People who complain about systemd often have very active imagination, but rarely any concrete facts."
Thanks for the supposedly witty put-down. Maybe you missed my actual concerns, any remedies for which have been conspicuously absent, as one might expect when it is seemingly a matter of cheering for the right team or something similarly juvenile.
But apart from getting me to mess around with package dependency gymnastics, I actually do want to know whether defining deliberately-conflicting packages is supposed to help in some way or whether it was just a supposedly amusing joke about people rejecting "new technology" and having to give up lots of other stuff, which is what such people are believed to want all along.
I had Debian Wheezy on my laptop, if my memory is correct, anyway, it was the latest Debian before systemd, and it had a "makefile style" init boot-process, based on SysV init. It booted (after POST) in 3 seconds to the KDM init screen. 3seconds !!!! It was so fast it was difficult to measure.
I installed then the next Debian, with systemd, and the same laptop booted in 30 seconds !!! 10 times slower.
My current laptop which is faster takes ages to boot, and sometimes it hangs forever - it needs a hard reboot - because it waits on some dependency that doesn't come up. And no, I won't debug it, if a system is so bad that it needs me to debug it's a pile a sh**t
But all this boot time is useless discussion anyway since I reboot my computer every month, so I really don't understand what the point about systemd is. It's utter useless crap, a solution looking for a problem.
Please, pretty please, bring back the Debian "makefile style" boot process of Wheezy (or whatever that version was).
The makefile-style boot is still there. You may have some software that won't work with it though, but that's an upstream choice, not a Debian one.
If that matters so much to you, here's what you can do:
Go to the page with the overview of the systemd APIs, and reimplement them for other init systems...
Does anyone think, know, believe, imagine, systemd is an IBM rewrite of Solaris and what implications that brings to the open source ecosystem, it's connection to DOJ, anti trust, military contract(s) and the OS inter opera bility movement. sorry interoperability flags the spell check. Maybe someone will fix that one fine day. https://www.ibm.com/support/knowledgecenter/SSLTBW_2.1.0/com.ibm.zos.v2r1.bpxa400/bpxug24.htm https://www.opengroup.org/
Thanks W for this blog and sticking with Debian for so long. I still don't know where I'll go after Debian, perish the thought.