#!/bin/sh
# Start/stop the atm daemon(s).

test -f /usr/sbin/atmarpd || exit 0

case "$1" in
start)  echo -n "Starting ATM ARP Daemon: "
        start-stop-daemon --start --quiet --exec /usr/sbin/atmarpd -b
        /bin/sleep 2
        echo "atmarpd."
        ;;
stop)   echo -n "Stopping ATM ARP Daemon: "
        start-stop-daemon --stop --quiet --exec /usr/sbin/atmarpd
        echo "atmarpd."
        ;;
restart|force-reload) echo -n "Re-starting ATM ARP Daemon: "
        start-stop-daemon --stop --quiet --exec /usr/sbin/atmarpd
        start-stop-daemon --start --quiet --exec /usr/sbin/atmarpd -b
        /bin/sleep 2
        echo "atmarpd."
        ;;
*)      echo "Usage: /etc/init.d/atm start|stop|restart|force-reload"; exit 1
        ;;
esac
exit 0
