- 0
- 0
- 约4.18千字
- 约 12页
- 2020-04-21 发布于湖北
- 举报
操纵 BGP AS-PATH 属性案例
BGP总是优先选择具有最短 AS路径的路由。本案例中,我们将配置 R1,将 1.0.0.0
通告给 R2、R3之前预先添加两个额外的 AS路径到 1.0.0.0 上( AS300、AS400)
具体配置如下:
//// r1 ////
int f2/0
ip ad 192.1.1.1 255.255.255.0
int f3/0
ip ad 193.1.1.1 255.255.255.0
int lo0
ip ad 1.1.1.1 255.255.255.0
int lo1
ip ad 2.2.2.2 255.255.255.0
router bgp 100
no syn
neighbor 192.1.1.2 remote-as 200
neighbor 193.1.1.3 remote-as 200
network 1.0.0.0
network 1.0.0.0
neighbor 193.1.1.3 route-map aspath out
access-list 1 permit 1.0.0.0 0.255.255.255
route-map aspath 10
match ip ad 1
set as-path prepend 300 400
route-map aspath 20
//// r2 ////
int f2/0
ip ad 192.1.1.2 255.255.255.0
int f4/0
ip ad 194.1.1.2 255.255.255.0
router os 1
netw 0.0.0.0 255.255.255.255 a 0
passive-interface f2/0
router bgp 200
no syn
neighbor 192.1.1.1 remote-as 100
neighbor 194.1.1.4 remote-as 200
neighbor 195.1.1.3 remote-as 200
neighbor 194.1.1.4 next-hop-self
//// r3 ////
int f3/0
ip ad 193.1.1.3 255.255.255.0
int f5/0
ip ad 195.1.1.3 255.255.255.0
router os 1
netw 0.0.0.0 255.255.255.255 a 0
passive-interface f3/0
router bgp 200
no syn
neighbor 193.1.1.1 remote-as 100
neighbor 195.1.1.4 remote-as 200
neighbor 195.1.1.4 next-hop-self
neighbor 194.1.1.2 remote-as 200
//// r4 ////
int f4/0
ip ad 194.1.1.4 255.255.255.0
int f5/0
ip ad 195.1.1.4 255.255.255.0
int lo0
ip ad 4.4.4.4 255.255.255.0
router os 1
netw 0.0.0.0 255.255.255.255 a 0
router bgp 200
no syn
neighbor 194.1.1.2 remote-as 200
neighbor 195.1.1.3 remote-as 200
netw 4.0.0.0
验证:
r3#sh ip b
Network Next Hop Metric
LocPrf Weight Path
*i1.0.0.0
您可能关注的文档
最近下载
- 2025年房地产经纪人线上渠道的获客成本计算专题试卷及解析.pdf VIP
- Rexroth博世力士乐GFT 8000 40系列行星减速机行走齿轮产品样本资料.pdf
- 风险控制岗位招聘笔试题及答案(某大型国企)2025年.docx VIP
- 精品解析:北京市朝阳区北京中学2025年统编版小升初考试语文试卷(原卷版).docx VIP
- 通用学术英语综合教程(读写)郑群课后习题答案解析.pdf VIP
- _中国古代舞蹈史.ppt
- 人教版新版小学二年级下册语文生字表课课贴【可打印】.pdf VIP
- 2025年四川省公务员考试行测真题答案及解析(完美打印版) .pdf VIP
- (2026春新版)苏教版二年级数学下册全册教案.docx
- 正压式空气呼吸器.pptx VIP
原创力文档

文档评论(0)