5 ms·
I’m young enough to have missed the transition and really like systemd, I rely on it for as much as I can
by klysm 5y ago
I’m young enough to have missed the transition and really like systemd, I rely on it for as much as I can
- MuffinFlavored 5y agoLike what if you don't mind me asking, and what did people used to use as an alternative?
- dharmab 5y agoFor the init system, the most common predecessor was a combination of sysvnit and "initscripts" (a shell script for each daemon on your system). Writing the init scripts was simple for the most basic cases but quite complex for complete, bug free case coverage. A big appeal of systemd for packagers and sysadmins was the relative simplicity of unit files. Now we just have to fill out a simple boilerplate INI style file for most services.
- kzrdude 5y agoAnd less distro divergence in how to write the service scripts, or how to start services etc.
- Blikkentrekker 5y agoIt was not. There is strange false history that systemd replaced sysvinit, which occurred only on Debian, because Debian was the last major system to discard sysvinit. Gentoo had replaced sysvinit with OpenRC in 2006; Fedora and Ubuntu were using Upstart in 2005. systemd primarily replaced Upstart and systems that used Runit or OpenRC tended to have stayed with them. Frankness be, this false history seems to be crafted in order to compare it with very outdated technology to make it look good. Obviously systemd is better than sysvinit, technology that almost all systems but Debian had discarded long before systemd was even started. The issue is whether it compares favorably to Upstart, runit, and OpenRC, and to the first I would say yes, because Upstart was full of very ugly hacks and didn't deliver it's ambition. In the second two cases, their mode of operation is so different that it's hard to compare. runit was inspired by daemontools and is very simple and effective and works in a very different way from most models of service management; OpenRC is backwards compatible with sysvinit and is essentially a large library so that init scripts typically need nothing more than something such as: #!/sbin/openrc-run command=sshd args="-D" daemon=no provides=ssh after=net Or something similar to work. I forgot the exact syntax but it works similar to simply assigning some variables and it handles the rest, but it still gives one full access to the shell to use whatever shell functionality one wants.
- wruza 5y agoAnd we can excuse Debian for that, because it was an OS of choice for those who plan to run things for a decade or two. If Debian included modern web frameworks into the distro, most of them wouldn't make it into stable.
- johnny22 5y agois that 2006 number correct re: gentoo? Although i wouldn't start by comparing against openrc, but rather the previous uhmm "baselayout" init system. (sorry, i haven't used gentoo in a long time). The previous gentoo init system was already better than sysvinit and initscripts. I still prefer and use systemd though.
- Blikkentrekker 5y agoNo, it is actually incorrect, all numbers are incorrect by one year it seems. Gentoo switched in 2007, and Ubuntu and Fedora used Upstart since 2006. And why wouldn't you compare it with the systems it actually competes against and replaces rather than against something that was barely used any more before systemd even stated development? The comparison with sysvinit, suggesting that those that do not use systemd advocate sysvinit instead, is simply a flagrant straw-man designed to make systemd look good.
- awrmc 5y ago>And why wouldn't you compare it with the systems it actually competes against and replaces rather than against something that was barely used any more before systemd even stated development? I would say that's a meaningless comparison and those other systems were never considered as real replacements. At that time I don't remember OpenRC getting any traction outside of Gentoo, and the distros using Upstart were already unhappy with it. Adding to that, systemd explicitly was targeting distros that used a lot of sysvinit scripts and was intended to be used as an upgrade for them. It's largely succeeded at that.
- marcan_42 5y agoOpenRC was a C rewrite of what was previously a bunch of bash scripts, but they still implemented the same rich dependency and function-based init logic; it was miles ahead of Debian's init.d scripts before it became OpenRC. OpenRC largely made it faster, and over the years the configuration became (optionally) more declarative and gained features. The actual OpenRC transition was largely seamless for users, because the init script syntax didn't change. So the year you're looking for isn't when OpenRC was introduced, but rather when Gentoo started using the OpenRC style of init script, which happened much earlier - it's definitely been like that since I started using Gentoo, at least since 2003 or so. It's actually a misconception that sysvinit is the whole init system; sysvinit is PID 1. Gentoo still uses sysvinit for PID 1 by default. What matters is what your service manager is - that's OpenRC here.
- imwillofficial 5y ago“ It was not.” Yes it was Upstart was super short lived, and OpenRC hardly used. The vast, and I mean vast majority of distros used SysV before transitioning to SystemD
- diegocg 5y agoA bunch of very large bash scripts that were entirely different in each distro, had tons of races and were much slower to boot (one of the reasons why systemd became so popular and there was popular pressure to switch to it is that it would speed up booting by several seconds). Also upstart, which was actually pretty good, but systemd was more ambitious.
- jeltz 5y agoI agree with most of this but have to disagree about these shell scripts being slow. On Debian most of them were written for dash instead of bash and they were executed in parallell based on magic comments which defined the dependencies. It was still a mess but a mess which was fast, not as fast as systemd but fast enough for most users. Additionally Upstart was not good. It has some good ideas but its approach to dependencies was generally regarded as unintuitive. Writing services in systemd is much more obvious than writing for Upstart.
- hedora 5y agoTake a look at OpenBSD. They managed to sidestep all this drama, and still ship a sane, well-documented init. If you spend an afternoon installing it and configuring a few network services, you’ll already know most of what there is to know about how init used to work. It used to be extremely elegant and robust. The main flaw in the design was that the “service” files were written in a Turing complete language, which meant that distribution maintainers could ship things that were arbitrarily terrible, and many chose to do so. (Edit: Also, the organizations that somehow couldn’t figure out how to use and maintain traditional init systems were the ones that produced the current generation replacements and pushed them so hard.)
- morelisp 5y ago> Also, the organizations that somehow couldn’t figure out how to use and maintain traditional init systems were the ones that produced the current generation replacements and pushed them so hard. This is revisionist. The organizations that built the current generation were those who had to support those who couldn't figure out how to use and maintain "traditional" init systems. Distro init scripts were (usually, and at great effort) decent, whether from Red Hat, SuSE, Debian, etc. (just don't ask too hard about why they were different). But the third-party (often, but not exclusively, proprietary) software vendors looking to support even a single distro were godawful. Eventually the support burden for e.g. Red Hat got large enough it made more sense to replace it wholesale than keep mentoring the latest batch of e.g. Oracle interns in how to write half-decent shell scripts.