3 # Startup script for l2tpns
5 # chkconfig: 2345 83 25
8 # pidfile: /var/run/l2tpns.pid
11 # Source function library.
12 . /etc/rc.d/init.d/functions
14 if [ -f /etc/sysconfig/lt2pns ]; then
15 . /etc/sysconfig/lt2pns
18 # Path to the l2tpns-monitor script, server binary, and short-form for messages.
19 l2tpns_monitor=/usr/sbin/l2tpns-monitor
20 l2tpns=/usr/sbin/l2tpns
25 echo -n $"Starting $prog: "
26 rm -f /tmp/l2tpns.stop
27 daemon --check=$prog $l2tpns_monitor $OPTIONS
31 pid=`pidofproc $l2tpns_monitor`
32 if [ -z "$pid" ] || [ "$pid" -eq 0 ]; then
33 echo -n "Error starting $prog"
38 [ $RETVAL = 0 ] && touch /var/lock/subsys/l2tpns
42 echo -n $"Stopping $prog: "
43 echo >/tmp/l2tpns.stop
47 [ $RETVAL = 0 ] && rm -f /var/lock/subsys/l2tpns /var/run/l2tpns.pid
50 echo -n $"Reloading $prog: "
56 # See how we were called.
74 if [ -f /var/run/l2tpns.pid ] ; then
85 rm -f /tmp/l2tpns.dump
89 echo $"Usage: $prog {start|stop|restart|condrestart|reload|status|coldrestart}"