Building network automation solutions

9 module online course

Start now!

OSPF Challenge #2: Final results

I’ve received almost a dozen responses to the second OSPF challenge, most of them correct. The key to the solution is the way OSPF checks neighbor’s IP address on point-to-point links (we already know that the subnet mask is ignored):

  • If the interface is unnumbered, the router ignores the source IP address in the OSPF hello packets.
  • If there’s an IP address configured on the interface, the router checks that the neighbor’s IP address (the source IP address in the OSPF hello packets) belongs to the same subnet. If the source IP address is not in the same subnet, the OSPF hello packet is ignored.

R1 and R2 (the router configuration can be found in the challenge) would establish adjacency only if the source IP address of the packets sent by R1 would be in the same subnet as the IP address on R2. Since the serial interface on R1 is unnumbered, R1 would use the IP address of the loopback interface in the OSPF hello packets. IP address of the loopback interface on R1 thus has to be in the subnet, giving you five choices (you cannot use the, and

However, as Yuri pointed out in his response, the routers do establish adjacency (so the challenge is solved) but do not build valid routing tables. The reason is the weird IP address used in the Link Data field of each unnumbered point-to-point link. According to RFC 2328, the router should use the MIB-II ifIndex as the IP address of an unnumbered interface. IOS performs subnet checks on SPF tree as well as on the OSPF hello packets and therefore R2 declares that R1 is not reachable. The following printout shows the R1’s router LSA as seen on R2:

R2#show ip ospf data router

OSPF Router with ID ( (Process ID 1)

Router Link States (Area 1)

Adv Router is not-reachable
LS age: 758
Options: (No TOS-capability, DC)
LS Type: Router Links
Link State ID:
Advertising Router:
LS Seq Number: 80000016
Checksum: 0x296B
Length: 48
Number of Links: 2

Link connected to: a Stub Network
(Link ID) Network/subnet number:
(Link Data) Network Mask:
Number of TOS metrics: 0
TOS 0 Metrics: 1

Link connected to: another Router (point-to-point)
(Link ID) Neighboring Router ID:
(Link Data) Router Interface address:
Number of TOS metrics: 0
TOS 0 Metrics: 64

All readers that sent me a correct response received a small award from our Remote Labs team: free access to the OSPF default mysteries e-lesson which includes a recorded presentation and three remote lab exercises.


  1. how many versions of OSPF has been release so for

    Tahir Saleem
  2. OSPF v3 is the latest one
    OSPF v2 is for ipv4
    OSPF v3 is for ipv6
Add comment