PDA

View Full Version : How to start ssh or other service at boot (Debian , Ubuntu)



Fli
02-15-2016, 02:37 PM
How on Debian based Linux (ubuntu) one can make service start at boot/restart?

I found this command:

ln -s /etc/init.d/ssh /etc/rc2.d/S18ssh

It is applicable for SSH

also there is command:

update-rc.d ssh defaults

but it told me:

"update-rc.d: warning: ssh stop runlevel arguments (0 1 6) do not match LSB Default-Stop values (none)"

so i tried above mentioned command (making symbolic link) instead

gexacor
07-10-2016, 08:44 AM
You need to edit '/etc/init.d/ssh' file and check if runlevel 6 included at both start and stop values.
That means that your service will be stopped and the begin of reboot and started after reboot.

Then you need to run 'update-rc.d ssh defaults'