LinuxQuestions.org
Visit Jeremy's Blog.
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 08-07-2007, 10:10 PM   #1
SBN
Member
 
Registered: Jul 2006
Distribution: UBUNTU, CentOS, FEDORA 8
Posts: 474

Rep: Reputation: 30
Symbolic Links


Hey guys in the rc level i see symbolic links with S20 or K20 beside a filenames what are these....
 
Old 08-07-2007, 10:16 PM   #2
jay73
LQ Guru
 
Registered: Nov 2006
Location: Belgium
Distribution: Ubuntu 11.04, Debian testing
Posts: 5,019

Rep: Reputation: 130Reputation: 130
Start-up scripts. S tells the system to start the application in question at boot time, K (=kill) tells it to leave it alone. The numbers indicate the order in which applications are started at boot time.
 
Old 08-08-2007, 09:06 AM   #3
Paul7
Member
 
Registered: Aug 2005
Location: Thailand
Distribution: Suse 10.2 / Win XP Home
Posts: 172

Rep: Reputation: 30
Under standard unix the script is placed in the directory /etc/init,d. There is no S or K in front. The second number behind S or K means only that the timeming gets OK. For example: you cannot stop tcp before nfs. Or the opposite by starting. All the thing works by ls in shellscript. That means list sequetial
 
Old 08-08-2007, 08:33 PM   #4
SBN
Member
 
Registered: Jul 2006
Distribution: UBUNTU, CentOS, FEDORA 8
Posts: 474

Original Poster
Rep: Reputation: 30
If i want to add a script in the init.d and create links in the run levels is there a way of correctly doing it so that it will act normally and the script will load properly upon boot.
 
Old 08-09-2007, 04:34 AM   #5
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.9, Centos 7.3
Posts: 17,411

Rep: Reputation: 2397Reputation: 2397Reputation: 2397Reputation: 2397Reputation: 2397Reputation: 2397Reputation: 2397Reputation: 2397Reputation: 2397Reputation: 2397Reputation: 2397
Most of those scipts are in shell, so have a look at a few and pick one that's close to what you want, then make your own copy.
It's usually advised that you put your stuff in
/etc/rc.local
file, or the equiv for your distro. Should be that for Centos, not sure about Ubuntu.
 
Old 08-09-2007, 06:48 AM   #6
IBall
Senior Member
 
Registered: Nov 2003
Location: Perth, Western Australia
Distribution: Ubuntu, Debian, Various using VMWare
Posts: 2,088

Rep: Reputation: 62
A tip: If you want to stop a service from starting when you enter a particular run level, change the capital S to lower case S in the relevant directory.

For example, if you don't want sendmail to start when you enter run level 2:
Code:
mv /etc/rc2.d/S99sendmail /etc/rc2.d/s99sendmail
--Ian
 
  


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
symbolic links durden2.0 Linux - Newbie 6 11-12-2008 04:06 AM
cp and symbolic links? sausagejohnson Linux - General 3 07-19-2005 02:25 AM
Symbolic Links Greg_courageous Linux - Newbie 1 05-10-2004 08:05 AM
Symbolic Links petercool Linux - General 2 08-20-2003 12:15 PM
Symbolic links bkmesenbrink Linux - Newbie 2 11-13-2002 12:54 PM

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

All times are GMT -5. The time now is 06:24 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