锐捷MPLS跨域方案A、B实验配置

news2025/8/13 3:43:58

目录

MPLS域内配置

MPLS域1配置

MPLS域2配置

域间方式A配置

域间方式B配置


MPLS隧道——跨域解决方案A、B讲解_静下心来敲木鱼的博客-CSDN博客_跨域a方案icon-default.png?t=M85Bhttps://blog.csdn.net/m0_49864110/article/details/127601807?spm=1001.2014.3001.5501


MPLS域内配置

MPLS域内配置同MPLS单域配置

MPLS域1配置

PE1配置

配置接口IP地址和IGP协议

int g0/0

no switchport

ip add 1.0.18.1 24

int g0/1

no switchport

ip add 1.0.12.1 24

int loop 0

ip add 1.1.1.1 32

router isis 1

net 49.0001.0000.0000.0001.00

int g0/1

ip router isis 1

int loop 0

ip router isis 1

配置LDP协议

mpls ip

 mpls router ldp

 ldp router-id interface loop 0 force

int g0/1

 label-switching

 mpls ip

配置Vpnv4的IBGP邻居

router bgp 100

bgp router-id 1.1.1.1

neighbor 3.3.3.3 remote-as 100

neighbor 3.3.3.3 update-source loop 0

address-family vpnv4 unicast

 neighbor 3.3.3.3 activate

 neighbor 3.3.3.3 send-community extended

address-family ipv4 unicast

  no neighbor 3.3.3.3 activate

配置与CE对接的实例与路由协议

ip vrf VPN-1

 rd 100:1

 route-target export 200:1

 route-target import 100:1

int g0/0

ip vrf forwarding VPN-1

ip add 1.0.18.1 24

route ospf 1 vrf VPN-1

area 0

network 1.0.18.0 0.0.0.255 area 0

将CE路由引入到BGP中

router bgp 100

address-family ipv4 vrf VPN-1

redistribute ospf 1 match internal external

将BGP路由引入到CE中

router ospf 1 vrf VPN-1

 redistribute bgp subnets

P2配置

配置接口IP地址和IGP协议

int g0/1

no switchport

ip add 1.0.12.2 24

int g0/0

no switchport

ip add 1.0.23.2 24

int loop 0

ip add 2.2.2.2 32

router isis 1

net 49.0001.0000.0000.0002.00

int g0/1

ip router isis 1

int g0/0

ip router isis 1

int loop 0

ip router isis 1

配置LDP协议

mpls ip

mpls router ldp

 ldp router-id interface loop 0 force

int g0/1

 label-switching

 mpls ip

int g0/0

 label-switching

 mpls ip

ASBR3配置

配置接口IP地址和IGP协议

int g0/1

no switchport

ip add 1.0.34.3 24

int g0/0

no switchport

ip add 1.0.23.3 24

int loop 0

ip add 3.3.3.3 32

router isis 1

net 49.0001.0000.0000.0003.00

int g0/0

ip router isis 1

int loop 0

ip router isis 1

配置LDP协议

mpls ip

mpls router ldp

 ldp router-id interface loop 0 force

int g0/0

 label-switching

 mpls ip

配置Vpnv4的IBGP邻居

router bgp 100

bgp router-id 3.3.3.3

neighbor 1.1.1.1 remote-as 100

neighbor 1.1.1.1 update-source loop 0

address-family vpnv4 unicast

 neighbor 1.1.1.1 activate

 neighbor 1.1.1.1 send-community extended

address-family ipv4 unicast

  no neighbor 1.1.1.1 activate

CE8配置

配置接口IP地址

int g0/0

no switchport

ip add 1.0.18.8 24

int loop 0

ip add 8.8.8.8 32

配置与PE对接的路由协议

router ospf 1

area 0

network 8.8.8.8 0.0.0.0 area 0

network 1.0.18.8 0.0.0.0 area 0

MPLS域2配置

PE6配置

配置接口IP地址和IGP协议

int g0/0

no switchport

ip add 1.0.67.6 24

int g0/1

no switchport

ip add 1.0.56.6 24

int loop 0

ip add 6.6.6.6 32

router isis 10

net 49.0002.0000.0000.0006.00

int g0/1

ip router isis 10

int loop 0

ip router isis 10

配置LDP协议

mpls ip

 mpls router ldp

 ldp router-id interface loop 0 force

int g0/1

 label-switching

 mpls ip

配置Vpnv4的IBGP邻居

router bgp 200

bgp router-id 6.6.6.6

