cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1093
Views
40
Helpful
6
Replies

OSPF Flood State

reetesh
Level 1
Level 1

Hello. I'm a bit confused about a particular concept related to OSPF. When we first initialize ospf the routers enter in the FLOOD STATE where LSAs are flooded for routers to build their LSDBs. My confusion is before flooding LSAs do routers go through the 7 states of Neighbor adjacencies??? And also the LSAs are flooded to ip multicast address 224.0.0.5. 

Grateful if someone can clarify this concept for me. 

1 Accepted Solution

Accepted Solutions

Hello,

When a router is first initialized with OSPF on its interfaces it sends out Hellos to the multicast address of 224.0.0.5.This is the INIT state.

Once it hears back from an adjacent device with its hello then they start forming a 2-way neighborship where certain parameters must match before moving on to 2-Way such as authentication,  subnet, STUB type, Hello/dead timers, etc. (Hellos must contain RID of router receiving and sending in order to start the process)

Once routers make it to 2-way some may stop here if the link is a multiaccess segment. This is where DR/BDR is elected. - this is important later

Then routers transition to Ex-Start state where the MTU is checked and primary/secondary router is chosen (not DR/BDR)

Next they move to the Exchange state - Once chosen only the primary router can transmit first. We will say its R1. R1 will send LSUs with just the LSA header info to let R2 know what its got. Once its received by R2 it will device which ones it needs and also send its LSUs to R1 so it can decide which ones it still needs. The routers send request for the LSAs (LSR - Link state request) they need and an LSU containing the full LSA is sent.

After that the loading state to finish up the exchange and run the SPT algorithm and finally the full state - (routers will only form full adjacency with the DR/BDR and send updates to the 224.0.0.6 address of DR/BDR routers)

So to answer your question its the Exchange state where the routers start exchanging LSUs that contain LSAs of their networks (Type-1 and Type-2 LSAs)/ Routers will only send updates to the DR/BDR. Then the DR is responsible for propagating that information to the other routers so they all have the same information in their LSDB in an Area and on a segment. If the segment does not have a DR/BDR election then the LSUs are just send to the multicast address. And finally if its a NBMA segment where the neighbors are manually configured it will just send the LSU to the neighbor IP address.

 

Also keep in mind LSUs are whats sent and the LSU contains 1 or more LSAs. As an example 1 LSU can contain 8 LSAs.

Hope that helps

 

-David

View solution in original post

6 Replies 6

Hello,

When a router is first initialized with OSPF on its interfaces it sends out Hellos to the multicast address of 224.0.0.5.This is the INIT state.

Once it hears back from an adjacent device with its hello then they start forming a 2-way neighborship where certain parameters must match before moving on to 2-Way such as authentication,  subnet, STUB type, Hello/dead timers, etc. (Hellos must contain RID of router receiving and sending in order to start the process)

Once routers make it to 2-way some may stop here if the link is a multiaccess segment. This is where DR/BDR is elected. - this is important later

Then routers transition to Ex-Start state where the MTU is checked and primary/secondary router is chosen (not DR/BDR)

Next they move to the Exchange state - Once chosen only the primary router can transmit first. We will say its R1. R1 will send LSUs with just the LSA header info to let R2 know what its got. Once its received by R2 it will device which ones it needs and also send its LSUs to R1 so it can decide which ones it still needs. The routers send request for the LSAs (LSR - Link state request) they need and an LSU containing the full LSA is sent.

After that the loading state to finish up the exchange and run the SPT algorithm and finally the full state - (routers will only form full adjacency with the DR/BDR and send updates to the 224.0.0.6 address of DR/BDR routers)

So to answer your question its the Exchange state where the routers start exchanging LSUs that contain LSAs of their networks (Type-1 and Type-2 LSAs)/ Routers will only send updates to the DR/BDR. Then the DR is responsible for propagating that information to the other routers so they all have the same information in their LSDB in an Area and on a segment. If the segment does not have a DR/BDR election then the LSUs are just send to the multicast address. And finally if its a NBMA segment where the neighbors are manually configured it will just send the LSU to the neighbor IP address.

 

Also keep in mind LSUs are whats sent and the LSU contains 1 or more LSAs. As an example 1 LSU can contain 8 LSAs.

Hope that helps

 

-David

Thank you so much. That was a very explicit explanation.

Glad to see David "solved" your question.

When I read it, I was somewhat confused as your mention of OSPF flooding (FLOOD STATE) might be, somehow, also referring to OSPF's periodic LSA (flood) refresh, which, of course, is somewhat different from two OSPF routers, exchanging their LSDBs during adjacency establishment.  The periodic refresh is more of a true flood, rather than a LSDB exchange.

Yeah I was going of the premise of the OP question asking "when the OSPF first initializes" it floods its LSUs during neighborship forming with the DBD. 

I never thought of the periodic refresh as being an actual flood since timers are built in so the LSUs aren't sent all at once again like in the initial DBD exchange. I guess I assume flood in context of "all at once" or "mass amount".

But then again I dont think I ever really dug deep into the actual definition of "Flood" as it relates to OSPF. I've seen a couple instances where it could mean several things. Good point!

I never thought of the periodic refresh as being an actual flood since timers are built in so the LSUs aren't sent all at once again like in the initial DBD exchange. I guess I assume flood in context of "all at once" or "mass amount".

My understanding on that, was, initially many OSPF implementations did (some still?) flood all their LSAs at the same time (for the periodic refresh).  Further, someone at Cisco, thinking about this in the RFC, thought, the RFC doesn't really call for them to actually be flooded at exactly the same time.  I.e. we can stagger out their distribution.  We just need to insure all the LSAs are refreshed every 30 minutes.  (An example, of Cisco improving something like OSPF by working within the grey areas of a RFC.)

Possibly interesting reading, where Cisco goes above and beyond RFC minimums: https://www.cisco.com/c/en/us/td/docs/ios-xml/ios/iproute_ospf/configuration/xe-16/iro-xe-16-book/iro-update.html

Thanks for the doc. I was looking as well to see what I could find. Yeah I knew the standard was every 30 minutes and as you mentioned CISCO being CISCO said well that might be a lot…let’s stagger it. I remember reading something like that. That’s where the “I didn’t consider the refresh a flood” came in as it wasn’t all at once. At least that was my interpretation.

Review Cisco Networking for a $25 gift card