[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: run levels (priority) and chkconfig --add

On Wed, 2004-10-20 at 15:05, Douglas Phillipson wrote:
> In order to add a service with chkconfig you need to add the two 
> commented lines for run level, priority and description like:
> # chkconfig: 35 30 20
> # description: Starts and stops ESRI sde service
> My question is, and I've read the man page on chkconfig, what are the 
> priorities, in this case 30 and 20.
> Are they the order in which this service is started relative to all 
> services?  Or are they the process priority to be given when the process 
> is started or stopped?  I'm leaning toward the "order" relative to all 
> services but I just wanted to make sure.  If this is the case than all 
> services should have different numbers here???  Is the highest legal 
> number 99?
> Regards
> Doug p

Yes, they are the order of starting and stopping the service relative to
other services.  When you do a chkconfig servicename on it will take the
first number (30, in your example) and create the symbolic linknames of
S30servicename.  When you do a chkconfig servicename off it will delete
the S symbolic linknames and create the K20servicename link.  These are
established in the rc?.d/ directories.  chkconfig will do it to
rc[2-5].d/ unless you specify --level as an option which will restrict
the rc?.d/ directories it manipulates.

Ultimately the /etc/rc.d/rc script is the one responsible for doing this
and executes the scripts one at a time in alphabetical order.  Since the
start scripts are of the form Snnservicename, even if two services have
the same number, it will then do them in "servicename" alphabetical



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]