From owner-freebsd-net@FreeBSD.ORG Thu Jul 24 23:42:56 2008 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 082851065673 for ; Thu, 24 Jul 2008 23:42:56 +0000 (UTC) (envelope-from babolo@cicuta.babolo.ru) Received: from ints.mail.pike.ru (ints.mail.pike.ru [85.30.199.194]) by mx1.freebsd.org (Postfix) with ESMTP id 346A28FC1E for ; Thu, 24 Jul 2008 23:42:54 +0000 (UTC) (envelope-from babolo@cicuta.babolo.ru) Received: (qmail 27079 invoked from network); 24 Jul 2008 23:42:53 -0000 Received: from cicuta.babolo.ru (85.30.229.5) by ints.mail.pike.ru with SMTP; 24 Jul 2008 23:42:53 -0000 Received: (nullmailer pid 32649 invoked by uid 136); Thu, 24 Jul 2008 23:42:49 -0000 X-ELM-OSV: (Our standard violations) hdr-charset=KOI8-R; no-hdr-encoding=1 In-Reply-To: <48874C7C.5070402@samoylyk.sumy.ua> To: Oleksandr Samoylyk Date: Fri, 25 Jul 2008 03:42:49 +0400 (MSD) From: .@babolo.ru X-Mailer: ELM [version 2.4ME+ PL99b (25)] MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=US-ASCII Message-Id: <1216942969.767893.32648.nullmailer@cicuta.babolo.ru> Cc: freebsd-net@freebsd.org, damien.deville@netasq.com Subject: Re: proxy-arp & mpd X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jul 2008 23:42:56 -0000 [ Charset KOI8-U unsupported, converting... ] > Damien Deville wrote: > > Hi, > > > > we are facing a similar issue with arp blocked in sbwait state. > > > > Here is a way to reproduce it: > > - add a bunch of arp entries in your arp table (best is around 255 > > entries). > > - launch two arp -a -d in parallel ('arp -a -d & arp -a -d &') > > > > Both processes will be in concurence to access the table. One process > > will successfully nuke all entries of the arp table, the other one will > > be blocked in rtmsg function on the read while executing a RTM_GET or > > RTM_DELETE command after some time. By instrumenting arp we noticed that > > it happened when both process access to the same entry. > > > > Here is a backtrace of the blocked arp on FreeBSD 7.0 > > > > (gdb) bt > > #0 0x28158f81 in read () from /lib/libc.so.7 > > #1 0x08049091 in rtmsg () > > #2 0x08049b44 in delete () > > #3 0x0804a1fd in nuke_entry () > > #4 0x08049a77 in search () > > #5 0x08049e75 in main () > > > > I can reproduce this on FreeBSD 4.11, 6.2 and 6.3, and FreeBSD 7.0. > > Any workaround so far? Another dirty hack http://free.babolo.ru/patch/src.usr.sbin.arp.patch (for FreeBSD 4) http://free.babolo.ru/patch6/src.usr.sbin.arp.patch (for FreeBSD 6) http://free.babolo.ru/patch7/src.usr.sbin.arp.patch (for FreeBSD 7)