BGP基础―综合试验

*~*~*~*~*~*~*~*~*~*~*~*~*~*~2008.10.30*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~*~
查看通告给neighbor的路由
show ip bgp neighbors [ip] advertised-routes
路由反射器(路由反射簇)RR
1:同AS中,客户端传递来的路由条目做全反射
2: 同AS中,非客户端传递来的路由条目不会传递给另外一个非客户端
3:不同AS传递来的路由 做全反射。
TIPS:
1.路由反射簇当作逻辑的一个路由器。这样路由反射器的路由传递方式就容易理解了。
2.路由反射簇只有RR知道,CLIENT不知道。(看命令)
neighbor 1.1.1.1 route-reflector-client
联邦:
bgp confederation identifier  [as] 对外AS
bgp confederation peers [as] 对内联邦
联邦EBGP还是需要
neighbor [ip] next-hop-self
联邦AS不会带出大AS;学到的联邦EBGP路由管理距离为200;
试验:
R6-AS:600)--(AS:105-[AS:65421-R4-R2-R1-AS:65421]--[AS:65035-R3-R5-AS:65035]-AS:105)--(AS:700-R7
环境:3个大AS:600;105;700
      在R4R2R1R3R5所在AS中启用联邦,R4-R2-R1 AS:65421;R3-R5 AS:65035
      在65421的R2启用RR,65035中使用peer-group建立邻�v。
目的:熟悉 掌握BGP基本概念,邻�v建立和路由传递。
--------R6-----------------------------------------------------------
router bgp 600
no synchronization
bgp router-id 6.6.6.6
bgp log-neighbor-changes
network 6.6.6.0 mask 255.255.255.0
neighbor 10.1.46.4 remote-as 105 //EBGP邻居
no auto-summary
!
--------R4-----------------------------------------------------------
router bgp 65421
no synchronization
bgp router-id 4.4.4.4
bgp log-neighbor-changes
bgp confederation identifier 105 //对外AS号
neighbor 2.2.2.2 remote-as 65421 //联邦IBGP邻居
neighbor 2.2.2.2 update-source Loopback0
neighbor 10.1.46.6 remote-as 600 //R6为EBGP邻居
no auto-summary
!
--------R2-----------------------------------------------------------
router bgp 65421
no synchronization
bgp router-id 2.2.2.2
bgp log-neighbor-changes
bgp confederation identifier 105  //对外AS号
neighbor 1.1.1.1 remote-as 65421  //联邦IBGP邻居
neighbor 1.1.1.1 update-source Loopback0
neighbor 1.1.1.1 route-reflector-client //配置RR
neighbor 4.4.4.4 remote-as 65421
neighbor 4.4.4.4 update-source Loopback0
neighbor 4.4.4.4 route-reflector-client
no auto-summary
!
--------R1-----------------------------------------------------------
router bgp 65421
no synchronization
bgp router-id 1.1.1.1
bgp log-neighbor-changes
bgp confederation identifier 105  //对外AS号
bgp confederation peers 65035     //联邦对等体
neighbor 2.2.2.2 remote-as 65421
neighbor 2.2.2.2 update-source Loopback0
neighbor 3.3.3.3 remote-as 65035
neighbor 3.3.3.3 ebgp-multihop 2  //联邦EBGP还是需要修改默认跳数
neighbor 3.3.3.3 update-source Loopback0
no auto-summary
!
--------R3-----------------------------------------------------------
router bgp 65035
no synchronization
bgp router-id 3.3.3.3
bgp log-neighbor-changes
bgp confederation identifier 105  //对外AS号
bgp confederation peers 65421     //联邦对等体
network 3.3.3.0 mask 255.255.255.0
neighbor 3and5 peer-group    //配置peer-group
neighbor 3and5 remote-as 65035
neighbor 3and5 update-source Loopback0
neighbor 1.1.1.1 remote-as 65421
neighbor 1.1.1.1 ebgp-multihop 2
neighbor 1.1.1.1 update-source Loopback0
neighbor 5.5.5.5 peer-group 3and5 //调用peer-group
no auto-summary
!
--------R5-----------------------------------------------------------
router bgp 65035 //参照R3
no synchronization
bgp router-id 5.5.5.5
bgp log-neighbor-changes
bgp confederation identifier 105
neighbor 5and3 peer-group
neighbor 5and3 remote-as 65035
neighbor 5and3 update-source Loopback0
neighbor 3.3.3.3 peer-group 5and3
neighbor 10.1.57.7 remote-as 700
no auto-summary
!
--------R7-----------------------------------------------------------
router bgp 700
no synchronization
bgp router-id 7.7.7.7
bgp log-neighbor-changes
network 7.7.7.0 mask 255.255.255.0
neighbor 10.1.57.5 remote-as 105
no auto-summary
!
问:为什么没有next-hop-self命令?
答:在配置IGP底层路由的时候,使用的RIPV2协议,为少打命令直接NET的0.0.0.0
    这样造成在IGP边缘AS之间连接的网段也发布进了IGP,所以当BGP学到邻AS来的路由
    时候,下一条网段在IGP中可达,及已被优,使用不需要配置next-hop-self命令了。

你可能感兴趣的:(基础,职场,休闲,BGP)