neighbor 4.4.4.4 remote-as 200

neighbor 4.4.4.4 update-source loop 0

address-family vpnv4 unicast

 neighbor 4.4.4.4 activate

 neighbor 4.4.4.4 send-community extended

address-family ipv4 unicast

  no neighbor 4.4.4.4 activate

配置与CE对接的实例与路由协议

ip vrf VPN-2

 rd 200:1

 route-target export 100:1

 route-target import 200:1

int g0/0

ip vrf forwarding VPN-2

ip add 1.0.67.6 24

route ospf 1 vrf VPN-2

area 0

network 1.0.67.0 0.0.0.255 area 0

将CE路由引入到BGP中

router bgp 200

address-family ipv4 vrf VPN-2

redistribute ospf 1 match internal external

将BGP路由引入到CE中

router ospf 1 vrf VPN-2

 redistribute bgp subnets

P5配置

配置接口IP地址和IGP协议

int g0/1

no switchport

ip add 1.0.56.5 24

int g0/0

no switchport

ip add 1.0.45.5 24

int loop 0

ip add 5.5.5.5 32

router isis 10

net 49.0002.0000.0000.0005.00

int g0/1

ip router isis 10

int g0/0

ip router isis 10

int loop 0

ip router isis 10

配置LDP协议

mpls ip

mpls router ldp

 ldp router-id interface loop 0 force

int g0/1

 label-switching

 mpls ip

int g0/0

 label-switching

 mpls ip

ASBR4配置

配置接口IP地址和IGP协议

int g0/1

no switchport

ip add 1.0.34.4 24

int g0/0

no switchport

ip add 1.0.45.4 24

int loop 0

ip add 4.4.4.4 32

router isis 10

net 49.0002.0000.0000.0004.00

int g0/0

ip router isis 10

int loop 0

ip router isis 10

配置LDP协议

mpls ip

mpls router ldp

 ldp router-id interface loop 0 force

int g0/0

 label-switching

 mpls ip

配置Vpnv4的IBGP邻居

router bgp 200

bgp router-id 4.4.4.4

neighbor 6.6.6.6 remote-as 200

neighbor 6.6.6.6 update-source loop 0

address-family vpnv4 unicast

 neighbor 6.6.6.6 activate

 neighbor 6.6.6.6 send-community extended

address-family ipv4 unicast

  no neighbor 6.6.6.6 activate

CE7配置

配置接口IP地址

int g0/0

no switchport

ip add 1.0.67.7 24

int loop 0

ip add 7.7.7.7 32

配置与PE对接的路由协议

router ospf 1

area 0

network 7.7.7.7 0.0.0.0 area 0

network 1.0.67.7 0.0.0.0 area 0


域间方式A配置

方式A:在ASBR3和ASBR4上建立基于实例的EBGP邻居,将Vpnv4路由转为IPv4路由传递到其它域中

PE1-CE8对应的实例:              export 200:1   import 100:1

ASBR1-ASBR2对应的实例:      export 100:1   import 200:1

ASBR2-ASBR1对应的实例:      export 200:1   import 100:1

PE6-CE7对应的实例:              export 100:1   import 200:1

蓝色为ASBR3配置、紫色为ASBR4配置

ASBR1和ASBR2创建VPN实例

对于ASBR3来说,其im值需要与CE1的ex值匹配,其ex值需要与ASBR4的im值匹配

ip vrf VPN-3

  rd 300:1

route-target export 100:1

  route-target import 200:1

int g0/1

ip vrf forwarding VPN-3

ip add 1.0.34.3 24

ip vrf VPN-4

 rd 400:1

 route-target export 200:1

 route-target import 100:1

int g0/1

ip vrf forwarding VPN-4

ip add 1.0.34.4 24

ASBR1和ASBR2建立基于实例的EBGP邻居

router bgp 100

address-family ipv4 vrf VPN-3

neighbor 1.0.34.4 remote-as 200

neighbor 1.0.34.4 activate

router bgp 200

address-family ipv4 vrf VPN-4

neighbor 1.0.34.3 remote-as 100

neighbor 1.0.34.3 activate

Show ip bgp vrf VPN-3 summary此时ASBR的实例邻居已经建立成功

Show ip bgp vrf VPN-3此时ASBR已经获得了CE路由

此时CE7和CE8可以互相访问了


域间方式B配置

方式B:在ASBR3和ASBR4上建立VPNV4的EBGP邻居,直接将VPNV4路由传递给对端

