IT数码 购物 网址 头条 软件 日历 阅读 图书馆
TxT小说阅读器
↓语音阅读,小说下载,古典文学↓
图片批量下载器
↓批量下载图片,美女图库↓
图片自动播放器
↓图片自动播放器↓
一键清除垃圾
↓轻轻一点,清除系统垃圾↓
开发: C++知识库 Java知识库 JavaScript Python PHP知识库 人工智能 区块链 大数据 移动开发 嵌入式 开发工具 数据结构与算法 开发测试 游戏开发 网络协议 系统运维
教程: HTML教程 CSS教程 JavaScript教程 Go语言教程 JQuery教程 VUE教程 VUE3教程 Bootstrap教程 SQL数据库教程 C语言教程 C++教程 Java教程 Python教程 Python3教程 C#教程
数码: 电脑 笔记本 显卡 显示器 固态硬盘 硬盘 耳机 手机 iphone vivo oppo 小米 华为 单反 装机 图拉丁
 
   -> 网络协议 -> MPLS-VPN实验 -> 正文阅读

[网络协议]MPLS-VPN实验

请添加图片描述

实验要求

1.如图连接拓扑,合理规划IP地址,R1、R5、R6、R7各种创建一个环回,IP地址分别为192.168.1.0 、192.168.2.0、192.168.3.0、192.168.4.0
2.AS 100内使用IGP协议为OSPF ,如图运行动态路由协议
3.要求R1-R5之间启用MPLS VPN ; R6-R7之间启用MPLS VPN;
4.将两条VPN 进行合并
5.R6-R7之间使用OSPF协议,要求R6-R7之间的私有IP地址通信优先使用MPLS

实验拓扑搭建

在这里插入图片描述

相关配置

AR1

interface GigabitEthernet0/0/0
ip address 12.1.1.1 255.255.255.0

interface GigabitEthernet0/0/1

interface GigabitEthernet0/0/2

interface NULL0

interface LoopBack0
ip address 192.168.1.1 255.255.255.255

interface LoopBack1

rip 100
undo summary
version 2
network 12.0.0.0
network 192.168.1.0

AR2

ip vpn-instance a
ipv4-family
route-distinguisher 100:1
vpn-target 100:1 1:1 export-extcommunity
vpn-target 100:1 1:1 import-extcommunity

ip vpn-instance b
ipv4-family
route-distinguisher 100:2
vpn-target 100:2 1:1 export-extcommunity
vpn-target 100:2 1:1 import-extcommunity

mpls lsr-id 2.2.2.2
mpls
lsp-trigger all

mpls ldp

interface GigabitEthernet0/0/0
ip binding vpn-instance b
ip address 12.1.1.2 255.255.255.0

interface GigabitEthernet0/0/1
ip binding vpn-instance a
ip address 26.1.1.2 255.255.255.0

interface GigabitEthernet0/0/2
ip address 23.1.1.1 255.255.255.0
mpls
mpls ldp

interface NULL0

interface LoopBack0
ip address 2.2.2.2 255.255.255.255
ospf network-type broadcast

interface LoopBack1
ip binding vpn-instance a
ip address 10.1.1.1 255.255.255.255

bgp 100
router-id 2.2.2.2
peer 4.4.4.4 as-number 100
peer 4.4.4.4 connect-interface LoopBack0

ipv4-family unicast
undo synchronization
peer 4.4.4.4 enable
peer 4.4.4.4 next-hop-local

ipv4-family vpnv4
policy vpn-target
peer 4.4.4.4 enable
peer 4.4.4.4 advertise-community

ipv4-family vpn-instance a
network 10.1.1.1 255.255.255.255
import-route ospf 200

ipv4-family vpn-instance b
import-route rip 100

ospf 1

ospf 100
area 0.0.0.0
network 2.2.2.2 0.0.0.0
network 23.1.1.1 0.0.0.0

ospf 200 router-id 92.2.2.2 vpn-instance a
import-route bgp
area 0.0.0.0
network 26.1.1.2 0.0.0.0
sham-link 10.1.1.1 10.1.1.2

rip 100 vpn-instance b
version 2
network 12.0.0.0
import-route bgp

route recursive-lookup tunnel

AR3

interface GigabitEthernet0/0/0
ip address 34.1.1.1 255.255.255.0
mpls
mpls ldp

interface GigabitEthernet0/0/1

interface GigabitEthernet0/0/2
ip address 23.1.1.2 255.255.255.0
mpls
mpls ldp

interface NULL0

interface LoopBack0
ip address 3.3.3.3 255.255.255.255
ospf network-type broadcast

ospf 1

ospf 100
area 0.0.0.0
network 3.3.3.3 0.0.0.0
network 23.1.1.2 0.0.0.0
network 34.1.1.1 0.0.0.0

AR4

ip vpn-instance a
ipv4-family
route-distinguisher 100:1
vpn-target 100:1 1:1 export-extcommunity
vpn-target 100:1 1:1 import-extcommunity

ip vpn-instance b
ipv4-family
route-distinguisher 100:2
vpn-target 100:2 1:1 export-extcommunity
vpn-target 100:2 1:1 import-extcommunity

mpls lsr-id 4.4.4.4
mpls
lsp-trigger all

mpls ldp

aaa
authentication-scheme default
authorization-scheme default
accounting-scheme default
domain default
domain default_admin
local-user admin password cipher % % K8m.Nt84DZ}e#<0`8bmE3Uw}% %
local-user admin service-type http

