Cisco Support Community
Showing results for 
Search instead for 
Did you mean: 
New Member

ospf unequal load balancing and auto-recovery

Hi all,

My network is using OSPF, i need to do unequal load balancing in two links. Use static route or PBR it could cause the auto-recovery problem. If one of the link down it will not tune to another link automatically, i need to modify the static route or PBR setting manually. I was wondering if i could use route-map to adjust OSPF inbound route's metric, insead of deny. I tried to do that, but i found the set statement do not work. Any comment about my scenario?

Cisco Employee

Re: ospf unequal load balancing and auto-recovery

Hi Flymen,

Floating static routes and pbr can also play a role for auto recovery and if link goes down can automatically switch to another link. Can you give some more brief about your network topology.

No doubt OSPF is more scalable and fast.



New Member

Re: ospf unequal load balancing and auto-recovery

Hi Ankur and paul,

Floating static routes cannot achieve auto-recovery due to the Fastethernet interface

status cannot represent the actual link status. Could you please provide more detail about the PBR and auto-recovery?

I have ever consider use static route with Object Tracking to achieve that, but my 7513 and 6509 IOS is not supported.

What my concern is do unequal load balancing and keep auto-recovery mechanism work fine.

Re: ospf unequal load balancing and auto-recovery

Basically what you have described, the answer is use EIGRP.

I am not sure why you think floating statics can't auto recover, you just have to be imaginative. If you are doing it on a lan, it does need the next hop to be in a dedicated subnet, and does not aoturecover if the device is up, but not passing traffic. It also needs the next hop device to be directly connected.

Int fas 0/4

no switchport

ip add

ip route

That way as long as the next hop does go down, the static will disappear.

I really must advise against unequal cost load balancing and OSPF - the protocol is not designed to do that. If you need that use EIGRP. You can con OSPF into thinking costs are equal, but you really need to fully understand OSPF to do that. Conning the RP will also mean both paths get an even-ish share. There is normally a reason for the unequal cost (10M Vs 100M Vs 1G ethernet as an example), and that may mean stuffing the same traffic down each is less than wise. It also makes it more difficult at 3am sunday morning and there is a routing problem. I like simple solutions, because people don't have to call me to fix it when there is a problem.


New Member

Re: ospf unequal load balancing and auto-recovery

Hi Paul,

I agree with you that EIGRP is much suitable in my network, i will consider migrate to EIGRP.

Int fa 0/4

no switchport

ip add

ip route

In this scenario, only if the physical fa0/4 goes down, the static will disappear. Sometimes although physical fa0/4 is UP, but the circuit could be down.

Re: ospf unequal load balancing and auto-recovery

OSPF does not equal cost load balance, and as it is a link state protocol, metric adjustment is not as straightforwards.

Adjustment to make the costs even may also not be great, as the costs will be unequal for a reason - normally different size links or a longer path with more links. Making the metrics equal would result in roughly equal load on the links.

If you want to influence the way OSPF chooses links, you need to know your network well, and adjust carefully.

If you have a large network, and the two links go to different places in the network, and it happens most of your routes are out of one of the links, you can adjust the cost of the links (raise the lower one) and some routes should then be better down the other link, Tune for the load balancing you want. You may need to tune the link at both ends to influence the return traffic as well.

Direct adjustment of a metric is not a easy thing to do with OSPF.

The only RP I know that will do unequal balancing is EIGRP.

If you add more info on your topologu - how big is the network? are we in an area or the backbone? If an area what type of area? where are the routes being sourced? eg local to OSPF within the same area, redistributed from another RP, if redistributed, what metric type is in use?

CreatePlease to create content