CN103634423B - Three-layered interface based MPLS-TP (multi-protocol label switching-transport profile) configuration method and device - Google Patents

Three-layered interface based MPLS-TP (multi-protocol label switching-transport profile) configuration method and device Download PDF

Info

Publication number
CN103634423B
CN103634423B CN201310647325.4A CN201310647325A CN103634423B CN 103634423 B CN103634423 B CN 103634423B CN 201310647325 A CN201310647325 A CN 201310647325A CN 103634423 B CN103634423 B CN 103634423B
Authority
CN
China
Prior art keywords
information
label
mac address
destination mac
vlan
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201310647325.4A
Other languages
Chinese (zh)
Other versions
CN103634423A (en
Inventor
邵继超
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Kyland Technology Co Ltd
Original Assignee
Kyland Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Kyland Technology Co Ltd filed Critical Kyland Technology Co Ltd
Priority to CN201310647325.4A priority Critical patent/CN103634423B/en
Publication of CN103634423A publication Critical patent/CN103634423A/en
Application granted granted Critical
Publication of CN103634423B publication Critical patent/CN103634423B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Small-Scale Networks (AREA)

Abstract

本发明实施例提供一种基于三层接口的MPLS‑TP配置方法及装置,该方法包括:根据自身保存的标签地址表中的VLAN接口信息,通过该每个VLAN接口发送该标签信息的ARP请求报文;接收返回的该标签信息的ARP回复报文,将该ARP回复报文中携带的MAC地址信息及出端口信息与标签地址表中的信息进行比较,当确定与标签地址表中的目的MAC地址信息及出端口信息不一致时,对标签地址表进行更新。由于在本发明实施例中通过建立标签信息、下一跳IP地址信息、VLAN 信息、出端口信息及目的MAC地址信息的映射列表,当网络拓扑变化时,能及时更新标下一跳节点的信息,从而大大提高了PTN 设备配置的灵活性。

The embodiment of the present invention provides a MPLS-TP configuration method and device based on a layer-3 interface. The method includes: sending an ARP request for the label information through each VLAN interface according to the VLAN interface information in the label address table stored by itself. message; receive the returned ARP reply message of the label information, compare the MAC address information and outbound port information carried in the ARP reply message with the information in the label address table, and when it is determined that it is consistent with the purpose in the label address table When the MAC address information and the outgoing port information are inconsistent, update the label address table. Because in the embodiment of the present invention, by establishing the mapping list of label information, next-hop IP address information, VLAN information, outgoing port information and destination MAC address information, when the network topology changes, the information of the next-hop node can be updated in time , thus greatly improving the flexibility of PTN equipment configuration.

Description

一种基于三层接口的MPLS-TP配置方法及装置An MPLS-TP configuration method and device based on a layer-3 interface

技术领域technical field

本发明涉及工业网络通讯技术领域,尤其涉及一种基于三层接口的MPLS-TP配置方法及装置。The invention relates to the technical field of industrial network communication, in particular to an MPLS-TP configuration method and device based on a three-layer interface.

背景技术Background technique

3G传输以及数据通讯IP化的大规模应用,丰富了基于包交换技术的飞速发展。基于多协议标签交换通信构架(Multi-Protocol Label Switching - Transport Profile,MPLS-TP)的二层虚拟专用网络(Virtual Private Network,VPN)解决方案克服了传统的ATM或FR网络中扩展复杂的缺点,MPLS-TP VPN通过使用标签栈技术,可以在一条分层服务提供程序(Layered Service Provider ,LSP)中复用多条虚电路,供应商边缘(PE)只要维护一条LSP信息,因此大大提高了系统的可扩展性。MPLS-TP L2 VPN降低了VPN业务开通复杂度,增强了安全性,特别是在现有的VPN中增加站点时,在大多数情况下只需把供应商边缘路由器连接到新站点上即可,相应的减小了业务提供的周期。The large-scale application of 3G transmission and IP data communication has enriched the rapid development of packet switching technology. The Layer 2 virtual private network (Virtual Private Network, VPN) solution based on Multi-Protocol Label Switching - Transport Profile (MPLS-TP) overcomes the shortcomings of traditional ATM or FR network expansion complexity, By using the label stack technology, MPLS-TP VPN can multiplex multiple virtual circuits in a layered service provider (Layered Service Provider, LSP), and the provider edge (PE) only needs to maintain one LSP information, thus greatly improving the system scalability. MPLS-TP L2 VPN reduces the complexity of VPN service provisioning and enhances security, especially when adding sites to the existing VPN, in most cases it is only necessary to connect the provider edge router to the new site, Correspondingly, the cycle of service provision is reduced.

通过采用MPLS-TP技术,可以在多元融合的网络中运行二层VPN、三层VPN、流量工程及Diffserv等许多业务,基于第二层的MPLS-TP VPN解决方案提供了运营商网络和客户的VPN网络之间的完全独立,也就是说,运营商边界的PE设备和用户边缘 (CE)设备之间没有进行路由交换,运营商只是简单向客户提供一些基于二层的网络功能。从客户的角度看运营商也只是简单提供了一个简单的二层连接。By adopting MPLS-TP technology, many services such as Layer 2 VPN, Layer 3 VPN, traffic engineering and Diffserv can be run in the multi-converged network. The MPLS-TP VPN solution based on the second layer provides The VPN networks are completely independent, that is, there is no routing exchange between the PE equipment at the operator's border and the user edge (CE) equipment, and the operator simply provides some Layer 2-based network functions to customers. From the customer's point of view, the operator simply provides a simple Layer 2 connection.

而在基于MPLS-TP技术应用的PTN设备的应用中,本节点和对端节点的端口之间需要获得对端的MAC地址,用于封装MPLS报文的目的MAC地址,对端设备接收到MPLS报文后识别报文中的目的MAC地址是否是本节点的MAC地址,然后才进行业务标签的鉴别,并且MPLS-TP的OAM标准G.8113.1正式定义不久,相应的产品还不够成熟,因此,已有的软件平台的OAM功能兼容性及灵活性都不尽如人意。In the application of PTN equipment based on the application of MPLS-TP technology, the MAC address of the peer node needs to be obtained between the ports of the local node and the peer node, which is used to encapsulate the destination MAC address of the MPLS message. Identify whether the destination MAC address in the message is the MAC address of the node after the text, and then identify the service label, and the OAM standard G.8113.1 of MPLS-TP has been formally defined soon, and the corresponding products are not mature enough, so, it has been The OAM function compatibility and flexibility of some software platforms are not satisfactory.

传统的采用三层接口的应用方案,需要指定网络侧端口,或者采用没有实现三层接口的方案,通过直接指定网络侧端口,人工写入对端MAC地址。因此,现有技术方案存在PTN设备的配置灵活性差,不能适应网络拓扑的变化的问题。The traditional application solution using the layer-3 interface needs to specify the port on the network side, or adopt the solution that does not implement the layer-3 interface, and manually write the MAC address of the peer end by directly specifying the port on the network side. Therefore, the prior art solution has the problem that the configuration flexibility of the PTN equipment is poor and cannot adapt to the change of the network topology.

发明内容Contents of the invention

本发明实施例提供一种基于三层接口的MPLS-TP配置方法及装置,用以解决现有技术中三层接口的PTN设备配置灵活性差,不能适应网络拓扑变化的问题。The embodiment of the present invention provides an MPLS-TP configuration method and device based on a layer-3 interface, which is used to solve the problem in the prior art that PTN equipment with a layer-3 interface has poor configuration flexibility and cannot adapt to network topology changes.

本发明实施例提供了一种基于三层接口的MPLS-TP配置方法,该方法包括:The embodiment of the present invention provides a kind of MPLS-TP configuration method based on three-layer interface, and this method comprises:

接收配置启动指令唤醒同步信号量,根据标签信息及下一跳IP地址信息在自身保存的标签地址表中查找对应的VLAN接口信息,通过所述查找到的每个VLAN接口发送该标签信息的ARP请求报文,其中,所述标签地址表中保存有标签信息、下一跳IP地址信息、VLAN信息、出端口信息及目的MAC地址信息;Receive the configuration start command to wake up the synchronous semaphore, search the corresponding VLAN interface information in the label address table saved by itself according to the label information and the next hop IP address information, and send the ARP of the label information through each VLAN interface found. Request message, wherein, label information, next hop IP address information, VLAN information, outgoing port information and destination MAC address information are stored in the label address table;

接收返回的该标签信息的ARP回复报文,获取所述ARP回复报文中携带的目的MAC地址信息、出端口信息及VLAN信息,根据该标签信息及所述ARP回复报文的VLAN信息,在标签协议表中查找对应的目的MAC地址信息及出端口信息;Receive the returned ARP reply message of the tag information, obtain the destination MAC address information, outgoing port information and VLAN information carried in the ARP reply message, according to the tag information and the VLAN information of the ARP reply message, in Find the corresponding destination MAC address information and outbound port information in the label protocol table;

将查找到的该目的MAC地址信息及出端口信息与所述ARP回复报文中携带的MAC地址信息及出端口信息进行比较,当确定与所述ARP回复报文中携带目的MAC地址信息及出端口信息不一致时,根据所述ARP回复报文中携带的目的MAC地址信息及出端口信息,对标签地址表进行更新。Comparing the found MAC address information and outgoing port information with the MAC address information and outgoing port information carried in the ARP reply message, when it is determined that the destination MAC address information and outgoing port information are carried in the ARP reply message When the port information is inconsistent, the label address table is updated according to the destination MAC address information and the outgoing port information carried in the ARP reply message.

本发明实施例提供了一种基于三层接口的MPLS-TP配置装置,该装置包括:The embodiment of the present invention provides a kind of MPLS-TP configuration device based on three-layer interface, and this device comprises:

查找发送模块,用于接收配置启动指令唤醒同步信号量,根据标签信息及下一跳IP地址信息在自身保存的标签地址表中查找对应的VLAN接口信息,通过所述查找到的每个VLAN接口发送该标签信息的ARP请求报文,其中,所述标签地址表中保存有标签信息、下一跳IP地址信息、VLAN信息、出端口信息及目的MAC地址信息;The search sending module is used to receive the configuration start command to wake up the synchronous semaphore, search the corresponding VLAN interface information in the label address table saved by itself according to the label information and the next hop IP address information, and pass each VLAN interface found by the search Sending the ARP request message of the label information, wherein the label address table stores label information, next-hop IP address information, VLAN information, outgoing port information and destination MAC address information;

ARP处理模块,用于接收返回的该标签信息的ARP回复报文,获取所述ARP回复报文中携带的目的MAC地址信息、出端口信息及VLAN信息,根据该标签信息及所述ARP回复报文的VLAN信息,在标签协议表中查找对应的目的MAC地址信息及出端口信息;The ARP processing module is used to receive the returned ARP reply message of the label information, obtain the destination MAC address information, outgoing port information and VLAN information carried in the ARP reply message, and according to the label information and the ARP reply message VLAN information of the text, look up the corresponding destination MAC address information and outbound port information in the label protocol table;

配置更新模块,用于将查找到的该目的MAC地址信息及出端口信息与所述ARP回复报文中携带的MAC地址信息及出端口信息进行比较,当确定与所述ARP回复报文中携带目的MAC地址信息及出端口信息不一致时,根据所述ARP回复报文中携带的目的MAC地址信息及出端口信息,对标签地址表进行更新。The configuration update module is used to compare the MAC address information and the outgoing port information of the purpose found with the MAC address information and the outgoing port information carried in the ARP reply message, and when it is determined that it is the same as that carried in the ARP reply message When the destination MAC address information and the egress port information are inconsistent, the label address table is updated according to the destination MAC address information and the egress port information carried in the ARP reply message.

本发明实施例提供一种基于三层接口的MPLS-TP配置方法及装置,该方法包括:根据自身保存的标签地址表中的VLAN接口信息,通过该每个VLAN接口发送每个标签信息的ARP请求报文;接收返回的该标签信息的ARP回复报文,将该ARP回复报文中携带的MAC地址信息及出端口信息与标签地址表中的信息进行比较,当确定与标签地址表中的目的MAC地址信息及出端口信息不一致时,对标签地址表进行更新。由于在本发明实施例中通过建立标签信息、下一跳IP地址信息、VLAN 信息、出端口信息及目的MAC地址信息的映射列表,当网络拓扑变化时,能及时更新标下一跳节点的信息,从而大大提高了PTN 设备配置的灵活性。Embodiments of the present invention provide a layer-3 interface-based MPLS-TP configuration method and device, the method comprising: according to the VLAN interface information in the label address table saved by itself, sending the ARP of each label information through each VLAN interface Request message; receive the returned ARP reply message of the label information, compare the MAC address information and the outbound port information carried in the ARP reply message with the information in the label address table, and when it is determined that it is consistent with the information in the label address table When the destination MAC address information and the egress port information are inconsistent, the label address table is updated. Because in the embodiment of the present invention, by establishing the mapping list of label information, next-hop IP address information, VLAN information, outgoing port information and destination MAC address information, when the network topology changes, the information of the next-hop node can be updated in time , thus greatly improving the flexibility of PTN equipment configuration.

附图说明Description of drawings

图1为本发明实施例提供的一种基于三层接口的MPLS-TP配置过程示意图;Fig. 1 is a kind of schematic diagram of MPLS-TP configuration process based on three-layer interface provided by the embodiment of the present invention;

图2本发明实施例提供的首次接入的端口UP事件触发的基于三层接口的MPLS-TP配置过程示意图;Figure 2 is a schematic diagram of the layer-3 interface-based MPLS-TP configuration process triggered by the port UP event of the first access provided by the embodiment of the present invention;

图3为本发明实施例提供的一种基于三层接口的MPLS-TP配置的具体实施过程示意图;FIG. 3 is a schematic diagram of a specific implementation process of MPLS-TP configuration based on a layer-3 interface provided by an embodiment of the present invention;

图4为本发明实施例提供的实现OAM处理功能的系统结构示意图;FIG. 4 is a schematic structural diagram of a system for realizing an OAM processing function provided by an embodiment of the present invention;

图5为本发明实施例提供的一种基于三层接口的MPLS-TP配置装置的结构示意图;FIG. 5 is a schematic structural diagram of an MPLS-TP configuration device based on a layer-3 interface provided by an embodiment of the present invention;

具体实施方式detailed description

本发明为了有效的减少PTN设备的维护成本,节省资源,提高配置的灵活性,提供了一种基于三层接口的MPLS-TP配置方法及装置。In order to effectively reduce the maintenance cost of PTN equipment, save resources and improve configuration flexibility, the present invention provides an MPLS-TP configuration method and device based on a three-layer interface.

下面结合说明书附图,对本发明进行详细说明。The present invention will be described in detail below in conjunction with the accompanying drawings.

图1为本发明实施例提供的一种基于三层接口的MPLS-TP配置过程示意图,该过程包括以下步骤:Fig. 1 is a kind of schematic diagram of MPLS-TP configuration process based on three-layer interface that the embodiment of the present invention provides, and this process comprises the following steps:

S101:接收配置启动指令唤醒同步信号量,根据标签信息及下一跳IP地址信息在自身保存的标签地址表中查找对应的VLAN接口信息,通过所述查找到的每个VLAN接口发送该标签信息的ARP请求报文,其中,标签地址表中保存有标签信息、下一跳IP地址信息、VLAN信息、出端口信息及目的MAC地址信息。S101: Receive the configuration start command to wake up the synchronous semaphore, search the corresponding VLAN interface information in the label address table saved by itself according to the label information and the next-hop IP address information, and send the label information through each VLAN interface found. ARP request message, wherein the label address table stores label information, next-hop IP address information, VLAN information, outgoing port information and destination MAC address information.

PE设备的配置保存到主CPU,主CPU通过PCIE接口控制交换模组中的ARP处理模块,并存储设备节点的每个端口的下一跳IP地址信息以及控制开启/关闭MPLS功能。The configuration of the PE device is saved to the main CPU. The main CPU controls the ARP processing module in the switch module through the PCIE interface, stores the next-hop IP address information of each port of the device node, and controls the opening/closing of the MPLS function.

当接收到配置启动指令时,从标签站中选取一个标签码,通过该标签码及保存在本地的标签地址表中的下一跳IP地址信息,查找对应的VLAN信息,并向该标签码对应的每个VLAN接口发送ARP请求报文,然后,选取标签栈中另一个标签码重复上述流程,直至将标签栈中每个标签码都发送一次,其中,从标签栈中选取标签码可以是依次选取,也可以是随机选取。When the configuration start command is received, a tag code is selected from the tag station, and the corresponding VLAN information is searched through the tag code and the next-hop IP address information stored in the local tag address table, and corresponding to the tag code. Each VLAN interface of each VLAN interface sends an ARP request message, and then selects another label code in the label stack to repeat the above process until each label code in the label stack is sent once, wherein, selecting the label code from the label stack can be in order selection, or random selection.

S102:接收返回的该标签信息的ARP回复报文,获取所述ARP回复报文中携带的目的MAC地址信息、出端口信息及VLAN信息,根据该标签信息及所述ARP回复报文的VLAN信息,在标签协议表中查找对应的目的MAC地址信息及出端口信息。S102: Receive the returned ARP reply message of the tag information, obtain the destination MAC address information, egress port information and VLAN information carried in the ARP reply message, and according to the tag information and the VLAN information of the ARP reply message , look up the corresponding destination MAC address information and outbound port information in the label protocol table.

主CPU配置下一跳IP地址信息的时候唤醒同步信号量,然后通过下一跳IP查找所属的VALN,依次发送下一跳IP和VLAN配置信息到ARP处理模块,ARP处理模块根据每个返回的ARP回复报文的VLAN信息及该ARP回复报文对应的标签码,在标签协议表中查找对应的表项。When the main CPU configures the next-hop IP address information, it wakes up the synchronous semaphore, and then searches for the VLAN it belongs to through the next-hop IP, and sends the next-hop IP and VLAN configuration information to the ARP processing module in turn, and the ARP processing module returns each The VLAN information of the ARP reply message and the label code corresponding to the ARP reply message are searched for corresponding entries in the label protocol table.

在本发明中为了解决因为丢包、网络异常等原因而导致的接收不到ARP回复报文的问题,在发送每一个标签码的ARP请求报文后,启动一个定时器,定时器超时则确定该标签码的ARP回复报文未收到。In the present invention, in order to solve the problem that the ARP reply message cannot be received due to reasons such as packet loss and network anomalies, after sending the ARP request message of each label code, a timer is started, and the timer is overtime and determined The ARP reply packet of the label code has not been received.

S103:将查找到的该目的MAC地址信息及出端口信息与所述ARP回复报文中携带的MAC地址信息及出端口信息进行比较。S103: Compare the found destination MAC address information and egress port information with the MAC address information and egress port information carried in the ARP reply message.

每个ARP回复报文中均包含该ARP回复报文对应的标签的下一跳的目的MAC地址信息和出端口信息,判断该ARP回复报文中携带的目的MAC地址信息与标签协议表中的目的MAC地址信息是否一致,当比较结果一致时,判断该ARP回复报文中携带的出端口信息与标签协议表中的出端口信息是否一致Each ARP reply message contains the next-hop destination MAC address information and outbound port information of the label corresponding to the ARP reply message, and it is judged that the destination MAC address information carried in the ARP reply message is consistent with the label protocol table. Whether the destination MAC address information is consistent, if the comparison result is consistent, judge whether the outbound port information carried in the ARP reply message is consistent with the outbound port information in the label protocol table

其中,该目的MAC地址信息和出端口信息随着网络拓扑结构的改变而变化。Wherein, the destination MAC address information and the egress port information change with the change of the network topology.

S104:当确定与所述ARP回复报文中携带目的MAC地址信息及出端口信息不一致时,根据所述ARP回复报文中携带的目的MAC地址信息及出端口信息,对标签地址表进行更新。S104: When it is determined that the destination MAC address information and the egress port information carried in the ARP reply message are inconsistent, update the label address table according to the destination MAC address information and the egress port information carried in the ARP reply message.

具体的,获取每个标签码的ARP回复报文中的目的MAC地址信息和出端口信息,判断该ARP回复报文中携带的目的MAC地址信息与标签协议表中的目的MAC地址信息是否一致,当确定目的MAC地址信息不一致时,将标签协议表中的目的MAC地址信息及出端口信息更新为ARP回复报文中携带的目的MAC地址信息及端口信息;Specifically, obtain the destination MAC address information and the outgoing port information in the ARP reply message of each label code, and judge whether the destination MAC address information carried in the ARP reply message is consistent with the destination MAC address information in the label protocol table, When it is determined that the destination MAC address information is inconsistent, update the destination MAC address information and the outgoing port information in the label protocol table to the destination MAC address information and port information carried in the ARP reply message;

当目的MAC地址信息一致时,判断该ARP回复报文中携带的出端口信息与标签协议表中的出端口信息是否一致,当确定出端口信息不一致时,将标签协议表中的出端口信息更新为ARP回复报文中携带的端口信息,其中,目的MAC地址信息和出端口信息的比较不分先后顺序。When the destination MAC address information is consistent, judge whether the outbound port information carried in the ARP reply message is consistent with the outbound port information in the label protocol table, and update the outbound port information in the label protocol table when it is determined that the outbound port information is inconsistent It is the port information carried in the ARP reply message, where the destination MAC address information and the outbound port information are compared in no particular order.

由于本发明实施例中通过对下一跳的目的MAC地址信息及出端口信息进行监控,当出现网络拓扑变化时,能及时的更新本地的标签协议表中的表项,从而避免了因为网络拓扑变化需要人工配置信息,而造成的资源浪费问题,提高了配置的灵活性。Since the embodiment of the present invention monitors the destination MAC address information and the outgoing port information of the next hop, when the network topology changes, the entries in the local label protocol table can be updated in time, thereby avoiding Changes require manual configuration of information, resulting in a waste of resources and improving the flexibility of configuration.

为了及时的采集下一跳的目的MAC地址信息及出端口信息,本发明的触发条件开启配置启动指令包括:In order to collect the destination MAC address information and the outgoing port information of the next hop in time, the trigger condition of the present invention opens the configuration start command and includes:

通过用户命令配置开启MPLS使能,配置下一跳的IP地址时唤醒同步信号量;或者,Enable MPLS through user command configuration, and wake up the synchronization semaphore when configuring the IP address of the next hop; or,

通过端口的UP事件,触发网络侧端口发送ARP请求报文;或者,Through the UP event of the port, the port on the network side is triggered to send an ARP request message; or,

通过在三层接口的ARP更新事件时, 触发硬件下载标签配置。When the ARP update event of the layer-3 interface is used, the hardware is triggered to download the label configuration.

具体的,当网络构架完成进行初始配置时,根据当前网络的拓扑结构,用户通过命令配置开MPLS使能,进行初始的标签协议的表项建立时触发,并且用户可以根据需要在预留物理接口,提前配置好每个标签码对应的下一跳IP地址及VLAN接口,当预留的物理接口连接到设备或者网络拓扑发生变化时,也将触发网络侧端口发送ARP请求报文;或者对用户对三层接口的ARP进行更新时,通过硬件下载标签配置,也将触发本操作。Specifically, when the initial configuration of the network architecture is completed, according to the topology of the current network, the user configures and enables MPLS through commands, which is triggered when the initial label protocol table entry is established, and the user can reserve physical interfaces as needed , configure the next-hop IP address and VLAN interface corresponding to each tag code in advance, when the reserved physical interface is connected to the device or the network topology changes, it will also trigger the network side port to send an ARP request message; or to the user When updating the ARP of the layer-3 interface, downloading the label configuration through the hardware will also trigger this operation.

另外,在本发明中当标签地址表发生改变时,为了快速建新的多协议标签交换隧道,保证MPLS-TP报文能正常传输,所述对自身保存的标签地址表进行更新之后,方法还包括:In addition, in the present invention, when the label address table changes, in order to quickly build a new multi-protocol label switching tunnel and ensure the normal transmission of MPLS-TP messages, after the self-saved label address table is updated, the method further includes :

清除已建立的交叉连接AC业务,根据所述ARP回复报文中携带VLAN信息、目的MAC地址信息、出端口信息及该标签信息,更新多协议标签交换隧道及该隧道上承载的所有虚电路接口,并创建新的交叉连接AC业务。Clear the established cross-connect AC service, and update the MPLS tunnel and all virtual circuit interfaces carried on the tunnel according to the VLAN information, destination MAC address information, egress port information and the label information carried in the ARP reply message , and create a new cross-connect AC service.

具体的,当本地保存的标签协议表中的某条表项发生变化时,根据该条表项的标签码、目的MAC地址信息及出端口信息,AC转发模块删除该条表象之前建立的交叉连接AC业务,销毁该条表象之前建立多协议标签交换隧道及该隧道上承载的所有虚电路接口;根据更新后的该表现的标签码、目的MAC地址信息、出端口信息及本地保存的VLAN信息和下一跳IP地址信息建立新的多协议标签交换隧道,并在该隧道上建立承载的所有虚电路接口,最后建立新的交叉连接AC业务。Specifically, when an entry in the locally stored label protocol table changes, the AC forwarding module deletes the cross-connect established before the entry according to the label code, destination MAC address information, and outbound port information of the entry. For AC services, establish a multi-protocol label switching tunnel and all virtual circuit interfaces carried on the tunnel before destroying the appearance; according to the updated label code, destination MAC address information, outgoing port information, and locally saved VLAN information and The next-hop IP address information establishes a new MPLS tunnel, and establishes all virtual circuit interfaces carried by the tunnel, and finally establishes a new cross-connection AC service.

当网络中有物理端口接入新设备时,通过端口UP事件启动配置指令,对该新设备进行下一跳的配置,根据每个标签码对应的ARP回复报文的VLAN信息,在标签协议表中建立新的表项,所述据该标签信息及所述ARP回复报文的VLAN信息,在标签协议表中查找对应的目的MAC地址信息及出端口信息包括:When a physical port in the network is connected to a new device, the configuration command is started through the port UP event to configure the next hop of the new device, and according to the VLAN information of the ARP reply message corresponding to each tag code, the Set up a new table item in, described according to the VLAN information of this label information and described ARP reply message, look up corresponding purpose MAC address information and outgoing port information in the label protocol table and include:

根据所述ARP回复报文中的VLAN信息及该标签信息,在标签地址表中进行查找,判断标签地址表中是否保存有对应的目的MAC地址信息和出端口信息;According to the VLAN information and the label information in the ARP reply message, search in the label address table, and judge whether there are corresponding destination MAC address information and outgoing port information stored in the label address table;

当确定所述标签地址表中未保存有对应的目的MAC地址信息和出端口信息时,根据所述ARP回复报文中VLAN 信息、目的MAC地址信息、出端口信息及该标签信息,创建多协议标签隧道及该隧道上承载的所有虚电路的接口,并创建交叉连接AC业务。When it is determined that the corresponding destination MAC address information and outgoing port information are not saved in the label address table, according to the VLAN information, destination MAC address information, outgoing port information and the label information in the ARP reply message, create a multi-protocol Label the tunnel and the interfaces of all virtual circuits carried by the tunnel, and create cross-connect AC services.

具体的,当组网的网络拓扑发生变化,新节点设备使用预留的物理端口连接到该网络时,触发网络侧端口发送ARP请求报文,PE设备通过标签栈中的标签码及下一跳IP地址,在本地保存的标签协议表中查找对应的VLAN信息,通过该VLAN 接口向新节点设备发送ARP请求报文,新节点设备接收到该ARP请求报文后,将自身的MAC地址信息及出端口信息通过ARP回复报文返回给PE设备,PE设备获取该ARP回复报文的目的MAC地址信息、出端口信息及VLAN信息,并根据该VLAN信息该ARP回复报文对应的标签码在标签协议表中进行查找,由于在标签协议表中未查找到对应的目的MAC地址信息及出端口信息,因此确定为首次学习到的目的MAC地址信息及出端口信息,根据该ARP回复报文包含的目的MAC地址信息、出端口信息、VLAN信息及本地保存的下一跳IP地址信息和标签码在标签协议表中建立新的表项,并根据所述ARP回复报文中VLAN 信息、目的MAC地址信息、出端口信息及该标签信息,创建多协议标签隧道及该隧道上承载的所有虚电路的接口,并创建交叉连接AC业务。Specifically, when the network topology of the networking changes and the new node device uses the reserved physical port to connect to the network, the port on the network side is triggered to send an ARP request message, and the PE device passes the label code in the label stack and the next hop IP address, find the corresponding VLAN information in the label protocol table saved locally, and send an ARP request message to the new node device through the VLAN interface. After receiving the ARP request message, the new node device sends its own MAC address information and The outbound port information is returned to the PE device through the ARP reply message, and the PE device obtains the destination MAC address information, outbound port information, and VLAN information of the ARP reply message, and according to the VLAN information, the tag code corresponding to the ARP reply message is placed on the label Search in the protocol table. Since the corresponding destination MAC address information and outbound port information are not found in the label protocol table, it is determined to be the first learned destination MAC address information and outbound port information. According to the information contained in the ARP reply message Destination MAC address information, outgoing port information, VLAN information, and locally stored next-hop IP address information and label code to create a new entry in the label protocol table, and according to the VLAN information and destination MAC address in the ARP reply message information, egress port information, and the label information, create a multi-protocol label tunnel and interfaces of all virtual circuits carried on the tunnel, and create cross-connect AC services.

图2为本发明实施例提供的首次接入的端口UP事件触发的基于三层接口的MPLS-TP配置过程示意图,该过程包括以下步骤:Fig. 2 is the schematic diagram of the MPLS-TP configuration process based on the three-layer interface triggered by the port UP event of the first access provided by the embodiment of the present invention, and the process includes the following steps:

S201:端口UP事件触发配置启动指令唤醒同步信号量,根据标签信息及下一跳IP地址信息在自身保存的标签地址表中查找对应的VLAN接口信息。S201: The port UP event triggers a configuration start command to wake up the synchronization semaphore, and searches the corresponding VLAN interface information in the label address table saved by itself according to the label information and the next-hop IP address information.

S202:通过所述查找到的每个VLAN接口发送该标签信息的ARP请求报文。S202: Send an ARP request packet of the tag information through each found VLAN interface.

S203:接收返回的该标签信息的ARP回复报文,获取所述ARP回复报文中携带的目的MAC地址信息、出端口信息及VLAN信息。S203: Receive the returned ARP reply message of the label information, and obtain the destination MAC address information, egress port information and VLAN information carried in the ARP reply message.

S204:根据该标签信息及所述ARP回复报文的VLAN信息,在标签协议表中查找对应的目的MAC地址信息及出端口信息。S204: According to the label information and the VLAN information of the ARP reply message, look up the corresponding destination MAC address information and egress port information in the label protocol table.

S205:判断标签地址表中是否保存有对应的目的MAC地址信息或出端口信息,当判断结果为是时,进行步骤S206,否则,进行步骤S207。S205: Judging whether the corresponding destination MAC address information or outgoing port information is saved in the label address table, if the judging result is yes, go to step S206; otherwise, go to step S207.

S206:判断查找到的该目的MAC地址信息及出端口信息与所述ARP回复报文中携带的MAC地址信息及出端口信息是否一致,当判定结果为是时,保持标签地址表不变,否则,进行步骤S207。。S206: Judging whether the found MAC address information and outgoing port information of the destination are consistent with the MAC address information and outgoing port information carried in the ARP reply message, when the judgment result is yes, keep the label address table unchanged, otherwise , go to step S207. .

S207:根据所述ARP回复报文中携带的目的MAC地址信息及出端口信息,对标签地址表进行更新。S207: Update the label address table according to the destination MAC address information and the egress port information carried in the ARP reply message.

S208:清除已建立的交叉连接AC业务,根据所述ARP回复报文中携带VLAN信息、目的MAC地址信息、出端口信息及该标签信息,更新多协议标签交换隧道及该隧道上承载的所有虚电路接口,并创建新的交叉连接AC业务。S208: Clear the established cross-connection AC service, and update the Multi-Protocol Label Switching Tunnel and all virtual circuit interface, and create a new cross-connect AC service.

具体的,在本发明实施例中,支持用户在组网时根据需要配置预留端口,通过在标签协议表中配置该预留端口的下一跳IP地址、VLAN信息及对应的标签信息,可以使新接网络的节点设备只需连接到预留物理端口,就能实现MPLS报文的正常通信。Specifically, in the embodiment of the present invention, users are supported to configure reserved ports as required during networking. By configuring the next-hop IP address, VLAN information, and corresponding label information of the reserved port in the label protocol table, it is possible to The node equipment newly connected to the network only needs to be connected to the reserved physical port to realize the normal communication of MPLS packets.

另外,在本发明中为了提高OAM报文的兼容性,灵活的实现G.8113.1标准的特性扩展功能,支持携带VLAN和UNTAG的OAM报文的处理,根据改变后的标签协议表中的表项建立新的交叉连接AC业务之后,所述方法还包括:In addition, in the present invention, in order to improve the compatibility of the OAM message, flexibly realize the feature extension function of the G.8113.1 standard, support the processing of the OAM message carrying VLAN and UNTAG, according to the entry in the label protocol table after the change After establishing a new cross-connect AC service, the method further includes:

根据多协议标签交换隧道接口及该隧道上承载的虚电路的接口,创建本端维护点和远端维护点,镜像交换芯片接收的CCM报文到从CPU,重定向从CPU发送的CCM报文到交换芯片的出端口;Create a local maintenance point and a remote maintenance point according to the interface of the MPLS tunnel and the interface of the virtual circuit carried by the tunnel, mirror the CCM message received by the switching chip to the slave CPU, and redirect the CCM message sent from the CPU to the output port of the switch chip;

镜像交换芯片接收的环回报文到主CPU,重定向主CPU发送的环回报文到交换芯片的出端口。The loopback packets received by the mirrored switch chip are sent to the main CPU, and the loopback packets sent by the main CPU are redirected to the egress port of the switch chip.

具体的,FP控制模块重定向和镜像OAM报文转发到主CPU和从CPU,可以支持带有VLAN和不携带VLAN的报文的接收,OAM报文接收任务在接收报文中断中挂接钩子接口,当AC转发模块根据标签协议表中修改后的表项建立新的交叉连接AC业务之后,通知OAM处理模块进行OAM处理,OAM处理模块根据多协议标签交换隧道接口及该隧道上承载的每个虚电路接口,创建本端维护点(MEP)和远端维护点,同时将CCM报文镜像到从CPU,并将从CPU发送的CCM报文重定向到交换芯片的出端口,然后将环回LB报文镜像到主CPU,并将主CPU发送的环回报文重定向到交换芯片的出端口。Specifically, the FP control module redirects and mirrors OAM messages and forwards them to the master CPU and the slave CPU, which can support the reception of messages with or without VLANs, and the OAM message receiving task is hooked in the interruption of receiving messages interface, when the AC forwarding module establishes a new cross-connection AC service according to the modified entry in the label protocol table, it notifies the OAM processing module to perform OAM processing, and the OAM processing module Create a virtual circuit interface, create a local maintenance point (MEP) and a remote maintenance point, mirror the CCM message to the slave CPU at the same time, and redirect the CCM message sent from the CPU to the egress port of the switch chip, and then transfer the ring The back LB message is mirrored to the primary CPU, and the loopback message sent by the main CPU is redirected to the egress port of the switch chip.

图3为本发明实施例提供的一种基于三层接口的MPLS-TP配置的具体实施过程示意图,该过程包括以下步骤:Fig. 3 is a schematic diagram of a specific implementation process of MPLS-TP configuration based on a layer-3 interface provided by the embodiment of the present invention, and the process includes the following steps:

S301:接收配置启动指令唤醒同步信号量,根据标签信息及下一跳IP地址信息在自身保存的标签地址表中查找对应的VLAN接口信息。S301: Receive a configuration start command to wake up the synchronous semaphore, and search the corresponding VLAN interface information in the label address table saved by itself according to the label information and the next-hop IP address information.

S302:通过所述查找到的每个VLAN接口发送该标签信息的ARP请求报文。S302: Send an ARP request packet of the tag information through each found VLAN interface.

S303:接收返回的该标签信息的ARP回复报文,获取该ARP回复报文中携带的目的MAC地址信息、出端口信息及VLAN信息。S303: Receive the returned ARP reply message of the label information, and obtain the destination MAC address information, egress port information and VLAN information carried in the ARP reply message.

S304:根据该标签信息及所述ARP回复报文的VLAN信息,在标签协议表中查找对应的目的MAC地址信息及出端口信息。S304: According to the label information and the VLAN information of the ARP reply message, look up the corresponding destination MAC address information and egress port information in the label protocol table.

S305:判断查找到的该目的MAC地址信息及出端口信息与所述ARP回复报文中携带的MAC地址信息及出端口信息是否一致,当判定结果为是时,保持标签地址表不变,否则,进行步骤S306。S305: Judging whether the found MAC address information and egress port information of the destination are consistent with the MAC address information and egress port information carried in the ARP reply message, when the determination result is yes, keep the label address table unchanged, otherwise , go to step S306.

S306:根据所述ARP回复报文中携带的目的MAC地址信息及出端口信息,对标签地址表进行更新。S306: Update the label address table according to the destination MAC address information and the egress port information carried in the ARP reply message.

S307:清除已建立的交叉连接AC业务,根据所述ARP回复报文中携带VLAN信息、目的MAC地址信息、出端口信息及该标签信息,更新多协议标签交换隧道及该隧道上承载的所有虚电路接口,并创建新的交叉连接AC业务。S307: Clear the established cross-connection AC service, and update the Multi-Protocol Label Switching Tunnel and all virtual circuit interface, and create a new cross-connect AC service.

S308:根据多协议标签交换隧道接口及该隧道上承载的虚电路的接口,创建本端维护点和远端维护点。S308: Create a local maintenance point and a remote maintenance point according to the interface of the MPLS tunnel and the interface of the virtual circuit carried by the tunnel.

S309:镜像交换芯片接收的CCM报文到从CPU,重定向从CPU发送的CCM报文到交换芯片的出端口。S309: Mirror the CCM message received by the switch chip to the slave CPU, and redirect the CCM message sent from the CPU to the egress port of the switch chip.

S310:镜像交换芯片接收的环回报文到主CPU,重定向主CPU发送的环回报文到交换芯片的出端口。S310: mirroring the loopback message received by the switch chip to the main CPU, and redirecting the loopback message sent by the main CPU to the output port of the switch chip.

在本发明中通过配置MEG ID,绑定的段层端口、隧道 ID和虚电路ID,本地/远端MEP ID,CCM报文的发送周期。将MPLS-TP OAM分为段层、LSP层和PW层,使得OAM实体建立在不同的层接口之上,与之对应的是建立3个数据库存储数据。通过采用平衡二叉树算法,加快遍历速度,提高了MPLS-TP的OAM的配置灵活性,也增加了OAM报文的兼容性。In the present invention, by configuring MEG ID, bound segment layer port, tunnel ID and virtual circuit ID, local/remote MEP ID, and sending period of CCM message. MPLS-TP OAM is divided into segment layer, LSP layer and PW layer, so that OAM entities are established on different layer interfaces, and correspondingly, three databases are established to store data. By using the balanced binary tree algorithm, the traversal speed is accelerated, the configuration flexibility of MPLS-TP OAM is improved, and the compatibility of OAM packets is also increased.

图4为本发明实施例提供的实现OAM处理功能的系统结构示意图,在该系统中包含ARP学习模块、FP处理模块、CCM处理模块及LB处理模块。其中,ARP学习模块建立邻居的ARP地址表,检索在段层端口、隧道(TUNNEL) ID和虚电路PW ID的MPLS-TP OAM接口处是否绑定了OAM功能。根据OAM接口更新数据库中的下一跳设备的目的MAC地址(DMAC)和端口以及内外层标签,同时通过RPC接口更新从CPU的数据库。FP处理模块用于重定向和镜像主CPU和从CPU接收MPLS-TP OAM报文,并根据ARP学习模块建立CCM报文和网络侧端口的映射。CCM处理模块根据OAM接口发送接收CCM报文、查数据库中MEP表以及告警处理。LB处理模块根据OAM接口发送接收LB/LT报文、查数据库中MEP表以及告警处理。FIG. 4 is a schematic structural diagram of a system for realizing OAM processing functions provided by an embodiment of the present invention, and the system includes an ARP learning module, an FP processing module, a CCM processing module, and a LB processing module. Wherein, the ARP learning module establishes the neighbor's ARP address table, and retrieves whether the OAM function is bound at the MPLS-TP OAM interface of the section layer port, tunnel (TUNNEL) ID and virtual circuit PW ID. Update the destination MAC address (DMAC) and port of the next-hop device in the database according to the OAM interface, as well as the inner and outer labels, and update the database of the slave CPU through the RPC interface at the same time. The FP processing module is used to redirect and mirror the main CPU and receive MPLS-TP OAM messages from the CPU, and establish the mapping between CCM messages and network side ports according to the ARP learning module. The CCM processing module sends and receives CCM messages according to the OAM interface, checks the MEP table in the database, and handles alarms. The LB processing module sends and receives LB/LT messages according to the OAM interface, checks the MEP table in the database, and handles alarms.

具体的,系统启动时,FP控制模块重定向和镜像OAM报文转发到主CPU和从CPU。可支持带有VLAN和不携带VLAN的报文的接收。OAM报文接收任务在接收报文中断中挂接钩子接口。Specifically, when the system is started, the FP control module redirects and mirrors the OAM message and forwards it to the master CPU and the slave CPU. It can support the reception of packets with or without VLAN. The OAM message receiving task hooks up the hook interface in the message receiving interrupt.

用户命令配置任务通过用户接口模块配置OAM接口和MEG ID、LEVEL等信息,然后配置本端/远端MEP和CCM参数。多个MEG ID可以绑定同一个OAM接口上(不同的级别),以实现OAM的业务嵌套。数据库采用平衡二叉树算法存储MEG ID为索引的数据结构,最后建立以OAM接口(段层端口/TUNNEL ID/PW ID)和LEVEL为索引的MEP查找表。The user command configuration task configures the OAM interface, MEG ID, LEVEL and other information through the user interface module, and then configures the local/remote MEP and CCM parameters. Multiple MEG IDs can be bound to the same OAM interface (different levels) to realize OAM business nesting. The database adopts the balanced binary tree algorithm to store the data structure indexed by MEG ID, and finally establishes the MEP lookup table indexed by OAM interface (segment layer port/TUNNEL ID/PW ID) and LEVEL.

创建MEP查找表的时候,下一跳信息根据MPLS网络侧端口连接状态决定是否创建。下一跳信息包括下一跳DMAC、物理端口以及OAM接口对应的段层端口/TUNNEL ID/PW ID的MPLS标签等信息。下一跳信息的创建是通过物理端口的UP事件触发ARP学习模块,从MPLS的配置中取出标签数据动态更新数据库,同时更新从CPU的数据库来完成的。设备启动时MPLS对应的物理端口UP事件触发ARP学习模块学习下一跳信息,并保存到数据库中。防止主CPU先于从CPU启动,造成数据库的不同步。When creating an MEP lookup table, whether to create the next hop depends on the port connection status on the MPLS network side. The next hop information includes information such as the next hop DMAC, the physical port, and the MPLS label of the segment layer port/TUNNEL ID/PW ID corresponding to the OAM interface. The next hop information is created by triggering the ARP learning module through the UP event of the physical port, taking out the label data from the MPLS configuration to dynamically update the database, and updating the database of the slave CPU at the same time. When the device is started, the UP event of the physical port corresponding to MPLS triggers the ARP learning module to learn the next hop information and save it in the database. Prevent the master CPU from starting before the slave CPU, causing the database to be out of sync.

本发明为双CPU实现MPLS-TP OAM的功能。通过交换芯片的FP功能控制从CPU处理CCM报文,主CPU用来处理其它类型的OAM报文。从CPU连接到交换芯片的固定端口用于收发业务报文。通过和主CPU的RPC通信完成状态机的改变实现OAM功能,并主动上报OAM报警信息。The invention realizes the function of MPLS-TP OAM for dual CPUs. The slave CPU is used to process CCM packets through the FP function of the switch chip, and the master CPU is used to process other types of OAM packets. The fixed port connected from the CPU to the switch chip is used to send and receive service packets. Through the RPC communication with the main CPU to complete the change of the state machine to realize the OAM function, and actively report the OAM alarm information.

图5为本发明实施例提供的一种基于三层接口的MPLS-TP配置装置的结构示意图,所述装置包括:Fig. 5 is a schematic structural diagram of an MPLS-TP configuration device based on a layer-3 interface provided by an embodiment of the present invention, the device comprising:

查找发送模块51,用于接收配置启动指令唤醒同步信号量,根据标签信息及下一跳IP地址信息在自身保存的标签地址表中查找对应的VLAN接口信息,通过所述查找到的每个VLAN接口发送该标签信息的ARP请求报文,其中,所述标签地址表中保存有标签信息、下一跳IP地址信息、VLAN信息、出端口信息及目的MAC地址信息;Search and send module 51, be used for receiving configuration start instruction to wake up synchronous semaphore, according to label information and next hop IP address information, search corresponding VLAN interface information in the label address table that self saves, through each VLAN that finds out The interface sends the ARP request message of the label information, wherein the label address table stores label information, next-hop IP address information, VLAN information, outgoing port information and destination MAC address information;

ARP处理模块52,用于接收返回的该标签信息的ARP回复报文,获取所述ARP回复报文中携带的目的MAC地址信息、出端口信息及VLAN信息,根据该标签信息及所述ARP回复报文的VLAN信息,在标签协议表中查找对应的目的MAC地址信息及出端口信息;The ARP processing module 52 is configured to receive the returned ARP reply message of the label information, obtain the destination MAC address information, outgoing port information and VLAN information carried in the ARP reply message, and reply according to the label information and the ARP reply message. For the VLAN information of the message, look up the corresponding destination MAC address information and outbound port information in the label protocol table;

配置更新模块53,用于将查找到的该目的MAC地址信息及出端口信息与所述ARP回复报文中携带的MAC地址信息及出端口信息进行比较,当确定与所述ARP回复报文中携带目的MAC地址信息及出端口信息不一致时,根据所述ARP回复报文中携带的目的MAC地址信息及出端口信息,对标签地址表进行更新。The configuration update module 53 is used to compare the MAC address information and the outgoing port information of the purpose found with the MAC address information and the outgoing port information carried in the ARP reply message. When carrying destination MAC address information and outgoing port information inconsistent, the label address table is updated according to the destination MAC address information and outgoing port information carried in the ARP reply message.

所述装置还包括:The device also includes:

配置启动模块54,用于通过用户命令配置开启MPLS使能,配置下一跳的IP地址时唤醒同步信号量;或者,通过端口的UP事件,触发网络侧端口发送ARP请求报文;或者,通过在三层接口的ARP更新事件时, 触发硬件下载标签配置。The configuration startup module 54 is used to enable MPLS through user command configuration, and wake up the synchronization semaphore when configuring the IP address of the next hop; or, through the UP event of the port, trigger the network side port to send the ARP request message; or, through When the ARP update event of the layer-3 interface is triggered, the hardware downloads the label configuration.

所述装置还包括:The device also includes:

ARP处理模块52,还用于根据所述ARP回复报文中的VLAN信息及该标签信息,在标签地址表中进行查找,判断标签地址表中是否保存有对应的目的MAC地址信息和出端口信息;The ARP processing module 52 is also used to search in the label address table according to the VLAN information and the label information in the ARP reply message, and judge whether the corresponding destination MAC address information and outgoing port information are stored in the label address table ;

AC转发模块55,用于当确定所述标签地址表中未保存有对应的目的MAC地址信息和出端口信息时,根据所述ARP回复报文中VLAN 信息、目的MAC地址信息、出端口信息及该标签信息,创建多协议标签隧道及该隧道上承载的所有虚电路的接口,并创建交叉连接AC业务。The AC forwarding module 55 is used for when it is determined that the corresponding destination MAC address information and outgoing port information are not stored in the label address table, according to the VLAN information, destination MAC address information, outgoing port information and The label information is used to create a multi-protocol label tunnel and interfaces of all virtual circuits carried on the tunnel, and to create a cross-connect AC service.

所述AC转发模块55,还用于清除已建立的交叉连接AC业务,根据所述ARP回复报文中携带VLAN信息、目的MAC地址信息、出端口信息及该标签信息,更新多协议标签交换隧道及该隧道上承载的所有虚电路接口,并创建新的交叉连接AC业务。The AC forwarding module 55 is also used to clear the established cross-connection AC service, and update the multi-protocol label switching tunnel according to the VLAN information, destination MAC address information, outgoing port information and the label information carried in the ARP reply message and all virtual circuit interfaces carried by the tunnel, and create a new cross-connect AC service.

所述装置还包括:The device also includes:

OAM处理模块56,用于根据多协议标签交换隧道接口及该隧道上承载的虚电路的接口,创建本端维护点和远端维护点,镜像交换芯片接收的CCM报文到从CPU,重定向从CPU发送的CCM报文到交换芯片的出端口;镜像交换芯片接收的环回报文到主CPU,重定向主CPU发送的环回报文到交换芯片的出端口。The OAM processing module 56 is used to create a local maintenance point and a remote maintenance point according to the multi-protocol label switching tunnel interface and the interface of the virtual circuit carried on the tunnel, and mirror the CCM message received by the switching chip to the slave CPU for redirection The CCM message sent from the CPU is sent to the output port of the switch chip; the loopback message received by the mirrored switch chip is sent to the main CPU, and the loopback message sent by the redirected main CPU is sent to the output port of the switch chip.

本发明实施例提供一种基于三层接口的MPLS-TP配置方法及装置,该方法包括:根据自身保存的标签地址表中的VLAN接口信息,通过该每个VLAN接口发送每个标签信息的ARP请求报文;接收返回的该标签信息的ARP回复报文,将该ARP回复报文中携带的MAC地址信息及出端口信息与标签地址表中的信息进行比较,当确定与标签地址表中的目的MAC地址信息及出端口信息不一致时,对标签地址表进行更新。由于在本发明实施例中通过建立标签信息、下一跳IP地址信息、VLAN 信息、出端口信息及目的MAC地址信息的映射列表,当网络拓扑变化时,能及时更新标下一跳节点的信息,从而大大提高了PTN 设备配置的灵活性。Embodiments of the present invention provide a layer-3 interface-based MPLS-TP configuration method and device, the method comprising: according to the VLAN interface information in the label address table saved by itself, sending the ARP of each label information through each VLAN interface Request message; receive the returned ARP reply message of the label information, compare the MAC address information and the outbound port information carried in the ARP reply message with the information in the label address table, and when it is determined that it is consistent with the information in the label address table When the destination MAC address information and the egress port information are inconsistent, the label address table is updated. Because in the embodiment of the present invention, by establishing the mapping list of label information, next-hop IP address information, VLAN information, outgoing port information and destination MAC address information, when the network topology changes, the information of the next-hop node can be updated in time , thus greatly improving the flexibility of PTN equipment configuration.

本领域内的技术人员应明白,本申请的实施例可提供为方法、系统、或计算机程序产品。因此,本申请可采用完全硬件实施例、完全软件实施例、或结合软件和硬件方面的实施例的形式。而且,本申请可采用在一个或多个其中包含有计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器、CD-ROM、光学存储器等)上实施的计算机程序产品的形式。Those skilled in the art should understand that the embodiments of the present application may be provided as methods, systems, or computer program products. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) having computer-usable program code embodied therein.

