LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
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 01-08-2004, 07:01 PM   #1
drknow
Member
 
Registered: Jan 2004
Distribution: Shrike (RH9)
Posts: 73

Rep: Reputation: 15
Running Scripts/Commands on Startup


Ok, first of all, let me apoligize for the small posting frenzy I have been on as of late. Its just that I am very new to linux, and I enjoy learning as much as possible and helping as many people as I can.

Now to my question . First I wanted to mount my ntfs partition to /mnt/windows. I got that all figured out by editing fstab. Then I thought about how useful it would be to run commands/scripts on whenever linux starts. So that is my question; How do I run commands on startup?

Thanks in advance,
Thad Blankenship
 
Old 01-08-2004, 07:39 PM   #2
Tinkster
Moderator
 
Registered: Apr 2002
Location: earth
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928Reputation: 928
That's a bit distro-dependend :)

Generally, most of them will understand
a
/etc/rc.d/rc.local
to be some sort of autoexec.bat ...
Slack does. And I think some others do, too.
SuSE used to have a slighlty differently named
file (but it's about two years since I've used
SuSE so I can't recall)...

What's your distro?


Cheers,
Tink
 
Old 01-08-2004, 07:46 PM   #3
SciYro
Senior Member
 
Registered: Oct 2003
Location: hopefully not here
Distribution: Gentoo
Posts: 2,038

Rep: Reputation: 51
look at /etc/inittab that contains a list of definitions, and general stsrtup procedure (starts gtty(or whatever login program you use), in the file youll see a list of runlvls and teh defualt one, then look for the strtup fiels name for that runlevel further down teh file itll be /etc/rc.d/rc.(whatever) , edit that new file you jsut found to add whatever prosess you want
 
Old 01-08-2004, 11:18 PM   #4
drknow
Member
 
Registered: Jan 2004
Distribution: Shrike (RH9)
Posts: 73

Original Poster
Rep: Reputation: 15
Thanks for the help....Ill try it out as soon as I can get out of this windows cage im in . By the way im using Shrike (RH9)
 
Old 01-09-2004, 05:14 AM   #5
rlange
LQ Newbie
 
Registered: Dec 2003
Location: Massachusetts USA
Distribution: Suse 9.0
Posts: 13

Rep: Reputation: 0
Quote:
Originally posted by Tinkster
That's a bit distro-dependend

Generally, most of them will understand
a
/etc/rc.d/rc.local
to be some sort of autoexec.bat ...
Slack does. And I think some others do, too.
SuSE used to have a slighlty differently named
file (but it's about two years since I've used
SuSE so I can't recall)...

What's your distro?


Cheers,
Tink
Anyone know of the file i would need to write a script to in order to enable 'unmask interupt" on Suse 9.0 personal???
 
  


Reply



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
Running scripts on startup darrenjhopkins Linux - Newbie 7 12-09-2004 04:51 AM
how to make/run startup scripts/commands ViN86 Slackware 3 04-24-2004 10:02 AM
running scripts on startup kaguru Linux - Newbie 2 01-10-2004 06:59 AM
running commands at startup tfalk3 Linux - General 4 05-27-2003 03:57 PM
Running ftp commands in scripts john lee Linux - Newbie 4 05-07-2003 12:19 AM

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

All times are GMT -5. The time now is 11:05 PM.

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
Open Source Consulting | Domain Registration