Start up script


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Start up script
# 1  
Old 03-09-2007
Start up script

Hello,

I have a script that starts a type of web server that I need to get to start up at startup, I would like to keep the current script in its directory and not stick it in the rc directorys. So really I want a shell script that will execute the web server script at startup. I dont really want anyone to type it out for me because where's the fun in at? If anyone could guide or link me to some sort of tutorial in would be most appreciated.

Thanks,

Mr Pink
# 2  
Old 03-09-2007
You could do something like this:
1. Create your webserver startup script to handle start and stop as arguments
2. Create a link in the rc3.d directory as S99<script_name> that points to your startup script and a link in rc0.d as S00<script_name> that points to the same script.

When the system shuts down or boots up, the links in the rc directories will invoke your script to start/stop the webserver.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

Systemd cant start my script

Hi, systemd cant start my script, but it work, at command prompt. Code and execute at command prompt #cat collector.sh #!/bin/bash case $1 in start) /home/postgres/scripts/pgwatch2/pgwatch2.sh /home/postgres/scripts/pgwatch2/pgwatch2_UI.sh ;; ... (7 Replies)
Discussion started by: kvaikla
7 Replies

2. Shell Programming and Scripting

Script to start process

Hi I want to create a script to be able to check if a process is running and act on it. Essentially I want to: Check acc process status /opt/ca/APMCommandCenterController./apmccctrl.sh status If process found not to be running Execute start command... (6 Replies)
Discussion started by: simpsa27
6 Replies

3. Shell Programming and Scripting

Start up init d script

Hi All, I'm trying to build a start up script, wud be gr8 if any one can explain what the below field means and how can i check it for my script. DAEMON_PATH="/home/wes/Development/projects/myapp" DAEMON=myapp DAEMONOPTS="-my opts" NAME=myapp DESC="My daemon description"... (4 Replies)
Discussion started by: Karthick N
4 Replies

4. Shell Programming and Scripting

Put Script on Start-up the sh Terminal

Hi all I want to put this script on start-up the sh Terminal to save history of output: if ; then logdir=$HOME/terminal-logs if ; then mkdir $logdir fi gzip -q $logdir/*.log logfile=$logdir/$(date +%F_%T).$$.log ... (12 Replies)
Discussion started by: Rahim_T
12 Replies

5. Shell Programming and Scripting

Use Webpage to Start Script

I apologize if this is in the incorrect section, I'm not quite sure which section it should go in. Anyways... I've got a script that I'd like to be able to start with a webpage, something that just has a button that says "Start this Bot", which will start the bot and put it in the background.... (4 Replies)
Discussion started by: JoeGazz84
4 Replies

6. Shell Programming and Scripting

Start program in background (or start crontab ahead of time)

Hey! I'm working on a script that will add a user, create some configfiles, and add a crontab for the user. The crontab looks like the following: @reboot /home/user/program config.conf & I would like for this process to start at the end of my script under the corresponding username by... (0 Replies)
Discussion started by: noratx
0 Replies

7. UNIX Desktop Questions & Answers

Where is xwindow start script

I am using a Mandrake spinoff (PCLinux) and would like to have a yakuake terminal started when I launch xwin. Where is the start up script? Thanks JZ (2 Replies)
Discussion started by: jwzumwalt
2 Replies

8. Shell Programming and Scripting

start a script from another tty

Hello all, im quite new to linux and was wonder if there was a way to start a script e.g. ./script1 on another tty for example im on /dev/pts/0 and i want to start a script called ./script1 on /dev/pts/1 but without actually typing directly into pts1 only into pts0 :) how would i go about... (1 Reply)
Discussion started by: moka
1 Replies

9. UNIX for Dummies Questions & Answers

Start/Stop Script

I'm a newbie to the Unix world Help! I have to maintain a host of Sybase database servers sitting on Unix Sun Solaris 8...I've been tasked with finding/creating a way to auto start/stop Unix via unix commands, specifically when the Unix servers need to be restarted we want Sybase to start... (2 Replies)
Discussion started by: jjv1
2 Replies

10. UNIX for Dummies Questions & Answers

Start Up Script

guys/gals...does anyone have a startup shell script for oracle/sybase...meaning at shutdown the databases stop themselves and at start up they start automatically...thanks much... (3 Replies)
Discussion started by: suntan
3 Replies
Login or Register to Ask a Question