#!/sbin/runscript # Copyright 1999-2006 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: /var/cvsroot/gentoo-x86/net-analyzer/arpwatch/files/arpwatch.init,v 1.9 2006/09/08 10:44:00 pva Exp $ depend() { need net } start() { for IFACE in ${IFACES} do ebegin "Starting arpwatch on ${IFACE}" DATAFILE=/var/lib/arpwatch/${IFACE}.dat if [ ! -f ${DATAFILE} ]; then touch ${DATAFILE} fi if [ -z ${ARPUSER} ]; then setsid /usr/sbin/arpwatch -i $IFACE -f /var/lib/arpwatch/$IFACE.dat ${OPTIONS} eend $? else setsid /usr/sbin/arpwatch -i $IFACE -u ${ARPUSER} -f /var/lib/arpwatch/$IFACE.dat ${OPTIONS} eend $? fi done } stop() { ebegin "Stopping arpwatch" killall arpwatch > /dev/null eend $? }