05-17-2008 10:10 AM - edited 03-03-2019 09:59 PM
Hi
Is it possible that same distination reach via diffrent ISP but metric value is same.? and that destination route is install in "Show ip route" table. Please let me known.
-M
05-17-2008 10:49 AM
Hello minu,
yes you can have two different eBGP advertisements installed in your routing table for an IP prefix.
Look at the command maximum-paths in the router bgp process. The default value is 1. if you use maximum-paths 2 you can have two paths installed in your ip routing table.
If you want to compare MED for advertisements coming from two different ISPs (BGP ASN) you can use the command
router bgp
bgp always-compare-med
! and to have a deterministic behaviour
bgp deterministic-med
maximum-paths 2
!
hope to help
Giuseppe
05-17-2008 05:16 PM
Giuseppe,
Bear in mind that IOS will not install the two paths in the RIB by default if they are not from the same neighbor AS.
You can use the following hidden command to change this behavior.
"bgp bestpath as-path multipath-relax"
Regards,
05-18-2008 08:59 AM
Thats interesting...
So, the maximum-paths command is only for installing multiple paths from the same neighbor?
Victor
05-18-2008 09:36 AM
Victor,
That is correct.
Regards,
05-18-2008 12:43 PM
Thanks, Harold. Makes sense.
Victor
05-18-2008 06:41 PM
Hi
That mean in " show ip route" do not have multiple routes for same destionation only this is happend with same AS not different different AS.
Please correct me if i am wrong..
-Minu
05-18-2008 11:54 PM
yes.. if you have maximum-paths configured under BGP, and you receive multiple routes to the same destination via different AS, it will not be installed in the routing table
you need to enter the command that harold pointed out
bgp bestpath as-path multipath-relax
configuring the above along with the maximum-paths will ensure that multiple entries are installed in the RT
Narayan
HTH
Narayan
05-19-2008 11:11 PM
Hi Narayan
I beliave maximum-path command only use only AS. that means it is useful when you have two link with same AS, here my question is the if i have two links with different AS and it will design in such way that i will have all attributes are same , in that case should i get two routes in "show ip route "
-minu
05-19-2008 11:34 PM
Minu,
When you enter the bgp best-path as-path multipath-relax command along with maximum paths command, the router will install 2 routes provided the other attributes are same
here is an example output where R1 (AS 100) is connected to both R2 (AS 200) and R3 (AS 300) both advertising prefix 1.1.1.0/24
R1
router bgp 100
no synchronization
bgp log-neighbor-changes
bgp bestpath as-path multipath-relax
neighbor 10.10.10.2 remote-as 200
neighbor 20.20.20.2 remote-as 300
maximum-paths 2
no auto-summary
R2
router bgp 200
no synchronization
bgp log-neighbor-changes
network 1.1.1.0 mask 255.255.255.0
neighbor 10.10.10.1 remote-as 100
no auto-summary
R3
router bgp 300
no synchronization
bgp log-neighbor-changes
network 1.1.1.0 mask 255.255.255.0
neighbor 20.20.20.1 remote-as 100
no auto-summary
r1#sh ip bgp
BGP table version is 3, local router ID is 20.20.20.1
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal,
r RIB-failure, S Stale
Origin codes: i - IGP, e - EGP, ? - incomplete
Network Next Hop Metric LocPrf Weight Path
*> 1.1.1.0/24 10.10.10.2 0 0 200 i
* 20.20.20.2 0 0 300 i
r1#
r1#sh ip route
Codes: 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
Gateway of last resort is not set
1.0.0.0/24 is subnetted, 1 subnets
B 1.1.1.0 [20/0] via 10.10.10.2, 00:07:53
[20/0] via 20.20.20.2, 00:03:49
20.0.0.0/24 is subnetted, 1 subnets
C 20.20.20.0 is directly connected, FastEthernet0/1
10.0.0.0/24 is subnetted, 1 subnets
C 10.10.10.0 is directly connected, FastEthernet0/0
r1#
Note : it is possible that the command may not appear in the CLI help but you can type it as it is
HTH
Narayan
05-20-2008 06:47 AM
Narayan:
Nice presentation. There's no better way to prove the theory than to actually put it to the test.
I rated your post.
Victor
05-20-2008 07:43 AM
victor
appreciate the comments as well as the rating
Narayan
05-20-2008 08:19 AM
Narayan,
Since both paths are installed into the routing table does this mean it will load-balance between the 2 routers?
Thanks,
Phil
05-20-2008 08:31 PM
Yes it would and would be based on the CEF per destination loadbalance by default
Narayan
05-21-2008 12:11 AM
Hi
thanks for clarification , this is really great help, onces again thanks
-minu
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