systemd's unique benefits (if any)
systemd's unique benefits (if any)
Posted Oct 16, 2014 18:44 UTC (Thu) by ksandstr (guest, #60862)In reply to: systemd's unique benefits (if any) by anselm
Parent article: On the sickness of our community
>The init script may return without an error but you still can't be sure that the service was in fact started successfully.
Not from any indication of the script itself, no. However a quick `pidof` and a check of the PID file dropped by start-stop-daemon (or the service process itself) should reveal whether the process is up or not, which is all that systemd's "hey I'm up" library call does. (As implementation goes, meta-data to provide for such a function could easily be carried in init.d scripts, just as dependency information is.)
That's to say, the guarantee of service up-ness provided by a process' continued presence is a slim one given failure cases besides the ones that cause a process to disappear outright. For example in a network server that spawns child processes to handle client connections there may be a systemic failure that prevents client interactions altogether but not startup of the parent. Failures in this spectrum will not be thoroughly revealed by any mechanism short of per-application querying to the full breadth of its functionality.
So I'm not counting this as unique to systemd's architecture, nor as a (r/)evolutionarily useful feature.
>Then there is that thing where systemd manages to figure out many if not most dependencies between services by itself, where sysvinit relies completely on error-prone explicit dependencies that a distribution maintainer needs to put in by hand.
This only exchanges one category of failure (insufficient maintainer diligence) for another (software-induced lossage). I'd tend to prefer the former since the correctness of the latter should ideally be proven for all possible sets of dependencies whereas the former need only be correct for one initscript at a time.
Furthermore I'm suspicious that systemd's mechanism won't cover all possible dependencies between initscripts, leading to a situation where there's a (potentially crusty, brittle, and/or legacy-saddled) magic algorithm, a set of hand-crafted dependencies, and a policy for combining the two into something that the startup function can actually execute. If nothing else this conflicts with the ideal of parsimony in design; especially since the dependency list could be generated ahead of time (e.g. by the package maintainer) with a tool that's equivalent to systemd's magic, and then stored in place of existing metadata.
Compared to the lossage that systemd's growth of accessory dependencies and their expansion is causing, it's still my opinion that Debian's switch to systemd and packages depending on it is a grand mistake.
