MPLS技术架构
mpls vpn全新vpn改变了包的格式,在2.5层,介于ip和2层之间,4bytes的标签.
mpls:多协议标签交换,为了解决快速路由,帧模式mpls.
ldp:标签分发协议,只能为igp路由分发标签.
bgp有分发标签的能力,为ipv4分发标签.
cef:思科快速转发,ip cef没开,标签没办法分发.
实验:
r1:
int lo0
ip add 11.1.1.1 255.255.255.255
int f1/0
ip add 12.1.1.1 255.255.255.0
no sh
int s2/0
ip add 10.1.1.1 255.255.255.0
r2:
int lo0
ip add 22.1.1.1 255.255.255.255
int f1/0
ip add 12.1.1.2 255.255.255.0
int s2/0
ip add 10.1.1.2 255.255.255.0
no sh
int f0/0
ip add 24.1.1.2 255.255.255.0
no sh
int s2/1
ip add 23.1.1.2 255.255.255.0
r3:
int lo0
ip add 33.1.1.1 255.255.255.255
int s2/0
ip add 23.1.1.3 255.255.255.0
int f0/0
ip add 35.1.1.3 255.255.255.0
int f1/0
ip add 34.1.1.3 255.255.255.0
r4:
int lo0
ip add 44.1.1.1 255.255.255.255
int f1/0
ip add 34.1.1.4 255.255.255.0
int f0/0
ip add 24.1.1.4 255.255.255.0
r5:
int lo0
ip add 55.1.1.1 255.255.255.255
int f0/0
ip add 35.1.1.5 255.255.255.0
no sh
r1:
router ospf 110
network 0.0.0.0 0.0.0.0 area 0
r2:
router ospf 110
network 0.0.0.0 0.0.0.0 area 0
r3:
router ospf 110
network 0.0.0.0 0.0.0.0 area 0
r4:
router ospf 110
network 0.0.0.0 0.0.0.0 area 0
r5:
router ospf 110
network 0.0.0.0 0.0.0.0 area 0
r1:
ip cef
mpls label range 100 199(可选项分发标签的范围)
int f1/0
mpls ip
r2:
ip cef
mpls label range 200 299
int f1/0
mpls ip
int f0/0
mpls ip
r3:
ip cef
mpls label range 300 399
int s2/1
mpls ip
int f1/0
mpls ip
r4:
ip cef
mpls label range 400 499
int f0/0
mpls ip
int f1/0
mpls ip
r5:
ip cef
mpls label range 500 599
r1:
show mpls forwarding-table(查看mpls转发表)
traceroute 55.1.1.1
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· TypeScript + Deepseek 打造卜卦网站:技术与玄学的结合
· 阿里巴巴 QwQ-32B真的超越了 DeepSeek R-1吗?
· 【译】Visual Studio 中新的强大生产力特性
· 10年+ .NET Coder 心语 ── 封装的思维:从隐藏、稳定开始理解其本质意义
· 【设计模式】告别冗长if-else语句:使用策略模式优化代码结构