LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 03-28-2005, 10:03 PM   #1
ToothlessRebel
Member
 
Registered: Jun 2004
Location: FL, USA
Distribution: Slackware 9.1
Posts: 190

Rep: Reputation: 30
How do I make a script run at boot?


How would I make a script on the machine run at boot?
 
Old 03-28-2005, 10:07 PM   #2
/bin/bash
Senior Member
 
Registered: Jul 2003
Location: Indiana
Distribution: Mandrake Slackware-current QNX4.25
Posts: 1,802

Rep: Reputation: 47
With slack you just put the script in /etc/rc.d directory and make it executable.
 
Old 03-28-2005, 10:51 PM   #3
Joey.Dale
Member
 
Registered: Jun 2003
Location: Tampa, Fl
Distribution: Gentoo, Slackware
Posts: 828

Rep: Reputation: 30
Also you could call it from rc.local:

Code:
echo "/path/to/foo.sh >> /etc/rc.d/rc.local
-Joey
 
Old 03-29-2005, 02:26 AM   #4
vimal
Red Hat India
 
Registered: Nov 2004
Location: Kerala/Pune,india
Distribution: RedHat, Fedora
Posts: 260

Rep: Reputation: 34
you just write the script and place it in /etc/rc.d/rcX.d.
the X denotes the runlevel . also give it exec: permission for root. thats all
 
Old 03-29-2005, 07:23 AM   #5
Joey.Dale
Member
 
Registered: Jun 2003
Location: Tampa, Fl
Distribution: Gentoo, Slackware
Posts: 828

Rep: Reputation: 30
Quote:
you just write the script and place it in /etc/rc.d/rcX.d.
the X denotes the runlevel . also give it exec: permission for root. thats all
Slackware uses BSD style init scripts, Redhat uses SystemV style scripts. So in slackware, the two answers before youur are correct.

-Joey
 
Old 03-29-2005, 08:44 PM   #6
ToothlessRebel
Member
 
Registered: Jun 2004
Location: FL, USA
Distribution: Slackware 9.1
Posts: 190

Original Poster
Rep: Reputation: 30
Thanks

Just a thank you.
 
Old 04-01-2005, 06:05 AM   #7
/bin/bash
Senior Member
 
Registered: Jul 2003
Location: Indiana
Distribution: Mandrake Slackware-current QNX4.25
Posts: 1,802

Rep: Reputation: 47
Here is a good explanation of the boot process for Slackware.
Slackware Linux 101
 
Old 04-15-2005, 02:26 PM   #8
gfreire
LQ Newbie
 
Registered: Apr 2005
Posts: 6

Rep: Reputation: 0
how about in Suse 9.2 i need to create a simple script that runs at boot so it can configure my wireless.
 
Old 04-27-2005, 12:30 AM   #9
ToothlessRebel
Member
 
Registered: Jun 2004
Location: FL, USA
Distribution: Slackware 9.1
Posts: 190

Original Poster
Rep: Reputation: 30
Umm, I wrote a script and placed it in /bin so that I may type "start-teamspeak" and it run the script to start a teamspeak server. However, if I add the line "start-teamspeak" to the file rc.local, it doesn't start the process at boot. What could I be doing wrong? Yes, the command works when not called by rc.local.
 
Old 04-27-2005, 01:46 AM   #10
bdox
Member
 
Registered: Feb 2005
Location: SoL iii
Distribution: Mandriva 2007
Posts: 110

Rep: Reputation: 15
try
/bin/start-teamspeak
in rc.local
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Can't make a script run hanasi Linux - Newbie 14 08-27-2005 03:14 PM
Can't get script to run on boot Ook Slackware 7 03-05-2005 01:31 AM
make hotplug run a script on detect bobbens Linux - Software 5 01-13-2005 11:42 AM
Run a script at boot, RH 7.2 dsheller Linux - Newbie 2 01-24-2004 09:12 PM
Can't get script to run on boot rickenbacherus Linux - General 5 08-21-2003 10:57 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 05:27 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration