BGP聚合路由 执行最苛刻的条件

如图,R1在AS1中,R2,R3,R4在一个大AS100中(R2,R3在AS23中,R4在AS4中),5在AS5中。
聚合路由执行最苛刻的条件-- LocPrf最大等。
R2#show route-map
route-map aa, permit, sequence 10
Match clauses:
ip address (access-lists): 1
Set clauses:
local-preference 1000
community internet 1:34464
origin incomplete
Policy routing matches: 0 packets, 0 bytes
route-map aa, permit, sequence 20
Match clauses:
ip address (access-lists): 2
Set clauses:
local-preference 2000
community 3:3392 local-AS
Policy routing matches: 0 packets, 0 bytes
route-map aa, permit, sequence 30
Match clauses:
ip address (access-lists): 3
Set clauses:
local-preference 3000
community 4:37856 no-advertise
Policy routing matches: 0 packets, 0 bytes
route-map aa, permit, sequence 40
Match clauses:
ip address (access-lists): 4
Set clauses:
community no-export
Policy routing matches: 0 packets, 0 bytes
route-map aa, permit, sequence 50
Match clauses:
Set clauses:
Policy routing matches: 0 packets, 0 bytes
R2#show access-lists
Standard IP access list 1
10 permit 200.1.1.0 (16 matches)
Standard IP access list 2
10 permit 200.1.2.0 (16 matches)
Standard IP access list 3
10 permit 200.1.3.0 (16 matches)
Standard IP access list 4
10 permit 200.1.4.0 (16 matches)
R2#show run | s bgp
router bgp 23
bgp router-id 2.2.2.2
bgp log-neighbor-changes
bgp confederation identifier 100
aggregate-address 200.1.0.0 255.255.252.0 as-set
neighbor 3.3.3.3 remote-as 23
neighbor 3.3.3.3 update-source Loopback0
neighbor 3.3.3.3 next-hop-self
neighbor 3.3.3.3 send-community both
neighbor 12.1.1.1 remote-as 1
neighbor 12.1.1.1 route-map aa in
ip bgp-community new-format
R2#show ip bgp
BGP table version is 33, local router ID is 2.2.2.2
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal,
r RIB-failure, S Stale, m multipath, b backup-path, f RT-Filter,
x best-external, a additional-path, c RIB-compressed,
Origin codes: i - IGP, e - EGP, ? - incomplete
RPKI validation codes: V valid, I invalid, N Not found

 Network          Next Hop            Metric LocPrf Weight Path

> 1.1.1.1/32 12.1.1.1 0 0 1 i
>i 5.5.5.5/32 3.3.3.3 0 100 0 (4) 5 i
> 200.1.0.0/22 0.0.0.0 3000 32768 1 ?
> 200.1.1.0 12.1.1.1 0 1000 0 1 ?
> 200.1.2.0 12.1.1.1 0 2000 0 1 i
> 200.1.3.0 12.1.1.1 0 3000 0 1 i
> 200.1.4.0 12.1.1.1 0 0 1 i
R3#show ip bgp
BGP table version is 29, local router ID is 3.3.3.3
Status codes: s suppressed, d damped, h history,
valid, > best, i - internal,
r RIB-failure, S Stale, m multipath, b backup-path, f RT-Filter,
x best-external, a additional-path, c RIB-compressed,
Origin codes: i - IGP, e - EGP, ? - incomplete
RPKI validation codes: V valid, I invalid, N Not found

 Network          Next Hop            Metric LocPrf Weight Path

>i 1.1.1.1/32 2.2.2.2 0 100 0 1 i
> 5.5.5.5/32 4.4.4.4 0 100 0 (4) 5 i
>i 200.1.1.0 2.2.2.2 0 1000 0 1 ?
>i 200.1.2.0 2.2.2.2 0 2000 0 1 i
>i 200.1.4.0 2.2.2.2 0 100 0 1 i
R4#show ip bgp
BGP table version is 27, 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, m multipath, b backup-path, f RT-Filter,
x best-external, a additional-path, c RIB-compressed,
Origin codes: i - IGP, e - EGP, ? - incomplete
RPKI validation codes: V valid, I invalid, N Not found

 Network          Next Hop            Metric LocPrf Weight Path

> 1.1.1.1/32 2.2.2.2 0 100 0 (23) 1 i
> 5.5.5.5/32 45.1.1.5 0 0 5 i
> 200.1.1.0 2.2.2.2 0 1000 0 (23) 1 ?
> 200.1.4.0 2.2.2.2 0 100 0 (23) 1 i
R4#
R5#show ip bgp
BGP table version is 35, local router ID is 5.5.5.5
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal,
r RIB-failure, S Stale, m multipath, b backup-path, f RT-Filter,
x best-external, a additional-path, c RIB-compressed,
Origin codes: i - IGP, e - EGP, ? - incomplete
RPKI validation codes: V valid, I invalid, N Not found

 Network          Next Hop            Metric LocPrf Weight Path

> 1.1.1.1/32 45.1.1.4 0 100 1 i
> 5.5.5.5/32 0.0.0.0 0 32768 i
> 200.1.1.0 45.1.1.4 0 100 1 ?
R2(config)#route-map aa permit 10
R2(config-route-map)#set as prepend 10 20 30 40 50
R2(config-route-map)#exit
R2(config)#route-map aa per
R2(config)#route-map aa permit 20
R2(config-route-map)#set as prepend 30 40 50
R2#show ip bgp
BGP table version is 36, local router ID is 2.2.2.2
Status codes: s suppressed, d damped, h history,
valid, > best, i - internal,
r RIB-failure, S Stale, m multipath, b backup-path, f RT-Filter,
x best-external, a additional-path, c RIB-compressed,
Origin codes: i - IGP, e - EGP, ? - incomplete
RPKI validation codes: V valid, I invalid, N Not found

 Network          Next Hop            Metric LocPrf Weight Path

