#!/sbin/sh # # Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved. # . /lib/svc/share/smf_include.sh . /lib/svc/share/ipf_include.sh PIDFILE=$SMF_SYSVOL_FS/ipmon.pid zone=`smf_zonename` if [ -f $PIDFILE ] ; then pid=`cat $PIDFILE 2>/dev/null` else pid=`pgrep -z $zone ipmon` fi case "$1" in start) /usr/sbin/ipmon -Ds ;; stop) kill -s SIGTERM $pid ;; *) echo "Usage: $0 \c" >&2 echo "(start|stop)" >&2 exit 1 ;; esac exit $SMF_EXIT_OK