Re: SNMP net-structure algorithm
Fred Baker <fbaker@acc.com> Thu, 08 April 1993 18:16 UTC
Received: from ietf.nri.reston.va.us by IETF.CNRI.Reston.VA.US id aa12791;
8 Apr 93 14:16 EDT
Received: from CNRI.RESTON.VA.US by IETF.CNRI.Reston.VA.US id aa12787;
8 Apr 93 14:16 EDT
Received: from inet-gw-2.pa.dec.com by CNRI.Reston.VA.US id aa20836;
8 Apr 93 14:16 EDT
Received: by inet-gw-2.pa.dec.com; id AA03500; Thu, 8 Apr 93 11:15:23 -0700
Received: by nsl.pa.dec.com; id AA22999; Thu, 8 Apr 93 09:38:14 -0700
Received: by nsl.pa.dec.com; id AA22995; Thu, 8 Apr 93 09:38:11 -0700
Received: by inet-gw-1.pa.dec.com; id AA22436; Thu, 8 Apr 93 09:38:08 -0700
Received: by saffron.acc.com (4.1/SMI-4.1)
id AA19719; Thu, 8 Apr 93 09:35:35 PDT
Date: Thu, 8 Apr 93 09:35:35 PDT
Sender: ietf-archive-request@IETF.CNRI.Reston.VA.US
From: Fred Baker <fbaker@acc.com>
Message-Id: <9304081635.AA19719@saffron.acc.com>
To: milde@ccmailgate.conware.de
Subject: Re: SNMP net-structure algorithm
Cc: bridge-mib@pa.dec.com, snmp@psi.com
>> I'm looking for some kind of algorithm, which allows to analyze >> the structure of a segmented LAN. The algorithm should only use the >> addressbook information of the dot1bridge-mib ( MIB-2 ). Well, here's the simplest approach I know. It has the weakness that if a MAC address ages out of its local bridge's FdbTables, the result can be indeterminate. Definition: A MAC Address (System Interface) is BETWEEN two bridges if and only if it is in the FDB of both bridges and the associated port indicates the same LAN. A useful special case of this is where one of the two bridges is the STP designated bridge on the LAN and its MAC address is the value of dot1dStpPortDesignatedBridge in the other bridge. Definition: A LEAF BRIDGE (with respect to a given port) is the designated bridge on the port in question, and no other bridge shows its MAC address on that port as dot1dStpPortDesignatedBridge Definition: A MAC Address (System Interface) is BEYOND a leaf bridge port if its MAC address is associated with that port. OK, so dividing your network up is a matter of identifying the systems that are on the LAN segments, which is to say, the ones BETWEEN certain bridges or BEYOND certain ports. The Algorithm: First, find all the bridges in the network. If they are all running RFC 1286, this SHOULD be a matter of sending out a single SNMP GET as a (one) broadcast. Second, dump all of their dot1dTpFdbTable, dot1dStpPortDesignatedBridge, ifPhysAddr, and dot1dStpPortDesignatedRoot values. Put all of the MAC Addresses in a file or table in memeory. Recursively starting with the root, and in that case setting INPORT to an unused port number: sort the MAC Address Table by dot1dTpFdbPort on this bridge FOR each value of dot1dTpFdbPort DO IF dot1dTpFdbPort == INPORT THEN these MAC addresses are BETWEEN the designated bridge and this bridge ELSE IF there is a bridge with dot1dStpPortDesignatedBridge == the address of this system THEN FOR each such bridge, call this procedure with that bridge the MAC address subset for this port INPORT = the port number on that bridge for which this is true END FOR ELSE these MAC addresses are BEYOND this port and it is a Leaf Bridge Port. END IF END FOR I hope that this helps.
- Re: SNMP net-structure algorithm Fred Baker