码迷,mamicode.com
首页 > 编程语言 > 详细

BGP Community(团体)配置实例

时间:2017-02-26 01:09:05      阅读:323      评论:0      收藏:0      [点我收藏+]

标签:table   http   sse   map   访问控制列表   route   end   log   res   

该实验是引用了BGP路由聚合配置实例的基础上,再深入探讨BGP团体实验。如下链接为“BGP路由聚合配置实例”基础部份:
http://www.cnblogs.com/vincent-liang/p/6441860.html

当你收到一个BGP路由带有no-export属性的,该台路由器将不再向eBGP路由节点发送该访问控制列表的IP路由。
查看R4没有no-export属性的BGP路由如下:
R4#show ip bgp
BGP table version is 19, local router ID is 4.4.4.4
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    3.3.3.3                                0 1 i
*>                  2.2.2.2                                0 1 i
*  22.22.22.0/24    3.3.3.3                                0 1 i
*>                  2.2.2.2                  0             0 1 i
*  33.33.33.0/24    2.2.2.2                                0 1 i
*>                  3.3.3.3                  0             0 1 i
*> 44.44.44.0/24    0.0.0.0                  0         32768 i
*> 55.55.55.0/24    5.5.5.5                  0             0 5 i
*> 66.66.66.0/24    6.6.6.6                  0             0 6 i
*> 101.1.0.0/22     0.0.0.0                       100  32768 {1,6} i
s  101.1.1.0/24     3.3.3.3                                0 1 i
s>                  2.2.2.2                                0 1 i
*> 101.1.2.0/24     6.6.6.6                  0             0 6 i
*> 101.1.3.0/24     6.6.6.6                  0             0 6 i
*> 106.1.1.0/24     6.6.6.6                  0             0 6 i

access-list 1 permit 55.55.55.0 0.0.0.255
route-map orange permit 10
 match ip address 1
 set community no-export
router bgp 5
 neighbor 4.4.4.4 send-community
 neighbor 4.4.4.4 route-map orange out

查看R4带有no-export属性的BGP路由如下:
R4#show ip bgp   
BGP table version is 24, local router ID is 4.4.4.4
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    3.3.3.3                                0 1 i
*>                  2.2.2.2                                0 1 i
*  22.22.22.0/24    3.3.3.3                                0 1 i
*>                  2.2.2.2                  0             0 1 i
*  33.33.33.0/24    2.2.2.2                                0 1 i
*>                  3.3.3.3                  0             0 1 i
*> 44.44.44.0/24    0.0.0.0                  0         32768 i
*> 66.66.66.0/24    6.6.6.6                  0             0 6 i
*> 101.1.0.0/22     0.0.0.0                       100  32768 {1,6} i
s  101.1.1.0/24     3.3.3.3                                0 1 i
s>                  2.2.2.2                                0 1 i
*> 101.1.2.0/24     6.6.6.6                  0             0 6 i
*> 101.1.3.0/24     6.6.6.6                  0             0 6 i
*> 106.1.1.0/24     6.6.6.6                  0             0 6 i

 

配置no-advertise前BGP路由
R1#show ip bgp
BGP table version is 16, local router ID is 1.1.1.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    0.0.0.0                  0         32768 i
*>i22.22.22.0/24    2.2.2.2                  0    100      0 i
*>i33.33.33.0/24    3.3.3.3                  0    100      0 i
* i44.44.44.0/24    4.4.4.4                  0    100      0 4 i
*>i                 4.4.4.4                  0    100      0 4 i
*>i55.55.55.0/24    4.4.4.4                  0    100      0 4 5 i
* i                 4.4.4.4                  0    100      0 4 5 i
*>i66.66.66.0/24    4.4.4.4                  0    100      0 4 6 i
* i                 4.4.4.4                  0    100      0 4 6 i
*> 101.1.1.0/24     0.0.0.0                  0         32768 i
*>i101.1.2.0/24     4.4.4.4                  0    100      0 4 6 i
* i                 4.4.4.4                  0    100      0 4 6 i
*>i101.1.3.0/24     4.4.4.4                  0    100      0 4 6 i
* i                 4.4.4.4                  0    100      0 4 6 i
*>i106.1.1.0/24     4.4.4.4                  0    100      0 4 6 i
* i                 4.4.4.4                  0    100      0 4 6 i

access-list 4 permit 44.44.44.0 0.0.0.255
route-map apple permit 10
 match ip address 4
 set community no-advertise
 neighbor 2.2.2.2 send-community
 neighbor 2.2.2.2 route-map apple out
 neighbor 3.3.3.3 send-community
 neighbor 3.3.3.3 route-map apple out
配置no-advertise后BGP路由
R1#show ip bgp
BGP table version is 34, local router ID is 1.1.1.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    0.0.0.0                  0         32768 i
*>i22.22.22.0/24    2.2.2.2                  0    100      0 i
*>i33.33.33.0/24    3.3.3.3                  0    100      0 i
*> 101.1.1.0/24     0.0.0.0                  0         32768 i

 

BGP Community(团体)配置实例

标签:table   http   sse   map   访问控制列表   route   end   log   res   

原文地址:http://www.cnblogs.com/vincent-liang/p/6443372.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!