10-09-2023 03:50 AM - last edited on 10-17-2023 02:50 AM by Translator
I want to configure load balancing using OSPF for two p2p link on r1941 router .
router 1:
192.168.1.0/24 is variably sub-netted, 2 subnets, 2 masks
C 192.168.1.0/24 is directly connected, GigabitEthernet0/0
L 192.168.1.1/32 is directly connected, GigabitEthernet0/0
O 192.168.2.0/24 [110/65] via 213.2.2.2, 00:00:05, Serial0/1/1
213.2.2.0/24 is variably sub-netted, 2 subnets, 2 masks
C 213.2.2.0/24 is directly connected, Serial0/1/1
L 213.2.2.1/32 is directly connected, Serial0/1/1
OSPF :
Router #show IP OSPF database
OSPF Router with ID (213.2.1.1) (Process ID 1)
Router Link States (Area 0)
Link ID ADV Router Age Sequence # Checksum Link count
213.2.1.1 213.2.1.1 10 0x80000006 0x0030d1 3
213.2.2.2 213.2.2.2 10 0x80000006 0x0006f7 3
router 2:
O 192.168.1.0/24 [110/65] via 213.2.2.1, 00:00:05, Serial0/1/1
192.168.2.0/24 is variably sub-netted, 2 subnets, 2 masks
C 192.168.2.0/24 is directly connected, GigabitEthernet0/0
L 192.168.2.1/32 is directly connected, GigabitEthernet0/0
213.2.2.0/24 is variably sub-netted, 2 subnets, 2 masks
C 213.2.2.0/24 is directly connected, Serial0/1/1
L 213.2.2.2/32 is directly connected, Serial0/1/1
OSPF:
Router #show IP OSPF database
OSPF Router with ID (213.2.2.2) (Process ID 1)
Router Link States (Area 0)
Link ID ADV Router Age Sequence # Checksum Link count
213.2.2.2 213.2.2.2 347 0x80000005 0x00f4dd 5
213.2.1.1 213.2.1.1 347 0x80000005 0x00488d 5
I want to load balancing on two paths pc1 to router link 1 to pc2 and back-route is pc2 to link 2 to pc1.
is it possible in OSPF?
Solved! Go to Solution.
10-11-2023 02:44 AM - edited 10-11-2023 02:44 AM
I got this just before...
dynamic routing protocols like OSPF and EIGRP(also called unicast routing protocols) that are used to build the symmetrical network and its forwarding paths. Means it is it's default behavior to use same path for send and receive... Still if you want to change default behaviour...you can change using conditional forwarding or PBR (policy based routing)
only Asymmetric network(Multicast routing) allows to use defferent paths for sending and receiving....
Best regards
******* If This Helps, Please Rate *******
10-09-2023 03:57 AM
I want to load balancing on two paths pc1 to router link 1 to pc2 and back-route is pc2 to link 2 to pc1.
everything is pssible based on the Traffic engineering using cost, but you need to make small diagram how that traffic flows, the requirement is not clear here.
10-09-2023 04:17 AM
Hello @mayurrathod3795,
If you want to fine-tune load balancing or if the cost values are not equal for some reason, you can use OSPF path cost manipulation techniques to make sure both paths have equal cost. You can adjust the OSPF interface cost or use OSPF reference bandwidth configuration to control the metric calculation.
Please provide us toplogy or diagram. Thanks a lot.
10-09-2023 05:55 AM
consider above image for reference
10-09-2023 06:59 AM
For your posted topology's WAN (serial) links, for OSPF's ECMP to work, each serial interface needs to have the same OSPF cost. By default, Cisco's OSPF will compute a cost based on what device believes is the interface bandwidth. If the serial interfaces do not have the same bandwidth, you can use the bandwidth statement to make them the same or set the OSPF cost per interface to be the same.
10-09-2023 05:54 AM
10-09-2023 06:16 AM - last edited on 10-17-2023 02:57 AM by Translator
In packet tracker go to the simulation mode...you track how the traffic is going and coming back...
or you can use
traceroute ip address (ex: traceroute 192.168.2.1)
command to track the path...
so you will come to know which link is used for forwarding and return traffic...
Best regards
******* If This Helps, Please Rate *******
10-09-2023 09:49 PM
i checked path in simulation mode its showing same path .
10-09-2023 11:36 PM
I think....that's how equal path load-balancing will heppen...
1st packet both request and reply through link1
2nd packet both request and reply through link2
3rd packet both request and reply thgrough link1
4th packet both request and reply through link2 and so on....
If you want change this default behaviour....you will needed to implement Conditional forwarding or Policy Based Routing (PBR)....on routers....
Best regards
******* If This Helps, Please Rate *******
10-10-2023 02:06 AM - last edited on 10-17-2023 02:58 AM by Translator
'I think....that's how equal path load-balancing will heppen..."
Return path selection is independent of request path.
For ECMP, non fast path forwarding round robins or CEF packet-by-packet mode round robins, otherwise "flow" use the same path for all packets.
Something like
ping
each packet is considered its own flow.
10-10-2023 02:16 AM - edited 10-10-2023 02:17 AM
Yes....that is called Round-robin Loadbalancing.... used by routers....
Thanks
10-09-2023 07:21 AM
If you want to fine-tune load balancing or if the cost values are not equal for some reason, you can use OSPF path cost manipulation techniques to make sure both paths have equal cost. You can adjust the OSPF interface cost or use OSPF reference bandwidth configuration to control the metric calculation.
10-09-2023 09:50 PM
cost value is same 64 in both path, also i tried bandwidth but its not applicable here.
10-10-2023 01:56 AM
Does route table show same destination network more than once?
If this is PT, could you post it?
10-09-2023 10:52 PM - last edited on 10-17-2023 03:04 AM by Translator
Show ip ospf database
As I see it show only link between router.
I need to see subnet of PC on both side
Do you use
redistrubte
connect?
If yes then remove
redistrubte
connect and add
network
command under each opsf process for PC subnet.
If you want one side load and other not
Make one side cost same and make other side cost difference.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide