OSPF Discovery

The relevant MIBs for OSPF topology are OSPF-MIB and OSPF-TRAP-MIB. In these MIBs are defined the relevant objects used to find OSPF links, specifically:

  • The Router ID which, in OSPF, has the same format as an IP address

  • But identifies the router independent of its IP address.

Also all the interfaces are identified by their IP addresses. The OSPF links come from the SNMP ospfNbrTable defined in OSPF-MIB and this table is in practice persisted in the ospfLink table:

Table 1. Supported OIDs from OSPF-MIB
Name OID Description

ospfRouterId

.1.3.6.1.2.1.14.1.1.0

A 32-bit integer uniquely identifying the router in the Autonomous System. By convention, to ensure uniqueness, this should default to the value of one of the router’s IP interface addresses. This object is persistent and when written the entity should save the change to non-volatile storage.

ospfAdminStat

.1.3.6.1.2.1.14.1.2.0

The administrative status of OSPF in the router. The value enabled denotes that the OSPF Process is active on at least one interface; disabled disables it on all interfaces. This object is persistent and when written the entity should save the change to non-volatile storage.

ospfVersionNumber

.1.3.6.1.2.1.14.1.3.0

The current version number of the OSPF protocol is 2.

ospfAreaBdrRtrStatus

.1.3.6.1.2.1.14.1.4.0

A flag to note whether this router is an Area Border Router.

ospfAreaASBdrRtrStatus

.1.3.6.1.2.1.14.1.5.0

A flag to note whether this router is configured as an Autonomous System Border Router. This object is persistent and when written the entity should save the change to non-volatile storage.

ospfIfIpAddress

.1.3.6.1.2.1.14.7.1.1

The IP address of this OSPF interface.

ospfAddressLessIf

.1.3.6.1.2.1.14.7.1.2

For the purpose of easing the instancing of addressed and addressless interfaces; this variable takes the value 0 on interfaces with IP addresses and the corresponding value of ifIndex for interfaces having no IP address.

ospfNbrIpAddr

.1.3.6.1.2.1.14.10.1.1

The IP address this neighbor is using in its IP source address. Note that, on addressless links, this will not be 0.0.0.0 but the address of another of the neighbor’s interfaces.

ospfNbrAddressLessIndex

.1.3.6.1.2.1.14.10.1.2

On an interface having an IP address, zero. On addressless interfaces, the corresponding value of ifIndex in the Internet Standard MIB. On row creation, this can be derived from the instance.

ospfNbrRtrId

.1.3.6.1.2.1.14.10.1.3

A 32-bit integer (represented as a type IpAddress) uniquely identifying the neighboring router in the Autonomous System.

Table 2. Supported OIDs from IP-MIB
Name OID Description

ipAdEntIfIndex

.1.3.6.1.2.1.4.20.1.2

The index value which uniquely identifies the interface to which this entry is applicable. The interface identified by a particular value of this index is the same interface as identified by the same value of the IF-MIB’s ifIndex.

ipAdEntNetMask

.1.3.6.1.2.1.4.20.1.3

The subnet mask associated with the IPv4 address of this entry. The value of the mask is an IPv4 address with all the network bits set to 1 and all the hosts bits set to 0.

Generic information about the OSPF link discovery process can be found in the OSPF Information box on the Node Detail Page of the device. Information gathered from these OIDs will be stored in the following database table:

ospf database
Figure 1. Database tables related to OSPF discovery