Introduction to OSPF

Hi Juan,

By default, OSPF will install up to 4 maximum paths. You can see this here:

Router#show ip protocols | begin ospf
Routing Protocol is "ospf 1"
  Outgoing update filter list for all interfaces is not set
  Incoming update filter list for all interfaces is not set
  Router ID 0.0.0.0
  Number of areas in this router is 0. 0 normal 0 stub 0 nssa
  Maximum path: 4
  Routing for Networks:
  Routing Information Sources:
    Gateway         Distance      Last Update
  Distance: (default is 110)

However, if you want to change this you can do it with the following command:

Router(config)#router ospf 1 
Router(config-router)#maximum-paths ?
  <1-32>  Number of paths

This IOS 15 router can even install up to 32 paths. I’ll edit the lesson so it shows 32 instead of 16.

Rene

1 Like

Hi,
Quick one : Is HELLO packet sent to everyone in the Area ? or only to the DR ?

Thanks

Hello Karthik

A HELLO packet is sent by an OSPF router as a unicast packet to its neighbors only. It is used to maintain the neighbor adjacency and to tell its OSPF neighbors that it is still there and active.

I hope this has been helpful!

Laz

Hi Rene,

How many router’s can be configured in a single area?

Regards,
Swapnil

Hello Swapnil

There is no hard and fast rule about the number of OSPF routers in a single area. It depends on how many subnets you have, what kind of bandwidths you have available and how complex the network topology is. Cisco does however have general rules that give you an idea of how many routers is too many.

Cisco recommends that you not more than 90-100 routers in a single OSPF area. Additionally it is Cisco’s recommendation that you not have more than 200 subnetworks per area. Again, these are general recommendations and other factors will definitely play a role in the limits involved.

It’s a good idea never to approach such numbers per area however. Having multiple areas also aids in administration as well as network design simplicity.

I hope this has been helpful!

Laz

1 Like

I was under the assumption the initial OSPF hello is a multicast packet sent to 224.0.0.5 when the router interface is no shutdown and hellos once the neighbor is formed are unicasted to the specific next hop.Is this not right ?

Hello Vijay

Thanks for the clarification, you are correct. I was thinking about virtual links. Specifically, the RFC2328 that defines OSPF (see link below) states the following:

On broadcast networks and physical point-to-point networks, Hello packets are sent every HelloInterval seconds to the IP multicast address AllSPFRouters. On virtual links, Hello packets are sent as unicasts (addressed directly to the other end of the virtual link) every HelloInterval seconds. On Point-to-MultiPoint networks, separate Hello packets are sent to each attached neighbor every HelloInterval seconds.

This was taken from the following:

Thanks again.

Laz

Hi Rene,
I think that the way OSPF calculates its cost to destination should also include cost of the exit interface to destination network: ‘Using the router on top we would have a cost of 10+8 which is 18’. I think it should be 10+8+x instead. Where ‘x’ is the cost of the very interface that the last router (extreme right) is connected directly to destination network. I’ve read this in CCNA R&S OCG ICND2 200-105 Wendel Odom fig 7-11 and table 7-6.
Do I miss something here? Thank you.
Adrian

Hello Adrian

Yes you are correct in that the total cost from a router to a particular destination includes the cost of the interface directly connected to the destination as well. In the lesson, Rene is comparing the various paths and emphasizing the differences between them so he didn’t include this cost. However, you are correct in that the cost of that interface should be included.

I’ll let Rene know so he can make the clarification.

Thanks again!

Laz

1 Like

Hi,

Can you please explain about LSA Type10 Opaque LSAs? It will be useful if you explain with a simple diagram. Why its being used for?

Regards,
Siji

Hello Siji

Type 10 LSAs are not part of any Cisco certification curriculum as far as I know, however, it is very interesting to look at, so here’s a small explanation.

LSA types 9, 10, and 11 are called opaque LSAs. They are designated for upgrades to OSPF for application specific purposes. For example, OSPF Traffic Engineering (OSPF-TE) defines extensions to OSPF that are used particularly by the Resource Reservation Protocol Traffic engineering (RSVP-TE) mechanisms employed in MPLS networks.