本申请是参照根据本申请实施例的方法、设备(系统)、和计算机程序产品的流程图和/或方框图来描述的。应理解可由计算机程序指令实现流程图和/或方框图中的每一流程和/或方框、以及流程图和/或方框图中的流程和/或方框的结合。可提供这些计算机程序指令到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理设备的处理器执行的指令产生用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的装置。The present application is described with reference to flowcharts and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the present application. It should be understood that each procedure and/or block in the flowchart and/or block diagram, and combinations of procedures and/or blocks in the flowchart and/or block diagram can be realized by computer program instructions. These computer program instructions may be provided to a general purpose computer, special purpose computer, embedded processor, or processor of other programmable data processing equipment to produce a machine such that the instructions executed by the processor of the computer or other programmable data processing equipment produce a Means for realizing the functions specified in one or more steps of the flowchart and/or one or more blocks of the block diagram.

这些计算机程序指令也可存储在能引导计算机或其他可编程数据处理设备以特定方式工作的计算机可读存储器中,使得存储在该计算机可读存储器中的指令产生包括指令装置的制造品,该指令装置实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能。These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing apparatus to operate in a specific manner, such that the instructions stored in the computer-readable memory produce an article of manufacture comprising instruction means, the instructions The device realizes the function specified in one or more procedures of the flowchart and/or one or more blocks of the block diagram.