firewall zone Local
priority 15

interface GigabitEthernet0/0/0
ip address 34.1.1.2 255.255.255.0
mpls
mpls ldp

interface GigabitEthernet0/0/1
ip binding vpn-instance b
ip address 45.1.1.2 255.255.255.0

interface GigabitEthernet0/0/2
ip binding vpn-instance a
ip address 47.1.1.2 255.255.255.0

interface NULL0

interface LoopBack0
ip address 4.4.4.4 255.255.255.255
ospf network-type broadcast

interface LoopBack1
ip binding vpn-instance a
ip address 10.1.1.2 255.255.255.255

bgp 100
router-id 4.4.4.4
peer 2.2.2.2 as-number 100
peer 2.2.2.2 connect-interface LoopBack0
peer 45.1.1.1 as-number 5
peer 47.1.1.1 as-number 7

ipv4-family unicast
undo synchronization
peer 2.2.2.2 enable
peer 2.2.2.2 next-hop-local
peer 45.1.1.1 enable
peer 47.1.1.1 enable

ipv4-family vpnv4
policy vpn-target
peer 2.2.2.2 enable

ipv4-family vpn-instance a
network 10.1.1.2 255.255.255.255
import-route ospf 200

ipv4-family vpn-instance b
import-route rip 100

ospf 100
area 0.0.0.0
network 4.4.4.4 0.0.0.0
network 34.1.1.2 0.0.0.0

ospf 200 router-id 94.4.4.4 vpn-instance a
import-route bgp
area 0.0.0.0
network 47.1.1.2 0.0.0.0
sham-link 10.1.1.2 10.1.1.1

rip 100 vpn-instance b
version 2
network 45.0.0.0
import-route bgp

route recursive-lookup tunnel

AR5

interface GigabitEthernet0/0/0

interface GigabitEthernet0/0/1
ip address 45.1.1.1 255.255.255.0

interface GigabitEthernet0/0/2

interface NULL0

interface LoopBack0
ip address 192.168.2.1 255.255.255.255

rip 100
undo summary
version 2
network 45.0.0.0
network 192.168.2.0

AR6

interface GigabitEthernet0/0/0
ip address 67.1.1.1 255.255.255.0
ospf cost 5

interface GigabitEthernet0/0/1
ip address 26.1.1.1 255.255.255.0

interface GigabitEthernet0/0/2

interface NULL0

interface LoopBack0
ip address 192.168.3.1 255.255.255.255

ospf 1
import-route ospf 200
area 0.0.0.0
network 67.1.1.1 0.0.0.0

ospf 200
area 0.0.0.0
network 26.1.1.1 0.0.0.0
network 192.168.3.1 0.0.0.0

AR7

interface GigabitEthernet0/0/0
ip address 67.1.1.2 255.255.255.0
ospf cost 5

interface GigabitEthernet0/0/1

interface GigabitEthernet0/0/2
ip address 47.1.1.1 255.255.255.0

interface NULL0

interface LoopBack0
ip address 192.168.4.1 255.255.255.255

ospf 1
import-route ospf 200
area 0.0.0.0
network 67.1.1.2 0.0.0.0

ospf 200
area 0.0.0.0
network 47.1.1.1 0.0.0.0
network 192.168.4.1 0.0.0.0

测试

AS 100内使用IGP协议为OSPF ,R2/R3/R4邻居关系
在这里插入图片描述
要求R1-R5之间启用MPLS VPN ; R6-R7之间启用MPLS VPN;
在这里插入图片描述请添加图片描述
请添加图片描述

将两条VPN 进行合并R1/R5/R6/R7之间可以相互访问
在这里插入图片描述

R6-R7之间使用OSPF协议,要求R6-R7之间的私有IP地址通信优先使用MPLS请添加图片描述
请添加图片描述

请添加图片描述

  网络协议 最新文章
使用Easyswoole 搭建简单的Websoket服务
常见的数据通信方式有哪些?
Openssl 1024bit RSA算法---公私钥获取和处
HTTPS协议的密钥交换流程
《小白WEB安全入门》03. 漏洞篇
HttpRunner4.x 安装与使用
2021-07-04
手写RPC学习笔记
K8S高可用版本部署
mySQL计算IP地址范围
上一篇文章      下一篇文章      查看所有文章
加:2021-08-16 12:04:52  更:2021-08-16 12:07:13 
 
开发: C++知识库 Java知识库 JavaScript Python PHP知识库 人工智能 区块链 大数据 移动开发 嵌入式 开发工具 数据结构与算法 开发测试 游戏开发 网络协议 系统运维
教程: HTML教程 CSS教程 JavaScript教程 Go语言教程 JQuery教程 VUE教程 VUE3教程 Bootstrap教程 SQL数据库教程 C语言教程 C++教程 Java教程 Python教程 Python3教程 C#教程
数码: 电脑 笔记本 显卡 显示器 固态硬盘 硬盘 耳机 手机 iphone vivo oppo 小米 华为 单反 装机 图拉丁

360图书馆 购物 三丰科技 阅读网 日历 万年历 2024年5日历 -2024/5/17 15:59:05-

图片自动播放器
↓图片自动播放器↓
TxT小说阅读器
↓语音阅读,小说下载,古典文学↓
一键清除垃圾
↓轻轻一点,清除系统垃圾↓
图片批量下载器
↓批量下载图片,美女图库↓
  网站联系: qq:121756557 email:121756557@qq.com  IT数码