Friday, April 9, 2010

BGP Studies

Well I finally got through the "theory" portion of Internet Routing Architectures, and am going through chapter 11 which actually begins the configuration portion as it pertains to Cisco.  I am doing the labs with Halabi as he explains them in the book.  Lots of redistribution stuff at first, and a backdoor lab as well.  I will note the backdoor lab here.  Topology is as such:

So the key here is that RTC is going to get 2 different routes to the 192.68.10.0/24 network.  The ospf connection is the more desirable one, check out the administrative distances:
BGP(external)-20
OSPF (internal)-110

So notice the route that shows up in the routing table:
Gateway of last resort is not set

     172.16.0.0/16 is variably subnetted, 4 subnets, 2 masks
B       172.16.220.0/24 [20/0] via 172.16.20.2, 00:24:31
C       172.16.20.0/24 is directly connected, Serial3/0
B       172.16.1.0/24 [20/0] via 172.16.20.2, 00:24:31
B       172.16.65.1/32 [20/65] via 172.16.20.2, 00:17:28
B    192.68.10.0/24 [20/0] via 172.16.20.2, 00:20:24
C    192.68.11.0/24 is directly connected, Loopback0
B    192.68.5.0/24 [20/20] via 172.16.20.2, 00:15:46
C    192.68.6.0/24 is directly connected, FastEthernet0/0


Its the less desirable BGP route.  So how do you remedy this?  Well, the easiest way is to simply use what is known as the BGP "backdoor."  This command:

3640-RTC(config)#router bgp 1
3640-RTC(config-router)#network 192.68.10.0 backdoor

Now, its seems weird that you do this on RTC...but using this command does not advertise the network, it simply changes the AD of the BGP route to 200.  If I were to sever the OSPF link, the bgp route would show back up...check it out.

3640-RTC(config)#int fa0/0
3640-RTC(config-if)#shut
02:32:50: %OSPF-5-ADJCHG: Process 2, Nbr 192.68.10.1 on FastEthernet0/0 from FULL to DOWN, Neighbor Down: Interface down or detached
3640-RTC(config-if)#do show ip route
Gateway of last resort is not set


     172.16.0.0/16 is variably subnetted, 4 subnets, 2 masks
B       172.16.220.0/24 [20/0] via 172.16.20.2, 00:45:13
C       172.16.20.0/24 is directly connected, Serial3/0
B       172.16.1.0/24 [20/0] via 172.16.20.2, 00:45:13
B       172.16.65.1/32 [20/65] via 172.16.20.2, 00:38:11
B    192.68.10.0/24 [200/0] via 172.16.20.2, 00:00:04
C    192.68.11.0/24 is directly connected, Loopback0
B    192.68.5.0/24 [20/20] via 172.16.20.2, 00:36:28
O    192.68.6.0/24 [110/1] via 192.68.6.2, 00:00:04, FastEthernet0/0


So that is how easy, and cool bgp backdoor is!

No comments:

Post a Comment