OSPF path selection issue

Unanswered Question
Apr 18th, 2007
User Badges:


My question is if an OSPF router learns a network from two different paths. One with a higher cost but it is a intra-area route. The other one with a lower cost but it is a inter-area route. It turns out the route choose the first one with a higher cost. Is this how it supposed to be? or it should always choose the one with a lower cost regardless of the route type?



  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 4 (1 ratings)
Jon Marshall Wed, 04/18/2007 - 23:24
User Badges:
  • Super Blue, 32500 points or more
  • Hall of Fame,

    Founding Member

  • Cisco Designated VIP,

    2017 LAN, WAN

Hi Andrew

Once OSPF has selected the longest match to the specific destination address which in your case you end up with 2 matches, the Intra area route and the Inter area route, it then uses the path type in the route selection process. In order of preference

1) Intra-area

2) Inter-area

3) E1 external

4) E2 external

So yes OSPF will choose the Intra-area route over the Inter-area route.



ariela Wed, 04/18/2007 - 23:25
User Badges:
  • Silver, 250 points or more

Hi Andrew,

Intra-area OSPF routes are preferred over inter-area routes regardless of the cost.



mounir.mohamed Thu, 04/19/2007 - 00:39
User Badges:
  • Gold, 750 points or more

Dear Andrew,

The OSPF routing process shall compare between any equal costs routes with the same area type, so if you have one Intra-area route to specific destination and another Inter-area route to the same destination, Regardless the cost the router will select the Intrea-area route over the inter one, because it's logic to keep the traffic within the area instead of send it out the area,

Also the below list shown the OSPF routes checklist:

1) Intra-area (To keep the traffic internal)

2) Inter-area (Prefered over External)

3) E1 external (Over E2 because the cost to the ASBR counted)

4) E2 external

Please rate helpful posts.

Best Regards,

Mounir Mohamed


This Discussion