这些计算机程序指令也可装载到计算机或其他可编程数据处理设备上,使得在计算机或其他可编程设备上执行一系列操作步骤以产生计算机实现的处理,从而在计算机或其他可编程设备上执行的指令提供用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的步骤。These computer program instructions can also be loaded onto a computer or other programmable data processing device, causing a series of operational steps to be performed on the computer or other programmable device to produce a computer-implemented process, thereby The instructions provide steps for implementing the functions specified in the flow chart flow or flows and/or block diagram block or blocks.

尽管已描述了本申请的优选实施例,但本领域内的技术人员一旦得知了基本创造性概念,则可对这些实施例做出另外的变更和修改。所以,所附权利要求意欲解释为包括优选实施例以及落入本申请范围的所有变更和修改。While preferred embodiments of the present application have been described, additional changes and modifications to these embodiments can be made by those skilled in the art once the basic inventive concept is appreciated. Therefore, the appended claims are intended to be construed to cover the preferred embodiment and all changes and modifications which fall within the scope of the application.

显然,本领域的技术人员可以对本申请进行各种改动和变型而不脱离本申请的精神和范围。这样,倘若本申请的这些修改和变型属于本申请权利要求及其等同技术的范围之内,则本申请也意图包含这些改动和变型在内。Obviously, those skilled in the art can make various changes and modifications to the application without departing from the spirit and scope of the application. In this way, if these modifications and variations of the present application fall within the scope of the claims of the present application and their equivalent technologies, the present application is also intended to include these modifications and variations.

