When the variable "arpwatch_interfaces" is set to a list of interfaces in /etc/rc.conf and "arpwatch_enable" is set to "YES" the rc script of arpwatch should start multiple copies of arpwatch, one for each interface. But upon reboot the rc script is normally called with "faststart" (not "start") as the sole argument, which the script does not handle correctly. As a result only one copy of arpwatch is started, with no arguments. Fix: The simplest fix is to make the rc script handle "faststart" the same as "start". A patch follows. *) - if [ "$1" = "start" ]; then + if [ "$1" = "start" -o "$1" = "faststart" ]; then for interface in ${arpwatch_interfaces}; do eval options=\$arpwatch_${interface}_options command_args="-i ${interface} ${options} -f arp.${interface}.dat" Another fix is to rewrite the rc script or rewrite arpwatch so that single process monitors multiple interfaces.--1jM9vDt4oIuLW87HN9oFC3ets5cKuUO4hC8jca2Fo0o1SsTX Content-Type: text/plain; name="file.diff" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="file.diff" --- arpwatch.old Sun Aug 6 15:02:21 2006 +++ arpwatch Sun Aug 6 15:10:59 2006 @@ -63,7 +63,7 @@ ;; How-To-Repeat: Set the following in /etc/rc.conf: arpwatch_enable="YES" arpwatch_interfaces="fxp0 rl0" #a list of two or more interfaces Then reboot the machine. Alternatively try starting arpwatch with "/usr/local/etc/rc.d/arpwatch faststart" After the reboot verify that only one copy of arpwatch is running.
State Changed From-To: open->feedback Awaiting maintainers feedback
I concur with the patch, please commit. Thomas
Responsible Changed From-To: freebsd-ports-bugs->rafan Eat.
State Changed From-To: feedback->closed Committed. Thanks!