5
# Starts/stops DECnet processes
7
# --------------------------------------------------------------------------
10
# Provides: dnet-progs
11
# Required-Start: $network $local_fs $remote_fs
12
# Required-Stop: $network $local_fs $remote_fs
13
# Default-Start: 2 3 4 5
15
# Short-Description: Starts DECnet daemons
16
# Description: Starts dnetd (the DECnet superserver) and other
20
# Daemons to start are defined in /etc/default/decnet
22
. /lib/lsb/init-functions
24
[ -f /etc/default/decnet ] && . /etc/default/decnet
26
ADDR="`grep executor /etc/decnet.conf 2> /dev/null | cut -f2`"
28
# Don't issue any messages if DECnet is not configured as
29
# dnet-common will have taken care of those.
30
if [ ! -f /etc/decnet.conf -o ! -f /proc/net/decnet -o ! -n "$ADDR" ]
38
echo -n "Starting DECnet daemons:"
40
for i in $DNET_DAEMONS
42
if [ -f /usr/sbin/$i ]
45
eval "flags=\$${i}_FLAGS"
46
start-stop-daemon --start --quiet --exec /usr/sbin/$i -- $flags
53
echo -n "Stopping DECnet daemons:"
54
for i in $DNET_DAEMONS
57
start-stop-daemon --stop --quiet --exec /usr/sbin/$i
62
# DECnet daemons all automatically reconfigure.
67
echo -n "Restarting DECnet daemons:"
68
for i in $DNET_DAEMONS
71
eval "flags=\$${i}_FLAGS"
72
start-stop-daemon --stop --quiet --exec /usr/sbin/$i
73
start-stop-daemon --start --quiet --exec /usr/sbin/$i $flags
79
echo "Usage $0 {start|stop|restart|reload|force-reload}"