LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   DamnSmallLinux (https://www.linuxquestions.org/questions/damnsmalllinux-42/)
-   -   running ssh on start up (https://www.linuxquestions.org/questions/damnsmalllinux-42/running-ssh-on-start-up-388142/)

simplebob 11-30-2005 11:36 PM

running ssh on start up
 
basically i need to know how to run the ssh service when DSL is starting up. i have nothing connected to the computer and i am using it as a file/web server so it would be best to get this correct the first time because it's a pain unplugging every thing from my windows box and attaching it to my linux box.

thank you in advance,

Dan...

dubya 12-01-2005 10:03 AM

I'm not sure I fully understand what you want to do. Did you want to start the ssh daemon when you boot the Linux box or Linux is already running and you want to start the ssh daemon when an internet connection is detected?

Starting the daemon is as easy as typing the following as root user:
Code:

# /etc/init.d/sshd start
I'm sorry if I misinterpreted; please clarify.

simplebob 12-01-2005 10:55 AM

yeah, when i boot my linux box i want the ssh deamon to start.

i know how to start it after it's running, but i have nothing attached to the computer other than the power supply and the network cable.

dubya 12-01-2005 11:13 AM

Usually by default, it is starting, but you can add it with the following comand:
Code:

# /sbin/chkconfig --add sshd
To check that it's been added, run:
Code:

# /sbin/chkconfig --list sshd
This will display whether the daemon is running or not at each run level.

jdogpc 12-01-2005 06:50 PM

Hi simplebob,

Just make a symbolic link from your /etc/init.d/sshd to your current runlevel that I think should be 5, so
ln -s /etc/init.d/sshd /etc/rc5.d/S55sshd

S55 before sshd means it should start in that ordinal position, so check that your network service starts before that number ( i.e. S54 or less).

to check your runlevel just type runlevel at a command prompt.


Hope this does what you want.

netcrawl 12-11-2005 01:21 PM

Just saw this thread; I happened to set this up today.

I'm using DSL 1.5 with a harddrive install on a P233, headless, to stream audio, similar to the what you describe wanting to do.

To start SSH at boot, I added the line:

/etc/init.d/ssh start

to the end of /etc/rc5.d/S99bootlocal

Works for me, hope this helps.

adssse 12-16-2005 04:39 PM

Yup, I believe it should also work if you place the line in bootlocal.sh

simplebob 12-16-2005 05:31 PM

addsse, i recall putting an entry in bootlocal.sh before for a media drive before and it worked. unfortunately i am going through a change of address, so i am going to try that when i get every thing unpacked and set up at my new place. i will let you know if it works though.

thank you to every one who replied. have a safe and happy holiday.

cheers,

Daniel McQuay

andrias 04-16-2008 04:49 PM

same problem with startup
 
same with earlier post, i've plan my dsl is running on level 3 and always run startx after boot (just the same use runlevel 5 but diferent way), any body give me suggestion to have to do ?


All times are GMT -5. The time now is 01:16 AM.