华为+sr-mpls BE简单配置案例

网络规划设计

1、不开ldp协议,只开mpls

2、使用ospf 10类lsa传递

3、私网互通

NE1配置

pe1\]dis current-configuration sysname pe1 ip vpn-instance a ipv4-family route-distinguisher 1:1 tnl-policy p1 //调用隧道策略,让本实例走这个隧道策略 vpn-target 1:1 export-extcommunity vpn-target 1:1 import-extcommunity mpls lsr-id 1.1.1.1 mpls //只开mpls不开ldp segment-routing //开段路由功能 interface Ethernet1/0/0 undo shutdown ip address 10.0.12.1 255.255.255.0 ospf enable 1 area 0.0.0.0 undo dcn undo dcn mode vlan interface Ethernet1/0/1 undo shutdown ip binding vpn-instance a ip address 10.0.11.1 255.255.255.0 undo dcn undo dcn mode vlan interface LoopBack0 ip address 1.1.1.1 255.255.255.255 ospf enable 1 area 0.0.0.0 ospf prefix-sid index 1 //SID偏移值,每台设备都不能一样 interface NULL0 bgp 100 peer 3.3.3.3 as-number 100 peer 3.3.3.3 connect-interface LoopBack0 ipv4-family unicast undo synchronization peer 3.3.3.3 enable ipv4-family vpnv4 policy vpn-target peer 3.3.3.3 enable //建立vpnv4邻居 ipv4-family vpn-instance a peer 10.0.11.2 as-number 65100 //和ce设备建立 实例bgp ospf 1 opaque-capability enable //开10类lsa功能 segment-routing mpls //支持段路由mpls segment-routing global-block 16000 23999 //SRGB范围设置,所设备最好是一样,通过这个加上偏移值进行区分 area 0.0.0.0 tunnel-policy p1 //定义隧道策略强制使用sr-lsp,并设置ecmp负载 tunnel select-seq sr-lsp load-balance-number 2 NE2配置 sysname p mpls lsr-id 2.2.2.2 mpls segment-routing interface Ethernet1/0/0 undo shutdown ip address 10.0.12.2 255.255.255.0 ospf enable 1 area 0.0.0.0 undo dcn undo dcn mode vlan interface Ethernet1/0/1 undo shutdown ip address 10.0.23.2 255.255.255.0 ospf enable 1 area 0.0.0.0 undo dcn undo dcn mode vlan interface LoopBack0 ip address 2.2.2.2 255.255.255.255 ospf enable 1 area 0.0.0.0 ospf prefix-sid index 2 interface NULL0 ospf 1 opaque-capability enable segment-routing mpls segment-routing global-block 16000 23999 area 0.0.0.0 NE3配置 \[pe2\]dis current-configuration sysname pe2 ip vpn-instance a ipv4-family route-distinguisher 2:1 tnl-policy p1 vpn-target 1:1 export-extcommunity vpn-target 1:1 import-extcommunity segment-routing interface Ethernet1/0/0 undo shutdown ip address 10.0.23.3 255.255.255.0 ospf enable 1 area 0.0.0.0 undo dcn undo dcn mode vlan interface Ethernet1/0/1 undo shutdown ip binding vpn-instance a ip address 10.0.32.3 255.255.255.0 undo dcn undo dcn mode vlan interface LoopBack0 ip address 3.3.3.3 255.255.255.255 ospf enable 1 area 0.0.0.0 ospf prefix-sid index 3 interface NULL0 bgp 100 peer 1.1.1.1 as-number 100 peer 1.1.1.1 connect-interface LoopBack0 ipv4-family unicast undo synchronization peer 1.1.1.1 enable ipv4-family vpnv4 policy vpn-target peer 1.1.1.1 enable ipv4-family vpn-instance a peer 10.0.32.2 as-number 65101 ospf 1 opaque-capability enable segment-routing mpls segment-routing global-block 16000 23999 area 0.0.0.0 tunnel-policy p1 tunnel select-seq sr-lsp load-balance-number 2 CE就是普通bgo配置,比较简单省略!!! 结果验证 ![在这里插入图片描述](https://i-blog.csdnimg.cn/direct/026943c873a641d0b19f7f4a78fded07.png) ![在这里插入图片描述](https://i-blog.csdnimg.cn/direct/7d46eb1c284f434d8135b796bfa8e8a4.png) 互通测试 ![在这里插入图片描述](https://i-blog.csdnimg.cn/direct/7f2d8d920c2c48179ac2dd0d1aeacfa8.png) ![在这里插入图片描述](https://i-blog.csdnimg.cn/direct/61253306f6134ce5835ec7eb067dba77.png)

相关推荐
小白跃升坊2 小时前
基于1Panel的AI运维
linux·运维·人工智能·ai大模型·教学·ai agent
MMME~2 小时前
Ansible Playbook高效自动化实战指南
网络·自动化·ansible
数据安全科普王2 小时前
从 HTTP/1.1 到 HTTP/3:协议演进如何改变 Web 性能?
网络·其他
杨江2 小时前
seafile docker安装说明
运维
舰长1152 小时前
linux 实现文件共享的实现方式比较
linux·服务器·网络
好好沉淀2 小时前
Docker开发笔记(详解)
运维·docker·容器
学***54232 小时前
如何轻松避免网络负载过大
开发语言·网络·php
weixin_395448912 小时前
main.c_cursor_0129
前端·网络·算法
zmjjdank1ng2 小时前
Linux 输出重定向
linux·运维
路由侠内网穿透.2 小时前
本地部署智能家居集成解决方案 ESPHome 并实现外部访问( Linux 版本)
linux·运维·服务器·网络协议·智能家居