Upstart
Patrick Goetz
pgoetz at mail.utexas.edu
Fri Mar 5 20:50:09 UTC 2010
Scott James Remnant wrote:
> You might have forgotten to plug your USB
> mouse in this boot; or maybe your cat has chewed the ethernet cable
> overnight and it won't come up, etc.
>
Actually, it was my gerbil that frequently chewed through the ethernet
cable, but then the cat ate the gerbil, so that bug has been resolved,
so to speak.
> D-Bus is used to communicate with the init daemon, and one of the method
> calls you may make is to emit an event. The event name is simply a
> string, and the arguments an array of strings. There's no need to
> configure Upstart to accept certain events, you just make them up as you
> go along.
>
Thanks for the detailed response, this is all starting to make sense.
So if service Z can't start until services A,B, and C have already
started the /etc/init/Z.conf file would contain the line:
start on (A started and B started and C started)
?
And if D alternatively replaces A and C, then this becomes
start on ((A started and B started and C started) or
(B started and D started))
?
One last question. I'm curious about the technical details of how this
is implemented; i.e. what blocks Z until A,B, and C have started? Does
upstart or some process simply make a list of /\/etc\/init\/(.+)\.conf/
and then poll through the list in a loop looking to see if the 'start
on' conditions have already been met => send a startup $1 signal to
init, remove $1 from the list whenever it does?
More information about the Ubuntu-devel-discuss
mailing list