Post by Brian Sutherlandcat /etc/default/schooltool
# This is a configuration file for /etc/init.d/schooltool.
# Comment out the line below or change the value to something else
than "yes"
# if you don't want to start the schooltool server on system startup.
The
# init script will effectively be disabled.
SCHOOLTOOL_ENABLE="yes"
Post by Brian Sutherlandcat /etc/init.d/schooltool
#! /bin/sh
#
# Start the server.
#
set -e
package=schooltool
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
DAEMON=/usr/bin/$package
NAME=$package
DESC="SchoolTool"
PNAME=$package # truncated to 15 chars by the kernel
PIDFILE=/var/run/$package/$package.pid
SCRIPTNAME=/etc/init.d/$package
CONFIGFILE=/etc/$package/$package.conf
DEFAULTFILE=/etc/default/$package
# Gracefully exit if the package has been removed or is not configured.
test -x $DAEMON || exit 0
test -f $CONFIGFILE || exit 0
if [ -r $DEFAULTFILE ]; then
. $DEFAULTFILE
fi
. /lib/lsb/init-functions
case "$1" in
start)
# Exit if the server has been disabled in /etc/default/$package
[ "$SCHOOLTOOL_ENABLE" != "yes" ] && exit 0
# Make sure we have a /var/run sub-directory
[ -d /var/run/$package ] \
|| install --group $package --owner $package -d /var/run/
$package
log_begin_msg "Starting $DESC..."
start-stop-daemon --start --quiet --oknodo --pidfile $PIDFILE \
--chuid $package --startas $DAEMON -- -d >/dev/null \
|| log_end_msg 1
log_end_msg 0
;;
stop)
log_begin_msg "Stopping $DESC..."
start-stop-daemon --stop --quiet --oknodo --pidfile $PIDFILE \
--name $PNAME --retry 30 || log_end_msg 1
sleep 1
log_end_msg 0
;;
restart|force-reload)
# Exit if the server has been disabled in /etc/default/$package
[ "$SCHOOLTOOL_ENABLE" != "yes" ] && exit 0
# Make sure we have a /var/run sub-directory
[ -d /var/run/$package ] || mkdir -p /var/run/$package
chown $package:$package /var/run/$package
log_begin_msg "Restarting $DESC..."
start-stop-daemon --stop --quiet --oknodo --pidfile $PIDFILE \
--name $PNAME --retry 30 || log_end_msg 1
sleep 1
start-stop-daemon --start --quiet --oknodo --pidfile $PIDFILE \
--chuid $package --startas $DAEMON -- -d >/dev/null \
|| log_end_msg 1
log_end_msg 0
;;
*)
log_success_msg "Usage: $SCRIPTNAME {start|stop|restart|
force-reload}" \
exit 1
;;
esac
exit 0
lrwxrwxrwx 1 root root 20 2006-09-04 11:11 /etc/rc2.d/S20schooltool -
Post by Brian Sutherland../init.d/schooltool
runlevel
N 2
Post by Brian Sutherlandls -l /usr/bin/schooltool
-rwxr-xr-x 1 root root 386 2006-03-22 13:10 /usr/bin/schooltool
Post by Brian SutherlandJust post any output from these here.
Regards
Graham