实验拓扑
实验要求:
路由器端口IP配置
OSPF协议配置,网段宣告
BGP 建邻
、
R3,R6路由器反射
[R6-bgp]peer 7.7.7.7 reflect-client
[R3-bgp]peer 4.4.4.4 reflect-client
测试BGP协议路由连通性
路由环回网段宣告,使环回间可以互相访问
[R3-bgp]net 172.16.3.0 24
[R4-bgp]net 172.16.4.0 24
[R5-bgp]net 172.16.5.0 24
[R6-bgp]net 172.16.6.0 24
[R7-bgp]net 172.16.7.0 24
路由汇总,减少路由条目,避免环路出现。
[R3-bgp]aggregate 172.16.0.0 16 detail-suppressed
[R3]ip route-static 172.16.0.0 16 NULL 0
[R4-bgp]aggregate 172.16.0.0 16 detail-suppressed
[R4]ip route-static 172.16.0.0 16 NULL 0
[R5]ip route-static 172.16.0.0 16 NULL 0
[R5-bgp]aggregate 172.16.0.0 16 detail-suppressed
[R6]ip route-static 172.16.0.0 16 NULL 0
[R6-bgp]aggregate 172.16.0.0 16 detail-suppressed
[R7-bgp]aggregate 172.16.0.0 16 detail-suppressed
[R7]ip route-static 172.16.0.0 16 NULL 0
测试
使用GREVPN使R1,R8环回互通。
配置隧道
[R1]int t0/0/0
[R1-Tunnel0/0/0]ip add 10.1.1.1 24
[R1-Tunnel0/0/0]tunnel-protocol gre
[R1-Tunnel0/0/0]source 1.1.1.1
[R1-Tunnel0/0/0]description 8.8.8.8
[R8]int t0/0/0
[R8-Tunnel0/0/0]ip add 10.1.1.2 24
[R8-Tunnel0/0/0]tunnel-protocol gre
[R8-Tunnel0/0/0]source 1.1.1.1
[R8-Tunnel0/0/0]description 8.8.8.8
传递私网路由
[R8]ip route-static 192.168.1.0 24 Tunnel 0/0/0
[R1]ip route-static 192.168.2.0 24 Tunnel 0/0/0