We help IT Professionals succeed at work.

How do I force OSPF to prefer a certain route when there are active redundant, meshed routes?

Medium Priority
2,949 Views
Last Modified: 2013-11-12
I tried to connect multiple sites with redundant, meshed routes and OSPF was preferring some routes over others in what seems to be an uncontrolled fashion.  I would like to give routing preferences and only use alternative route when a circuit goes down.

For example, A-B connects over a 54Mbps wireless.  A-C connects over a 1.5Mbps MPLS.  B-C connects over a 1.5Mbps T1 via GRE/IPsec tunnel.  For some reason, OSPF tells C that the best route is to B, two hops away, not A, one hop away.

I tried to set Priority 1 on A-C at C and Priority 100 on B-C at same.  Doesn't seem to change OSPF preference.  Perhaps I'm using the wrong keyword.  Cisco 1841 routers.

Please note that this is more complicated than the above.  I have A/B, A/C, A/D, A/E, etc. and there are B/C, B/D, B/E, etc. in case A fails.  Furthermore, there are two routers at A and B, one connecting A/B only (PTP wireless) and one connecting to the Internet/MPLS with tunnels to each location, including between A/B (in case the PTP fails).

The simpliest term is that each location (C, D, etc.) have connections to A.  Some locations have two connections, a MPLS and an IPsec VPN through Internet.  All location also have an IPsec VPN through Internet to B, too.  So, that's a total of 2 (no MPLS) or 3 (with MPLS) connections per location.  I need OSPF at other locations to prefer MPLS (if applicable), IPsec to A and finally IPsec to B in that order.  No load balancing, just auto-update OSPF only when circuits/routers go down.

As for A/B, they should prefer the 54Mbps PTP route then the IPsec VPN route between themselves.

Regards,

John Babbitt
Systems Administrator
Ashland Support Group
Comment
Watch Question

Instructor
CERTIFIED EXPERT
Top Expert 2015
Commented:
The first method of controlling the path selection in OSPF is by adjusting the cost of the links.

The priority has nothing to do with how OSPF selects the path. Priority is used to determine the designated router on a multiaccess network.

The second method of controlling path selection would be to change the administrative distance for selected networks.

But try changing the link cost first.

To change the link cost, in interface config mode, use the command:

ip ospf cost <1 - 65535>

Not the solution you were looking for? Getting a personalized solution is easy.

Ask the Experts
John BabbittSystems Administrator

Author

Commented:
You're not forgotten but this has been put on the back burner until after March 16th.  Big project going on.  However, I will certainly give your solution a try and if it works, assign you the points.

Looking at my configs not too long ago, I do see ip ospf cost though it doesn't seem to work.  However, I learned that I also need to apply that to all the individual interfaces.  I'll have to sort it all out and give it a try.
Access more of Experts Exchange with a free account
Thanks for using Experts Exchange.

Create a free account to continue.

Limited access with a free account allows you to:

  • View three pieces of content (articles, solutions, posts, and videos)
  • Ask the experts questions (counted toward content limit)
  • Customize your dashboard and profile

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.