Oh, i am sorry, i was wrong, net.link.ether.inet.log_arp_wrong_iface
is for another problem.
On Tue, 18 Sep 2001, Maxim Konovalov wrote:
>
> Hello,
>
> On Tue, 18 Sep 2001, Matthew Luckie wrote:
>
> > Hi there
> >
> > At work there are several freebsd machines that route packets through a
> > "load balanced" or "redundant" router configuration.
> > The gateway's IP address actually refers to two different machines.
> > Naturally the gateway is used quite a bit, and the syslog fills up with "arp
> > X moved from Y to Z on fxp0" messages.
> >
> > I'm guessing that not many people would have this problem.
> > Below is a patch that I have found useful for these machines.
> > I'm aware that there are security considerations with this patch; by default
> > the sysctl is not activated.
>
> There *is* a sysctl for it:
>
> $ sysctl net.link.ether.inet.log_arp_wrong_iface=0
>
> > I'm not subscribed to the list, CC me on any responses please.
> >
> > Matthew
> >
> > --- if_ether.c.orig Tue Sep 18 13:56:16 2001
> > +++ if_ether.c Tue Sep 18 14:27:46 2001
> > @@ -502,6 +502,12 @@
> > &log_arp_wrong_iface, 0,
> > "log arp packets arriving on the wrong interface");
> >
> > +static int log_arp_moved = 1;
> > +
> > +SYSCTL_INT(_net_link_ether_inet, OID_AUTO, log_arp_moved, CTLFLAG_RW,
> > + &log_arp_moved, 0,
> > + "log arp moved");
> > +
> > static void
> > in_arpinput(m)
> > struct mbuf *m;
> > @@ -586,12 +592,13 @@
> > }
> > if (sdl->sdl_alen &&
> > bcmp((caddr_t)ea->arp_sha, LLADDR(sdl), sdl->sdl_alen))
> > {
> > - if (rt->rt_expire)
> > + if (rt->rt_expire) {
> > + if(log_arp_moved)
> > log(LOG_INFO, "arp: %s moved from %6D to %6D on
> > %s%d\n",
> > inet_ntoa(isaddr), (u_char *)LLADDR(sdl),
> > ":",
> > ea->arp_sha, ":",
> > ac->ac_if.if_name, ac->ac_if.if_unit);
> > - else {
> > + } else {
> > log(LOG_ERR,
> > "arp: %6D attempts to modify permanent entry
> > for %s on %s%d\n",
> > ea->arp_sha, ":", inet_ntoa(isaddr),
> >
> >
> > To Unsubscribe: send mail to [EMAIL PROTECTED]
> > with "unsubscribe freebsd-net" in the body of the message
> >
> >
>
>
--
Maxim Konovalov, MAcomnet, Internet-Intranet Dept., system engineer
phone: +7 (095) 796-9079, mailto: [EMAIL PROTECTED]
To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-net" in the body of the message