@@ -44,14 +44,16 @@
case "$1" in
start)
- echo -n "Starting barnyard2 "
+ echo "Starting barnyard2 "
for INT in ${INTERFACES} ; do
ARCHIVEDIR="${SNORTDIR}/${INT}/archive"
WALDO_FILE="${SNORTDIR}/${INT}/barnyard2.waldo"
+ PIDFILE="/var/run/barnyard2_${INT}.pid"
mkdir -p ${ARCHIVEDIR} `dirname ${WALDO_FILE}`
chown -R ${USER}:${GROUP} ${ARCHIVEDIR} `dirname ${WALDO_FILE}`
- BARNYARD_OPTS="-D -c ${CONF} -d ${SNORTDIR} -w ${WALDO_FILE} -a ${ARCHIVEDIR} -f ${LOG_FILE} -X ${PIDFILE} ${EXTRA_ARGS}"
- /sbin/startproc $barnyard2_BIN ${BARNYARD_OPTS}
+ BARNYARD_OPTS="-D -c ${CONF} -i ${INT} -d ${SNORTDIR} -w ${WALDO_FILE} -a ${ARCHIVEDIR} -f ${LOG_FILE} ${EXTRA_ARGS}"
+ echo -n " instance ${INT} "
+ /sbin/startproc -p /var/run/barnyard2_${INT}.pid $barnyard2_BIN ${BARNYARD_OPTS}
done
# Remember status and be verbose
rc_status -v
|