Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 10 Jun 2010 16:05:24 +0800
From:      Adrian Chadd <adrian@freebsd.org>
To:        Max Laier <max@love2party.net>
Cc:        Nick Rogers <ncrogers@gmail.com>, freebsd-hackers@freebsd.org
Subject:   Re: arp(8) performance w/ many aliases assigned to an interface
Message-ID:  <AANLkTin7sEJscNBLWi2NDEOcZ1yIvl3r-xgWBDcsoXdB@mail.gmail.com>
In-Reply-To: <201006092321.05453.max@love2party.net>
References:  <AANLkTikLZCREKNUdon_kRHtzvPkk-XbbXF9ghUuBjoGw@mail.gmail.com> <201006092321.05453.max@love2party.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On 10 June 2010 05:21, Max Laier <max@love2party.net> wrote:

>> Is there something that can be done to speedup the call to
>> if_indextoname(), or would it be worthwhile for me to submit a patch that
>> adds the ability to skip the interface lookup as an arp(8) option?
>
> how about the attached:
>

This patch only short-circuits the lookup for a specific case - lots
of entries with the same ifname. What about other situations - say,
alternating interfaces in ARP?

I read if_indextoname(). The problem is that each call is sucking down
the ifaddrs table and looking for the index. Is this likely to be a
problem in other situations, rather than just /usr/sbin/arp ?


Adrian



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?AANLkTin7sEJscNBLWi2NDEOcZ1yIvl3r-xgWBDcsoXdB>