jskfan
asked on
configure BGP when Static Routes are used.
configure BGP when Static Routes are used.
in the topology below we have 2 routers in 2 different AS numbers. If we configure the 2 routers with static route or default route, so that they will have reachability
then can we configure BGP peering between the 2 routers based on their physical interfaces' ip addresses and redistribute connected networks, I wonder if BGP will have any meaning, because Static or Default routes will be preferred over BGP protocol as their AD is lower than BGP AD.
Anyone to shade some lights on this ?
Thank you
in the topology below we have 2 routers in 2 different AS numbers. If we configure the 2 routers with static route or default route, so that they will have reachability
then can we configure BGP peering between the 2 routers based on their physical interfaces' ip addresses and redistribute connected networks, I wonder if BGP will have any meaning, because Static or Default routes will be preferred over BGP protocol as their AD is lower than BGP AD.
Anyone to shade some lights on this ?
Thank you
ASKER
OK..
so it is doable , right ?
I mean we can configure static routes on both links between the 2 routers then configure BGP and redistribute connected on both routers..?
the reason I am asking this question, because if I configure any other IGP between the 2 routers (EIGRP,OSPF,RIP), their AD is still higher than EBGP AD (20), and BGP routes will be in the routing table.
Probably it is very rare to have IGP configured between 2 Service Providers , but with static or default route it could exist.
so it is doable , right ?
I mean we can configure static routes on both links between the 2 routers then configure BGP and redistribute connected on both routers..?
the reason I am asking this question, because if I configure any other IGP between the 2 routers (EIGRP,OSPF,RIP), their AD is still higher than EBGP AD (20), and BGP routes will be in the routing table.
Probably it is very rare to have IGP configured between 2 Service Providers , but with static or default route it could exist.
Yes. You can do it.
But static routes will still take precedence unless you change the AD's.
But static routes will still take precedence unless you change the AD's.
ASKER
Sorry Don, for the confusion...
What I was trying to understand is , the reason that BGP is used on the Internet, is because of the size of the routing table that it can hold, and we know the updates happen every 180 seconds.
Now if the routing tables do not have BGP but they have static routes or default routes instead, then will this defeat the purpose of using BGP along with static route or default route ?
What I was trying to understand is , the reason that BGP is used on the Internet, is because of the size of the routing table that it can hold, and we know the updates happen every 180 seconds.
Now if the routing tables do not have BGP but they have static routes or default routes instead, then will this defeat the purpose of using BGP along with static route or default route ?
Updates only happen every hundred and eighty seconds with rip.
If your routing table is small enough that you can get by with static routes, then there's really no reason to use bgp in the first place.
I think I'm not understanding what you were trying to accomplish.
If your routing table is small enough that you can get by with static routes, then there's really no reason to use bgp in the first place.
I think I'm not understanding what you were trying to accomplish.
ASKER
Don,
I will post the LAB output in a minute
I will post the LAB output in a minute
ASKER
R1#
interface Ethernet0/0
ip address 192.168.12.1 255.255.255.0
!
interface Ethernet0/1
ip address 192.168.13.1 255.255.255.0
!
router bgp 1
redistribute connected
neighbor 192.168.12.2 remote-as 1
neighbor 192.168.13.3 remote-as 2
!
ip route 0.0.0.0 0.0.0.0 192.168.13.3
!
R2#
interface Loopback0
ip address 2.2.2.2 255.255.255.255
!
interface Ethernet0/0
ip address 192.168.12.2 255.255.255.0
!
router bgp 1
bgp log-neighbor-changes
network 192.168.12.0
redistribute connected
neighbor 192.168.12.1 remote-as 1
!
R3#
interface Ethernet0/0
ip address 192.168.13.3 255.255.255.0
!
interface Ethernet0/1
ip address 192.168.34.3 255.255.255.0
!
router bgp 2
redistribute connected
neighbor 192.168.13.1 remote-as 1
neighbor 192.168.34.4 remote-as 2
!
ip route 0.0.0.0 0.0.0.0 192.168.13.1
!
R4#
interface Loopback0
ip address 4.4.4.4 255.255.255.255
!
interface Ethernet0/0
ip address 192.168.34.4 255.255.255.0
!router bgp 2
bgp log-neighbor-changes
redistribute connected
neighbor 192.168.34.3 remote-as 2
ASKER
R4#sh ip route bgp
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
a - application route
+ - replicated route, % - next hop override
Gateway of last resort is not set
2.0.0.0/32 is subnetted, 1 subnets
B 2.2.2.2 [200/0] via 192.168.13.1, 00:11:26
B 192.168.12.0/24 [200/0] via 192.168.13.1, 00:11:26
B 192.168.13.0/24 [200/0] via 192.168.34.3, 00:11:26
R4#
R2#sh ip route bgp
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
a - application route
+ - replicated route, % - next hop override
Gateway of last resort is not set
4.0.0.0/32 is subnetted, 1 subnets
B 4.4.4.4 [200/0] via 192.168.13.3, 00:11:38
B 192.168.13.0/24 [200/0] via 192.168.12.1, 00:11:38
B 192.168.34.0/24 [200/0] via 192.168.13.3, 00:11:38
R2#
ASKER
I was not sure that the BGP routes that have been advertised will still show as BGP
So even with default Route between R1 and R3 , the BGP routes that have been learned will still show as BGP routes ..
I was confused till I set up the LAB
So even with default Route between R1 and R3 , the BGP routes that have been learned will still show as BGP routes ..
I was confused till I set up the LAB
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thank you for clarification
Not sure what you’re looking for, but as you mentioned, any routes learned through BGP will not show in the routing table if there is a static route configured for that network.