当前位置:网站首页>BGP solves routing black hole through MPLS
BGP solves routing black hole through MPLS
2022-08-02 08:22:00 【not very smart】
目录
The construction of the topology andIP地址的规划
实验要求:
The construction of the topology andIP地址的规划
First experiment requirementAS2Network segment address based on172.16.0.0/16划分,This segment is very big,We are free to draw,怎么舒服怎么来,But as far as possible to ensure the reasonable utilization,Reduce waste address.
According to the above complete topology structures, and the division of address
IGP配置
先在AS2内部使用OSPF使AS2内部互通,View the routing table after the completion of,Ensure internal cut up to
BGP配置
R1与R2、R5Built between adjacent,R2、R5、R7Between two adjacent building,R7与R8Build adjacent each other
Direct built adjacent
[R1]bgp 1
[R1-bgp] peer 12.1.1.2 as-number 2 (The other side of the physical interfaceIP及AS号)
环回接口建邻
[R2]bgp 2
[R2-bgp]peer 172.16.1.13 as-number 2
[R2-bgp]peer 172.16.1.13 connect-interface LoopBack 0
[R2-bgp]peer 172.16.1.13 next-hop-local
According to the above operation is completed after configuration,Can view the neighbor table
R1
R5
MPLS配置
通过mpls Solve the control plane can reach inaccessible data level
[r2]mpls lsr-id 172.16.0.1
(必须先定义mpls的router-id,要为本地设备的真实ip地址,且邻居可达)
[r2]mpls 再开启mpls协议
[r2]mpls ldp
[r2-mpls-ldp]q
之后需要在所有标签经过的接口上开启协议
[r2]interface GigabitEthernet 0/0/1
[r2-GigabitEthernet0/0/1]mpls 先开启MPLS
[r2-GigabitEthernet0/0/1]mpls ldp 再激活LDP协议
AS2Each of the router configuration according to the operating neighbor relationship
建立后可以通过“display mpls ldp peer”查看邻居表
BGPAnnouncement and routing
首先R1与R8Does not affect directly declare
[R1]bgp 1
[R1-bgp]ne
[R1-bgp]network 1.1.1.0 24
AS2The topic request:R1访问R2、3、4The user segment byR5,访问R5、6、7网段通过R1,So to do routing policy
此处可以借助BGPRouting rules to reduce the amount of configuration, 由于R2与R5之间为IBGP关系,且通过IBGPNeighbors routing in passed to learnEBGPNeighbors will erase properties,MEDValue will not show,In the routing table is equivalent to /0,So I can take this,只在R2上宣告2、3、4用户网段,R2传给R5再传给R1Routing will be better thanR2直接传给R1的,R1会将R5Add table,从而满足题目要求,同理在R5上宣告5、6、7用户网段.但是2与5The user segment withR1Was built directly connected neighbors,So they proclaimed routingMED值为0,与通过IBGPLearning is the same,So will compareRouter id,R5的大于R2所以5The road user segment to choose the right,只需修改2的用户网段
[R2]ip ip-prefix a permit 172.16.2.0 24 (抓取流量)
[R2]route-policy a permit node 10
[R2-route-policy]if-match ip-prefix med
[R2-route-policy]apply cost 1
[R2]route-policy a permit node 20 (建立空表)去BGP调用
[R2]bgp 2
[R2-bgp]peer 12.1.1.1 route-policy a export (出方向调用)
此时可以在R1上查看
Can see the requirements and existing backup
Can also add a summary to the backup
[R2-bgp]aggregate 172.16.0.0 16 detail-suppressed
再到R1上查看
You can see the summary
最后进行测试
边栏推荐
猜你喜欢
MySQL-Execution Process + Cache + Storage Engine
MFC最详细入门教程[转载]
PanGu-Coder: A function-level code generation model
暂未找到具体原因但解决了的bug
Biotin-C6-amine|N-生物素基-1,6-己二胺|CAS:65953-56-2
MySQL事务(transaction) (有这篇就足够了..)
研发过程中的文档管理与工具
WebForm DropDownList分别绑定年月
CASA模型、CENTURY模型应用与案例分析
牛客2022 暑期多校4 D Jobs (Easy Version)(递推优化策略)
随机推荐
Xilinx Constraint Study Notes - Timing Constraints
小说里的编程 【连载之二十五】元宇宙里月亮弯弯
用C写小游戏(三子棋)
理论问题与工程问题的差异在哪里?
ROS file system and related commands
MySQL事务(transaction) (有这篇就足够了..)
HCIP 第五天
离线部署通过tiup 配置好topology.yaml文件指定PD TV TIDBserver 是不是会自动在其他机器创建好对应得模块?
Seleniu截图代码以及给图片赋值名字
通过建立新的SaaS业务来推动增长的六种方法
flutter 参数传一个范型数据
18、优化网站性能
按键控制流水灯(计时器)
Metasploit (MSF) Basic Super Detailed Edition
OSPF 综合实验
ROS文件系统以及相关命令
WebForm DropDownList分别绑定年月
.NET静态代码织入——肉夹馍(Rougamo) 发布1.1.0
HCIP第一天
读入、输出优化