How to disable openssh-server & my sql server from startup services?

Tom H tomh0665 at gmail.com
Mon Mar 10 22:57:01 UTC 2014


On Sun, Mar 9, 2014 at 12:49 PM, Gene Heskett <gheskett at wdtv.com> wrote:
> On Sunday 09 March 2014 12:46:58 Karl Auer did opine:
>> On Sun, 2014-03-09 at 10:40 +0100, Mauro Sanna wrote:
>>>
>>> locate the scripts in /etc/init.d and then do a chmod -x
>>
>> No, DON'T do that.
>>
>> a) the OP said quite clearly that he was using upstart-controlled
>> programs
>>
>> b) using chmod in /etc/init.d will have no effect on most
>> upstart-controlled programs
>>
>> c) for programs not controlled by upstart, you will then also be unable
>> to start the scripts manually (at least not without doing something like
>> "sudo sh /etc/init.d/progname")
>>
>> d) it's ugly. Read "man update-rc.d" instead
>
> Thank you Karl, I was not, even after all this time, aware of such a tool.
> So I read the man page. It looks a lot like chkconfig but with somewhat
> more opaque docs. I don't consider it an improvement, but I am not manning
> the tiller here either.

The reason that you haven't seen this tool before is that it's
theoretically meant for maintainer scripts in the same way that
"invoke-rc.d" is.

We, users, are supposed to use wrappers for these executables in the
same way that we're meant to use the adduser wrapper rather than
useradd.

"service" is a wrapper for "invoke-rc.d". Unfortunately "update-rc.d"
doesn't have a wrapper so you have to use it to enable/disable
sysvinit daemons.

The "update-rc.d" docs that you found opaque are most probably the
ones explaining the "start|stop" verbs and options and they're no
longer used and they're flagged as bugs when found in Debian
maintainer scripts.




More information about the ubuntu-users mailing list