
Load balacing in RIP and Ibgp my changing AD
R6--------------------------R5
|
|
|----------------R22
R6 to R5 RIP ( IP SUNBET 9.9.56.0/24)
R6 to R22 IBGP (IP SUNBET 9.9.226.0/24)
R5 advt 55.0.0.0/8 via RIP
R22 advt 55.0.0.0/8 via IBGP
I want to do loan balance the traffic to destination 55.0.0.0/8
I have modified the AD on R6 for IBGP route to 120.
-------R6
Interface IP-Address OK? Method Status Protocol
FastEthernet0/0.46 9.9.46.6 YES NVRAM up up
FastEthernet0/0.56 9.9.56.6 YES NVRAM up up
FastEthernet0/0.62 9.9.226.6 YES NVRAM up up
Loopback0 9.9.0.6 YES NVRAM up up
!
router rip
network 9.0.0.0
no auto-summary
!
router bgp 100
no synchronization
bgp log-neighbor-changes
bgp redistribute-internal
neighbor 9.9.226.22 remote-as 100
distance bgp 2 120 10
no auto-summary
!
----R5
R5#sh ip int brief
Interface IP-Address OK? Method Status Protocol
FastEthernet0/0 unassigned YES NVRAM up up
FastEthernet0/0.56 9.9.56.5 YES NVRAM up up
Loopback0 9.9.0.5 YES NVRAM up up
Loopback55 55.55.55.55 YES NVRAM up up
router rip
network 9.0.0.0
network 55.0.0.0
no auto-summary
!
----R22
R22#sh ip int brief
Interface IP-Address OK? Method Status Protocol
FastEthernet0/0 unassigned YES NVRAM up up
FastEthernet0/0.62 9.9.226.22 YES NVRAM up up
FastEthernet0/1 unassigned YES NVRAM administratively down down
Serial2/0 unassigned YES NVRAM administratively down down
Serial2/1 unassigned YES NVRAM administratively down down
Serial2/2 unassigned YES NVRAM administratively down down
Serial2/3 unassigned YES NVRAM administratively down down
Loopback0 9.9.0.22 YES NVRAM up up
Loopback55 55.55.55.55 YES manual up up
R22#
router bgp 100
no synchronization
bgp log-neighbor-changes
network 55.0.0.0
neighbor 9.9.226.6 remote-as 100
no auto-summary
!
ON R6 i can see AD value of the ibgp route is set to 120.howvever load balaning not happening.
R6#sh ip route 55.0.0.0
Routing entry for 55.0.0.0/8
Known via "bgp 100", distance 120, metric 0, type internal
Last update from 9.9.226.22 00:12:27 ago
Routing Descriptor Blocks:
* 9.9.226.22, from 9.9.226.22, 00:12:27 ago
Route metric is 0, traffic share count is 1
AS Hops 0
MPLS label: none
If i shut the interface between R6 and R22....same route (55.0.0.0/8) is learned from R5.
R6#sh ip route 55.0.0.0
Routing entry for 55.0.0.0/8
Known via "rip", distance 120, metric 1
Redistributing via rip
Last update from 9.9.56.5 on FastEthernet0/0.56, 00:00:04 ago
Routing Descriptor Blocks:
* 9.9.56.5, from 9.9.56.5, 00:00:04 ago, via FastEthernet0/0.56
Route metric is 1, traffic share count is 1
By default R6 is prefering iBGP route to reach 55.0.0.0/8.
Can anyone please suggest why load balancing is not happening on R6 in between RIP and Ibgp route ?
Regards
Ganpat
Comments
Hi!
Nice question! Answer is quite straight I think:
Usually you do load balancing with static routes or any other routing protocol, when there are equal costs to the destination (metric). An exception are BGP and EIGRP, those protocols allow unequal-cost load-balancing and you can see this with the "sh ip route x.x.x.x" output when you have a look at the traffic share count. But imagine you were the router and you have one side BGP with ad 100 and one side RIP with AD 100 to the destination. How would you judge your unequal cost load-balancing here? I mean whats better....2 hops or a BGP metric or a AS-path? Or you could even take a different protocol....EIGRP with a cost of 45828424? What would you compare this to in hops?
Regards!
Markus
Hi Markus,
As per my underatnding if router is receiving same prefix from two routing protocol and bot having same AD then its should install route in Routing table from both protocol
Can you please explain me in details?
I tested it in the lab an before I paste a lot of stuff here you can read this article here.
http://packetlife.net/blog/2008/dec/6/two-routing-protocols-same-ad/
I get the same results as Jeremy!
HTH!
Regards!
Markus
Load balancing is done only for routes learnt with simmilar method i.e IGP/BGP or static mechanism.
Since Metric is highly significant only to a protocol, it is illogical for RIB process to compare route metric of different protocols with the same AD.
When RIB is faced with decision between routes of same AD, it decides as follows:
Nice one!
Thanks for the post!
Do you have a source for us where you got that info?
TIA!
Regards!
Markus
Actually I couldn't find any written document about this
I created a lab with all protocols & static routes and found the result. Anyone can do the same.
http://netoperation.blogspot.com/2011/03/administrative-distance.html
P.S I didnot test ISIS but from what I have found for other protocols, it shouldn't be any different.
Thanks for your replyies guys!!!
/Ganpat
Hi Guys,
I'm so sorry but the conclusion I have made previously was very incorrect. The correct one is if the AD values are the same for routes b/n different protocols, then the oldest route ( the first one to enter the RIB) will win.
Please find the right information on Alex Zinin's book chapter 4 Routing maintenance:
When a route is passed to the Routing table (RT) process, the router uses the
following logic.
same network.
route.
values of the old and new routes as follows.
route is different from the AD of the route in the table, the route with the
lower AD value is preferred. If the new route is chosen, all paths in the old
route are removed, the new path is installed, and the associated AD and metric
values of the route are changed accordingly. Otherwise—the already installed
route has a better AD value—the new route is not installed, but the router saves
information about the protocol that submitted the new route for installation in
the prefix descriptor and sends a query to the protocol when a backup route is
needed.
submitted by the same process, the new route is processed according to the rules
of distance-vector protocols (see Chapter
8).
sources, the behavior depends on whether the routes are submitted by processes
of the same type. If they are, the metrics of the routes are compared as if the
routes were from the same protocol. If metrics are the same, the route from the
process with the lower process number wins. If the routes are from different
sources, the new route is ignored. (Note that this check is implemented for
EIGRP routes only. All other routes are treated as from different protocols, so
the old route is left in the routing table.)
I think you might be misunderstanding something there.
If two prefixes are to be compared that have the same AD but are from different protocols (i.e. one protocol has had its AD increased/decreased) then the router will compare the original AD before manipulation as the tie breaker.
What the paragraph from the book you have posted is trying to say is that if within say EIGRP a prefix is advertised from two sources with the same AD and same metric then if you have ECLB turned off then it will only use the older of the advertisements.
HI David,
I must disagree.This chapter discusses how the RIB process works on a cisco router. Route source is the routing information source ( or routing protocol) that injected the routes into the RIB process.
When routes to the same destinations are submitted to it from the same route source process, different route source process of the same type or from different process of different type, the RIB route selection process will take the step as stated in the book.
If the routes are submitted have equal AD ( for whatever reason) and if they come from different EIGRP process/AS, then RIB will select them based on lowe metric and lower process number.
If the routes are submitted have equal AD ( for whatever reason) and if they come from different protocols or the same protocol other than EIGRP but different process, then the oldest route will win the election.
Instead of just believing a book published in 2001 I went away just to check it all out:
http://networkbroadcast.co.uk/2013/03/cisco-rib-operations-ad-comparisons/
Hopefully that clears it up for you Rob.
@david,
Thanks for checking that out. Yes the book is very old, but from what I have seen so far most of the fundamental things in the book are still legitimate. But it seems to contradicts from what we see in our "experiments". I'll verify it further
@northlandboy,
Which documentations have you seen? I couldn't find any "legitimate" documents except Alex Zinin's so far.
It's one of those things I remember reading, but right now I can't find any good sources. I'll have a hunt around, see if I can find it again.
Thanks to all for clearing this up (for me). So suppose multi-path is disabled, route will be resolved in the following order:
AD
Original AD
Metric
Process Id
Age
It does make a lot of sense since this guarantees that metric is compared only between sources of the same type.