[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Bug#727708: init multiple instances of a daemon




On 22/12/13 21:03, Russ Allbery wrote:
> Daniel Pocock <daniel@pocock.com.au> writes:
> 
>> This email is not so much about the change of init system but just about
>> the multiple-instance problem, regardless of which init we use.  It is
>> not a huge hassle but it is something that could be handled more
>> smoothly.
> 
>> Some packages provide a way to start multiple instances in one shot from
>> their init script, e.g.
>> http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=433660
>> which does it in such a way that a single invocation of the init script
>> hits all instances (e.g. starting all when you may only want to start one).
> 
> This is something that I specifically looked at when evaluating the
> features of upstart and systemd (I haven't been able to find the necessary
> documentation for OpenRC), and I'm happy to report that they both have
> mechanisms for doing this.  upstart calls this "instances" and systemd
> calls this "unit templates".  Both allow you to write a single service
> configuration file that can then be started multiple times with differing
> parameters, creating independent services from the same configuration.

Just to clarify: does this mean systemd and upstart can refer to the
instances collectively or individually as required?  E.g. you can tell
it restart all instances of httpd (on dpkg upgrade) or just restart one
specific instance (after a config change)?

Will additional effort be needed so that dpkg or maintainer scripts can
request the collective restart of all instances, should this be
documented with a wishlist bug against dpkg perhaps?


Reply to: