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

Re: administration of initscripts

On Mon, Apr 15, 2013 at 05:28:02PM +0200, Erwan David wrote:
> Le 15/04/2013 16:55, Roger Leigh a écrit :
> >On Mon, Apr 15, 2013 at 08:39:27AM -0400, Stefan Monnier wrote:
> >>>I have been using Debian for many years now.  In all of that time  I
> >>>have never wanted to "manage" init scripts.  I always wonder.  What
> >>>are people trying to do?
> >>>What is more complicated than this.  If you want it then install it.
> >>>If you don't want it then remove or purge it.  With those two commands
> >>>all management is handled automatically.
> >>I don't know need/use multiple run-levels.  But I do wish it were
> >>easier/standard to disable particular services.  Uninstalling the
> >>corresponding package is not always an option (e.g. I'm thinking of the
> >>network-manager package, for example, or a daemon which you prefer to
> >>run "on demand" when a particular user logs in, ...).
> >update-rc.d foo disable|enable
> >
> >is one method.
> Which does not only work since unsing telinit to change runlevel
> after boot do not start the services enabled in the new level.

Sorry, this doesn't make sense to me.  What exactly do you want to
happen here?

This is completely independent of changing runlevels with telinit.
This enables or disables the service via the rc?.d links.  Enabling
sets the runlevels to start and stop in to the defaults.  Disabling
sets the service to stop in all runlevels.  You can still manually
start and stop the service using invoke-rc.d or service.

If you want to change the runlevel the service starts/stops in, you
can use update-rc.d for that as well.  But I've not come across a need
for altering the default runlevels (or using runlevels other than 1 and
2) at runtime in over 15 years of using Debian.  If there are any
genuinely useful use cases for them, I'd be interested to hear what
they are, since generally most people ignore them entirely.


  .''`.  Roger Leigh
 : :' :  Debian GNU/Linux    http://people.debian.org/~rleigh/
 `. `'   schroot and sbuild  http://alioth.debian.org/projects/buildd-tools
   `-    GPG Public Key      F33D 281D 470A B443 6756 147C 07B3 C8BC 4083 E800

Reply to: