Alternative Init System

Rocco Stanzione grasshopper at linuxkungfu.org
Tue Feb 28 14:08:10 GMT 2006


This struck me as a good place to bring this thread from ubuntu-devel

On Monday 27 February 2006 01:33, Corey Burger wrote:
> If a good replacement for init existed, it would already be used. 

I have to take issue with this logic.  Replacing the init system is going to 
be a lot of work, and nobody's going to do that work when the idea isn't even 
on the radar, when arguments in favor of it haven't been heard, or when it's 
assumed that no adequate replacement exists because init hasn't already been 
replaced.  Also, a lot of individual users *are* using alternative init 
systems with very good results.  At the last place I worked, we used 
runit-run in server environments for stability, because it supervises 
services and can restart them if they fail, and we used it on workstations 
and laptops because of the dramatically reduced boot times.

> There does exist a few solutions out there, all of which are suboptimal
>
> Init-ng - Mostly a hack
> launchd = what OS X  uses. released under the APSL and thus unsuitable
> as the APSL is considered to be non-free
> http://en.wikipedia.org/wiki/Launchd
> SMF - from Solaris, unknown if it is covered under OpenSolaris. Even
> if it is, it is CDDL, which is considered to be non-free

Where to start?  This list is hardly complete.  It doesn't include the 
specific suggestion I made when I started this thread: runit-run.  "Mostly a 
hack" is not a very well thought out (or at least well-articulated) 
criticism.  I'm not familiar with init-ng but I suspect it deserves a closer 
look than this.  If the other two are infeasible due to licensing issues, 
that's fine - so is DJB's supervisor.  But someone thought supervisor a good 
enough system to be reimplemented under another license, and runit-run was 
born.

> So as you can see, there is no easy solution. Please take any further
> discussion to sounder as it is not appropriate for ubuntu-devel.

This is correct in that it's not going to be easy to replace init.  It's not 
just a matter of packaging a new init system.  Init scripts for existing 
packages will have to be rewritten.  Standards need to be created, etc.  
Developers will very likely find their machines unbootable several times 
while the kinks get worked out.  Boot-up service managers will have to be 
replaced or heavily modified.  Is it worth it?  I obviously think so, but 
it's not for me to decide.  I honestly haven't yet found it worth the effort 
to fully replace init on any of my personal systems because the primary 
benefit on a desktop machine is the dramatically lower startup times, and I 
don't reboot often enough to care too much about that.  But if the benefits 
of the work can be multiplied thousands of times as all Ubuntu users are able 
to take advantage of it, I look at it a little differently.

There is one other argument against the move, besides the amount of work 
required, that I can think of.  Users would have to relearn a thing or two 
about working with services and their processes.  `ps` doesn't give as useful 
a view as one might like of processes running under runit-run.  Tools like 
update-rc.d, invoke-rc.d, /etc/init.d/* etc. are replaced, and the new tools 
would require some education for users.  Another potential benefit, though, 
is that once you learn how to use the runit-run tools, services are actually 
easier to manage and troubleshoot.

I'll cut myself short here and see what the rest of you think about the idea.  
I won't be heartbroken if it gets shot down, but I think it's worth a hard 
look and a little discussion.

Thanks,

Rocco

ps.  OK one more thing.  Most of the ubuntu-devel thread was comprised of 
comparisons of startup times on various operating systems.  People care about 
this.  As I said when I started the original thread, it comes up several 
times a day on #ubuntu.  I've only ever seen one machine whose user had taken 
the time to fully replace sysV init with runit-run, and I witnessed 8 seconds 
from power-on to desktop, and this was on a so-so machine.  I would love to 
have this on the list of reasons to choose Ubuntu.  For those of you 
unfamiliar with the system or who need a refresher, here's a good place to 
start: http://smarden.org/runit/benefits.html



More information about the sounder mailing list