Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

sshd ---- where to place script for startup'shutdown 3

Status
Not open for further replies.

johndrake

Technical User
Jul 25, 2002
97
Hi All,

One of our people has written a script for starting
up ssh on our host. Where would I place this script so that
it gets executed when the system is started up/shutdown?

-Jow
 
Hi,

Is really useful this script ?
Does sshd not start automatically via inetd, when it receives call at ssh port ( 22? )

However you can add a line ( manually or with appropriate command ) in /etc/inittab .

Bye.
 
Hello,

Is their a startup and shutdown script that this
would be needed to put into or the inittab file handles
both?

Thank you
 
for shutdown script... you can add a file at /etc/shutdown.rc, and put it inside this file...
 
Hi,

On OS 4.3 , there are entries in inittab for different run levels i.e l2:2:wait:/etc/rc.d/rc 2
depending on what run level you are running at ( who -r)
you can have your script with start / stop depending on whether you shutdown your machine or start it up. Have a look in /etc/rc.d/samples directory and read the README.txt
basically you have one script beginning with S( and a number) to start app and K( and a number to stop the app)
this is linked to /etc/rc.d/(scriptname)

SO you can have multiple startup and shutdown scripts depending on what you are running.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top