> 1.1.1.1/32 12.1.1.1 0 0 1 i
>i 5.5.5.5/32 3.3.3.3 0 100 0 (4) 5 i
> 200.1.0.0/22 0.0.0.0 3000 32768 {10,20,30,40,50,1} ?
> 200.1.1.0 12.1.1.1 0 1000 0 10 20 30 40 50 1 ?
> 200.1.2.0 12.1.1.1 0 2000 0 30 40 50 1 i
> 200.1.3.0 12.1.1.1 0 3000 0 1 i
*> 200.1.4.0 12.1.1.1 0 0 1 i
R2#show ip bgp 200.1.0.0
BGP routing table entry for 200.1.0.0/22, version 36
Paths: (1 available, best #1, table default, not advertised to any peer)
Not advertised to any peer
Refresh Epoch 1
{10,20,30,40,50,1}, (aggregated by 100 2.2.2.2)
0.0.0.0 from 0.0.0.0 (2.2.2.2)
Origin incomplete, localpref 3000, weight 32768, valid, aggregated, local, best
Community: internet 1:34464 3:3392 4:37856 no-advertise local-AS

原文地址:http://blog.51cto.com/13625527/2104126

时间: 2024-11-07 21:42:55

BGP聚合路由 执行最苛刻的条件的相关文章

配置OSPF发布聚合路由

1.组网需求 .. Switch A和SwitchB位于AS 200内,AS200内使用OSPF作为IGP协议. .. SwitchC.Switch D和SwitchE位于AS100内,AS 100内使用OSPF作为IGP协议. .. Switch B和SwitchC之间建立EBGP连接,配置BGP引入OSPF和直连路由,配置OSPF进程引入BGP路由. ..为了减小SwitchA的路由表规模,在SwitchB.上配置路由聚合,只发布聚合后的路由10.0.0.0/8.一:配置接口的IP地址二:配

OSPF发布聚合路由

1.13.3 配置OSPF发布聚合路由 组网需求? ? Switch A 和 Switch B 位于 AS 200 内,AS 200 内使用 OSPF 作为 IGP 协议.? ? Switch C.Switch D 和 Switch E 位于 AS 100 内,AS 100 内使用 OSPF 作为 IGP 协议.? ? Switch B 和 Switch C 之间建立 EBGP 连接,配置 BGP 引入 OSPF 和直连路由,配置 OSPF进程引入 BGP 路由.? ? 为了减小 Switch

BGP邻居路由条目数超限

背景:我们公司用的两条线路,其中一条是电信的MPLS线路,我们需要把路由传给电信的BGP路由,由电信的BGP路由协议进行传递到总部相应的路由表中.问题现象:突然电信的MPLS线路断了,然后NETCARE打电话过来报告故障,我还是以为光纤断了,就让NETCARE安排寻线.过了一段时间,邮件过来了,说我们发布的路由条目超过限制,正常我们是最多只能发布20条. 解决方案:我第一时间连上公司的核心交换机,查看路由发布情况.show ip route eigrp 1感觉没有不正常的路由发布呀.show i

乾颐堂军哥HCIE12-BGP的对等体组和BGP的路由操控理论和实验

BGP1.对等体组peer group出/入方向策略需要一致步骤:定义peer组: group QYT internal在组中添加内容,即命令或者策略peer QYT connect-interface LoopBack0peer QYT reflect-client针对一个邻居来调用peer组:peer 55.1.1.1 group QYT!bgp 345group QYT internalpeer QYT connect-interface LoopBack0peer 44.1.1.1 as

hcl ospf发布聚合路由配置

1.先配好个端口vlan及ip2.配置各个交换机及的ospf![]A(https://s1.51cto.com/images/blog/201905/26/bbfc5de1874804880d74f377f2f1204b.png?x-oss-process=image/watermark,size_16,text_QDUxQ1RP5Y2a5a6i,color_FFFFFF,t_100,g_se,x_10,y_10,shadow_90,type_ZmFuZ3poZW5naGVpdGk=)C3.配置

quagga源码学习--BGP协议路由更新

BGP的核心就是交换路由,所以关键的部分还是在路由的更新与撤销上面,这之间包含了冗长的属性,community等等处理过程,不做详述. bgp_read函数是路由更新的事件处理函数,在收到BGP_MSG_UPDATE消息的时候开始调用bgp_update_receive函数处理. 1 switch (i) { 2 case NLRI_UPDATE: 3 case NLRI_MP_UPDATE: 4 nlri_ret = bgp_nlri_parse(peer, NLRI_ATTR_ARG, &n

公用表(CTE)表达式引发的改变执行顺序同WHERE条件顺序引发的bug

以下模拟一下CTE出错 /*测试环境 Microsoft SQL Server 2008 R2 (RTM) - 10.50.1600.1 (X64) Apr 2 2010 15:48:46 Copyright (c) Microsoft Corporation Developer Edition (64-bit) on Windows NT 6.1 <X64> (Build 7601: Service Pack 1) */ 生成表Tab数据: --> --> (Roy)生成測試數據

BGP 的路由发布策略

BGP Speaker只把自己使用的路由通告给对等体.(BGP Speaker只选最优的路径给自己使用,即只将最优路由发布给对等体:) BGP Speaker从EBGP获得的路由会向自己的所有的BGP对等体通告(包括EBGP对等体和IBGP对等体). BGP Speaker从IBGP对等体获得的路由不向它的IBGP对等体通告. BGP Speaker从IBGP获得的路由是否通告给它的EBGP对等体要依IGP和BGP同步的情况来决定. 从IBGP获得的路由仅发布给它的EBGP对等体: 关闭BGP同

BGP的路由反射与BGP联盟

配置思路: 首先把IGP配置通 就是把路由配置好 然后才可以建立邻居 AR1 和 AR2 建立内部邻居 先配置小 AS 号然后再指定大 AS 号 然后用虚拟端口loopback IP 地址建立邻居注:不要忘记 指向邻居的端口改为loopback端口 AR2 和 AR1 建立内部邻居 先配置小 AS 号然后再指定大 AS 号 然后用虚拟端口loopback IP 地址建立邻居AR2 和 AR3 建立内部邻居 先配置小 AS 号然后再指定大 AS 号 然后用虚拟端口loopback IP 地址建立邻