cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Announcements
202
Views
15
Helpful
4
Replies
Highlighted

route selection criteria in a multi-process OSPF environment

This should be a straight-forward question:

 

If a router is running two different ospf processes, each process with a separate neighbor, what happens if the router receives the a Type 5 LSA for the same destination from both neighbors aka from each of the OSPF processes ?

 

How can I prefer one external route over the other, if each is received from a different process ? Using OSPF cost, or Admin distance ?

 

Thanks !

Everyone's tags (1)
1 ACCEPTED SOLUTION

Accepted Solutions
Hall of Fame Expert

Re: route selection criteria in a multi-process OSPF environment

Hello Khaled,

 

>> If a router is running two different ospf processes, each process with a separate neighbor, what happens if the router receives the a Type 5 LSA for the same destination from both neighbors aka from each of the OSPF processes ?

 

Multiple OSPF processes run separately (ships in the night concept)  and each of them attempts to install its own version of the route in the routing table.

The IP routing table daemon does not care about the type of route O, O IA , O E1 , O E2 it can only compare the admin distance and metric. The IP routing table daemon cannot compare the router-ids of the two external LSAs and the two OSPF processes do not communicate between them directly.

If the metric is the same the first = faster OSPF process will have its route installed in the routing table.

This means not deterministic results.

 

>> How can I prefer one external route over the other, if each is received from a different process ? Using OSPF cost, or Admin distance ?

As explained before to avoid competition between the two OSPF processes you should tweak the OSPF admin distance for different types of routes

The distance command in OSPF allows to specify the admin distance for intra area, inter area, external routes.

! primary process

router ospf 10

distance ospf intra-area 105 inter-area 105 external 115

! secondary process

router ospf 20

distance ospf intra-area 110 inter-area 110 external 120

 

This way you have a clear hierarchy on the OSPF processes and competition is avoided.

I used this approach in a complex migratation merging two service provider networks with good results.

 

Edit:

I verified in a recent document the behaviour is still the same as I have described.

 

>> The preference rule between a given OSPF process and any other process (be it OSPF or another routing protocol) should follow the administrative distance rule. However, because different OSPF processes will have the same administrative distance by default, OSPF distance should be configured explicitly for different OSPF processes in order to achieve the desired behavior.

see

https://www.cisco.com/c/en/us/support/docs/ip/open-shortest-path-first-ospf/4170-ospfprocesses.html

last update Jan 2018

 

 

Hope to help

Giuseppe

 

4 REPLIES 4
VIP Mentor

Re: route selection criteria in a multi-process OSPF environment

Hello,

 

if everything else is equal, the OSPF process with the highest router ID will be the one whose route is installed. That said, post tthe exact configurations you have...

Re: route selection criteria in a multi-process OSPF environment

Thank you Georg.

 

The configs are simply along the lines of:

!
interface GigabitEthernet0/1.10

description *** Link to Router XX ***
encapsulation dot1Q 10
ip address 172.16.0.1 255.255.255.252
ip ospf network point-to-point
ip ospf 1 area 0
!
interface GigabitEthernet0/1.20

description *** Link to Router YY ***
encapsulation dot1Q 20
ip address 172.16.0.5 255.255.255.252
ip ospf network point-to-point
ip ospf 2 area 0
!

So I understand from your answer that if router XX has a higher router ID than router YY, then the route received from ospf process 1 will be preferred ?

 

If this is the case, my follow up question would be: What can be used to prefer one route over the other: cost or admin distance ? Noting that both routes have the same type.

 

Thank you again.

Hall of Fame Expert

Re: route selection criteria in a multi-process OSPF environment

Hello Khaled,

 

>> If a router is running two different ospf processes, each process with a separate neighbor, what happens if the router receives the a Type 5 LSA for the same destination from both neighbors aka from each of the OSPF processes ?

 

Multiple OSPF processes run separately (ships in the night concept)  and each of them attempts to install its own version of the route in the routing table.

The IP routing table daemon does not care about the type of route O, O IA , O E1 , O E2 it can only compare the admin distance and metric. The IP routing table daemon cannot compare the router-ids of the two external LSAs and the two OSPF processes do not communicate between them directly.

If the metric is the same the first = faster OSPF process will have its route installed in the routing table.

This means not deterministic results.

 

>> How can I prefer one external route over the other, if each is received from a different process ? Using OSPF cost, or Admin distance ?

As explained before to avoid competition between the two OSPF processes you should tweak the OSPF admin distance for different types of routes

The distance command in OSPF allows to specify the admin distance for intra area, inter area, external routes.

! primary process

router ospf 10

distance ospf intra-area 105 inter-area 105 external 115

! secondary process

router ospf 20

distance ospf intra-area 110 inter-area 110 external 120

 

This way you have a clear hierarchy on the OSPF processes and competition is avoided.

I used this approach in a complex migratation merging two service provider networks with good results.

 

Edit:

I verified in a recent document the behaviour is still the same as I have described.

 

>> The preference rule between a given OSPF process and any other process (be it OSPF or another routing protocol) should follow the administrative distance rule. However, because different OSPF processes will have the same administrative distance by default, OSPF distance should be configured explicitly for different OSPF processes in order to achieve the desired behavior.

see

https://www.cisco.com/c/en/us/support/docs/ip/open-shortest-path-first-ospf/4170-ospfprocesses.html

last update Jan 2018

 

 

Hope to help

Giuseppe

 

Re: route selection criteria in a multi-process OSPF environment

Thank you Giuseppe. Very helpful indeed.

CreatePlease to create content
Content for Community-Ad
July's Community Spotlight Awards