Showing results for 
Search instead for 
Did you mean: 

OSPF equal cost load balancing not working?

Dear all,

I tried to setup an equal cost load balancing with OSPF (yes I know with EIGRP it can be easier but my environment uses multi vendor setup therefore EIGRP can't be used) but it doesn't seem to work.


So let's say my Cisco router (R1) connected to R2 and R4 through OSPF, and I want to reach the network behind R3, or in this case its loopback address. All network are in area 0. I'm expecting that in this setup I can have the traffic from R1 loopback ( to R3 loopback ( to be load balanced between R2 and R4, but what I got instead is only an asymmetric routing. See the details below:



OSPF config on R1:

R1#sh run | s router
router ospf 1
network area 0
network area 0
network area 0


all the show command from R1:

R1#sh ip route
Routing entry for
Known via "ospf 1", distance 110, metric 3, type intra area
Last update from on FastEthernet0/0, 00:39:41 ago
Routing Descriptor Blocks:
*, from, 00:39:41 ago, via FastEthernet0/1
Route metric is 3, traffic share count is 1, from, 00:39:41 ago, via FastEthernet0/0
Route metric is 3, traffic share count is 1
R1#sh ip ospf database

OSPF Router with ID ( (Process ID 1)

Router Link States (Area 0)

Link ID ADV Router Age Seq# Checksum Link count 415 0x80000004 0x005C0E 3 212 0x80000004 0x0089AF 3 177 0x80000004 0x00AD23 3 200 0x80000003 0x00CC1A 3

Net Link States (Area 0)

Link ID ADV Router Age Seq# Checksum 212 0x80000002 0x002CD4 200 0x80000002 0x00F1F8 177 0x80000002 0x005A83 200 0x80000002 0x008832
R1#show ip ospf nei

Neighbor ID Pri State Dead Time Address Interface 1 FULL/DR 00:00:36 FastEthernet0/1 1 FULL/DR 00:00:33 FastEthernet0/0


Ping from loopback R1 to R3

R1#ping sour
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to, timeout is 2 seconds:
Packet sent with a source address of
Success rate is 100 percent (5/5), round-trip min/avg/max = 32/48/84 ms


Packet capture on R3 interface facing R2

R3 facing R2.png


Capture from R3 interface facing to R4

R3 facing R4.png


So it looks like the echo request goes through R1-R4-R3 then the reply goes through R3-R2-R1. From what I see it looks more like asymmetric routing instead of load-balancing.


Please advise why I am not getting the result as expected.



Meheretab Mengistu
Rising star


Please share the output of the following commands: sh ip route ospf, traceroute source probes 2, and traceroute source probes 2.





Hi Meheretab, thanks for coming by... here's the output as requested:


R1#sh ip route ospf
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP
+ - replicated route, % - next hop override

Gateway of last resort is not set is subnetted, 1 subnets
O [110/2] via, 01:22:51, FastEthernet0/0 is subnetted, 1 subnets
O [110/3] via, 01:22:41, FastEthernet0/1
[110/3] via, 01:22:41, FastEthernet0/0 is subnetted, 1 subnets
O [110/2] via, 01:22:41, FastEthernet0/1 is variably subnetted, 6 subnets, 2 masks
O [110/2] via, 01:22:41, FastEthernet0/0
O [110/2] via, 01:22:41, FastEthernet0/1


R1#traceroute source probe 2
Type escape sequence to abort.
Tracing the route to
VRF info: (vrf in name/id, vrf out name/id)
1 24 msec 24 msec
2 56 msec 16 msec


R3#traceroute source probe 2
Type escape sequence to abort.
Tracing the route to
VRF info: (vrf in name/id, vrf out name/id)
1 56 msec 60 msec
2 40 msec 36 msec

 please advise

As you can see, there is load-balancing between the two available paths learned through OSPF. It is working as expected. If you run packet capture while you do traceroute, you should see packets traveling in both directions.

You will get more information here:

Cisco Employee

Equal cost load balancing is working as expected. At least from R1 perspective, if it has two routes to a specific destination via OSPF then it is equally load balancing with different next hops, this also applies for R3 as unequal load balancing is not supported in OSPF.

This is natural behavior, hardware based routing is based on CEF that by default uses per-destination hashing parameters to determine which next hop address will use for an specific flow of packets. For example, destination will always use the same link as long as the routing table doesn't change.

There are some ways to force CEF to allow packets to be distributed between links independently of its desintation like packet-sharing mode or enabling process-based switching of packets, but this can result in issues with TCP connections or firewall policies.

If you want to force a specific destination to go through a specific next hop address, you can use a PBR.
Joseph W. Doherty
Hall of Fame Expert

As the other posters have commented, it appears to be working correctly. Understand, by default, OSPF load balancing uses the same next hop for all a single flow's traffic. Also, I believe, by default, OSPF (actually CEF) will use the same next hop for traffic with the same attributes it uses to determine the next hop. (This latter "feature" often results in uneven loading of your multiple paths, especially in the short term. The best feature Cisco offers for dynamic load balancing, without splitting a single flow's packets, would be PfR.)