OSPF Next Hop IP Address with different Network Types

OSPF will use different IP addresses for the next hop depending on the network type that you use. This can be confusing when you try to configure OSPF on top of a frame-relay network. In this short lesson I want to show you the difference between the next hop IP address and the OSPF network type that we use.

There are 5 OSPF network types:

  • Non-Broadcast
  • Broadcast
  • Point-to-Multipoint
  • Point-to-Multipoint Non-Broadcast
  • Point-to-Point

I made non-broadcast and broadcast blue because these two network types have something in common. They both require a DR/BDR election and basically you are telling OSPF that you have a multi-access network. In other words…every router can reach any other router. This can be challenging with frame-relay because this is not always the case if you have a partial-mesh or hub and spoke configuration.

Point-to-multipoint, point-to-multipoint non-broadcast and point-to-point are in red because they have one thing in common: We tell OSPF that we have a “bunch of point-to-point” links. As you will see in my demonstration the “blue” network types have a different next hop behavior as the “red” network types.

Let’s take a look at a configuration so I can demonstrate it to you:

ospf frame relay

Above you see a frame-relay hub and spoke network. We have two PVCs but there is only a single subnet so this is a frame-relay point-to-multipoint network. You can also see that router Spoke1 has network /24 behind it. We will advertise this network into OSPF and see what the next hop IP address is like. Let’s configure our routers:

Hub(config)#interface serial 0/0
Hub(config-if)#ip address
Hub(config-if)#encapsulation frame-relay 
Hub(config-if)#ip ospf network broadcast 
Hub(config)#router ospf 1
Hub(config-router)#network area 0
Spoke1(config)#interface serial 0/0
Spoke1(config-if)#ip address
Spoke1(config-if)#encapsulation frame-relay 
Spoke1(config-if)#ip ospf network broadcast 
Spoke1(config-if)#ip ospf priority 0
Spoke1(config)#router ospf 1
Spoke1(config-router)#network area 0
Spoke2(config)#interface serial 0/0
Spoke2(config-if)#ip address
Spoke2(config-if)#encapsulation frame-relay 
Spoke2(config-if)#ip ospf network broadcast 
Spoke2(config-if)#ip ospf priority 0
Spoke2(config)#router ospf 1
Spoke2(config-router)#network area 0

Above you see my configuration for the hub and spoke routers. I configured frame-relay, used the broadcast network type and made sure that the spoke routers won’t become the DR/BDR with the priority 0 command. Now let’s advertise network /24 in OSPF on router Spoke1:

Spoke1(config)#interface loopback 0
Spoke1(config-if)#ip address    
Spoke1(config)#router ospf 1
Spoke1(config-router)#network area 0

We will add a loopback interface so we can advertise the network in OSPF. Let’s check router Spoke2 to see what it looks like in the routing table:

We're Sorry, Full Content Access is for Members Only...

If you like to keep on reading, Become a Member Now! Here is why:

  • Learn any CCNA, CCNP and CCIE R&S Topic. Explained As Simple As Possible.
  • Try for Just $1. The Best Dollar You've Ever Spent on Your Cisco Career!
  • Full Access to our 655 Lessons. More Lessons Added Every Week!
  • Content created by Rene Molenaar (CCIE #41726)

535 Sign Ups in the last 30 days

100% Satisfaction Guaranteed!
You may cancel your monthly membership at any time.
No Questions Asked!


Forum Replies

  1. Excellent lesson :slight_smile:

  2. Hi Hussein,

    Routing protocols like EIGRP or RIP don’t have the broadcast and non-broadcast network types that OSPF has. By default they use multicast and if you use the neighbor command they switch to unicast traffic only, that’s it.

    The next hop will be the Hub router though, you can see see an example here:

    ... Continue reading in our forum

  3. Good Day Rene,

    Thank You again for Brilliant explanation. Now I have a challenge to on my lab environment to configure the switch which will connect between HUB and Spoke1 and 2 as frame relay. is it possible to get clarification on that step by step with picture example if possible.

    Thank You again.

  4. Hi Rene,

    This is by the far the most explanation for CCNP.
    My question is why do we have to elect DR/BDR on Non Broadcast network? I thought DR/BDR are only needed on broadcast networks?

12 more replies! Ask a question or join the discussion by visiting our Community Forum