Re:What should we expect from a modern init system?
by akira2501 on Monday January 20, 2014 @08:40PM
(#7092859)
daemontools has the best philosophy for this in my opinion: just start the service. If the prerequisites are unavailable, the service will just terminate. If that happens, wait one second, then try start again.
It's perfect. No stupid 5 minute timeout like sysvinit, no stupid dependency management like systemd/upstart, very little to consider when adding new services.
If you want to use it as your init.. just look into 'runit-init'. I've been using this for 4+ years, and it's fantastic.
Personally, I don't want to know anything about the timing on which each device is available, to figure out manually the right order to start the services. That's the kind of job a program can and should do. I didn't like when I have to set IRQs manually too, or when X asked me about the data of the video chip that was connected to its bus.
Back to the init scripts. How do those scripts know if a daemon is still running? One mechanism is to check the existence of a file with the daemon's pid! IMO the current system is an anti-aesthetic patch. Only inertia keeps it alive.
This is what I would like to see in a linux system:
* A common config language for the basic services. Something like the defunct [elektra initiative](http://freedesktop.org/wiki/Software/Elektra/) * An automate mechanism to orderly start the system. * Something like Dan Berstein's daemontool to handle the daemons, plus the cron jobs. * For Ritchie's sake, keep logs as text files!