cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
572
Views
10
Helpful
7
Replies

OSPF adjacency

Sagar4
Level 1
Level 1

In a single area OSPF, suppose there are five routers A, B, C, D, E. Now if C and D are DR and BDR and router A is directly connected to only router B. How does router A decide that it has to form adjacency only with DR and BDR and not with other routers? Is there any command we enter to ensure adjacency is only formed with DR and BDR and not other routers or does it happen automatically on it's own like how routes are learned dynamically?

7 Replies 7

 to form adjacency only with DR and BDR <<- this need to be FULL adjacency
make sure C and D elect as DR and  BDR and automatic other router in same broadcast domain will be FULL adj with DR/BDR.
and to make sure other router not elect as DR/BDR use ip ospf priority 0 <<-
 

Hello,

I think you're misunderstanding the process (or I misunderstood what you're asking). The DR/BDR is elected per segment. By your description C and D are connected to eachother and have done the DR/BDR election (and possibly B). If A is only connected to B then A and B will run their own OSPF adjacency and elect a separate DR/BDR from C and D. A will not form and adjacency with router C or D if it has to go through router B to do it. It all needs to connect on the same subnet/multi-access segment.

If every router is connected to the same switch and a part of the same DR/BDR election then this happens automatically. A DR/BDR is elected, all routers form Full adjacency with them and 2-way with all other neighbors.

If this isnt clear could you provide a drawing or topology of how the devices are connected?

 

While I cannot image a scenario where you would implement this but if all your devices are on the same Multi-access segment and you dont want adjacencies between some devices you can configure authentication so only devices configured with the same authentication would form an adjacency. Again, no scenario would require this as it would disrupt routing and give you very skewed results.

-David

"While I cannot image a scenario where you would implement this but if all your devices are on the same Multi-access segment and you dont want adjacencies between some devices you can configure authentication so only devices configured with the same authentication would form an adjacency."

Agree, cannot think of a reason to do this, and it's an imaginative approach, but how would this work (on shared segment) if you want both A and B to have adjacency to C (DR) and D (BDR), all four having same key, but not to each other?  (BTW, when I first read this, I thought might using a passive interface setting be even easier, but it's the same problem.)

Perhaps the best we might do is set priorities on A, B and E to zero (as we both mentioned).

Yeah it was definitely a stretch and as mentioned a terrible idea. I was thinking in a roundabout way maybe it could work with Key chains but after logically thinking it through that probably wouldn't work either. 

Well having retired before using 15.4(1)T, or later, I was unaware keychains were now supported for OSPF.

So, did you have in mind something like routers A, C & D sharing a key (in their keychains) ditto B, C & D and E, C & D?

If so, would it work?  Hmm, possibly(?).

So, "terrible idea", possibly not!

"Terrible to do, possibly yes! - laugh.

Not sure how exactly the setup would look like. Yeah matching key chains to possible neighbors, but with the multi access segment and it’s rules it’s a bit different than EIGRP. That may work better (possibly). I haven’t labbed it but seeing as how that’s probably not how the OP network is setup hopefully I won’t have to.

And yes, terrible to do!

Joseph W. Doherty
Hall of Fame
Hall of Fame

"In a single area OSPF, suppose there are five routers A, B, C, D, E. Now if C and D are DR and BDR and router A is directly connected to only router B."

Than it's an invalid topology (assuming we're discussing valid DR and BDR topologies for those five routers [sharing a common network]).

All five routers must have direct adjacency to all the others.  The whole point of DR/BDR is to minimize the number of actual adjacencies needed (a full mesh).  I.e. DR forms an adjacency to all the others, ditto BDR, for backup purposes (dual hub and spoke).  If as you note, C and D are DR and BDR, A doesn't need to form an adjacency with B or E., ditto for B and E.

"How does router A decide that it has to form adjacency only with DR and BDR and not with other routers?"

When it discovers they are the DR and BDR.

"Is there any command we enter to ensure adjacency is only formed with DR and BDR and not other routers or does it happen automatically on it's own like how routes are learned dynamically?"

It's automatic although you can set router priorities for DR/BDR elections including precluding a router from ever being DR or BDR.

BTW, DR or BDR is per network, i.e. the same physical router might be zero to multiple DRs or BDRs at the same time.

Review Cisco Networking products for a $25 gift card