PE1-CE8对应的实例:              export 200:1   import 100:1

PE6-CE7对应的实例:              export 100:1   import 200:1

蓝色为ASBR3配置、紫色为ASBR4配置

ASBR相连接口之间开启MPLS

int g0/1

 label-switching

 mpls ip

int g0/1

 label-switching

 mpls ip

ASBR建立Vpnv4的EBGP邻居

router bgp 100

neighbor 1.0.34.4 remote-as 200

address-family ipv4

no neighbor 1.0.34.4 activate

address-family vpnv4 unicast

neighbor 1.0.34.4 activate

router bgp 200

neighbor 1.0.34.3 remote-as 100

address-family ipv4

no neighbor 1.0.34.3 activate

address-family vpnv4 unicast

neighbor 1.0.34.3 activate

配置取消RT值检测

由于ASBR上没有配置实例,所以需要在ASBR上配置取消RT值检测

router bgp 200

address-family vpnv4 unicast

no bgp default route-target filter

router bgp 200

address-family vpnv4 unicast

no bgp default route-target filter

配置传递路由时更改下一跳为自身

由于从EBGP收到的路由传递给IBGP时,不会更改下一跳

例如:对于ASBR4从ASBR3学到的路由传递给PE6时,PE6收到的关于站点1的路由下一跳为ASBR3,对于PE6来说路由下一跳不可达,不会传递给CE7

此时就需要在ASBR上配置向IBGP邻居PE传递路由时将下一跳更改为自身(或者直接将ASBR的路由引入到BGP中传递给PE,不推荐)

router bgp 200

address-family vpnv4 unicast

neighbor 1.1.1.1 next-hop-self

router bgp 200

address-family vpnv4 unicast

neighbor 6.6.6.6 next-hop-self

 

此时CE之间可以互通

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.coloradmin.cn/o/33358.html

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈,一经查实,立即删除!

相关文章

同态加密库Seal库的安装(win11+VS2022)

先说一下,seal库是微软开发的同态加密库,目前支持三种算法bfv,bgv和ckks。提供的语言版本是C艹和C#。 工具准备 这是github上提供的要求。 要准备的东西有 vs2022(社区版就行了,网上一堆教程)&#xff0c…

使用 Python 和 Matplotlib下载美股数据

介绍: 提示:例如 这是关于使用机器学习创建交易策略的系列文章中的第一篇。关于机器学习在交易中的实际应用,我主要参考的是 Marco Lopez de Prado 的金融机器学习进展。 尽管在人工智能方面有多年经验,但我从未将其应用于交易…

Spring Boot中@Import三种使用方式

Import是一个非常有用的注解,它的长处在于你可以通过配置来控制是否注入该Bean,也可以通过条件来控制注入哪些Bean到Spring容器中。 比如我们熟悉的:EnableAsync 、EnableCaching、EnableScheduling等等统一采用的都是借助Import注解来实现的…

TMD,JVM类加载原来是这样的!!!!

接上篇:https://boxuegu.blog.csdn.net/article/details/128000217 通过字节码,我们了解了class文件的结构 通过运行数据区,我们了解了jvm内部的内存划分及结构 接下来,让我们看看,字节码怎么进入jvm的内存空间&…

电脑硬盘分区软件哪个好用,无损分区软件哪个好

为了合理地利用磁盘空间,会进行磁盘分区的操作。由于磁盘分区涉及到计算机相关的操作知识,很多的用户都不会。所以,只能借助于专业的磁盘分区工具,那么,电脑硬盘分区软件哪个好用?在本文中,易我…

走进常熟东南相互电子,看AI如何深入产业让工厂更智能

苏州常熟一家4万多平方米的生产车间内,一块块指甲盖大小的PCB电路板,在装有人工智能算法模型的的摄像头下,快速精准地完成外观检测,让头发丝大小的瑕疵无处可藏。 成立于2006年的东南相互电子,是一家集半导体与元器件…

ActiveMQ 反序列化漏洞(CVE-2015-5254)特征分析

介绍 Apache ActiveMQ是美国阿帕奇(Apache)软件基金会所研发的一套开源的消息中间件,它支持Java消息服务、集群、Spring Framework等。 Apache ActiveMQ 5.13.0之前5.x版本中存在安全漏洞,该漏洞源于程序没有限制可在代理中序列…

Flutter高仿微信-第37篇-单聊-红包

