Date: Fri, 25 Aug 2006 18:34:44 GMT From: Jordan Gordeev <jgordeev@dir.bg> To: freebsd-gnats-submit@FreeBSD.org Subject: ports/102509: [patch] the rc script of net-mgmt/arpwatch does not work correctly when multiple interfaces are to be monitored Message-ID: <200608251834.k7PIYi8n089675@www.freebsd.org> Resent-Message-ID: <200608251840.k7PIeOi5027505@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 102509 >Category: ports >Synopsis: [patch] the rc script of net-mgmt/arpwatch does not work correctly when multiple interfaces are to be monitored >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Fri Aug 25 18:40:24 GMT 2006 >Closed-Date: >Last-Modified: >Originator: Jordan Gordeev >Release: FreeBSD 6.1-RELEASE >Organization: >Environment: >Description: The rc script of arpwatch sets the arpwatch_interfaces variable to an empty value and then calls load_rc_config. But if _rc_conf_loaded is true when the rc script is executed, and this happens upon reboot, the value of variable arpwatch_interfaces is set by rc.conf, then it is cleared in the rc script and then the call to load_rc_config does not reload its value. The result is that if arpwatch_interfaces is set in /etc/rc.conf to a list of two or more interfaces then upon reboot, the script misbehaves and only one process is started. >How-To-Repeat: Install arpwatch, set arpwatch_enable="YES" and arwpatch_interfaces="fxp0 fxp1" in /etc/rc.conf and reboot the machine. Then check thath only one arpwatch process is running. >Fix: The following simple fix solves the problem. --- arpwatch.old Fri Aug 25 21:13:09 2006 +++ arpwatch Fri Aug 25 21:13:41 2006 @@ -12,7 +12,6 @@ # arpwatch_enable=${arpwatch_enable:-"NO"} arpwatch_dir="/usr/local/arpwatch/" -arpwatch_interfaces= . /etc/rc.subr >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200608251834.k7PIYi8n089675>