Disable automatic starting of sshd?
12,753
Solution 1
Remove the service from startup with:
sudo update-rc.d -f sshd remove
Reset it with:
sudo update-rc.d sshd defaults
Solution 2
You could install Boot-Up Manager. It is a GUI to enable or disable services on startup.
sudo apt-get install bum
It has to be run as root user.
sudo bum
Related videos on Youtube
Author by
blong
Updated on September 18, 2022Comments
-
blong over 1 year
Possible Duplicate:
How do I disable SSH from starting automatically?Simple question here; what's the correct way to stop the sshd service from starting when the OS boots ? I'm not sure if this answer is correct, so I'm hoping some guru(s) can help me out!
What I'd like is a configuration that (after boot) allows me to start the service using
sudo service ssh start
when necessary.Version info:
me@home:~$ ssh -V OpenSSH_5.9p1 Debian-5ubuntu1, OpenSSL 1.0.1 14 Mar 2012 me@home:~$ lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 12.04.1 LTS Release: 12.04 Codename: precise
-
here over 9 yearsUseful answers at askubuntu.com/questions/19320/how-to-enable-or-disable-services
-
-
blong over 11 yearsI'm not exactly sure what you mean by remove and reset... Will I still be able to start the service manually? (i.e. with
sudo service ssh start
) ? -
blong over 11 yearsIt looks like this isn't exactly the solution I'm looking for:
me@home-computer:~$ sudo update-rc.d -f sshd remove
Removing any system startup links for /etc/init.d/sshd ...
me@home-computer:~$ sudo reboot
When my computer restarted, I was able to ssh to localhost without starting the service:me@home-computer:~$ ssh me@localhost
me@localhost's password: ***
Welcome to Ubuntu 12.04...
I'm looking for a way to simply stop the service from starting automatically. Any other thoughts? -
wojox over 11 yearsDid you try the answer you posted in your question? That is another option. Probably a good one.
-
blong over 11 yearsI didn't post an answer in my question, not sure what you mean?
-
here over 9 yearsThis does not work on ubuntu 14.04. See
upstart
and/etc/init/ssh.conf
how-to-enable-or-disable-services