Claims (10)

1.一种基于三层接口的MPLS-TP配置方法,其特征在于,所述方法包括:1. a kind of MPLS-TP configuration method based on three-layer interface, it is characterized in that, described method comprises: 接收配置启动指令唤醒同步信号量,根据标签信息及下一跳IP地址信息在自身保存的标签地址表中查找对应的VLAN接口信息,通过查找到的每个VLAN接口发送该标签信息的ARP请求报文,其中,所述标签地址表中保存有标签信息、下一跳IP地址信息、VLAN信息、出端口信息及目的MAC地址信息;Receive the configuration start command to wake up the synchronous semaphore, search the corresponding VLAN interface information in the label address table saved by itself according to the label information and the next hop IP address information, and send the ARP request report of the label information through each VLAN interface found The text, wherein, label information, next hop IP address information, VLAN information, outgoing port information and destination MAC address information are stored in the label address table; 接收返回的该标签信息的ARP回复报文,获取所述ARP回复报文中携带的目的MAC地址信息、出端口信息及VLAN信息,根据该标签信息及所述ARP回复报文的VLAN信息,在标签协议表中查找对应的目的MAC地址信息及出端口信息;Receive the returned ARP reply message of the tag information, obtain the destination MAC address information, outgoing port information and VLAN information carried in the ARP reply message, according to the tag information and the VLAN information of the ARP reply message, in Find the corresponding destination MAC address information and outbound port information in the label protocol table; 将查找到的该目的MAC地址信息及出端口信息与所述ARP回复报文中携带的MAC地址信息及出端口信息进行比较,当确定与所述ARP回复报文中携带目的MAC地址信息及出端口信息不一致时,根据所述ARP回复报文中携带的目的MAC地址信息及出端口信息,通过将标签地址表中的目的MAC地址信息及出端口信息更新为ARP回复报文中携带的目的MAC地址信息及出端口信息,对标签地址表进行更新。Comparing the found MAC address information and outgoing port information with the MAC address information and outgoing port information carried in the ARP reply message, when it is determined that the destination MAC address information and outgoing port information are carried in the ARP reply message When the port information is inconsistent, according to the destination MAC address information and outgoing port information carried in the ARP reply message, update the destination MAC address information and outgoing port information in the label address table to the destination MAC address information carried in the ARP reply message. Address information and outbound port information, and update the label address table. 2.如权利要求1所述的方法,其特征在于,所述配置启动指令包括:2. The method according to claim 1, wherein the configuration startup instruction comprises: 通过用户命令配置开启MPLS使能,配置下一跳的IP地址时唤醒同步信号量;或者,Enable MPLS through user command configuration, and wake up the synchronization semaphore when configuring the IP address of the next hop; or, 通过端口的UP事件,触发网络侧端口发送ARP请求报文;或者,Through the UP event of the port, the port on the network side is triggered to send an ARP request message; or, 通过在三层接口的ARP更新事件时,触发硬件下载标签配置。When the ARP update event of the layer-3 interface is used, the hardware is triggered to download the label configuration. 3.如权利要求1所述的方法,其特征在于,所述据该标签信息及所述ARP回复报文的VLAN信息,在标签协议表中查找对应的目的MAC地址信息及出端口信息包括:3. The method according to claim 1, wherein, according to the VLAN information of the label information and the ARP reply message, searching for corresponding destination MAC address information and outgoing port information in the label protocol table comprises: 根据所述ARP回复报文中的VLAN信息及该标签信息,在标签地址表中进行查找,判断标签地址表中是否保存有对应的目的MAC地址信息和出端口信息;According to the VLAN information and the label information in the ARP reply message, search in the label address table, and judge whether there are corresponding destination MAC address information and outgoing port information stored in the label address table; 当确定所述标签地址表中未保存有对应的目的MAC地址信息和出端口信息时,根据所述ARP回复报文中VLAN信息、目的MAC地址信息、出端口信息及该标签信息,创建多协议标签隧道及该隧道上承载的所有虚电路的接口,并创建交叉连接AC业务。When it is determined that the corresponding destination MAC address information and outgoing port information are not stored in the label address table, according to the VLAN information, destination MAC address information, outgoing port information and the label information in the ARP reply message, create a multi-protocol Label the tunnel and the interfaces of all virtual circuits carried by the tunnel, and create cross-connect AC services. 4.如权利要求1所述的方法,其特征在于,对标签地址表进行更新之后,方法还包括:4. The method according to claim 1, characterized in that, after the tag address table is updated, the method further comprises: 清除已建立的交叉连接AC业务,根据所述ARP回复报文中携带VLAN信息、目的MAC地址信息、出端口信息及该标签信息,更新多协议标签交换隧道及该隧道上承载的所有虚电路接口,并创建新的交叉连接AC业务。Clear the established cross-connect AC service, and update the MPLS tunnel and all virtual circuit interfaces carried on the tunnel according to the VLAN information, destination MAC address information, egress port information and the label information carried in the ARP reply message , and create a new cross-connect AC service. 5.如权利要求3或4所述的方法,其特征在于,还包括:5. The method according to claim 3 or 4, further comprising: 根据多协议标签交换隧道接口及该隧道上承载的虚电路的接口,创建本端维护点和远端维护点,镜像交换芯片接收的CCM报文到从CPU,重定向从CPU发送的CCM报文到交换芯片的出端口;Create a local maintenance point and a remote maintenance point according to the interface of the MPLS tunnel and the interface of the virtual circuit carried by the tunnel, mirror the CCM message received by the switching chip to the slave CPU, and redirect the CCM message sent from the CPU to the output port of the switch chip; 镜像交换芯片接收的环回报文到主CPU,重定向主CPU发送的环回报文到交换芯片的出端口。The loopback packets received by the mirrored switch chip are sent to the main CPU, and the loopback packets sent by the main CPU are redirected to the egress port of the switch chip. 6.一种基于三层接口的MPLS-TP配置装置,其特征在于,所述装置包括:6. A kind of MPLS-TP configuration device based on three-layer interface, it is characterized in that, described device comprises: 查找发送模块,用于接收配置启动指令唤醒同步信号量,根据标签信息及下一跳IP地址信息在自身保存的标签地址表中查找对应的VLAN接口信息,通过查找到的每个VLAN接口发送该标签信息的ARP请求报文,其中,所述标签地址表中保存有标签信息、下一跳IP地址信息、VLAN信息、出端口信息及目的MAC地址信息;The search sending module is used to receive the configuration start command to wake up the synchronous semaphore, search the corresponding VLAN interface information in the label address table saved by itself according to the label information and the next hop IP address information, and send the information through each VLAN interface found. An ARP request message for label information, wherein label information, next-hop IP address information, VLAN information, outgoing port information and destination MAC address information are stored in the label address table; ARP处理模块,用于接收返回的该标签信息的ARP回复报文,获取所述ARP回复报文中携带的目的MAC地址信息、出端口信息及VLAN信息,根据该标签信息及所述ARP回复报文的VLAN信息,在标签协议表中查找对应的目的MAC地址信息及出端口信息;The ARP processing module is used to receive the returned ARP reply message of the label information, obtain the destination MAC address information, outgoing port information and VLAN information carried in the ARP reply message, and according to the label information and the ARP reply message VLAN information of the text, look up the corresponding destination MAC address information and outbound port information in the label protocol table; 配置更新模块,用于将查找到的该目的MAC地址信息及出端口信息与所述ARP回复报文中携带的MAC地址信息及出端口信息进行比较,当确定与所述ARP回复报文中携带目的MAC地址信息及出端口信息不一致时,根据所述ARP回复报文中携带的目的MAC地址信息及出端口信息,通过将标签地址表中的目的MAC地址信息及出端口信息更新为ARP回复报文中携带的目的MAC地址信息及出端口信息,对标签地址表进行更新。The configuration update module is used to compare the MAC address information and the outgoing port information of the purpose found with the MAC address information and the outgoing port information carried in the ARP reply message, and when it is determined that it is the same as that carried in the ARP reply message When the destination MAC address information and the outgoing port information are inconsistent, according to the destination MAC address information and the outgoing port information carried in the ARP reply message, the destination MAC address information and the outgoing port information in the label address table are updated to the ARP reply report. The destination MAC address information and outbound port information carried in the text update the label address table. 7.如权利要求6所述的装置,其特征在于,所述装置还包括:7. The device of claim 6, further comprising: 配置启动模块,用于通过用户命令配置开启MPLS使能,配置下一跳的IP地址时唤醒同步信号量;或者,通过端口的UP事件,触发网络侧端口发送ARP请求报文;或者,通过在三层接口的ARP更新事件时,触发硬件下载标签配置。Configure the startup module, which is used to enable MPLS through user command configuration, and wake up the synchronization semaphore when configuring the IP address of the next hop; or, through the UP event of the port, trigger the port on the network side to send an ARP request message; or, through When an ARP update event occurs on a Layer 3 interface, the hardware is triggered to download the label configuration. 8.如权利要求6所述的装置,其特征在于,所述装置还包括:8. The device of claim 6, further comprising: ARP处理模块,还用于根据所述ARP回复报文中的VLAN信息及该标签信息,在标签地址表中进行查找,判断标签地址表中是否保存有对应的目的MAC地址信息和出端口信息;The ARP processing module is also used to search in the label address table according to the VLAN information and the label information in the ARP reply message, and judge whether the corresponding destination MAC address information and outgoing port information are stored in the label address table; AC转发模块,用于当确定所述标签地址表中未保存有对应的目的MAC地址信息和出端口信息时,根据所述ARP回复报文中VLAN信息、目的MAC地址信息、出端口信息及该标签信息,创建多协议标签隧道及该隧道上承载的所有虚电路的接口,并创建交叉连接AC业务。The AC forwarding module is configured to respond to the VLAN information, destination MAC address information, outbound port information and Label information, create a multi-protocol label tunnel and interfaces of all virtual circuits carried by the tunnel, and create cross-connect AC services. 9.如权利要求6所述的装置,其特征在于,所述AC转发模块,还用于清除已建立的交叉连接AC业务,根据所述ARP回复报文中携带VLAN信息、目的MAC地址信息、出端口信息及该标签信息,更新多协议标签交换隧道及该隧道上承载的所有虚电路接口,并创建新的交叉连接AC业务。9. The device according to claim 6, wherein the AC forwarding module is further configured to clear the established cross-connection AC service, according to the ARP reply message carrying VLAN information, destination MAC address information, Outgoing port information and the label information, update the multi-protocol label switching tunnel and all virtual circuit interfaces carried on the tunnel, and create a new cross-connect AC service. 10.如权利要求8或9所述的装置,其特征在于,所述装置还包括:10. The device according to claim 8 or 9, further comprising: OAM处理模块,用于根据多协议标签交换隧道接口及该隧道上承载的虚电路的接口,创建本端维护点和远端维护点,镜像交换芯片接收的CCM报文到从CPU,重定向从CPU发送的CCM报文到交换芯片的出端口;镜像交换芯片接收的环回报文到主CPU,重定向主CPU发送的环回报文到交换芯片的出端口。The OAM processing module is used to create a local maintenance point and a remote maintenance point according to the multi-protocol label switching tunnel interface and the interface of the virtual circuit carried on the tunnel, mirror the CCM message received by the switching chip to the slave CPU, and redirect the slave CPU The CCM message sent by the CPU is sent to the output port of the switch chip; the loopback message received by the mirrored switch chip is sent to the main CPU, and the loopback message sent by the redirected main CPU is sent to the output port of the switch chip.
CN201310647325.4A 2013-12-06 2013-12-06 Three-layered interface based MPLS-TP (multi-protocol label switching-transport profile) configuration method and device Active CN103634423B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201310647325.4A CN103634423B (en) 2013-12-06 2013-12-06 Three-layered interface based MPLS-TP (multi-protocol label switching-transport profile) configuration method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310647325.4A CN103634423B (en) 2013-12-06 2013-12-06 Three-layered interface based MPLS-TP (multi-protocol label switching-transport profile) configuration method and device

