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

Re: update-rc.d usage



* Tong* wrote:

> Q: In RedHat, the chkconfig can also be used to generate a code
>    skeleton that have start/stop, etc. Can we do it in debian?

update-rc.d would be the equivalent tool.

> Q: what is the right way to specify a service that
>    only has start but no stop?

Make the script do nothing but exit 0 when given the parameter "stop".

> I just can't get it right. from the man page it is:
> 
> ,-----
> |  update-rc.d [-n] name defaults [NN | NN-start NN-stop]
> `-----
> 
> % update-rc.d local defaults 80-start

You misread the usage line. The '|' means "or", so you need to use one of
these two forms:

update-rc.d name defaults NN
update-rc.d name defaults NN-start NN-stop

Adam



Reply to: