bgp第三方下一条_bgp
 
案例要求:
ebgp第三方下一跳
要求:R1与R3建立对等体关系,R2不运行BGP,
只使用RIP路由协议,将11.11.11.0网络通过R3宣告出去,
让R1获得其信息。
 
配置步骤:(这个实验很简单,就不详细阐述了)
 
一、基本配置:
r1(config)#int fa0/0
r1(config-if)#no shutdown
r1(config-if)#ip add 10.10.10.1 255.255.255.0
r2(config)#int fa0/0
r2(config-if)#no shutdown
r2(config-if)#ip add 10.10.10.3 255.255.255.0
r2(config-if)#int loo 0
r2(config-if)#ip add 11.11.11.1 255.255.255.0

r3(config)#int fa0/0
r3(config-if)#ip add 10.10.10.2 255.255.255.0
r3(config-if)#no shutdown 
 
二、配置:
r1(config)#router bgp 100
r1(config-router)#neighbor 10.10.10.2 remote-as 200
r2(config)#router rip  
r2(config-router)#version 2
r2(config-router)#no auto-summary
r2(config-router)#network 11.11.11.0
r2(config-router)#network 10.10.10.0
r3(config)#router bgp 200
r3(config-router)#neighbor 10.10.10.1 remote-as 100
r3(config-router)#network 11.11.11.0 mask 255.255.255.0
r3(config)#router rip
r3(config-router)#version 2
r3(config-router)#no auto-summary
r3(config-router)#network 10.10.10.0
 
三、检测:
    这时 发现11.11.11.0网络的下一跳是:10.10.10.3:
r1#show 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
     10.0.0.0/24 is subnetted, 1 subnets
C       10.10.10.0 is directly connected, FastEthernet0/0
     11.0.0.0/24 is subnetted, 1 subnets
B       11.11.11.0 [20/1] via 10.10.10.3, 00:01:11
r1#show ip bgp
BGP table version is 2, local router ID is 10.10.10.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
*> 11.11.11.0/24    10.10.10.3               1             0 200 i