当前位置:网站首页>华为设备配置HoVPN
华为设备配置HoVPN
2022-06-11 21:34:00 【51CTO】

1. 配置IP地址
[UPE-LoopBack0]ip add 1.1.1.1 32
[UPE-GigabitEthernet0/0/0]ip add 20.1.1.1 24
[UPE-GigabitEthernet0/0/1]ip add 10.1.1.1 24
[SPE-LoopBack0]ip add 2.2.2.2 32
[SPE-GigabitEthernet0/0/0]ip add 20.1.1.2 24
[SPE-GigabitEthernet0/0/1]ip add 30.1.1.2 24
[PE]int LoopBack 0
[PE-LoopBack0]ip add 3.3.3.3 32
[PE-GigabitEthernet0/0/0]ip add 30.1.1.3 24
[PE-GigabitEthernet0/0/1]ip add 10.2.1.3 24
[CE1-GigabitEthernet0/0/0]ip add 10.1.1.4 24
[CE2-GigabitEthernet0/0/0]ip add 10.2.1.5 24
2. 在骨干网设备上配置OSPF,实现骨干网的IP连通性
[UPE]ospf 1
[UPE-ospf-1]area 0
[UPE-ospf-1-area-0.0.0.0]network 1.1.1.1 0.0.0.0
[UPE-ospf-1-area-0.0.0.0]network 20.1.1.0 0.0.0.255
[SPE]ospf 1
[SPE-ospf-1]area 0
[SPE-ospf-1-area-0.0.0.0]network 2.2.2.2 0.0.0.0
[SPE-ospf-1-area-0.0.0.0]network 30.1.1.0 0.0.0.255
[SPE-ospf-1-area-0.0.0.0]network 20.1.1.0 0.0.0.255
[PE]ospf 1
[PE-ospf-1]area 0
[PE-ospf-1-area-0.0.0.0]network 3.3.3.3 0.0.0.0
[PE-ospf-1-area-0.0.0.0]network 30.1.1.0 0.0.0.255
3. 在骨干网上配置MPLS基本能力和MPLS LDP,建立LDP LSP
[UPE]mpls lsr-id 1.1.1.1
[UPE]mpls
[UPE]mpls ldp
[UPE-GigabitEthernet0/0/0]mpls
[UPE-GigabitEthernet0/0/0]mpls ldp
[SPE]mpls lsr-id 2.2.2.2
[SPE]mpls
[SPE]mpls ldp
[SPE-GigabitEthernet0/0/0]mpls
[SPE-GigabitEthernet0/0/0]mpls ldp
[SPE-GigabitEthernet0/0/1]mpls
[SPE-GigabitEthernet0/0/1]mpls ldp
[PE]mpls lsr-id 3.3.3.3
[PE]mpls
[PE]mpls ldp
[PE-GigabitEthernet0/0/0]mpls
[PE-GigabitEthernet0/0/0]mpls ldp
4. 配置UPE与SPE、PE与SPE的MP-IBGP对等体关系
[UPE]bgp 100
[UPE-bgp]peer 2.2.2.2 as-number 100
[UPE-bgp]peer 2.2.2.2 connect-interface LoopBack 0
[UPE-bgp]ipv4-family vpnv4
[UPE-bgp-af-vpnv4]peer 2.2.2.2 enable
[SPE]bgp 100
[SPE-bgp]peer 1.1.1.1 as-number 100
[SPE-bgp]peer 1.1.1.1 connect-interface LoopBack 0
[SPE-bgp]peer 3.3.3.3 as-number 100
[SPE-bgp]peer 3.3.3.3 connect-interface LoopBack 0
[SPE-bgp]ipv4-family vpnv4
[SPE-bgp-af-vpnv4]peer 1.1.1.1 enable
[SPE-bgp-af-vpnv4]peer 3.3.3.3 enable
[PE]bgp 100
[PE-bgp]peer 2.2.2.2 as-number 100
[PE-bgp]peer 2.2.2.2 connect-interface LoopBack 0
[PE-bgp]ipv4-family vpnv4
[PE-bgp-af-vpnv4]peer 2.2.2.2 enable
5. UPE和PE上创建VPN实例,并与CE间配置EBGP
[UPE]ip vpn-instance vpna
[UPE-vpn-instance-vpna]ipv4-family
[UPE-vpn-instance-vpna-af-ipv4]route-distinguisher 100:1
[UPE-vpn-instance-vpna-af-ipv4]vpn-target 1:1
[UPE-GigabitEthernet0/0/1]ip binding vpn-instance vpna
[UPE-GigabitEthernet0/0/1]ip add 10.1.1.1 24
[UPE]bgp 100
[UPE-bgp]ipv4-family vpn-instance vpna
[UPE-bgp-vpna]peer 10.1.1.4 as-number 65410
[UPE-bgp-vpna]import-route direct
[CE1]bgp 65410
[CE1-bgp]peer 10.1.1.1 as-number 100
[CE1-bgp]import-route direct
[PE]ip vpn-instance vpna
[PE-vpn-instance-vpna]ipv
[PE-vpn-instance-vpna]ipv4-family
[PE-vpn-instance-vpna-af-ipv4]route-distinguisher 100:2
[PE-vpn-instance-vpna-af-ipv4]vpn-target 1:1
[PE-GigabitEthernet0/0/1]ip binding vpn-instance vpna
[PE-GigabitEthernet0/0/1]ip add 10.2.1.3 24
[PE]bgp 100
[PE-bgp]ipv4-family vpn-instance vpna
[PE-bgp-vpna]peer 10.2.1.5 as-number 65420
[PE-bgp-vpna]import-route direct
[CE2]bgp 65420
[CE2-bgp]peer 10.2.1.3 as-number 100
[CE2-bgp]import-route direct
6. SPE上配置VPN实例,指定UPE,并向UPE发布VPN实例的缺省路由
[SPE]ip vpn-instance vpna
[SPE-vpn-instance-vpna]route-distinguisher 200:1
[SPE-vpn-instance-vpna-af-ipv4]vpn-target 1:1
[SPE]bgp 100
[SPE-bgp]ipv4-family vpnv4
[SPE-bgp-af-vpnv4]peer 1.1.1.1 upe //指定自己的UPE
[SPE-bgp-af-vpnv4]peer 1.1.1.1 default-originate vpn-instance vpna //向UPE发布VPN实例的缺省路由
7. 检查配置