LSA Types 9, 10 and 11 are differentiated by the scope of their flooding. Type 9 is a link-local LSA, meaning it only goes to direct neighbors. LSA Type 10 remains within the area while LSA Type 11 goes everywhere except for stub areas.

For more info about these LSAs, you can check out RFC2370 and RFC5250.

I hope this has been helpful!

Laz

Hi chaps - quick question - what is the danger if routers within the same area use a different reference bandwidth? Thanks - Gareth.

Hello Gareth

If you have a different reference bandwidths on different OSPF routers, then the result is that one router will evaluate a specific link speed with one cost, while another will evaluate it at another cost. This may result in one router making one choice for a particular route, while the other makes the opposite choice, resulting in a loop. Another downfall is the fact that the SPF algorithm will need to be continually run because of continually conflicting information being shared between routers, and convergence may not occur.

Whenever you change the reference bandwidth in a Cisco router, you will see the following:

Router(config-router)#auto-cost reference-bandwidth 1000
% OSPF: Reference bandwidth is changed. 
        Please ensure reference bandwidth is consistent across all routers

You can find more information about the OSPF reference bandwidth at the following lesson:

I hope this has been helpful!

Laz

1 Like

Thank Laz - when a router evaluates the cost of a link - is this shared with other routers in the area or just kept locally?

Hello Gareth

As you know, OSPF is a link state routing protocol, and as such, each node within the topology creates a map of the connectivity to all the destinations of the network. When converged, each node should have an identical map. This map is constructed because each router shares information about its own networks with other OSPF routers.

Now the map is the same for all routers, but using that map, each router independently calculates the best logical path to every possible destination based on the information it has gathered from all other routers.

Now to answer your question specifically, yes OSPF routers will share the cost of their own physical links in the framework of the procedure as described above, in order for all routers to obtain a correct and valid map of the network.

I hope this has been helpful!

Laz

1 Like

Thanks Laz,

This makes sense but I am slightly confused.

I have labbed a simple topology in GNS3 where two routers share a point to point link which is announced into OSPF along with each device’s loopback address.

I’ve changed the reference bandwidth on both devices so that router A sees the shared point to point link as a cost of ‘1’ while router B sees it as ‘10.’

I can issue the 'show ip ospf database router x.x.x.x ’ command from each device which proves that the differing costs are being shared between routers.

The confusing part is that a ‘show ip route’ on each device shows the admin distance and cost from…

Router A loopback to Router B loopback as (110/2)

Router B loopback to Router A loopback as (110/11)

Shouldn’t router B also record the cost as ‘2’ in the route table?

It is seeing the cumulative cost as 11 because of it’s own calculation on the point to point link using its own reference bandwidth BUT if router A is advertising the cost for the link as the lower value of ‘1,’ should this be used instead?

Thanks,

Gareth.

Hello Gareth

The cost associated with a particular path through the network is the cumulative cost based on the bandwidth value that is stated within each interface. However, this bandwidth value is only taken into account on outgoing interfaces. This means that a path in one direction may have a different cost to that in the other direction, because the bandwidth value of the outgoing interfaces is only taken into account. That’s why the cost form Router A to B is smaller than the cost from Router B to A.

I hope this has been helpful!

Laz

Outgoing interfaces! Of course - that makes perfect sense. I guess I would have never noticed this without configuring the reference bandwidth differently on both devices so it goes to show the value of breaking things :smile: Thank you for clearing this up for me Laz - it has been bugging me for over a week now! Cheers - Gareth.

1 Like

I’ve heard it said that the DR router is responsible for the control plane of an area - does this mean it only the DR and BDR routers which run the SPF?

Hello Gareth

First of all, it’s useful to clarify that in a single OSPF area, there may be multiple DRs and BDRs. I’m not sure if this is what you meant with your wording, but just to be sure, a DR is not elected per area, but per network segment. Another way to look at it is per subnet.

Now to say that the DR and BDR is solely responsible for the control plain is not quite right, but to say that it does play a role in the control plain would probably be more correct. To get straight to the point, all OSPF routers run the SPF algorithm to find the shortest path to each destination. The only role beyond that, that the DR and BDR play is to be a central location from which LSAs can be distributed more efficiently between routers on the same segment.

I hope this has been helpful!

Laz

1 Like