Flutter高仿微信系列共59篇,从Flutter客户端、Kotlin客户端、Web服务器、数据库表结构、Xmpp即时通讯服务器、视频通话服务器、腾讯云服务器全面讲解。 详情请查看 效果图: 详情请参考 Flutter高仿微信-第29篇-单聊 , 这里只是提取红包功能的…

第二章:Pythonocc官方demo 案例47(获取物体的最优的包容体)

源代码: #!/usr/bin/env python ## ##This file is part of pythonOCC. ## ##pythonOCC is free software: you can redistribute it and/or modify ##it under the terms of the GNU Lesser General Public License as published by ##the Free Software Foundati…

Hadoop笔记-02 安装

文章目录1 VBOX安装CentOS71.1 安装VBOX软件1.2 下载CentOS7镜像文件1.3 初始化VBOX虚拟盘1.4 CentOS7网络配置1.5 CentOS7 yum源配置1.6 CentOS7 一般配置1.6.1关闭防火墙1.6.2 修改hostname1.6.3 配置DNS绑定1.6.4 关闭selinux2 JDK等基础安装配置2.1 安装JDK前检查2.2 安装t…

《Happy Birthday》游戏开发记录(送给朋友的小礼物)

游戏开发的学习记录⑦ 项目:Happy Birthday (一个小小小游戏,基于unity给朋友做的一个生日小礼物🎁,之前都是礼物加信💌,今年想用自己的技能,把信的内容以另一种方式送给她。但在做…

STM32实战总结:HAL之modbus

什么是modbus? Modbus是一种串行通信协议,是Modicon公司(现在的施耐德电气 Schneider Electric)于1979年为使用可编程逻辑控制器(PLC)通信而发表。Modbus已经成为工业领域通信协议的业界标准(De…

OsgEarth3基础3D图形实现

OsgEarth3基础3D图形实现主要难点Geometry能力姿态支持任意立方体 PolygonCube矩形立方体 Box圆锥体 Cone圆柱体 Cylinder四棱锥 Pyramid球体 Sphere源码示例ElementGeometry圆锥Cone这里尝试在通过OsgEarth提供的各种图形绘制方法,实现基础的3D图形。每个图形除了基…

推荐一个非常实用的程序员导航网站,码农必备!

这是一个非常好用的程序员导航网站,拥有该网站,就拥有一站式导航,再也不用为找网址而发愁了! 先直接上网址:https://hao.panziye.com/ 现在来说说为什么推荐该程序员导航网站! 1、支持自定义导航网址 该…

pytorch的安装教程

1. 官网 pytorch.org 哎呀呀呀,这是嘛呀哪里有download的按钮啊 别急 ,往下拉就ok了哈哈 得看你自己电脑的配置了,自己选就行 、、注意哦 我们得复制一条指令 、 有anaconda的吧 在自己想要的环境里面 黏贴就行 有了 pytorch 可以干嘛呢…

Electron:BrowserView使用方法

我们知道,使用BrowserWindow来创建一个新的窗口,那么如果想在窗口中战胜斯更多的web内容,比如嵌入其他网站的内容,那就使用BrowserView了。 BrowserView的位置是相对于父窗口,比如: 代码如下:…

python项目使用pyinstaller打包

一、安装pyinstaller 打包要使用pyinstaller,使用pip来安装一下这个第三方库,打开命令行输入pip install pyinstaller 二、打包含有多个文件的python项目 1、首先打开电脑的cmd命令行,并切换到项目的根目录 项目路径输入cmd回车,可直接打开含有项目路径的cmd窗口 2、…

【推荐系统】行列式点过程(DPP)算法推导

一、背景 推荐系统主要解决用户和物品之间的相关性,以及推荐列表的多样性。相关性主要通过用户兴趣和物品之间的匹配程度来衡量,希望把用户感兴趣的物品推荐给用户,可以通过CTR预估模型来构建。多样性的衡量没有那么直观,一种方法…

std::unique_ptr(基础和仿写)

目录 一、C参考手册说明 1、解释注释 2、 参考代码 二、对std::unique_ptr分析 1、创建一个unique_ptr 2、无法进行复制构造和赋值操作 3、可以进行移动赋值 4.可以返回unique——ptr 5、管理动态数组 6、在容器中保存指针 三、对std::unique_ptr设计 1、对于的那个…

关于生命周期的面试题vue

1.第一次进入到页面(组件)会执行哪些生命周期 beforeCreate 》 没有data,没有elcreated 》 有data,没有elbeforeMount 》 有data,没有el(其实已经在准备了)mounted 》 有data,有el …