[lug] init script that won't run stop() under F11

Michael J. Hammel mjhammel at graphics-muse.org
Tue Sep 29 16:17:36 MDT 2009


I've got an F11 init script that starts fine but never gets called when
init changes run states to one of the states marked as off for the
script.  The script's stop() works fine if run manually.  But the script
is simply never called, for example going from init 3 to init 2.

Here is the header of the script:

#!/bin/sh
#
# $Id: crunchBoot,v 1.8 2009/09/29 18:10:06 mjhammel Exp $
# Startup script for CEI Cloud Images
#
# chkconfig: 345 99 15
# description: Configure a CEI Cloud Image at boot time
#
### BEGIN INIT INFO
# Provides: crunchBoot
# Required-Start: $local_fs $network $named $remote_fs
# Required-Stop: $local_fs $network $named $remote_fs
# Defalt-Start: 3 4 5
# Default-Stop: 0 1 2 6
# Description: Configure a CEI Cloud Image at boot time
### END INIT INFO


I boot into init 3 and the script starts just fine.  But running "init
2" from the command line causes the script to be ignored completely - if
I put an echo statement at the top of the script after the header it
does not get printed.  I run the script with the stop arg to manually
stop it (in init 2) and then run init 3 manually and the script starts
up again just fine.  So this is just a shutdown problem.  Also, there
are appropriate entries under /etc/rc.d/rcX.d for the script:

[root at swlabF11 ~]# cd /etc/rc.d
[root at swlabF11 rc.d]# find . -name "*crunchBoot"
./init.d/crunchBoot
./rc0.d/K15crunchBoot
./rc2.d/K15crunchBoot
./rc3.d/S99crunchBoot
./rc6.d/K15crunchBoot
./rc1.d/K15crunchBoot
./rc5.d/S99crunchBoot
./rc4.d/S99crunchBoot

And these are proper symlinks to the file under init.d/crunchBoot.

Anyone got any ideas why the script is never getting called or some tips
on trying to figure out what is really going on here?
-- 
Michael J. Hammel                                    Principal Software Engineer
mjhammel at graphics-muse.org                           http://graphics-muse.org
------------------------------------------------------------------------------
    You will do foolish things, but do them with enthusiasm.  --  Colette




More information about the LUG mailing list