Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 20 Apr 2004 10:01:03 +0200 (CEST)
From:      Harti Brandt <novo@cs.tu-berlin.de>
To:        Bill Fumerola <billf@FreeBSD.ORG>
Cc:        net@FreeBSD.ORG
Subject:   Re: what is the story on if_index allocation ?
Message-ID:  <20040420095454.S728@130-149-145-34.dialup.cs.tu-berlin.de>
In-Reply-To: <20040419224330.GN17862@elvis.mu.org>
References:  <20040419110912.A71274@xorpc.icir.org> <Pine.BSF.4.21.0404191227150.64627-100000@InterJet.elischer.org> <20040419224330.GN17862@elvis.mu.org>

next in thread | previous in thread | raw e-mail | index | archive | help


On Mon, 19 Apr 2004, Bill Fumerola wrote:

> i disagree that this logic belongs outside the kernel in the snmp agent.
> an inconsistant if_index makes it difficult and error prone for using
> the index in multiple utilities whose data may be combined/joined/scaled
> with information from the snmp agent's IF-MIB/ifXTable tables.

The question is based on what do you decide to give an interface the same
index? Same hardware name? Same PCI slot? Same MAC address (what about
interfaces without MAC addresses and virtual interfaces)? Same IP address
(what about interfaces without IP address)?

In the bSNMP daemon currently I have two classes of interfaces: real ones
and 'dynamic' ones. For real ones I remember their name through the uptime
of the daemon and assign them the same index when they re-appear (by
loading/unloading the driver) with the same name. Actually I think that an
application (statistics or others) should look at the timestamp of the
last change of an interface and assume that the interface is another one
even if it has the same index if the timestamp changed.

harti



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