CE1上没有到CE2接口网段的路由,但有一条下一跳为UPE的缺省路由;CE2上有到CE1接口网段的BGP路由,CE1和CE2可以相互Ping通
看
到有一条VPN实例vpna的缺省路由,下一跳为SPE
边栏推荐
- CANN编码的一些报错汇编
- 8、 BOM - chapter after class exercises and answers
- 常用文件函数
- Refresh and upgrade | innovation, starting from cloud store
- The same efficiency tool for leading enterprises to promote smart finance. Let's have a quick look?
- Expérience 10 génération de courbes bezier - amélioration expérimentale - génération de courbes B - spline par point de contrôle
- JVM|前言介绍
- [Part 14] source code analysis and application details of completionservice class [key]
- Leetcode-129- sum of numbers from root node to leaf node
- Iros 2021 | new idea of laser vision fusion? Lidar intensity diagram +vpr
猜你喜欢

LabVIEW controls Arduino to realize ultrasonic ranging (advanced chapter-5)

Codeforces Round #744 (Div. 3) 解题报告

Why is rpa+ low code a powerful tool to accelerate the digital transformation of finance?

Codeworks round 744 (Div. 3) problem solving Report

LeetCode-104-二叉树的最大深度

How to use RPA robot to start the first step of digital transformation of freight forwarding industry?

servlet获取表单数据

JS performs non empty judgment on various data types of the returned data.

LeetCode-322-零钱兑换

Add personal statement for go file in file template in Golan
随机推荐
如何创建最简单的 SAP Kyma Function
UML系列文章(29)体系结构建模---模式和框架
Using the sap ui5 cli command line tool to build and run SAP ui5 applications
Expérience 10 génération de courbes bezier - amélioration expérimentale - génération de courbes B - spline par point de contrôle
AC自动机
Object creation process of JVM
Codeforces Round #742 (Div. 2) F. One-Four Overload
【C语言进阶】整型在内存中的存储
Flutter series: detailed explanation of container layout commonly used in flutter
JVM|运行时数据区;程序计数器(PC寄存器);
String copy function
关于斜率优化
Leetcode-32- longest valid bracket
Codeforces Round #744 (Div. 3) 解题报告
12 golden rules of growth
Leetcode-98- validate binary search tree
As a senior abap consultant, which SAP technology can be selected as the main direction in the next step?
LabVIEW Arduino电子称重系统(项目篇—1)
JUnit tests multithreaded code, and the sub thread does not run
js对返回的数据的各种数据类型进行非空判断。