Publications (2)

Publication Number Publication Date
CN103634423A CN103634423A (en) 2014-03-12
CN103634423B true CN103634423B (en) 2017-01-18

Family

ID=50215038

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310647325.4A Active CN103634423B (en) 2013-12-06 2013-12-06 Three-layered interface based MPLS-TP (multi-protocol label switching-transport profile) configuration method and device

Country Status (1)

Country Link
CN (1) CN103634423B (en)

Families Citing this family (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104283983B (en) * 2014-10-27 2018-01-09 新华三技术有限公司 Virtual machine IP address distribution method and device in a kind of software defined network
CN105812163B (en) * 2014-12-31 2019-02-12 北京东土科技股份有限公司 A method and system for preventing port Vlan configuration errors
DE102017123251A1 (en) * 2016-10-07 2018-04-12 Hyundai Motor Company Operating method of a communication node for selective waking in the vehicle network
CN106790757B (en) * 2016-12-29 2019-09-20 迈普通信技术股份有限公司 A kind of method and device that ARP entry updates
CN108092860B (en) * 2017-12-07 2019-09-10 中盈优创资讯科技有限公司 Two etale topology topology discovery method, apparatus, storage medium and the equipment of Metropolitan Area Network (MAN)
CN111435948B (en) * 2019-01-12 2021-11-19 华为技术有限公司 Method for transmitting message in network and network equipment
CN112180817B (en) * 2019-07-02 2021-11-16 北京东土科技股份有限公司 Method, device, device and storage medium for converting binary tree from ladder diagram
CN110457228B (en) * 2019-08-22 2022-12-20 携程计算机技术(上海)有限公司 Method and system for comparing messages returned by interfaces
CN111970201A (en) * 2020-08-28 2020-11-20 迈普通信技术股份有限公司 Multi-chip cascade forwarding system and forwarding control method
CN119420713B (en) * 2024-09-29 2025-10-28 新华三技术有限公司 AC LIF maintenance method, electronic equipment, device and storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1581818A (en) * 2003-07-31 2005-02-16 华为技术有限公司 Method for supporting multi-port virtual LAN by multi-protocol label swtich
CN1980177A (en) * 2005-12-02 2007-06-13 中兴通讯股份有限公司 Method for realizing virtual special local network service broadcast
CN102035740A (en) * 2010-12-17 2011-04-27 中兴通讯股份有限公司 Multi-protocol label switching layer-3 virtual private network fast reroute (MPLSL3VPNFRR) method and system

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
DE602006002961D1 (en) * 2006-05-04 2008-11-13 Nokia Siemens Networks Gmbh Automatic backup of the forwarding of the packets into the MPLS network in a double-linked Ethernet bridge
KR100927126B1 (en) * 2007-11-26 2009-11-18 한국전자통신연구원 The entry and exit nodes of the MPS network with improved packet transmission speed, and the packet transmission speed improvement method of the MPS network system

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1581818A (en) * 2003-07-31 2005-02-16 华为技术有限公司 Method for supporting multi-port virtual LAN by multi-protocol label swtich
CN1980177A (en) * 2005-12-02 2007-06-13 中兴通讯股份有限公司 Method for realizing virtual special local network service broadcast
CN102035740A (en) * 2010-12-17 2011-04-27 中兴通讯股份有限公司 Multi-protocol label switching layer-3 virtual private network fast reroute (MPLSL3VPNFRR) method and system

Also Published As

Publication number Publication date
CN103634423A (en) 2014-03-12

Similar Documents

Publication Publication Date Title
CN103634423B (en) Three-layered interface based MPLS-TP (multi-protocol label switching-transport profile) configuration method and device
CN105453487B (en) Method, apparatus, and medium for dual-homing deployment in a data center environment
US9386047B2 (en) Method, switch, server and system for sending connection establishment request
TW202026896A (en) Asynchronous object manager in a network routing environment
US10263808B2 (en) Deployment of virtual extensible local area network
CN101047601B (en) Implementation method and system of dual-homing network based on VPLS
CN109660441B (en) Method and device for multicast replication in overlay network
WO2014194749A1 (en) Vpn implementation processing method and apparatus for edge device
WO2015000362A1 (en) Service node configuration method, service node pond register and system
EP2661847A1 (en) Pseudo wire switching method and device
CN108075969B (en) Message forwarding method and device
EP2852108B1 (en) Method and device for clearing media access control forwarding table items
US11601335B2 (en) Methods and systems for neighbor-acknowledged graceful insertion/removal protocol
CN106452862A (en) Method and device for determining loop network
CN112422398A (en) Message transmission method and communication device
US20190215191A1 (en) Deployment Of Virtual Extensible Local Area Network
CN107911495B (en) MAC address synchronization method and VTEP
CN104184667B (en) Flux of multicast moving method and device in a kind of SPB network of M in M-modes
CN115174312B (en) Broadcast information transmission method, tunnel endpoint device, electronic device, and medium
JP2014140095A (en) Communication system and network relay device
CN103685029B (en) Message forwarding method and equipment in a kind of rapid ring protection protocol networking
CN108667729B (en) SDN service isolation and routing method and device based on MPLS
WO2012062106A1 (en) Tunnel multiplexing method for linear protection group and tail-node of tunnel
CN102232277B (en) Method, system and corresponding device for implementing border gateway protocol - advertised discovery (BGP-AD)
CN114095552B (en) BFD Session Establishment Methods, Equipment, and Systems

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant