[go: up one dir, main page]

CN103856404B - Data transmission method, device and system in a kind of looped network - Google Patents

Data transmission method, device and system in a kind of looped network Download PDF

Info

Publication number
CN103856404B
CN103856404B CN201310722942.6A CN201310722942A CN103856404B CN 103856404 B CN103856404 B CN 103856404B CN 201310722942 A CN201310722942 A CN 201310722942A CN 103856404 B CN103856404 B CN 103856404B
Authority
CN
China
Prior art keywords
ring
message
node
label
hop node
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
CN201310722942.6A
Other languages
Chinese (zh)
Other versions
CN103856404A (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.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies 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 Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN201310722942.6A priority Critical patent/CN103856404B/en
Publication of CN103856404A publication Critical patent/CN103856404A/en
Application granted granted Critical
Publication of CN103856404B publication Critical patent/CN103856404B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Small-Scale Networks (AREA)

Abstract

The embodiment of the invention discloses the data transmission method in a kind of looped network, device and system.The embodiment of the present invention is used and receives message on the building ring of MPLS TP looped networks, wherein, the message includes ring label, label switched path label, pseudo line tag and payload, and label switched path label includes the ring mark of purpose ring and the node identification of destination node, pseudo line tag includes the ring mark of source ring and the node identification of source node, then, ring label in the message, label switched path label, pseudo line tag inquires about preset not intercommunication list, to determine the need for forwarding the packet to next-hop node, if desired, then forward the packet to next-hop node, if need not, then omit the operation for forwarding the packet to next-hop node;The program not only can simply and neatly realize the intercommunication and not intercommunication between node, improve efficiency of transmission, and, also allow for follow-up maintenance.

Description

一种环网中的数据传输方法、装置和系统A data transmission method, device and system in a ring network

技术领域technical field

本发明涉及通信技术领域,具体涉及一种环网中的数据传输方法、装置和系统。The invention relates to the field of communication technology, in particular to a data transmission method, device and system in a ring network.

背景技术Background technique

近年来,随着移动通信技术的发展,通信业务尤其是网际协议(IP,InternetProtocol)业务也逐年递升,为了满足不断增长的IP业务的需求,各种基于IP业务的数据传输方式应运而生,基于多协议标签交换的传输子集(MPLS-TP,MultiProtocol LabelSwitching Transport Profile)环网技术就是其中的一种。In recent years, with the development of mobile communication technology, communication services, especially Internet Protocol (IP, Internet Protocol) services are also increasing year by year. In order to meet the growing needs of IP services, various data transmission methods based on IP services have emerged. The ring network technology based on multi-protocol label switching (MPLS-TP, MultiProtocol LabelSwitching Transport Profile) is one of them.

MPLS-TP技术,举例来说,可以采用环状拓扑,双环结构,其中,外环也称为工作环,内环也称为保护环。外环顺时针和内环逆时针同时双向传输数据,外环携带内环数据包的管理字节,内环携带外环数据包的管理字节,从而使得双环互为保护和备份,提高数据传输的安全性。MPLS-TP technology, for example, can adopt a ring topology and a double-ring structure, wherein the outer ring is also called a working ring, and the inner ring is also called a protection ring. The outer ring is clockwise and the inner ring is anticlockwise and bidirectionally transmits data at the same time. The outer ring carries the management byte of the inner ring data packet, and the inner ring carries the management byte of the outer ring data packet, so that the two rings can protect and backup each other and improve data transmission. security.

现有的MPLS-TP环网的数据传输方式不够灵活,不利于提高传输效率。The data transmission mode of the existing MPLS-TP ring network is not flexible enough, which is not conducive to improving the transmission efficiency.

发明内容Contents of the invention

本发明实施例提供一种环网中的数据传输方法、装置和系统,可以灵活地实现节点间的互通和不互通,提高传输效率。Embodiments of the present invention provide a data transmission method, device and system in a ring network, which can flexibly realize intercommunication or non-intercommunication between nodes, and improve transmission efficiency.

第一方面,提供一种环网中的数据传输方法,包括:In the first aspect, a data transmission method in a ring network is provided, including:

在MPLS-TP环网的工作环上接收报文,所述报文中包括环标签、标签交换路径标签、伪线标签和净荷,所述标签交换路径标签包括目的环的环标识和目的节点的节点标识,所述伪线标签包括源环的环标识和源节点的节点标识;Receive a message on the working ring of the MPLS-TP ring network, the message includes a ring label, a label-switched path label, a pseudowire label and a payload, and the label-switched path label includes the ring identifier of the destination ring and the destination node The node identifier of the pseudowire label includes the ring identifier of the source ring and the node identifier of the source node;

根据所述报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将所述报文转发给下一跳节点;Querying a preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the message to determine whether the message needs to be forwarded to a next-hop node;

若确定需要将所述报文转发给下一跳节点,则将所述报文转发给下一跳节点;If it is determined that the message needs to be forwarded to the next-hop node, then forward the message to the next-hop node;

若确定不需要将所述报文转发给下一跳节点,则省略将所述报文转发给下一跳节点的操作。If it is determined that the packet does not need to be forwarded to the next-hop node, the operation of forwarding the packet to the next-hop node is omitted.

在第一种可能的实施方式中,结合第一方面,所述根据所述报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定所述报文是否需要转发给下一跳节点之前,还包括:In a first possible implementation manner, in combination with the first aspect, querying a preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the message to determine whether the message is Before forwarding to the next hop node, it also includes:

根据所述报文中的标签交换路径标签查询终结环回报文列表,以确定是否为环路;Querying the list of terminated loop return packets according to the label switched path label in the packet to determine whether it is a loop;

若确定为环路,则丢弃报文;If it is determined to be a loop, discard the message;

若确定不是环路,则触发执行根据所述报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定所述报文是否需要转发给下一跳节点的操作。If it is determined that it is not a loop, then trigger execution according to the ring label, label switching path label, and pseudowire label in the message to query the preset non-interworking list to determine whether the message needs to be forwarded to the next hop node operate.

在第二种可能的实施方式中,结合第一方面的第一种可能的实施方式,所述根据所述报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将所述报文转发给下一跳节点之前,还包括:In a second possible implementation manner, in combination with the first possible implementation manner of the first aspect, the querying of the preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the packet , before determining whether to forward the message to the next hop node, it also includes:

确定所述报文为组播报文;determining that the packet is a multicast packet;

复制所述报文,并将复制的报文发送给当前节点的虚拟转发实例或虚拟租用线。The message is copied, and the copied message is sent to the virtual forwarding instance or the virtual leased line of the current node.

在第三种可能的实施方式中,结合第一方面的第一种可能的实施方式,所述根据所述报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将所述报文转发给下一跳节点之前,还包括:In a third possible implementation manner, in combination with the first possible implementation manner of the first aspect, querying a preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the packet , before determining whether to forward the message to the next hop node, it also includes:

确定所述报文为单播报文;determining that the packet is a unicast packet;

根据所述报文中的标签交换路径标签确定需要交换时,触发执行根据所述报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将所述报文转发给下一跳节点的操作;When it is determined that switching is required according to the label switched path label in the message, it is triggered to query the preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the message to determine whether all of them need to be switched. Describe the operation of forwarding the message to the next hop node;

根据所述报文中的标签交换路径标签确定为弹掉POP时,将所述报文发送给当前节点的虚拟转发实例或虚拟租用线。When it is determined that the POP is popped according to the label switched path label in the message, the message is sent to the virtual forwarding instance or the virtual leased line of the current node.

在第四种可能的实施方式中,结合第一方面、第一方面的第一至三任一种可能的实施方式,所述将所述报文转发给下一跳节点,包括:In a fourth possible implementation manner, in combination with the first aspect and any one of the first to third possible implementation manners of the first aspect, the forwarding the message to the next-hop node includes:

对所述MPLS-TP环网的工作环的链路和下一跳节点进行检测;Detecting the link and the next hop node of the working ring of the MPLS-TP ring network;

若检测到链路故障,则进行保护倒换,通过MPLS-TP环网的保护环将所述报文发送给下一跳节点;If a link failure is detected, then protection switching is performed, and the message is sent to the next hop node through the protection ring of the MPLS-TP ring network;

若检测到下一跳节点故障,则进行保护倒换,通过MPLS-TP环网的保护环,利用绕过故障节点的路径将所述报文发送给下一跳节点的下一跳节点;If the failure of the next hop node is detected, then protection switching is performed, and the message is sent to the next hop node of the next hop node by using the path bypassing the faulty node through the protection ring of the MPLS-TP ring network;

若既没有检测到链路故障也没有检测到下一跳节点故障,则通过MPLS-TP环网的工作环将所述报文转发给下一跳节点。If neither link failure nor next-hop node failure is detected, the message is forwarded to the next-hop node through the working ring of the MPLS-TP ring network.

在第五种可能的实施方式中,结合第一方面、第一方面的第一至三任一种可能的实施方式,若所述MPLS-TP环网的工作环包括核心工作环和接入工作环,则所述将所述报文转发给下一跳节点,包括:In the fifth possible implementation manner, in combination with the first aspect and any one of the first to third possible implementation manners of the first aspect, if the working ring of the MPLS-TP ring network includes a core working ring and an access working ring ring, then the described message is forwarded to the next hop node, including:

若下一跳节点位于核心工作环上,且为主相交环点,则在确定与所述下一跳节点相关的多条链路发生故障时,或在确定所述下一跳节点发生故障时,通过MPLS-TP环网的保护环,利用所述备相交环点将所述报文传输到接入工作环中。If the next hop node is located on the core working ring and is the primary intersecting ring point, when it is determined that multiple links related to the next hop node fail, or when it is determined that the next hop node fails , using the backup intersecting ring point to transmit the message to the access working ring through the protection ring of the MPLS-TP ring network.

在第六种可能的实施方式中,结合第一方面的第五种可能的实施方式,在确定与所述下一跳节点相关的多条链路发生故障时,通过MPLS-TP环网的保护环,利用所述备相交环点将所述报文传输到接入工作环中,包括:In the sixth possible implementation manner, in combination with the fifth possible implementation manner of the first aspect, when it is determined that multiple links related to the next-hop node fail, the MPLS-TP ring network protection ring, using the backup intersecting ring point to transmit the message to the access working ring, including:

在确定与所述下一跳节点相关的多条链路发生故障时,由所述下一跳节点通知备相交环点挂接接入工作环的阻塞点,以便通过MPLS-TP环网的保护环,利用所述备相交环点将所述报文传输到接入工作环中。When it is determined that multiple links related to the next hop node fail, the next hop node notifies the standby intersecting ring point to connect to the blocking point of the working ring, so as to pass the protection of the MPLS-TP ring network ring, using the backup intersecting ring point to transmit the message to the access working ring.

在第七种可能的实施方式中,结合第一方面的第五种可能的实施方式,在确定所述下一跳节点发生故障时,通过MPLS-TP环网的保护环,利用所述备相交环点将所述报文传输到接入工作环中,包括:In the seventh possible implementation manner, in combination with the fifth possible implementation manner of the first aspect, when it is determined that the next hop node fails, the protection ring of the MPLS-TP ring network is used to use the backup intersecting The ring point transmits the message to the access working ring, including:

在确定所述下一跳节点发生故障时,由备相交环点感知主相交环点故障并挂接接入工作环的阻塞点,以便通过MPLS-TP环网的保护环,利用所述备相交环点将所述报文传输到接入工作环中。When it is determined that the next hop node fails, the standby intersecting ring point senses the failure of the primary intersecting ring point and connects to the blocking point of the working ring, so that the standby intersecting ring can be used through the protection ring of the MPLS-TP ring network. The ring point transmits the message to the access working ring.

在第八种可能的实施方式中,结合第一方面、第一方面的第一至三任一种可能的实施方式,若所述MPLS-TP环网的工作环包括核心工作环和接入工作环,则:In the eighth possible implementation manner, in combination with the first aspect and any one of the first to third possible implementation manners of the first aspect, if the working ring of the MPLS-TP ring network includes a core working ring and an access working ring ring, then:

若当前节点位于核心工作环上,且为主相交环点,则在将所述报文发送给位于接入工作环上的下一跳节点时,刷新相交点表项;If the current node is located on the core working ring and is the main intersecting ring point, when the message is sent to the next hop node located on the access working ring, the intersection table item is refreshed;

若当前节点位于核心工作环上,且为备相交环点,则当所述当前节点与所述当前节点的虚拟转发实例/虚拟租用线的连接关系由阻塞变为不阻塞,或由不阻塞变为阻塞时,清除所述当前节点上的所有表项,所述虚拟转发实例/虚拟租用线挂接到接入工作环的初始状态为阻塞。If the current node is located on the core working ring and is a standby intersecting ring point, when the connection relationship between the current node and the virtual forwarding instance/virtual leased line of the current node changes from blocking to non-blocking, or from non-blocking to When it is blocked, all entries on the current node are cleared, and the initial state of the virtual forwarding instance/virtual leased line attached to the access working ring is blocked.

第二方面,提供一种环网中的数据传输装置,包括接收单元、查询单元、发送单元和阻塞单元;In a second aspect, a data transmission device in a ring network is provided, including a receiving unit, a query unit, a sending unit, and a blocking unit;

接收单元,用于在MPLS-TP环网的工作环上接收报文,所述报文中包括环标签、标签交换路径标签、伪线标签和净荷,所述标签交换路径标签包括目的环的环标识和目的节点的节点标识,所述伪线标签包括源环的环标识和源节点的节点标识;The receiving unit is used to receive a message on the working ring of the MPLS-TP ring network, the message includes a ring label, a label switched path label, a pseudowire label and a payload, and the label switched path label includes the destination ring a ring identifier and a node identifier of a destination node, wherein the pseudowire label includes a ring identifier of a source ring and a node identifier of a source node;

查询单元,用于根据所述报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将所述报文转发给下一跳节点;A query unit, configured to query a preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the message to determine whether the message needs to be forwarded to a next-hop node;

发送单元,用于在查询单元确定需要将所述报文转发给下一跳节点时,将所述报文转发给下一跳节点;a sending unit, configured to forward the message to the next-hop node when the query unit determines that the message needs to be forwarded to the next-hop node;

阻塞单元,用于在查询单元确定不需要将所述报文转发给下一跳节点时,省略将所述报文转发给下一跳节点的操作。A blocking unit, configured to omit the operation of forwarding the message to the next-hop node when the query unit determines that the message does not need to be forwarded to the next-hop node.

在第一种可能的实施方式中,结合第一方面,所述数据传输装置还包括确定单元;In a first possible implementation manner, with reference to the first aspect, the data transmission device further includes a determining unit;

所述确定单元,用于根据所述报文中的标签交换路径标签查询终结环回报文列表,以确定是否为环路,若为环路,则丢弃报文;若不是环路时,则触发查询单元执行根据所述报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定所述报文是否需要转发给下一跳节点的操作。The determination unit is configured to query the list of terminated loop return packets according to the label switched path label in the packet to determine whether it is a loop, and if it is a loop, discard the packet; if it is not a loop, trigger The query unit performs an operation of querying a preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the message to determine whether the message needs to be forwarded to a next-hop node.

在第二种可能的实施方式中,结合第一方面的第一种可能的实施方式,其中:In the second possible implementation manner, in combination with the first possible implementation manner of the first aspect, wherein:

所述发送单元,还用于确定所述报文为组播报文,复制所述报文,并将复制的报文发送给当前节点的虚拟转发实例或虚拟租用线。The sending unit is further configured to determine that the message is a multicast message, copy the message, and send the copied message to a virtual forwarding instance or a virtual leased line of the current node.

在第三种可能的实施方式中,结合第一方面的第一种可能的实施方式,其中:In a third possible implementation manner, in combination with the first possible implementation manner of the first aspect, wherein:

所述发送单元,还用于确定所述报文为单播报文;根据所述报文中的标签交换路径标签确定需要交换时,触发查询单元执行根据所述报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将所述报文转发给下一跳节点的操作;根据所述报文中的标签交换路径标签确定为弹掉POP时,将所述报文发送给当前节点的虚拟转发实例或虚拟租用线。The sending unit is also used to determine that the message is a unicast message; when it is determined that the switch needs to be switched according to the label switching path label in the message, trigger the query unit to perform the ring label and label switching according to the label in the message. The path label and the pseudowire label query the preset non-communication list to determine whether the message needs to be forwarded to the next hop node; when the label switching path label in the message is determined to be a pop-up POP, Send the message to the virtual forwarding instance or virtual leased line of the current node.

在第四种可能的实施方式中,结合第一方面、第一方面的第一至三任一种可能的实施方式,所述发送单元,具体用于:In a fourth possible implementation manner, in combination with the first aspect and any one of the first to third possible implementation manners of the first aspect, the sending unit is specifically configured to:

对所述MPLS-TP环网的工作环的链路和下一跳节点进行检测;Detecting the link and the next hop node of the working ring of the MPLS-TP ring network;

若检测到链路故障,则进行保护倒换,通过MPLS-TP环网的保护环上将所述报文发送给下一跳节点;若检测到下一跳节点故障,则进行保护倒换,通过MPLS-TP环网的保护环,利用绕过故障节点的路径将所述报文发送给下一跳节点的下一跳节点;If a link failure is detected, protection switching is performed, and the message is sent to the next hop node through the protection ring of the MPLS-TP ring network; if a failure of the next hop node is detected, protection switching is performed, and the MPLS - the protection ring of the TP ring network, using the path bypassing the faulty node to send the message to the next hop node of the next hop node;

若既没有检测到链路故障也没有检测到下一跳节点故障,则通过MPLS-TP环网的工作环将所述报文转发给下一跳节点。If neither link failure nor next-hop node failure is detected, the message is forwarded to the next-hop node through the working ring of the MPLS-TP ring network.

在第五种可能的实施方式中,结合第一方面、第一方面的第一至三任一种可能的实施方式,若所述MPLS-TP环网的工作环包括核心工作环和接入工作环,则所述发送单元,具体用于:In the fifth possible implementation manner, in combination with the first aspect and any one of the first to third possible implementation manners of the first aspect, if the working ring of the MPLS-TP ring network includes a core working ring and an access working ring ring, the sending unit is specifically used for:

若下一跳节点位于核心工作环上,且为主相交环点,则在确定与所述下一跳节点相关的多条链路发生故障时,或在确定所述下一跳节点发生故障时,通过MPLS-TP环网的保护环,利用所述备相交环点将所述报文传输到接入工作环中。If the next hop node is located on the core working ring and is the primary intersecting ring point, when it is determined that multiple links related to the next hop node fail, or when it is determined that the next hop node fails , using the backup intersecting ring point to transmit the message to the access working ring through the protection ring of the MPLS-TP ring network.

在第六种可能的实施方式中,结合第一方面的第五种可能的实施方式,所述发送单元,具体用于:In a sixth possible implementation manner, in combination with the fifth possible implementation manner of the first aspect, the sending unit is specifically configured to:

若下一跳节点位于核心工作环上,且为主相交环点,则在确定与所述下一跳节点相关的多条链路发生故障时,由所述下一跳节点通知备相交环点挂接接入工作环的阻塞点,以便通过MPLS-TP环网的保护环,利用所述备相交环点将所述报文传输到接入工作环中。If the next hop node is located on the core working ring and is the primary intersecting ring point, when it is determined that multiple links related to the next hop node fail, the next hop node notifies the standby intersecting ring point The blocking point of the access working ring is mounted, so as to transmit the message to the access working ring by using the backup intersecting ring point through the protection ring of the MPLS-TP ring network.

在第七种可能的实施方式中,结合第一方面的第五种可能的实施方式,所述发送单元,具体用于:In a seventh possible implementation manner, in combination with the fifth possible implementation manner of the first aspect, the sending unit is specifically configured to:

若下一跳节点位于核心工作环上,且为主相交环点,则在确定所述下一跳节点发生故障时,由备相交环点感知主相交环点故障并挂接接入工作环的阻塞点,以便通过MPLS-TP环网的保护环,利用所述备相交环点将所述报文传输到接入工作环中。If the next hop node is located on the core working ring and is the main intersecting ring point, when it is determined that the next hop node fails, the standby intersecting ring point senses the failure of the main intersecting ring point and connects to the active intersecting ring point. The blocking point is used to transmit the message to the access working ring by using the backup crossing ring point through the protection ring of the MPLS-TP ring network.

在第八种可能的实施方式中,结合第一方面、第一方面的第一至三任一种可能的实施方式,若所述MPLS-TP环网的工作环包括核心工作环和接入工作环,则所述环网中的数据传输装置还包括刷新单元,具体用于:In the eighth possible implementation manner, in combination with the first aspect and any one of the first to third possible implementation manners of the first aspect, if the working ring of the MPLS-TP ring network includes a core working ring and an access working ring ring, the data transmission device in the ring network also includes a refresh unit, specifically for:

若当前节点位于核心工作环上,且为主相交环点,则将所述报文发送给位于接入工作环上的下一跳节点时,刷新相交点表项;If the current node is located on the core working ring and is the main intersecting ring point, when the message is sent to the next hop node located on the access working ring, the intersecting point entry is refreshed;

若当前节点位于核心工作环上,且为备相交环点,则当所述当前节点与所述当前节点的虚拟转发实例/虚拟租用线的连接关系由阻塞变为不阻塞,或由不阻塞变为阻塞时,清除所述当前节点上的所有表项,所述虚拟转发实例/虚拟租用线挂接到接入工作环的初始状态为阻塞。If the current node is located on the core working ring and is a standby intersecting ring point, when the connection relationship between the current node and the virtual forwarding instance/virtual leased line of the current node changes from blocking to non-blocking, or from non-blocking to When it is blocked, all entries on the current node are cleared, and the initial state of the virtual forwarding instance/virtual leased line attached to the access working ring is blocked.

第三方面,提供一种通信系统,包括本发明实施例提供的任一种环网中的数据传输装置。In a third aspect, a communication system is provided, including any data transmission device in a ring network provided by the embodiments of the present invention.

本发明实施例采用在MPLS-TP环网的工作环上接收报文,其中,该报文采用MPLS进行封装,报文中包括环标签、标签交换路径标签、伪线标签和净荷,而标签交换路径标签包括目的环的环标识和目的节点的节点标识,伪线标签包括源环的环标识和源节点的节点标识,然后,根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将该报文转发给下一跳节点,若需要,则将该报文转发给下一跳节点,若不需要,则省略将所述报文转发给下一跳节点的操作;由于在该方案中维护了一张不互通列表,并通过查询该不互通列表来确定节点之间是否可以互通,因此,不仅可以简单且灵活地实现节点间的互通和不互通,提高传输效率,而且,也便于后续的维护。In the embodiment of the present invention, the message is received on the working ring of the MPLS-TP ring network, wherein the message is encapsulated by MPLS, and the message includes a ring label, a label switching path label, a pseudowire label and a payload, and the label The switch path label includes the ring identifier of the destination ring and the node identifier of the destination node, and the pseudowire label includes the ring identifier of the source ring and the node identifier of the source node. Then, according to the ring label, label switching path label, pseudowire The label queries the preset non-communication list to determine whether the message needs to be forwarded to the next-hop node. If necessary, the message is forwarded to the next-hop node. If not, the message is omitted The operation forwarded to the next hop node; since a non-communication list is maintained in this scheme, and whether the nodes can communicate with each other is determined by querying the non-communication list, it is not only simple and flexible to realize the inter-node Intercommunication and no intercommunication can improve transmission efficiency and facilitate subsequent maintenance.

附图说明Description of drawings

为了更清楚地说明本发明实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings that need to be used in the description of the embodiments will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present invention. For those skilled in the art, other drawings can also be obtained based on these drawings without any creative effort.

图1是本发明实施例提供的环网中的数据传输方法的流程图;FIG. 1 is a flowchart of a data transmission method in a ring network provided by an embodiment of the present invention;

图2a是本发明实施例提供的MPLS-TP环网的场景示意图;Figure 2a is a schematic diagram of a scenario of an MPLS-TP ring network provided by an embodiment of the present invention;

图2b是本发明实施例提供的环网中的数据传输方法的另一流程图;Fig. 2b is another flow chart of the data transmission method in the ring network provided by the embodiment of the present invention;

图3是本发明实施例提供的环网中的数据传输方法的又一流程图;Fig. 3 is another flow chart of the data transmission method in the ring network provided by the embodiment of the present invention;

图4a是本发明实施例提供的MPLS-TP环网发生链路故障时的场景示意图;FIG. 4a is a schematic diagram of a scene when a link failure occurs in an MPLS-TP ring network provided by an embodiment of the present invention;

图4b是本发明实施例提供的MPLS-TP环网发生节点故障时的场景示意图;FIG. 4b is a schematic diagram of a scene when a node failure occurs in an MPLS-TP ring network provided by an embodiment of the present invention;

图5是本发明实施例提供的MPLS-TP环网的又一场景示意图;FIG. 5 is a schematic diagram of another scenario of an MPLS-TP ring network provided by an embodiment of the present invention;

图6a是本发明实施例提供的MPLS-TP环网发生多点故障时的场景示意图;FIG. 6a is a schematic diagram of a scene when a multi-point failure occurs in an MPLS-TP ring network provided by an embodiment of the present invention;

图6b是本发明实施例提供的MPLS-TP环网中主相交环点发生故障时的场景示意图;FIG. 6b is a schematic diagram of a scenario when a failure occurs at a primary intersecting ring point in an MPLS-TP ring network provided by an embodiment of the present invention;

图7是本发明实施例提供的环网中的数据传输装置的结构示意图。Fig. 7 is a schematic structural diagram of a data transmission device in a ring network provided by an embodiment of the present invention.

具体实施方式detailed description

下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。The following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only some, not all, embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative efforts fall within the protection scope of the present invention.

本发明实施例提供一种环网中的数据传输方法、装置和系统。以下分别进行详细说明。Embodiments of the present invention provide a data transmission method, device and system in a ring network. Each will be described in detail below.

实施例一、Embodiment one,

本实施例将从环网中的数据传输装置的角度进行描述,该环网中的数据传输装置具体可以集成在路由器中,这些路由器可作为MPLS-TP环网中的节点。举例来说,MPLS-TP环网可以承载综合业务,例如单播业务和多播业务等。This embodiment will be described from the perspective of the data transmission device in the ring network. Specifically, the data transmission device in the ring network may be integrated in routers, and these routers may serve as nodes in the MPLS-TP ring network. For example, the MPLS-TP ring network can bear integrated services, such as unicast services and multicast services.

一种环网中的数据传输方法,包括:在MPLS-TP环网的工作环上接收报文,其中,该报文中包括环标签、标签交换路径标签、伪线(PW,Pseudo Wire,也称为虚链路)标签和净荷,标签交换路径(LSP,Label Switched Path)标签包括目的环的环标识和目的节点的节点标识,伪线标签包括源环的环标识和源节点的节点标识;根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将所述报文转发给下一跳节点;若确定需要将所述报文转发给下一跳节点,则将该报文转发给下一跳节点;若确定不需要将所述报文转发给下一跳节点,则省略将所述报文转发给下一跳节点的操作。A data transmission method in a ring network, comprising: receiving a message on a working ring of an MPLS-TP ring network, wherein the message includes a ring label, a label switching path label, a pseudowire (PW, Pseudo Wire, also Label and payload, Label Switched Path (LSP, Label Switched Path) label includes the ring ID of the destination ring and the node ID of the destination node, and the pseudowire label includes the ring ID of the source ring and the node ID of the source node ; Query the preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the message to determine whether the message needs to be forwarded to the next hop node; if it is determined that the message needs to be forwarded Forward to the next hop node, then forward the message to the next hop node; if it is determined that the message does not need to be forwarded to the next hop node, then omit the operation of forwarding the message to the next hop node .

如图1所示,具体流程可以如下:As shown in Figure 1, the specific process can be as follows:

101、在MPLS-TP环网的工作环(即外环)上接收报文。101. Receive the message on the working ring (that is, the outer ring) of the MPLS-TP ring network.

其中,该报文可以是组播报文,也可以是单播报文,与现有的环网中的报文不同的是,该报文采用多协议标签交换(MPLS,Multi-Protocol Label Switching)进行封装(现有是根据MAC来对报文进行转发),即该报文中可以包括环标签(ring label)、标签交换路径标签(lsp label)、伪线标签(pw label)和净荷,即该报文的格式为“环标签+标签交换路径标签+伪线标签+净荷”。Wherein, the message can be a multicast message or a unicast message. The difference from the message in the existing ring network is that the message adopts Multi-Protocol Label Switching (MPLS, Multi-Protocol Label Switching) Encapsulation (the existing message is forwarded according to the MAC), that is, the message can include the ring label (ring label), label switching path label (lsp label), pseudowire label (pw label) and payload, That is, the format of the message is "ring label + label switched path label + pseudowire label + payload".

其中,标签交换路径标签在格式上可以采用现有的标签交换路径标签的格式,但是其内容可以包括目的环的环标识(dring id)和目的节点的节点标识(dleaf id),伪线标签可以包括源环的环标识(sring id)和源节点的节点标识(sleaf id)。Among them, the format of the label switched path label can adopt the format of the existing label switched path label, but its content can include the ring ID (dring id) of the destination ring and the node ID (dleaf id) of the destination node, and the pseudowire label can be It includes the ring ID (sring id) of the source ring and the node ID (sleaf id) of the source node.

102、根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将该报文转发给下一跳节点,若需要将该报文转发给下一跳节点,则执行步骤103;若不需要将该报文转发给下一跳节点,则执行步骤104。102. Query the preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the message to determine whether the message needs to be forwarded to the next-hop node, and if the message needs to be forwarded to If the next hop node is selected, step 103 is performed; if the message does not need to be forwarded to the next hop node, step 104 is performed.

其中,该不互通列表可以包括环标识(ring id)和节点标识(leaf id),用于指示节点之间是否互通,从而通过报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,就可以确定是否需要将该报文转发给下一跳节点。Wherein, the non-interworking list may include a ring ID (ring id) and a node ID (leaf id), which are used to indicate whether the nodes are interoperable, so that the pre-checked information can be queried through the ring label, label switching path label, and pseudowire label in the message. It can be determined whether the message needs to be forwarded to the next-hop node through the configured non-interworking list.

其中,在步骤“根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定该报文是否需要转发给下一跳节点(即步骤102)”之前,还可以确定当前是否已构成环路,如果不是环路,才根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定该报文是否需要转发给下一跳节点,如果已经构成环路,则可以将该报文丢弃,即在步骤“根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定该报文是否需要转发给下一跳节点”之前,该方法还可以包括:Among them, before the step "query the preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the message to determine whether the message needs to be forwarded to the next-hop node (that is, step 102)" , you can also determine whether a loop is currently formed. If it is not a loop, check the preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the message to determine whether the message needs to be forwarded. For the next hop node, if a loop has been formed, the message can be discarded, that is, in the step "query the preset non-interworking list according to the ring label, label switching path label, and pseudowire label in the message, to Before determining whether the message needs to be forwarded to the next hop node", the method may also include:

根据该报文中的标签交换路径标签查询终结环回报文列表,以确定是否为环路,若为环路,则丢弃报文;若不是环路,则执行“根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定该报文是否需要转发给下一跳节点”的步骤(即步骤102)。According to the label switching path label in the message, query the list of the termination ring return message to determine whether it is a loop, if it is a loop, discard the message; if it is not a loop, execute "according to the ring label in the message , label switched path label, and pseudowire label to query the preset non-interworking list to determine whether the message needs to be forwarded to the next hop node" (that is, step 102).

此外,每个节点在接收到该报文后,根据报文传输方式的不同,还可以对报文作出进一步不同的处理,比如,对于组播而言,此时还可以复制一份报文发送给当前节点的虚拟转发实例(VSI,Virtual Switch Instance)或虚拟租用线(VLL,VirtualLeasedLine),以便该VSI或VLL可以根据该复制的报文刷新接入媒体层(MAC,Media Access Control)地址列表,并在VSI或VLL内部对该报文进行转发;而对于单播而言,则可以在根据该报文中的标签交换路径标签确定需要交换(swap)时,直接在环上进行交换(即ring swap),而如果根据该报文中的标签交换路径标签确定为弹掉(POP)时,则进入VSI或VLL,并进行VSI或VLL内部转发行为;即在步骤“根据所述报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将所述报文转发给下一跳节点(即步骤102)”之前,该方法还可以包括:In addition, after each node receives the message, it can further process the message according to the different transmission methods of the message. For example, for multicast, it can also copy a message and send it to To the virtual forwarding instance (VSI, Virtual Switch Instance) or virtual leased line (VLL, VirtualLeasedLine) of the current node, so that the VSI or VLL can refresh the access media layer (MAC, Media Access Control) address list according to the copied message , and forward the packet within the VSI or VLL; and for unicast, it can be swapped directly on the ring when it is determined according to the label switching path label in the packet that it needs to be swapped (swap). ring swap), and if it is determined to be a pop-up (POP) according to the label switching path label in the message, it will enter the VSI or VLL and perform the internal forwarding behavior of the VSI or VLL; that is, in the step "according to the message in the Before the ring label, label switched path label, and pseudowire label query the preset non-interworking list to determine whether the packet needs to be forwarded to the next-hop node (that is, step 102), the method may also include:

(1)组播;(1) Multicast;

确定该报文为组播报文,复制该报文(即组播报文),并将复制的报文发送给当前节点的VSI或VLL,以便VSI或VLL根据该复制的报文刷新MAC地址列表,并在VSI或VLL内部对所述报文进行转发。Determine that the message is a multicast message, copy the message (that is, a multicast message), and send the copied message to the VSI or VLL of the current node, so that the VSI or VLL can refresh the MAC address according to the copied message list, and forward the message inside the VSI or VLL.

(2)单播;(2) Unicast;

确定该报文为单播报文,根据该报文中的标签交换路径标签确定需要交换(swap)时,执行“根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将该报文转发给下一跳节点”的步骤;根据该报文中的标签交换路径标签确定为POP时,将该报文发送给当前节点的VSI或VLL,以便VSI或VLL根据该报文刷新MAC地址列表,并在VSI或VLL内部对该报文进行转发。It is determined that the packet is a unicast packet, and when it is determined that swap is required according to the label switching path label in the packet, execute "query the preset non-interworking list to determine whether the message needs to be forwarded to the next hop node” step; when the label switching path label in the message is determined to be POP, the message is sent to the VSI or VLL of the current node, So that the VSI or VLL refreshes the MAC address list according to the message, and forwards the message inside the VSI or VLL.

需说明的是,对于未知的单播报文,也按照组播进行处理,在此不再赘述。It should be noted that, for unknown unicast packets, they are also processed according to multicast, which will not be repeated here.

103、若确定需要将该报文转发给下一跳节点,则将该报文转发给下一跳节点。103. If it is determined that the packet needs to be forwarded to the next-hop node, forward the packet to the next-hop node.

例如,具体可以进行链路检测和节点检测,若均正常(即无故障),则直接通过工作环将该报文转发给下一跳节点,否则,若发现链路故障或节点故障,则进行保护倒换,即步骤103具体可以如下:For example, specific link detection and node detection can be performed. If both are normal (that is, there is no fault), the message will be forwarded to the next hop node directly through the working ring. Otherwise, if a link failure or node failure is found, then the Protection switching, that is, step 103 may specifically be as follows:

对该MPLS-TP环网的工作环的链路和下一跳节点进行检测,Detect the link and the next hop node of the working ring of the MPLS-TP ring network,

若检测到链路故障,则进行保护倒换,通过MPLS-TP环网的保护环(即内环)上将该报文发送给下一跳节点;If a link failure is detected, protection switching is performed, and the message is sent to the next hop node through the protection ring (ie inner ring) of the MPLS-TP ring network;

若检测到下一跳节点故障,则进行保护倒换,通过MPLS-TP环网的保护环(即内环),利用绕过故障节点的路径将该报文发送给下一跳节点的下一跳节点;If the failure of the next hop node is detected, protection switching will be performed, and the message will be sent to the next hop of the next hop node through the protection ring (that is, the inner ring) of the MPLS-TP ring network by using the path that bypasses the faulty node node;

若既没有检测到链路故障也没有检测到下一跳节点故障,则通过MPLS-TP环网的工作环将所述报文转发给下一跳节点。If neither link failure nor next-hop node failure is detected, the message is forwarded to the next-hop node through the working ring of the MPLS-TP ring network.

另外,需说明的是,该MPLS-TP环网可以是单环的,也可以是多环如双环。其中,双环可以包括核心工作环和接入工作环,其中,核心工作环和接入工作环可以包括两个相交环点,一个为主相交环点,另一个为备相交环点,其中,对于主相交环点和备相交环点这两个节点的VSI或VLL来说,既需要分别挂接在核心工作环上,也需要挂接在接入工作环上,但是,对于备相交环点而言,其VSI或VLL挂接在接入工作环的初始状态为阻塞,只有当主相交环点通知备相交环点挂接阻塞点时,或者,备相交环点感知主相交环点故障时,备相交环点才会接通(即挂接)阻塞点。In addition, it should be noted that the MPLS-TP ring network may be a single ring or multiple rings such as double rings. Wherein, the dual ring may include a core working ring and an access working ring, wherein the core working ring and the access working ring may include two intersecting ring points, one is a primary intersecting ring point, and the other is a standby intersecting ring point, wherein, for For the VSI or VLL of the two nodes, the primary intersecting ring point and the standby intersecting ring point, they need to be mounted on the core working ring and the access working ring respectively. However, for the standby intersecting ring point In other words, the initial state of its VSI or VLL connected to the working ring is blocked. Only when the master intersecting ring notifies the standby intersecting ring to attach the blocking point, or when the standby intersecting ring detects that the main intersecting ring fails, the backup Intersecting ring points will connect (that is, hook up) the choke point.

若该MPLS-TP环网的工作环包括核心工作环和接入工作环,则步骤“将该报文转发给下一跳节点”具体可以如下:If the working ring of the MPLS-TP ring network includes a core working ring and an access working ring, then the step "forwarding the message to the next hop node" can specifically be as follows:

若下一跳节点位于核心工作环上,且为主相交环点,则在确定与该下一跳节点相关的多条链路发生故障(即发生多点故障)时,或在确定所述下一跳节点发生故障时,通过MPLS-TP环网的保护环,利用该备相交环点将该报文传输到接入工作环中;具体可以如下:If the next hop node is located on the core working ring and is the main intersecting ring point, when it is determined that multiple links related to the next hop node fail (that is, a multi-point failure occurs), or when determining the following When a one-hop node fails, the backup intersecting ring point is used to transmit the message to the access working ring through the protection ring of the MPLS-TP ring network; the details can be as follows:

在确定与该下一跳节点相关的多条链路发生故障时,由所述下一跳节点通知备相交环点挂接接入工作环的阻塞点,以便通过MPLS-TP环网的保护环,利用该备相交环点将所述报文传输到接入工作环中。When it is determined that multiple links related to the next hop node fail, the next hop node notifies the standby intersecting ring point to connect to the blocking point of the working ring, so as to pass through the protection ring of the MPLS-TP ring network , using the backup intersecting ring point to transmit the message to the access working ring.

在确定该下一跳节点发生故障时,由备相交环点感知主相交环点故障并挂接接入工作环的阻塞点,以便通过MPLS-TP环网的保护环,利用该备相交环点将所述报文传输到接入工作环中。When it is determined that the next hop node fails, the standby intersecting ring point senses the failure of the primary intersecting ring point and connects to the blocking point of the working ring, so as to use the backup intersecting ring point through the protection ring of the MPLS-TP ring network The message is transmitted to the access working ring.

此外,根据当前节点的位置的不通,其所需要执行的后续处理也会有所不同,例如,具体可以如下:In addition, depending on the location of the current node, the follow-up processing that needs to be performed will also be different. For example, the details can be as follows:

若当前节点(即步骤101~104的执行主体)位于核心工作环上,且为主相交环点,则在将该报文发送给位于接入工作环上的下一跳节点时,还需要刷新相交点表项,其中,该相交点表项可以包括环标识和节点标识,主要用于当从其他接口接收到的以该当前节点作为源节点的报文时,判断是否终结该报文(即此时为环回)。If the current node (that is, the execution subject of steps 101 to 104) is located on the core working ring and is the main intersecting ring point, when sending the message to the next-hop node on the access working ring, it needs to refresh Intersection point entry, where the intersection point entry may include a ring ID and a node ID, and is mainly used for judging whether to terminate the message when receiving a message with the current node as the source node from other interfaces (that is, In this case, loopback).

而若当前节点(即步骤101~104的执行主体)位于核心工作环上,且为备相交环点,则当该当前节点与所述当前节点的VSI或VLL的连接关系由阻塞变为不阻塞,或由不阻塞变为阻塞时,还需要清除该当前节点上的所有表项,其中,VSI或VLL挂接到接入工作环的初始状态为阻塞。And if the current node (that is, the execution subject of steps 101 to 104) is located on the core working ring and is a standby intersecting ring point, then when the connection relationship between the current node and the VSI or VLL of the current node changes from blocking to non-blocking , or when changing from non-blocking to blocking, all entries on the current node also need to be cleared, wherein the initial state of the VSI or VLL attached to the access working ring is blocking.

104、若确定不需要将该报文转发给下一跳节点,则省略将该报文转发给下一跳节点的操作。104. If it is determined that the packet does not need to be forwarded to the next-hop node, omit the operation of forwarding the packet to the next-hop node.

例如,其中,省略将该报文转发给下一跳节点的操作具体可以是不动作,比如不对该报文进行处理,也可以是丢弃该报文或阻塞该报文等操作,在此不再赘述。For example, omitting the operation of forwarding the message to the next hop node may specifically be no action, such as not processing the message, or discarding the message or blocking the message, etc. repeat.

由上可知,本实施例采用在MPLS-TP环网的工作环上接收报文,其中,该报文采用MPLS进行封装,报文中包括环标签、标签交换路径标签、伪线标签和净荷,而标签交换路径标签包括目的环的环标识和目的节点的节点标识,伪线标签包括源环的环标识和源节点的节点标识,然后,根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将该报文转发给下一跳节点,若需要,则将该报文转发给下一跳节点,若不需要,则省略将所述报文转发给下一跳节点的操作;由于在该方案中,采用的是MPLS对报文进行封装,因此在环网上对报文进行传输时,无需刷新MAC表,所以可以提高倒换速度;而且,由于在该方案中,维护了一张不互通列表,并通过查询该不互通列表来确定节点之间是否可以互通,因此,不仅可以简单且灵活地实现节点间的互通和不互通,提高传输效率,而且,也便于后续的维护。As can be seen from the above, in this embodiment, the message is received on the working ring of the MPLS-TP ring network, wherein the message is encapsulated by MPLS, and the message includes a ring label, a label switching path label, a pseudowire label and a payload , and the label-switched path label includes the ring ID of the destination ring and the node ID of the destination node, and the pseudowire label includes the ring ID of the source ring and the node ID of the source node. Then, according to the ring label in the message, the label-switched path label 、Pseudowire label queries the preset non-communication list to determine whether the message needs to be forwarded to the next hop node, if necessary, forward the message to the next hop node, if not, omit all Describe the operation of forwarding the message to the next hop node; because in this scheme, MPLS is used to encapsulate the message, so when the message is transmitted on the ring network, there is no need to refresh the MAC table, so the switching speed can be improved; Moreover, in this scheme, a non-communication list is maintained, and whether nodes can communicate with each other is determined by querying the non-communication list. Therefore, not only the intercommunication and non-communication between nodes can be realized simply and flexibly, but also the improvement of The transmission efficiency is high, and it is also convenient for subsequent maintenance.

根据实施例一所描述的方法,以下将在实施例二、三、四和五中举例作进一步详细说明。According to the method described in Example 1, examples will be given in Examples 2, 3, 4 and 5 below for further detailed description.

实施例二、Embodiment two,

在本实施例中,将以该环网中的数据传输装置具体为环网处理模块,且具体集成在路由器中,且路由器作为MPLS-TP环网中的节点为例进行说明。In this embodiment, the data transmission device in the ring network is specifically a ring network processing module, which is specifically integrated in a router, and the router is used as a node in the MPLS-TP ring network as an example for description.

如图2a所示,可以基于以太网建立MPLS-TP环网,该MPLS-TP环网中包括工作环(即外环)和保护环(即内环),该工作环和保护环将以太网中的各个节点连接了起来,为了描述方便,在本实施例中,将以该MPLS-TP环网包括节点A、节点B、节点C和节点D为例进行说明,其中,每个节点都包括环网处理模块(比如RPR模块或MPLS-TP环网模块等)和VSI(或VLL),其中,每个VSI(或VLL)均挂接在工作环上,其中,图2a中的虚线表示报文的传输路线。As shown in Figure 2a, an MPLS-TP ring network can be established based on Ethernet. The MPLS-TP ring network includes a working ring (ie, the outer ring) and a protection ring (ie, the inner ring). Each node in the network is connected. For the convenience of description, in this embodiment, the MPLS-TP ring network includes node A, node B, node C and node D as an example for illustration, wherein each node includes Ring network processing module (such as RPR module or MPLS-TP ring network module, etc.) The transmission route of the text.

其中,为了多不同的节点进行区分,每个根和每个节点都具有一个身份标识,比如根的身份标识为根标识(root id),节点的身份标识为节点标识(leafid),并且,在对网络侧的报文进行封装时,也可以将这些标识封装在报文中,即网络侧报文的格式可以如表一所示:Among them, in order to distinguish between different nodes, each root and each node has an identity, for example, the identity of the root is the root ID (root id), the identity of the node is the node ID (leafid), and, in When encapsulating the packets on the network side, these identifiers can also be encapsulated in the packets, that is, the format of the packets on the network side can be shown in Table 1:

表一Table I

环标签ring label 标签交换路径标签label switched path label 伪线标签Pseudowire tags 净荷Payload

其中,标签交换路径标签在格式上可以采用现有的标签交换路径标签的格式,但是其内容可以包括目的环的环标识(dring id)和目的节点的节点标识(dleaf id),伪线标签可以包括源环的环标识(sring id)和源节点的节点标识(sleaf id)。Among them, the format of the label switched path label can adopt the format of the existing label switched path label, but its content can include the ring ID (dring id) of the destination ring and the node ID (dleaf id) of the destination node, and the pseudowire label can be It includes the ring ID (sring id) of the source ring and the node ID (sleaf id) of the source node.

此外,每个节点上均会配置不互通列表,其中,该不互通列表可以包括环标识(ring id)和节点标识(leaf id),用于指示节点之间是否互通,从而通过报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,就可以确定是否需要将该报文转发给下一跳节点。In addition, each node will be configured with a non-interworking list, where the non-interworking list may include a ring ID (ring id) and a node ID (leaf id), which are used to indicate whether the nodes are interoperable, so that through The ring label, label switched path label, and pseudowire label query the preset non-communication list to determine whether the packet needs to be forwarded to the next-hop node.

除了需要配置不互通列表之外,为了避免环回,在源节点还需要配置终结环回报文列表,该终结环回报文列表可以包括环标识(ring id)和节点标识(leaf id),这样,根据报文中的标签交换路径标签,通过查询该终结环回报文列表,就可以确定当前是否已构成环路(即是否回到源节点),以便作出进一步处理,比如,若为环路,则丢弃报文;若不是环路,则执行“根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定该报文是否需要转发给下一跳节点”的步骤,等等。In addition to configuring the non-communication list, in order to avoid loopbacks, the source node also needs to configure the list of ring termination messages. The list of ring termination messages can include the ring ID (ring id) and the node ID (leaf id). In this way, According to the label switching path label in the message, by querying the list of the terminating ring return message, it can be determined whether a loop has been formed (that is, whether to return to the source node) for further processing. For example, if it is a loop, then Discard the message; if it is not a loop, execute "query the preset non-communication list according to the ring label, label switching path label, and pseudowire label in the message to determine whether the message needs to be forwarded to the next hop node " steps, and so on.

基于图2a所示的MPLS-TP环网结构,以下将以组播为例,对其执行流程进行详细说明。Based on the structure of the MPLS-TP ring network shown in Figure 2a, the following will take multicast as an example to describe its execution process in detail.

其中,需说明的是,可以通过多种方式来确定当前报文是否为组播报文,比如,组播报文可以采用特定的环标识和节点标识,这样,根据该环标识和节点标识就可以识别出当前报文是否为组播报文,或者,也可以通过额外标识来指示当前报文是否为组播报文,等等,在此不再赘述。Among them, it should be noted that whether the current message is a multicast message can be determined in a variety of ways. For example, a multicast message can use a specific ring ID and node ID. In this way, according to the ring ID and node ID, the Whether the current packet is a multicast packet can be identified, or an additional identifier can be used to indicate whether the current packet is a multicast packet, etc., which will not be repeated here.

如图2b所示,一种环网中的数据传输方法,具体流程可以如下:As shown in Figure 2b, a data transmission method in a ring network, the specific process may be as follows:

201、源接入节点A为上环点,源接入节点A的VSI(或VLL)接收的组播源发送的初始报文。201. The source access node A is the loop-up point, and the VSI (or VLL) of the source access node A receives the initial message sent by the multicast source.

202、源接入节点A的VSI(或VLL)确定该初始报文为组播报文后,由环网处理模块对该初始报文进行MPLS封装。202. After the VSI (or VLL) of the source access node A determines that the initial packet is a multicast packet, the ring network processing module performs MPLS encapsulation on the initial packet.

其中,该封装后报文可以包括环标签、标签交换路径标签、伪线标签和净荷。Wherein, the encapsulated message may include a ring label, a label switched path label, a pseudowire label and a payload.

其中,标签交换路径标签在格式上可以采用现有的标签交换路径标签的格式,但是其内容可以包括目的环的环标识和目的节点的节点标识,伪线标签可以包括源环的环标识和源节点的节点标识。Among them, the format of the label switched path label can adopt the format of the existing label switched path label, but its content can include the ring ID of the destination ring and the node ID of the destination node, and the pseudowire label can include the ring ID of the source ring and the source The node ID of the node.

比如,可以将该初始报文封装为:目的环的环标识为“ring1”,目的节点的节点标识为特定值组播id,源环的环标识为“ring1”,源节点的节点标识为“root1”,并且在环标签的保留字中标记该报文为组播报文。For example, the initial packet can be encapsulated as: the ring identifier of the destination ring is "ring1", the node identifier of the destination node is a specific value multicast id, the ring identifier of the source ring is "ring1", and the node identifier of the source node is " root1", and mark the packet as a multicast packet in the reserved word of the ring label.

203、源接入节点A的环网处理模块对终结环回报文列表进行配置。203. The ring network processing module of the source access node A configures the list of terminated ring return packets.

其中,该终结环回报文列表可以包括环标识和节点标识,这样,根据报文中的标签交换路径标签,通过查询该终结环回报文列表,就可以确定当前是否已构成环路(即是否回到源节点)。Wherein, the message list of the terminating ring may include a ring ID and a node ID. In this way, according to the label switching path label in the message, by querying the list of the terminating ring returning message, it can be determined whether a loop has been formed currently (that is, whether a loop is returned or not). to the source node).

比如,在此可以在终结环回报文列表配置:当接收到源环的环标识为“ring1”,源节点的节点标识为“root1”时,确定为环路。For example, it can be configured in the termination ring return message list: when the ring ID of the source ring is received as "ring1" and the node ID of the source node is "root1", it is determined to be a loop.

204、源接入节点A的VSI(或VLL)根据封装后报文中的各种信息,比如根据MAC地址、环标识和节点标识等刷新MAC地址列表,并在VSI(或VLL)内部对所述报文进行转发。204. The VSI (or VLL) of the source access node A refreshes the MAC address list according to various information in the encapsulated message, such as the MAC address, ring ID, and node ID, and internally updates all The message is forwarded.

205、源接入节点A的环网处理模块根据该封装后报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将该封装后报文转发给下一跳节点B,若需要将该封装后报文转发给下一跳节点B,则执行步骤206;若不需要将该封装后报文转发给下一跳节点B,则省略将该封装后的报文转发给下一跳节点B的操作。205. The ring network processing module of the source access node A queries the preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the encapsulated message to determine whether the encapsulated message needs to be forwarded For the next hop node B, if it is necessary to forward the encapsulated message to the next hop node B, then perform step 206; if it is not necessary to forward the encapsulated message to the next hop node B, then omit the encapsulation The operation of forwarding the subsequent message to the next hop node B.

其中,该不互通列表可以包括环标识和节点标识,用于指示节点之间是否互通,从而通过报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,就可以确定是否需要将该报文转发给下一跳节点B。Wherein, the non-interworking list may include ring identifiers and node identifiers, which are used to indicate whether the nodes are interoperable, so that the preset non-interworking list can be queried through the ring label, label switched path label, and pseudowire label in the message. It is determined whether the message needs to be forwarded to the next hop node B.

206、若确定需要将该报文转发给下一跳节点B,则源接入节点A的环网处理模块将该封装后报文通过工作环路发送给下一跳节点B。206. If it is determined that the message needs to be forwarded to the next-hop node B, the ring network processing module of the source access node A sends the encapsulated message to the next-hop node B through the working ring.

207、节点B的环网处理模块接收该封装后报文,确定该封装后报文为组播报文,于是复制该封装后报文,并将复制的报文发送给当前节点的VSI(或VLL),以便VSI(或VLL)根据该复制的报文刷新MAC地址列表,并在VSI(或VLL)内部对该复制的报文进行转发。207. The ring network processing module of node B receives the encapsulated message, determines that the encapsulated message is a multicast message, then copies the encapsulated message, and sends the copied message to the VSI (or VLL), so that the VSI (or VLL) refreshes the MAC address list according to the copied message, and forwards the copied message inside the VSI (or VLL).

208、节点B的环网处理模块根据该封装后报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将该封装后报文转发给下一跳节点C,若需要将该封装后报文转发给下一跳节点C,则执行步骤209;若不需要将该封装后报文转发给下一跳节点C,则省略将该封装后的报文转发给下一跳节点C的操作。208. The ring network processing module of Node B queries the preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the encapsulated message to determine whether the encapsulated message needs to be forwarded to the next Jumping node C, if it is necessary to forward the encapsulated message to the next hop node C, then perform step 209; if it is not necessary to forward the encapsulated message to the next hop node C, then omit the packaged message The operation of forwarding the text to the next hop node C.

其中,步骤207和208的执行可以不分先后。Wherein, steps 207 and 208 may be performed in no particular order.

需说明的是,此时还可以根据该封装后报文中的标签交换路径标签查询终结环回报文列表以确定是否构成环路,由于在本实施例中,源环的环标识为“ring1”,源节点的节点标识为“root1”,因此,此时并不构成环路,因此,可以直接执行步骤208。It should be noted that at this time, the list of termination ring return packets can also be queried according to the label switched path label in the encapsulated packet to determine whether a loop is formed, because in this embodiment, the ring identifier of the source ring is "ring1" , the node identifier of the source node is "root1", therefore, a loop is not formed at this time, therefore, step 208 can be directly executed.

209、若确定需要将该报文转发给下一跳节点C,则节点B的环网处理模块将该封装后报文通过工作环路发送给下一跳节点C。209. If it is determined that the message needs to be forwarded to the next-hop node C, the ring network processing module of the node B sends the encapsulated message to the next-hop node C through the working ring.

210、节点C的环网处理模块接收该封装后报文,确定该封装后报文为组播报文,于是复制该封装后报文,并将复制的报文发送给当前节点的VSI(或VLL),以便VSI(或VLL)根据该复制的报文刷新MAC地址列表,并在VSI(或VLL)内部对该复制的报文进行转发。210. The ring network processing module of node C receives the encapsulated message, determines that the encapsulated message is a multicast message, then copies the encapsulated message, and sends the copied message to the VSI (or VLL), so that the VSI (or VLL) refreshes the MAC address list according to the copied message, and forwards the copied message inside the VSI (or VLL).

211、节点C的环网处理模块根据该封装后报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将该封装后报文转发给下一跳节点D,若需要将该封装后报文转发给下一跳节点D,则执行步骤212;若不需要将该封装后报文转发给下一跳节点D,则省略将该封装后的报文转发给下一跳节点D的操作。211. The ring network processing module of node C queries the preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the encapsulated message to determine whether the encapsulated message needs to be forwarded to the next Jump node D, if it is necessary to forward the encapsulated message to the next hop node D, then perform step 212; if it is not necessary to forward the encapsulated message to the next hop node D, then omit the packaged message The operation of forwarding the text to the next hop node D.

其中,步骤210和211的执行可以不分先后。Wherein, steps 210 and 211 may be executed in no particular order.

需说明的是,此时还可以根据该封装后报文中的标签交换路径标签查询终结环回报文列表以确定是否构成环路,由于在本实施例中,源环的环标识为“ring1”,源节点的节点标识为“root1”,因此,此时并不构成环路,因此,可以直接执行步骤211。It should be noted that at this time, the list of termination ring return packets can also be queried according to the label switched path label in the encapsulated packet to determine whether a loop is formed, because in this embodiment, the ring identifier of the source ring is "ring1" , the node identifier of the source node is "root1", therefore, a loop is not formed at this time, therefore, step 211 can be directly executed.

212、若确定需要将该报文转发给下一跳节点D,则节点C的环网处理模块将该封装后报文通过工作环路发送给下一跳节点D。212. If it is determined that the message needs to be forwarded to the next-hop node D, the ring network processing module of node C sends the encapsulated message to the next-hop node D through the working ring.

213、节点D的环网处理模块接收该封装后报文,确定该封装后报文为组播报文,于是复制该封装后报文,并将复制的报文发送给当前节点的VSI(或VLL),以便VSI(或VLL)根据该复制的报文刷新MAC地址列表,并在VSI(或VLL)内部对该复制的报文进行转发。213. The ring network processing module of node D receives the encapsulated message, determines that the encapsulated message is a multicast message, then copies the encapsulated message, and sends the copied message to the VSI (or VLL), so that the VSI (or VLL) refreshes the MAC address list according to the copied message, and forwards the copied message inside the VSI (or VLL).

214、节点D的环网处理模块根据该封装后报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将该封装后报文转发给下一跳节点A,若需要将该封装后报文转发给下一跳节点A,则执行步骤215;若不需要将该封装后报文转发给下一跳节点A,则省略将该封装后的报文转发给下一跳节点A的操作。214. The ring network processing module of node D queries the preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the encapsulated message to determine whether the encapsulated message needs to be forwarded to the next Jump node A, if it is necessary to forward the encapsulated message to the next hop node A, then perform step 215; if it is not necessary to forward the encapsulated message to the next hop node A, then omit the packaged message The operation of forwarding the text to the next hop node A.

其中,步骤213和214的执行可以不分先后。Wherein, steps 213 and 214 may be executed in no particular order.

需说明的是,此时还可以根据该封装后报文中的标签交换路径标签查询终结环回报文列表以确定是否构成环路,由于在本实施例中,源环的环标识为“ring1”,源节点的节点标识为“root1”,因此,此时并不构成环路,因此,可以直接执行步骤215。It should be noted that at this time, the list of termination ring return packets can also be queried according to the label switched path label in the encapsulated packet to determine whether a loop is formed, because in this embodiment, the ring identifier of the source ring is "ring1" , the node identifier of the source node is "root1", therefore, a loop is not formed at this time, therefore, step 215 can be directly executed.

215、若确定需要将该报文转发给下一跳节点A,则节点D的环网处理模块将该封装后报文通过工作环路发送给下一跳节点A。215. If it is determined that the message needs to be forwarded to the next-hop node A, the ring network processing module of node D sends the encapsulated message to the next-hop node A through the working ring.

216、源接入节点A的环网处理模块接收到该封装后报文后,根据该封装后报文中的标签交换路径标签查询终结环回报文列表,由于源环的环标识为“ring1”,源节点的节点标识为“root1”,于是确定为环路,所以,丢弃该封报文。216. After receiving the encapsulated packet, the ring network processing module of the source access node A queries the list of termination ring return packets according to the label switching path label in the encapsulated packet. Since the ring identifier of the source ring is "ring1" , the node ID of the source node is "root1", so it is determined to be a loop, so the packet is discarded.

由上可知,本实施例采用在MPLS-TP环网的工作环上接收组播报文,其中,该组播报文采用MPLS进行封装,组播报文中包括环标签、标签交换路径标签、伪线标签和净荷,而标签交换路径标签包括目的环的环标识和目的节点的节点标识,伪线标签包括源环的环标识和源节点的节点标识,然后,根据该组播报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将该组播报文转发给下一跳节点,若需要,则将该组播报文转发给下一跳节点,若不需要,则省略将该组播报文转发给下一跳节点的操作;由于在该方案中,采用的是MPLS对报文进行封装,因此在环网上对报文进行传输时,无需刷新MAC表,所以可以提高倒换速度;而且,由于在该方案中,维护了一张不互通列表,并通过查询该不互通列表来确定节点之间是否可以互通,因此,不仅可以简单且灵活地实现节点间的互通和不互通,提高传输效率,而且,也便于后续的维护。As can be seen from the above, in this embodiment, the multicast message is received on the working ring of the MPLS-TP ring network, wherein the multicast message is encapsulated by MPLS, and the multicast message includes a ring label, a label switching path label, and a pseudowire label and payload, and the label switched path label includes the ring identifier of the destination ring and the node identifier of the destination node, and the pseudowire label includes the ring identifier of the source ring and the node identifier of the source node. Then, according to the ring label in the multicast message, The label switching path label and the pseudowire label query the preset non-communication list to determine whether the multicast message needs to be forwarded to the next-hop node, and if necessary, forward the multicast message to the next-hop node. If not needed, omit the operation of forwarding the multicast message to the next hop node; in this scheme, MPLS is used to encapsulate the message, so when the message is transmitted on the ring network, there is no need to refresh MAC table, so the switching speed can be improved; moreover, because in this scheme, a non-communication list is maintained, and it is determined whether nodes can communicate with each other by querying the non-communication list, therefore, not only simple and flexible implementation Intercommunication and non-intercommunication between nodes improves transmission efficiency and facilitates subsequent maintenance.

实施例三、Embodiment three,

与实施例二相同的是,同样以该环网中的数据传输装置具体为环网处理模块,且具体集成在路由器中,且路由器作为MPLS-TP环网中的节点为例进行说明。与实施例二不同的是,在本实施例中,将以单播为例进行说明。Same as the second embodiment, the data transmission device in the ring network is specifically a ring network processing module, which is specifically integrated in a router, and the router is used as a node in the MPLS-TP ring network as an example for illustration. Different from Embodiment 2, in this embodiment, unicast will be used as an example for description.

如图3所示,一种环网中的数据传输方法,具体流程可以如下:As shown in Figure 3, a data transmission method in a ring network, the specific process can be as follows:

301、源接入节点A为上环点,源节点A的VSI(或VLL)获取初始报文。301. The source access node A is the loop-up point, and the VSI (or VLL) of the source node A obtains the initial packet.

302、源接入节点A的VSI(或VLL)确定该初始报文为单播报文后,由环网处理模块对该初始报文进行MPLS封装。302. After the VSI (or VLL) of source access node A determines that the initial packet is a unicast packet, the ring network processing module performs MPLS encapsulation on the initial packet.

其中,该封装后报文可以包括环标签、标签交换路径标签、伪线标签和净荷。Wherein, the encapsulated message may include a ring label, a label switched path label, a pseudowire label and a payload.

其中,标签交换路径标签在格式上可以采用现有的标签交换路径标签的格式,但是其内容可以包括目的环的环标识和目的节点的节点标识,伪线标签可以包括源环的环标识和源节点的节点标识。Among them, the format of the label switched path label can adopt the format of the existing label switched path label, but its content can include the ring ID of the destination ring and the node ID of the destination node, and the pseudowire label can include the ring ID of the source ring and the source The node ID of the node.

比如,可以将该初始报文封装为:目的环的环标识为“ring1”,目的节点的节点标识为“root2”,源环的环标识为“ring1”,源节点的节点标识为“root1”。For example, the initial packet can be encapsulated as: the ring ID of the destination ring is "ring1", the node ID of the destination node is "root2", the ring ID of the source ring is "ring1", and the node ID of the source node is "root1" .

其中,“root1”为节点A的节点标识,“root2”为节点D的节点标识。Wherein, "root1" is the node ID of node A, and "root2" is the node ID of node D.

303、源接入节点A的环网处理模块对终结环回报文列表进行配置。303. The ring network processing module of the source access node A configures the list of terminated ring return packets.

其中,该终结环回报文列表可以包括环标识和节点标识,这样,根据报文中的标签交换路径标签,通过查询该终结环回报文列表,就可以确定当前是否已构成环路(即是否回到源节点)。Wherein, the message list of the terminating ring may include a ring ID and a node ID. In this way, according to the label switching path label in the message, by querying the list of the terminating ring returning message, it can be determined whether a loop has been formed currently (that is, whether a loop is returned or not). to the source node).

比如,在此可以在终结环回报文列表配置:当接收到源环的环标识为“ring1”,源节点的节点标识为“root1”时,确定为环路。For example, it can be configured in the termination ring return message list: when the ring ID of the source ring is received as "ring1" and the node ID of the source node is "root1", it is determined to be a loop.

304、源接入节点A的VSI(或VLL)根据封装后报文中的各种信息,比如根据MAC地址、环标识和节点标识等刷新MAC地址列表,并在VSI(或VLL)内部对所述报文进行转发。304. The VSI (or VLL) of the source access node A refreshes the MAC address list according to various information in the encapsulated message, such as the MAC address, ring ID, and node ID, and updates all The message is forwarded.

305、源接入节点A的环网处理模块根据该封装后报文中的标签交换路径标签确定需要交换(swap)时,根据该封装后报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将该封装后报文转发给下一跳节点B,若需要将该封装后报文转发给下一跳节点B,则执行步骤305;若不需要将该封装后报文转发给下一跳节点B,则省略将该封装后的报文转发给下一跳节点B的操作。305. When the ring network processing module of the source access node A determines that it needs to be swapped (swap) according to the label switching path label in the encapsulated message, according to the ring label, label switching path label, and pseudowire in the encapsulated message The label queries the preset non-interworking list to determine whether the encapsulated message needs to be forwarded to the next-hop node B, and if the encapsulated message needs to be forwarded to the next-hop node B, step 305 is performed; if not If the encapsulated message needs to be forwarded to the next-hop node B, the operation of forwarding the encapsulated message to the next-hop node B is omitted.

其中,该不互通列表可以包括环标识和节点标识,用于指示节点之间是否互通,从而通过报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,就可以确定是否需要将该报文转发给下一跳节点B。Wherein, the non-interworking list may include ring identifiers and node identifiers, which are used to indicate whether the nodes are interoperable, so that the preset non-interworking list can be queried through the ring label, label switched path label, and pseudowire label in the message. It is determined whether the message needs to be forwarded to the next hop node B.

306、若确定需要将该报文转发给下一跳节点B,则源接入节点A的环网处理模块将该封装后报文通过工作环路发送给下一跳节点B。306. If it is determined that the message needs to be forwarded to the next-hop node B, the ring network processing module of the source access node A sends the encapsulated message to the next-hop node B through the working ring.

307、节点B的环网处理模块接收该封装后报文,确定该封装后报文为单播报文,于是在根据该封装后报文中的标签交换路径标签确定需要交换(swap)时,根据封装后报文中的各种信息,比如根据MAC地址、环标识和节点标识等刷新MAC地址列表。307. The ring network processing module of Node B receives the encapsulated packet, determines that the encapsulated packet is a unicast packet, and then determines that swap is required according to the label switching path label in the encapsulated packet, according to Various information in the encapsulated message, such as refreshing the MAC address list according to the MAC address, ring ID, and node ID.

308、节点B的环网处理模块根据该封装后报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将该封装后报文转发给下一跳节点C,若需要将该封装后报文转发给下一跳节点C,则执行步骤308;若不需要将该封装后报文转发给下一跳节点C,则省略将该封装后的报文转发给下一跳节点C的操作。308. The ring network processing module of Node B queries the preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the encapsulated message to determine whether the encapsulated message needs to be forwarded to the next Jumping node C, if it is necessary to forward the encapsulated message to the next hop node C, then perform step 308; if it is not necessary to forward the encapsulated message to the next hop node C, then omit the packaged message The operation of forwarding the text to the next hop node C.

其中,步骤307和308的执行可以不分先后。Wherein, steps 307 and 308 may be executed in no particular order.

需说明的是,此时还可以根据该封装后报文中的标签交换路径标签查询终结环回报文列表以确定是否构成环路,由于在本实施例中,源环的环标识为“ring1”,源节点的节点标识为“root1”,因此,此时并不构成环路,因此,可以直接执行步骤307。It should be noted that at this time, the list of termination ring return packets can also be queried according to the label switched path label in the encapsulated packet to determine whether a loop is formed, because in this embodiment, the ring identifier of the source ring is "ring1" , the node ID of the source node is "root1", therefore, a loop is not formed at this time, therefore, step 307 can be directly executed.

309、若确定需要将该报文转发给下一跳节点C,则节点B的环网处理模块将该封装后报文通过工作环路发送给下一跳节点C。309. If it is determined that the message needs to be forwarded to the next-hop node C, the ring network processing module of the node B sends the encapsulated message to the next-hop node C through the working ring.

310、节点C的环网处理模块接收该封装后报文,确定该封装后报文为单播报文,于是在根据该封装后报文中的标签交换路径标签确定需要交换(swap)时,根据封装后报文中的各种信息,比如根据MAC地址、环标识和节点标识等刷新MAC地址列表。310. The ring network processing module of node C receives the encapsulated packet, determines that the encapsulated packet is a unicast packet, and then determines that swap (swap) is required according to the label switching path label in the encapsulated packet, according to Various information in the encapsulated message, such as refreshing the MAC address list according to the MAC address, ring ID, and node ID.

311、节点C的环网处理模块根据该封装后报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将该封装后报文转发给下一跳节点D,若需要将该封装后报文转发给下一跳节点D,则执行步骤311;若不需要将该封装后报文转发给下一跳节点D,则省略将该封装后的报文转发给下一跳节点D的操作。311. The ring network processing module of node C queries the preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the encapsulated message to determine whether the encapsulated message needs to be forwarded to the next Jump node D, if it is necessary to forward the encapsulated message to the next hop node D, then perform step 311; if it is not necessary to forward the encapsulated message to the next hop node D, then omit the packaged message The operation of forwarding the text to the next hop node D.

其中,步骤310和311的执行可以不分先后。Wherein, steps 310 and 311 may be executed in no particular order.

需说明的是,此时还可以根据该封装后报文中的标签交换路径标签查询终结环回报文列表以确定是否构成环路,由于在本实施例中,源环的环标识为“ring1”,源节点的节点标识为“root1”,因此,此时并不构成环路,因此,可以直接执行步骤307。It should be noted that at this time, the list of termination ring return packets can also be queried according to the label switched path label in the encapsulated packet to determine whether a loop is formed, because in this embodiment, the ring identifier of the source ring is "ring1" , the node ID of the source node is "root1", therefore, a loop is not formed at this time, therefore, step 307 can be directly executed.

312、若确定需要将该报文转发给下一跳节点D,则节点B的环网处理模块将该封装后报文通过工作环路发送给下一跳节点D。312. If it is determined that the message needs to be forwarded to the next-hop node D, the ring network processing module of the node B sends the encapsulated message to the next-hop node D through the working ring.

313、节点D的环网处理模块接收该封装后报文,确定该封装后报文为单播报文,于是根据该报文中的标签交换路径标签确定为POP(即确定节点D为目的节点)时,将该封装后报文发送给节点D的VSI(或VLL)。313. The ring network processing module of node D receives the encapsulated message, determines that the encapsulated message is a unicast message, and then determines that it is POP according to the label switching path label in the message (that is, determines that node D is the destination node) , the encapsulated packet is sent to the VSI (or VLL) of node D.

需说明的是,对于未知的单播报文,也按照组播进行处理,在此不再赘述。It should be noted that, for unknown unicast packets, they are also processed according to multicast, which will not be repeated here.

由上可知,本实施例采用在MPLS-TP环网的工作环上接收报文,其中,该单播报文采用MPLS进行封装,单播报文中包括环标签、标签交换路径标签、伪线标签和净荷,而标签交换路径标签包括目的环的环标识和目的节点的节点标识,伪线标签包括源环的环标识和源节点的节点标识,然后,根据该单播报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将该报文转发给下一跳节点,若需要,则将该报文转发给下一跳节点,若不需要,则省略将该报文转发给下一跳节点的操作;由于在该方案中,采用的是MPLS对报文进行封装,因此在环网上对报文进行传输时,无需刷新MAC表,所以可以提高倒换速度;而且,由于在该方案中,维护了一张不互通列表,并通过查询该不互通列表来确定节点之间是否可以互通,因此,不仅可以简单且灵活地实现节点间的互通和不互通,提高传输效率,而且,也便于后续的维护。As can be seen from the above, in this embodiment, the message is received on the working ring of the MPLS-TP ring network, wherein the unicast message is encapsulated by MPLS, and the unicast message includes a ring label, a label switching path label, a pseudowire label and a net The label of the label switched path includes the ring ID of the destination ring and the node ID of the destination node, and the pseudowire label includes the ring ID of the source ring and the node ID of the source node. Then, according to the ring label in the unicast message, the label switched path Labels and pseudowire labels query the preset non-communication list to determine whether the message needs to be forwarded to the next-hop node. If necessary, forward the message to the next-hop node. If not, omit the The operation of forwarding the message to the next hop node; in this scheme, MPLS is used to encapsulate the message, so when the message is transmitted on the ring network, there is no need to refresh the MAC table, so the switching speed can be improved; Moreover, in this scheme, a non-communication list is maintained, and whether nodes can communicate with each other is determined by querying the non-communication list. Therefore, not only the intercommunication and non-communication between nodes can be realized simply and flexibly, but also the improvement of The transmission efficiency is high, and it is also convenient for subsequent maintenance.

实施例四、Embodiment four,

在根据实施例二和三的基础上,为了提高数据传输的安全性,各个节点在将报文转发给下一跳节点之前,进行链路检测和节点检测,若均正常(即无故障),则直接通过工作环将该报文转发给下一跳节点,否则,若发现链路故障或节点故障,则进行保护倒换,以下将分别进行详细说明。On the basis of Embodiments 2 and 3, in order to improve the security of data transmission, each node performs link detection and node detection before forwarding the message to the next hop node. If both are normal (that is, there is no fault), The message is directly forwarded to the next-hop node through the working ring, otherwise, if a link failure or node failure is found, protection switching is performed, which will be described in detail below.

(1)链路故障;(1) Link failure;

参见图4a,节点A和节点B分别检测到节点A和节点B之间的链路发生故障1,A点进行保护倒换(即wrapping倒换),将报文切换到保护环上进行传输,一直到节点B,再从保护环切换回到工作环,完成保护倒换。Referring to Figure 4a, node A and node B respectively detect that the link between node A and node B fails 1, point A performs protection switching (wrapping switching), and switches the message to the protection ring for transmission until Node B switches from the protection ring back to the working ring to complete the protection switching.

其中,图4a中的虚线表示报文的传输路线,该保护倒换类似于普通的环倒换,在此不再赘述。Wherein, the dotted line in Fig. 4a indicates the transmission route of the message, and the protection switching is similar to the common ring switching, and will not be repeated here.

(2)节点故障;(2) Node failure;

参见图4b,上游路由器,比如协议无关组播(PIM,Protocol IndependentMulticast)双向转发检测(BFD,Bidirectional Forwarding Detection)设备或组播源检测到节点A发生故障2,上游路由器触发保护倒换,将报文通过节点D进行下发,节点D检测到节点A发生故障2,触发环网的保护倒换,将报文从工作环切换到保护环,一直传输到节点B,才将报文从保护环切换回工作环,完成保护倒换,此后,报文继续在工作环上进行传送,在此不再赘述。Referring to Figure 4b, an upstream router, such as a Protocol Independent Multicast (PIM, Protocol Independent Multicast) Bidirectional Forwarding Detection (BFD, Bidirectional Forwarding Detection) device or a multicast source detects that node A has failed 2, and the upstream router triggers protection switching and sends the packet Sending through node D, node D detects that node A has failed 2, triggers the protection switchover of the ring network, switches the message from the working ring to the protection ring, and transmits it to node B before switching the message back from the protection ring In the working ring, the protection switching is completed, and after that, the packets continue to be transmitted on the working ring, which will not be repeated here.

其中,图4b中的虚线表示报文的传输路线,该环网的保护倒换类似于普通的环倒换,在此不再赘述。Wherein, the dotted line in FIG. 4b represents the transmission route of the message, and the protection switching of the ring network is similar to the common ring switching, and will not be repeated here.

可见,节点故障和链路故障倒换过程类似,此外,需说明的是,单播和组播的倒换过程类似,双点故障和单点故障的倒换过程也类似,在此不再赘述。It can be seen that the switching process of node failure and link failure is similar. In addition, it should be noted that the switching process of unicast and multicast is similar, and the switching process of double-point failure and single-point failure is also similar, which will not be repeated here.

由上可知,本实施例同样可以实现与实施二和三同样的有益效果,而且,由于本实施例在传送报文时,可以对链路和节点进行故障检测,并且在检测到故障时进行保护倒换,所以,可以进一步提高数据传输的安全性。It can be seen from the above that this embodiment can also achieve the same beneficial effects as the second and third implementations, and because this embodiment can detect faults on links and nodes when transmitting messages, and perform protection when faults are detected Switching, therefore, can further improve the security of data transmission.

实施例五、Embodiment five,

在实施二、三和四中,均以单环为例进行说明,应当理解的是,对于多环,也同样适用于上述方法,以下将以双环为例进行详细说明。In implementations 2, 3 and 4, a single ring is taken as an example for illustration. It should be understood that the above method is also applicable to multiple rings. The following will take a double ring as an example to describe in detail.

如图5所示,可以基于以太网建立MPLS-TP环网,该MPLS-TP环网为双环结构,包括核心环(即环1(ring1))和接入环(即环2(ring2)),核心环又包括工作环(即外环)和保护环(即内环),在此称为核心工作环和核心保护环,同理,接入环也包括工作环(即外环)和保护环(即内环),在此称为接入工作环和接入保护环。该工作环和保护环将以太网中的各个节点连接了起来,为了描述方便,在本实施例中,将以该MPLS-TP环网包括节点A、节点B、节点C、节点D、节点E和节点F为例进行说明,其中,节点B为主相交环点,节点C为备相交环点。其中,每个节点都包括环网处理模块和VSI(或VLL),其中,每个VSI(或VLL)均挂接在工作环上,其中,图5中的虚线表示报文的传输路线。As shown in Figure 5, an MPLS-TP ring network can be established based on Ethernet. The MPLS-TP ring network is a double-ring structure, including a core ring (that is, ring 1 (ring1)) and an access ring (that is, ring 2 (ring2)). , the core ring includes the working ring (i.e. the outer ring) and the protection ring (i.e. the inner ring), which are referred to here as the core working ring and the core protection ring. Similarly, the access ring also includes the working ring (i.e. the outer ring) and the protection ring. The ring (that is, the inner ring) is called an access working ring and an access protection ring here. The working ring and the protection ring connect the various nodes in the Ethernet. For the convenience of description, in this embodiment, the MPLS-TP ring network will include node A, node B, node C, node D, and node E Take node F as an example for illustration, wherein, node B is the primary intersecting ring point, and node C is the standby intersecting ring point. Wherein, each node includes a ring network processing module and a VSI (or VLL), wherein each VSI (or VLL) is connected to a working ring, wherein the dotted line in Fig. 5 indicates a transmission route of a message.

其中,为了多不同的节点进行区分,每个根和每个节点都具有一个身份标识,比如根的身份标识为根标识(root id),节点的身份标识为节点标识(leaf id),并且,在对网络侧的报文进行封装时,也可以将这些标识封装在报文中,即网络侧报文的格式可以如表二所示:Among them, in order to distinguish between different nodes, each root and each node has an identity, for example, the identity of the root is the root ID (root id), the identity of the node is the node ID (leaf id), and, When encapsulating the message on the network side, these identifiers can also be encapsulated in the message, that is, the format of the message on the network side can be shown in Table 2:

表二Table II

环标签ring label 标签交换路径标签label switched path label 伪线标签Pseudowire tags 净荷Payload

其中,标签交换路径标签在格式上可以采用现有的标签交换路径标签的格式,但是其内容可以包括目的环的环标识(dring id)和目的节点的节点标识(dleaf id),伪线标签可以包括源环的环标识(sring id)和源节点的节点标识(sleaf id)。Among them, the format of the label switched path label can adopt the format of the existing label switched path label, but its content can include the ring ID (dring id) of the destination ring and the node ID (dleaf id) of the destination node, and the pseudowire label can be It includes the ring ID (sring id) of the source ring and the node ID (sleaf id) of the source node.

此外,每个节点上均会配置不互通列表,其中,该不互通列表可以包括环标识(ring id)和节点标识(leaf id),用于指示节点之间是否互通,从而通过报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,就可以确定是否需要将该报文转发给下一跳节点。In addition, each node will be configured with a non-interworking list, where the non-interworking list may include a ring ID (ring id) and a node ID (leaf id), which are used to indicate whether the nodes are interoperable, so that through The ring label, label switched path label, and pseudowire label query the preset non-communication list to determine whether the packet needs to be forwarded to the next-hop node.

除了需要配置不互通列表之外,为了避免环回,在主相交环点和备相交环点(即节点B和节点C)还需要配置终结环回报文列表,该终结环回报文列表可以包括环标识(ringid)和节点标识(leaf id),这样,根据报文中的标签交换路径标签,通过查询该终结环回报文列表,就可以确定当前是否已构成环路(即是否回到源节点),以便作出进一步处理,比如,若为环路,则丢弃报文;若不是环路,则执行“根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定该报文是否需要转发给下一跳节点”的步骤,等等。In addition to configuring the non-communication list, in order to avoid loopbacks, it is also necessary to configure the list of finalized ringback packets on the primary intersecting ringpoint and standby intersecting ringpoint (that is, node B and node C). ID (ringid) and node ID (leaf id), in this way, according to the label exchange path label in the message, by querying the list of the terminating ring return message, it can be determined whether the current loop has been formed (that is, whether to return to the source node) , in order to make further processing, for example, if it is a loop, then discard the message; if it is not a loop, execute "query the preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the message , to determine whether the message needs to be forwarded to the next hop node", and so on.

基于图5所示的MPLS-TP环网结构,以下将以组播为例,对其执行流程进行详细说明。Based on the structure of the MPLS-TP ring network shown in FIG. 5 , the following will take multicast as an example to describe its execution process in detail.

其中,需说明的是,可以通过多种方式来确定当前报文是否为组播报文,比如,组播报文可以采用特定的环标识和节点标识,这样,根据该环标识和节点标识就可以识别出当前报文是否为组播报文,或者,也可以通过额外标识来指示当前报文是否为组播报文,等等,在此不再赘述。Among them, it should be noted that whether the current message is a multicast message can be determined in a variety of ways. For example, a multicast message can use a specific ring ID and node ID. In this way, according to the ring ID and node ID, the Whether the current packet is a multicast packet can be identified, or an additional identifier can be used to indicate whether the current packet is a multicast packet, etc., which will not be repeated here.

该双环结构下的数据传输方法与单环的数据传输方法类似,只是主相交环点,即节点B来说,在将该报文发送给位于接入工作环上的下一跳节点E时,还需要刷新相交点表项,其中,该相交点表项可以包括环标识和节点标识,主要用于当从其他接口接收到的以该当前节点作为源节点的报文时,判断是否终结该报文(即此时为环回)。The data transmission method under the double-ring structure is similar to the single-ring data transmission method, except that the main intersecting ring point, that is, node B, when sending the message to the next-hop node E located on the access working ring, It is also necessary to refresh the intersection point entry, wherein the intersection point entry can include a ring ID and a node ID, and is mainly used for judging whether to terminate the message when receiving a message with the current node as the source node from other interfaces. text (that is, loopback at this time).

此外,对于备相交环点,即节点C来说,当节点C与节点C的VSI或VLL的连接关系由阻塞变为不阻塞,或由不阻塞变为阻塞时,还需要清除节点C上的所有表项,其中,VSI或VLL挂接到接入工作环的初始状态为阻塞。In addition, for the standby intersecting ring point, that is, node C, when the connection relationship between node C and the VSI or VLL of node C changes from blocking to non-blocking, or from non-blocking to blocking, it is necessary to clear the For all table entries, the initial state of the VSI or VLL attached to the access working ring is blocked.

由上可知,本实施例采用在MPLS-TP环网的工作环上接收报文,其中,该报文中包括环标签、标签交换路径标签、伪线标签和净荷,而标签交换路径标签包括目的环的环标识和目的节点的节点标识,伪线标签包括源环的环标识和源节点的节点标识,然后,根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将该报文转发给下一跳节点,若需要,则将该报文转发给下一跳节点,若不需要,则省略将该报文转发给下一跳节点的操作;由于在该方案中,采用的是MPLS对报文进行封装,因此在环网上对报文进行传输时,无需刷新MAC表,所以可以提高倒换速度;而且,由于在该方案中,维护了一张不互通列表,并通过查询该不互通列表来确定节点之间是否可以互通,因此,不仅可以简单且灵活地实现节点间的互通和不互通,提高传输效率,而且,也便于后续的维护。As can be seen from the above, the present embodiment adopts receiving messages on the working ring of the MPLS-TP ring network, wherein, the message includes a ring label, a label switched path label, a pseudowire label and a payload, and the label switched path label includes The ring ID of the destination ring and the node ID of the destination node, the pseudowire label includes the ring ID of the source ring and the node ID of the source node, and then query the preset to determine whether the message needs to be forwarded to the next hop node, if necessary, forward the message to the next hop node, if not, omit forwarding the message to the next hop The operation of the node; because in this scheme, MPLS is used to encapsulate the message, so when the message is transmitted on the ring network, there is no need to refresh the MAC table, so the switching speed can be improved; and, because in this scheme, A non-intercommunication list is maintained, and it is determined whether nodes can communicate with each other by querying the non-intercommunication list. Therefore, it is not only simple and flexible to realize intercommunication and non-intercommunication between nodes, improve transmission efficiency, but also facilitate follow-up maintenance.

实施例六、Embodiment six,

在根据实施例五的基础上,为了提高数据传输的安全性,各个节点在将报文转发给下一跳节点之前,进行链路检测和节点检测,若均正常(即无故障),则直接通过工作环将该报文转发给下一跳节点,否则,若发现链路故障或节点故障,则进行保护倒换。On the basis of Embodiment 5, in order to improve the security of data transmission, each node performs link detection and node detection before forwarding the message to the next hop node. The message is forwarded to the next hop node through the working ring, otherwise, if a link failure or node failure is found, protection switching is performed.

其中,单点故障(除主相交环点)的处理方式与实施四相同,在此不再赘述,以下将对多点故障和主相交环点的情况分别进行详细说明。Among them, the single-point fault (except the main intersecting ring point) is handled in the same way as in the fourth implementation, and will not be repeated here, and the multi-point fault and the main intersecting ring point will be described in detail below.

参见图6a,节点A和主相交环点B之间发生故障1,主相交环点B和备相交环点C之间也发生故障2,由于此时备相交环点C检测到在接入工作环和主相交点之间还互通,因此备相交环点C对于接入工作环不做任何处理,无法做到虚线1的保护倒换,在此种故障条件下,下挂接入环的业务中断,即节点A、C和D到节点B、C、E和F的单播流量不通。为此,此时,可以由主相交环点B通知备相交环点C挂接阻塞点,即接通阻塞点,从而通过备相交环点C将报文传送到接入环上。比如,具体可以如下:Referring to Figure 6a, fault 1 occurs between node A and primary intersecting ring point B, and fault 2 also occurs between primary intersecting ring point B and backup intersecting ring point C. The ring and the main intersecting point are still communicating, so the standby intersecting ring point C does not perform any processing for accessing the working ring, and cannot implement the protection switching of the dotted line 1. Under such fault conditions, the service of the downlink access ring is interrupted , that is, the unicast traffic from nodes A, C, and D to nodes B, C, E, and F is blocked. Therefore, at this time, the primary intersecting ring point B can notify the standby intersecting ring point C to attach the blocking point, that is, connect the blocking point, so that the message can be transmitted to the access ring through the standby intersecting ring point C. For example, the details can be as follows:

报文由组播源下发给节点A,节点A检测到节点A与主相交环点B之间的链路发生故障,因此触发保护倒换,通过保护桥将报文从核心工作环切换到核心保护环中,由于主相交环点B和备相交环点C的链路也发生故障,因此该报文会沿着核心保护环,一直传送到备相交环点C时,才通过保护桥将报文切换回核心工作环,然后按照正常的链路传输方式对报文进行传送。此外,主相交环点B也感知到自身(即主相交环点B)与节点A之间的链路,以及自身(主相交环点B)与备相交环点C之间的链路均发生故障,因此,主相交环点B通知备相交环点C挂接阻塞点,即接通阻塞点,使得报文可以通过备相交环点C将报文传送到接入工作环上,由于主相交环点B与备相交环点C之间的链路不通,因此,报文在通过备相交环点C进入接入工作环时,会通过保护桥将报文切换到接入保护环上,一直传送到主相交环点B时,才通过保护桥将报文切换回接入工作环,然后按照正常的链路传输方式对报文进行传送,在此不再赘述。The message is sent from the multicast source to node A. Node A detects that the link between node A and the main intersecting ring point B has failed, so it triggers protection switching, and switches the message from the core working ring to the core through the protection bridge. In the protection ring, because the link between primary intersecting ring point B and standby intersecting ring point C also fails, the message will be transmitted along the core protection ring to standby intersecting ring point C, and then the report will be sent through the protection bridge. The message is switched back to the core working ring, and then the message is transmitted according to the normal link transmission mode. In addition, the primary intersecting ring point B also perceives the link between itself (that is, the primary intersecting ring point B) and node A, and the link between itself (the primary intersecting ring point B) and the backup intersecting ring point C. Therefore, the primary intersecting ring point B notifies the standby intersecting ring point C to mount the blocking point, that is, the blocking point is connected, so that the packet can be transmitted to the access working ring through the standby intersecting ring point C, because the primary intersecting ring point C The link between ring point B and backup intersecting ring point C is unreachable. Therefore, when packets enter the access working ring through backup intersecting ring point C, the packets will be switched to the access protection ring through the protection bridge. When it is transmitted to the main intersecting ring point B, the message is switched back to the access working ring through the protection bridge, and then the message is transmitted according to the normal link transmission mode, which will not be repeated here.

参见图6b,由于主相交环点B发生故障1,因此,此时备相交环点C可以检测到在接入工作环和主相交点之间不互通,所以,备相交环点C挂接阻塞点,即接通阻塞点,从而使得报文可以通过备相交环点C将报文传送到接入环上。比如,具体可以如下:Referring to Fig. 6b, since fault 1 occurs on the primary intersecting ring point B, at this time, the backup intersecting ring point C can detect that there is no intercommunication between the access working ring and the main intersecting point, so the backup intersecting ring point C is blocked Point, that is, to connect the blocking point, so that the message can be sent to the access ring through the backup intersecting ring point C. For example, the details can be as follows:

报文由组播源下发给节点A,节点A检测到主相交环点B发生故障,因此触发保护倒换,通过保护桥将报文从核心工作环切换到核心保护环中,一直传送到备相交环点C时,才通过保护桥将报文切换回核心工作环,然后按照正常的链路传输方式对报文进行传送。此外,备相交环点C也检测到主相交环点B发生故障,因此,备相交环点C挂接阻塞点,即接通阻塞点,使得报文可以通过备相交环点C将报文传送到接入工作环上,由于主相交环点B发生故障,因此,报文在通过备相交环点C进入接入工作环时,会通过保护桥将报文切换到接入保护环上,一直传送到主相交环点E时,才通过保护桥将报文切换回接入工作环,然后按照正常的链路传输方式对报文进行传送,在此不再赘述。The message is sent from the multicast source to node A. Node A detects that the main intersecting ring point B is faulty, so it triggers protection switching. The message is switched from the core working ring to the core protection ring through the protection bridge, and is transmitted to the standby ring. When intersecting ring point C, the message is switched back to the core working ring through the protection bridge, and then the message is transmitted according to the normal link transmission mode. In addition, the standby intersecting ring point C also detects that the primary intersecting ring point B is faulty. Therefore, the standby intersecting ring point C is connected to the blocking point, that is, the blocking point is connected, so that the message can be transmitted through the standby intersecting ring point C. On the access working ring, because the primary intersecting ring point B fails, when the packet enters the access working ring through the backup intersecting ring point C, the packet will be switched to the access protection ring through the protection bridge. When it is transmitted to the main intersecting ring point E, the message is switched back to the access working ring through the protection bridge, and then the message is transmitted according to the normal link transmission mode, which will not be repeated here.

由上可知,本实施例同样可以实现与实施五同样的有益效果,而且,由于本实施例在传送报文时,可以对链路和节点进行故障检测,并且在检测到故障时进行保护倒换,所以,可以进一步提高数据传输的安全性。It can be seen from the above that this embodiment can also achieve the same beneficial effect as that of Embodiment 5. Moreover, since this embodiment can perform fault detection on links and nodes when transmitting messages, and perform protection switching when a fault is detected, Therefore, the security of data transmission can be further improved.

实施例七、Embodiment seven,

为了更好地实施以上方法,本发明实施例还提供一种环网中的数据传输装置,如图7所示,该数据传输装置包括接收单元701、查询单元702、发送单元703和阻塞单元;In order to better implement the above method, an embodiment of the present invention also provides a data transmission device in a ring network. As shown in FIG. 7, the data transmission device includes a receiving unit 701, a query unit 702, a sending unit 703 and a blocking unit;

接收单元701,用于在MPLS-TP环网的工作环上接收报文。The receiving unit 701 is configured to receive messages on the working ring of the MPLS-TP ring network.

其中,该报文可以是组播报文,也可以是单播报文,该报文采用MPLS进行封装,该报文中可以包括环标签(ring label)、标签交换路径标签(lsp label)、伪线标签(pwlabel)和净荷,即该报文的格式为“环标签+标签交换路径标签+伪线标签+净荷”。Wherein, the message may be a multicast message or a unicast message, and the message is encapsulated by MPLS, and the message may include a ring label (ring label), a label switched path label (lsp label), a fake Wire label (pwlabel) and payload, that is, the format of the packet is "ring label + label switching path label + pseudowire label + payload".

其中,标签交换路径标签在格式上可以采用现有的标签交换路径标签的格式,但是其内容可以包括目的环的环标识(dring id)和目的节点的节点标识(dleaf id),伪线标签可以包括源环的环标识(sring id)和源节点的节点标识(sleaf id)。Among them, the format of the label switched path label can adopt the format of the existing label switched path label, but its content can include the ring ID (dring id) of the destination ring and the node ID (dleaf id) of the destination node, and the pseudowire label can be It includes the ring ID (sring id) of the source ring and the node ID (sleaf id) of the source node.

查询单元702,用于根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将所述报文转发给下一跳节点。The query unit 702 is configured to query a preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the message, so as to determine whether the message needs to be forwarded to the next-hop node.

其中,该不互通列表可以包括环标识(ring id)和节点标识(leaf id),用于指示节点之间是否互通,从而通过报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,就可以确定是否需要将该报文转发给下一跳节点。Wherein, the non-interworking list may include a ring ID (ring id) and a node ID (leaf id), which are used to indicate whether the nodes are interoperable, so that the pre-checked information can be queried through the ring label, label switching path label, and pseudowire label in the message. It can be determined whether the message needs to be forwarded to the next-hop node through the configured non-interworking list.

发送单元703,用于在查询单元702确定需要将该报文转发给下一跳节点时,将该报文转发给下一跳节点;The sending unit 703 is configured to forward the message to the next-hop node when the query unit 702 determines that the message needs to be forwarded to the next-hop node;

阻塞单元704,用于在查询单元确定不需要将该报文转发给下一跳节点时,省略将该报文转发给下一跳节点的操作。The blocking unit 704 is configured to omit the operation of forwarding the message to the next-hop node when the query unit determines that the message does not need to be forwarded to the next-hop node.

其中,在查询单元702根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定该报文是否需要转发给下一跳节点之前,还可以确定当前是否已构成环路,如果不是环路,才根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定该报文是否需要转发给下一跳节点,如果已经构成环路,则可以将该报文丢弃,即该环网中的数据传输装置还可以包括确定单元;Among them, before the query unit 702 queries the preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the message to determine whether the message needs to be forwarded to the next-hop node, it can also determine the current Whether a loop has been formed, if it is not a loop, query the preset non-communication list according to the ring label, label switching path label, and pseudowire label in the message to determine whether the message needs to be forwarded to the next-hop node , if a loop has been formed, the message can be discarded, that is, the data transmission device in the ring network can also include a determination unit;

确定单元,用于根据该报文中的标签交换路径标签查询终结环回报文列表,以确定是否为环路,若为环路,则丢弃报文;若不是环路时,则触发查询单元执行根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定该报文是否需要转发给下一跳节点的操作。The determining unit is used to query the list of termination ring return messages according to the label switching path label in the message, so as to determine whether it is a loop, and if it is a loop, then discard the message; if it is not a loop, trigger the query unit to execute According to the ring label, label switched path label, and pseudowire label in the message, query the preset non-interworking list to determine whether the message needs to be forwarded to the next-hop node.

此外,每个节点在接收到该报文后,根据报文传输方式的不同,还可以对报文作出进一步不同的处理,比如,对于组播而言,此时还可以复制一份报文发送给当前节点的VSI或VLL,以便该VSI或VLL可以根据该复制的报文刷新MAC地址列表,并在VSI或VLL内部对该报文进行转发;而对于单播而言,则可以在根据该报文中的标签交换路径标签确定需要交换(swap)时,直接在环上进行交换(即ring swap),而如果根据该报文中的标签交换路径标签确定为POP时,则进入VSI或VLL,并进行VSI或VLL内部转发行为;即:In addition, after each node receives the message, it can further process the message according to the different transmission methods of the message. For example, for multicast, it can also copy a message and send it to to the VSI or VLL of the current node, so that the VSI or VLL can refresh the MAC address list according to the copied message, and forward the message inside the VSI or VLL; When the label switching path label in the message determines that it needs to be swapped (swap), it will be exchanged directly on the ring (that is, ring swap), and if it is determined to be POP according to the label switching path label in the message, it will enter VSI or VLL , and perform VSI or VLL internal forwarding behavior; that is:

发送单元703,还可以用于确定该报文为组播报文,复制该报文,并将复制的报文发送给当前节点的VSI或VLL,以便VSI或VLL根据该复制的报文刷新MAC地址列表,并在VSI或VLL内部对该报文进行转发。The sending unit 703 can also be used to determine that the message is a multicast message, copy the message, and send the copied message to the VSI or VLL of the current node, so that the VSI or VLL can refresh the MAC according to the copied message address list, and forward the message within the VSI or VLL.

发送单元703,还可以用于确定该报文为单播报文;根据该报文中的标签交换路径标签确定需要交换时,触发查询单元702执行根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将所述报文转发给下一跳节点的操作;根据所该报文中的标签交换路径标签确定为POP时,将所述报文发送给当前节点的VSI或VLL,以便VSI或VLL根据所述报文刷新MAC地址列表,并在VSI或VLL内部对该报文进行转发。The sending unit 703 can also be used to determine that the message is a unicast message; when it is determined that switching is required according to the label switched path label in the message, trigger the query unit 702 to perform 1. The pseudowire label queries the preset non-interworking list to determine whether the message needs to be forwarded to the next hop node; when it is determined to be POP according to the label switching path label in the message, the The message is sent to the VSI or VLL of the current node, so that the VSI or VLL refreshes the MAC address list according to the message, and forwards the message inside the VSI or VLL.

需说明的是,对于未知的单播报文,也按照组播进行处理,在此不再赘述。It should be noted that, for unknown unicast packets, they are also processed according to multicast, which will not be repeated here.

其中,在将该报文转发给下一跳节点时,可以进行链路检测和节点检测,若均正常(即无故障),则直接通过工作环将该报文转发给下一跳节点,否则,若发现链路故障或节点故障,则进行保护倒换,即发送单元703,具体可以用于:Among them, when forwarding the message to the next hop node, link detection and node detection can be carried out. If both are normal (that is, there is no fault), the message is directly forwarded to the next hop node through the working ring, otherwise , if a link failure or node failure is found, protection switching is performed, that is, the sending unit 703 can be specifically used for:

对该MPLS-TP环网的工作环的链路和下一跳节点进行检测,Detect the link and the next hop node of the working ring of the MPLS-TP ring network,

若检测到链路故障,则进行保护倒换,通过MPLS-TP环网的保护环(即内环)上将该报文发送给下一跳节点;If a link failure is detected, protection switching is performed, and the message is sent to the next hop node through the protection ring (ie inner ring) of the MPLS-TP ring network;

若检测到下一跳节点故障,则进行保护倒换,通过MPLS-TP环网的保护环(即内环),利用绕过故障节点的路径将该报文发送给下一跳节点;If the failure of the next hop node is detected, protection switching will be performed, and the message will be sent to the next hop node through the protection ring (that is, the inner ring) of the MPLS-TP ring network by using the path that bypasses the faulty node;

若既没有检测到链路故障也没有检测到下一跳节点故障,则通过MPLS-TP环网的工作环将所述报文转发给下一跳节点。If neither link failure nor next-hop node failure is detected, the message is forwarded to the next-hop node through the working ring of the MPLS-TP ring network.

另外,需说明的是,该MPLS-TP环网可以是单环的,也可以是多环如双环。其中,双环可以包括核心工作环和接入工作环,其中,核心工作环和接入工作环可以包括两个相交环点,一个为主相交环点,另一个为备相交环点,其中,对于主相交环点和备相交环点这两个节点的VSI或VLL来说,需要分别挂接在核心工作环上,也需要挂接在接入工作环上,但是,对于备相交环点而言,其VSI或VLL挂接在接入工作环的初始状态为阻塞,只有当主相交环点通知备相交环点挂接阻塞点时,或者,备相交环点感知主相交环点故障时,备相交环点才会接通(即挂接)阻塞点。In addition, it should be noted that the MPLS-TP ring network may be a single ring or multiple rings such as double rings. Wherein, the dual ring may include a core working ring and an access working ring, wherein the core working ring and the access working ring may include two intersecting ring points, one is a primary intersecting ring point, and the other is a standby intersecting ring point, wherein, for For the VSI or VLL of the two nodes, the primary intersecting ring point and the standby intersecting ring point, they need to be mounted on the core working ring and the access working ring respectively. However, for the standby intersecting ring point , the initial state of the VSI or VLL connected to the working ring is blocked. Only when the primary intersecting ring notifies the standby intersecting ring to attach the blocking point, or when the standby intersecting ring detects that the primary intersecting ring is faulty, the standby intersecting ring The loop point will connect (that is, mount) the choke point.

若该MPLS-TP环网的工作环包括核心工作环和接入工作环,则该环网中的数据传输装置还可以包括刷新单元,具体用于:If the working ring of the MPLS-TP ring network includes a core working ring and an access working ring, then the data transmission device in the ring network may also include a refreshing unit, specifically for:

若当前节点位于核心工作环上,且为主相交环点,则将所述报文发送给位于接入工作环上的下一跳节点时,刷新相交点表项;If the current node is located on the core working ring and is the main intersecting ring point, when the message is sent to the next hop node located on the access working ring, the intersecting point entry is refreshed;

若当前节点位于核心工作环上,且为备相交环点,则当所述当前节点与所述当前节点的虚拟转发实例/虚拟租用线的连接关系由阻塞变为不阻塞,或由不阻塞变为阻塞时,清除所述当前节点上的所有表项,所述虚拟转发实例/虚拟租用线挂接到接入工作环的初始状态为阻塞。If the current node is located on the core working ring and is a standby intersecting ring point, when the connection relationship between the current node and the virtual forwarding instance/virtual leased line of the current node changes from blocking to non-blocking, or from non-blocking to When it is blocked, all entries on the current node are cleared, and the initial state of the virtual forwarding instance/virtual leased line attached to the access working ring is blocked.

此时,发送单元703,具体还可以用于:若下一跳节点位于核心工作环上,且为主相交环点,则在确定与该下一跳节点相关的多条链路发生故障(即发生多点故障)时,或在确定所述下一跳节点发生故障时,通过MPLS-TP环网的保护环,利用该备相交环点将该报文传输到接入工作环中。具体可以如下:At this time, the sending unit 703 can also be specifically configured to: if the next-hop node is located on the core working ring and is the main intersecting ring point, then when it is determined that multiple links related to the next-hop node fail (i.e. When a multi-point failure occurs), or when it is determined that the next hop node fails, the message is transmitted to the access working ring by using the backup intersecting ring point through the protection ring of the MPLS-TP ring network. The details can be as follows:

在确定与该下一跳节点相关的多条链路发生故障时,由所述下一跳节点通知备相交环点挂接接入工作环的阻塞点,以便通过MPLS-TP环网的保护环,利用该备相交环点将所述报文传输到接入工作环中。When it is determined that multiple links related to the next hop node fail, the next hop node notifies the standby intersecting ring point to connect to the blocking point of the working ring, so as to pass through the protection ring of the MPLS-TP ring network , using the backup intersecting ring point to transmit the message to the access working ring.

在确定该下一跳节点发生故障时,由备相交环点感知主相交环点故障并挂接接入工作环的阻塞点,以便通过MPLS-TP环网的保护环,利用该备相交环点将所述报文传输到接入工作环中。When it is determined that the next hop node fails, the standby intersecting ring point senses the failure of the primary intersecting ring point and connects to the blocking point of the working ring, so as to use the backup intersecting ring point through the protection ring of the MPLS-TP ring network The message is transmitted to the access working ring.

该环网中的数据传输装置具体可以集成在路由器中,这些路由器可作为MPLS-TP环网中的节点。Specifically, the data transmission device in the ring network can be integrated in routers, and these routers can be used as nodes in the MPLS-TP ring network.

具体实现时,以上各个单元可以作为独立的实体实现,也可以进行任意组合,作为同一或若干个实体来实现,以上各个单元的具体实施可参见前面的实施例,在此不再赘述。In specific implementation, each of the above units may be implemented as an independent entity, or may be combined arbitrarily as the same or several entities. The specific implementation of each of the above units may refer to the previous embodiments, and will not be repeated here.

由上可知,本实施例的环网中的数据传输装置的接收单元701可以在MPLS-TP环网的工作环上接收报文,其中,该报文采用MPLS进行封装,报文中可以包括环标签、标签交换路径标签、伪线标签和净荷,而标签交换路径标签包括目的环的环标识和目的节点的节点标识,伪线标签包括源环的环标识和源节点的节点标识,然后,由查询单元702根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将该报文转发给下一跳节点,若需要,则由发送单元703将该报文转发给下一跳节点,若不需要,则由阻塞单元704省略将该报文转发给下一跳节点的操作;由于在该方案中,采用的是MPLS对报文进行封装,因此在环网上对报文进行传输时,无需刷新MAC表,所以可以提高倒换速度;而且,由于在该方案中,维护了一张不互通列表,并通过查询该不互通列表来确定节点之间是否可以互通,因此,不仅可以简单且灵活地实现节点间的互通和不互通,提高传输效率,而且,也便于后续的维护。As can be seen from the above, the receiving unit 701 of the data transmission device in the ring network of this embodiment can receive a message on the working ring of the MPLS-TP ring network, wherein the message is encapsulated by MPLS, and the message can include ring label, label switching path label, pseudowire label and payload, and the label switching path label includes the ring identifier of the destination ring and the node identifier of the destination node, and the pseudowire label includes the ring identifier of the source ring and the node identifier of the source node, and then, The query unit 702 queries the preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the message to determine whether the message needs to be forwarded to the next hop node, and if necessary, the sending Unit 703 forwards the message to the next hop node, if not needed, then the operation of forwarding the message to the next hop node is omitted by the blocking unit 704; Encapsulation, so when the message is transmitted on the ring network, there is no need to refresh the MAC table, so the switching speed can be improved; moreover, because in this scheme, a non-interworking list is maintained, and the node is determined by querying the non-interworking list Therefore, not only can the intercommunication and non-intercommunication between nodes be realized simply and flexibly, the transmission efficiency can be improved, but also the subsequent maintenance is convenient.

实施例八、Embodiment eight,

相应的,本发明实施例还提供一种通信系统,包括本发明实施例提供的任一种环网中的数据传输装置,该环网中的数据传输装置具体可参见实施例七,在此不再赘述。Correspondingly, the embodiment of the present invention also provides a communication system, including any data transmission device in the ring network provided by the embodiment of the present invention. For the data transmission device in the ring network, please refer to Embodiment 7 for details, and it will not be described here. Let me repeat.

由于该通信系统包括本发明实施例提供的任一种环网中的数据传输装置,因此,同样可以实现与本发明实施例提供的任一种环网中的数据传输装置同样的有益效果,详见前面的实施例,在此不再赘述。Since the communication system includes any data transmission device in the ring network provided by the embodiment of the present invention, it can also achieve the same beneficial effects as the data transmission device in any ring network provided by the embodiment of the present invention. See the previous embodiments, and details will not be repeated here.

实施例九、Embodiment nine,

相应的,本发明实施例还提供一种网络设备,包括处理器、用于存储数据的存储器和用于收发数据的收发设备,如下:Correspondingly, the embodiment of the present invention also provides a network device, including a processor, a memory for storing data, and a transceiver device for sending and receiving data, as follows:

处理器,用于在MPLS-TP环网的工作环上接收报文,其中,该报文中包括环标签、标签交换路径标签、伪线标签和净荷,标签交换路径标签包括目的环的环标识和目的节点的节点标识,伪线标签包括源环的环标识和源节点的节点标识;根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将所述报文转发给下一跳节点;若是,则将该报文转发给下一跳节点;若否,则省略将该报文转发给下一跳节点的操作。The processor is used to receive the message on the working ring of the MPLS-TP ring network, wherein, the message includes the ring label, the label switching path label, the pseudowire label and the payload, and the label switching path label includes the ring label of the destination ring ID and the node ID of the destination node, the pseudowire label includes the ring ID of the source ring and the node ID of the source node; according to the ring label, label switching path label, and pseudowire label in the message, query the preset non-communication list, and use Determine whether the message needs to be forwarded to the next-hop node; if yes, forward the message to the next-hop node; if not, omit the operation of forwarding the message to the next-hop node.

其中,在根据报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定该报文是否需要转发给下一跳节点之前,还可以确定当前是否已构成环路,如果不是环路,才根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定该报文是否需要转发给下一跳节点,如果已经构成环路,则可以将该报文丢弃,即:Among them, before querying the preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the message to determine whether the message needs to be forwarded to the next-hop node, it can also be determined whether a ring is currently formed If it is not a loop, then query the preset non-communication list according to the ring label, label switched path label, and pseudowire label in the message to determine whether the message needs to be forwarded to the next-hop node. If there is a loop, the message can be discarded, that is:

该处理器,还用于根据该报文中的标签交换路径标签查询终结环回报文列表,以确定是否为环路;若为环路,则丢弃报文;若不是环路,则执行根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定该报文是否需要转发给下一跳节点的步骤。The processor is also used to query the list of terminated loop return packets according to the label switching path label in the packet to determine whether it is a loop; if it is a loop, discard the packet; if it is not a loop, execute according to the The ring label, label switched path label, and pseudowire label in the message query a preset non-interworking list to determine whether the message needs to be forwarded to a next-hop node.

此外,每个节点在接收到该报文后,根据报文传输方式的不同,还可以对报文作出进一步不同的处理,比如,对于组播而言,此时还可以复制一份报文发送给当前节点的VSI或VLL,以便该VSI或VLL可以根据该复制的报文刷新MAC地址列表,并在VSI或VLL内部对该报文进行转发;而对于单播而言,则可以在根据该报文中的标签交换路径标签确定需要交换(swap)时,直接在环上进行交换(即ring swap),而如果根据该报文中的标签交换路径标签确定为弹掉(POP)时,则进入VSI或VLL,并进行VSI或VLL内部转发行为;即在“根据所述报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将所述报文转发给下一跳节点”之前,该处理器,还用于执行如下操作:In addition, after each node receives the message, it can further process the message according to the different transmission methods of the message. For example, for multicast, it can also copy a message and send it to to the VSI or VLL of the current node, so that the VSI or VLL can refresh the MAC address list according to the copied message, and forward the message inside the VSI or VLL; When the label switching path label in the message determines that it needs to be swapped (swap), it is directly exchanged on the ring (that is, ring swap), and if it is determined to be popped (POP) according to the label switching path label in the message, then Enter the VSI or VLL, and perform the internal forwarding behavior of the VSI or VLL; that is, query the preset non-interworking list according to the ring label, label switched path label, and pseudowire label in the message to determine whether the Before the message is forwarded to the next hop node", the processor is also used to perform the following operations:

(1)组播;(1) Multicast;

确定该报文为组播报文,复制该报文(即组播报文),并将复制的报文发送给当前节点的VSI或VLL,以便VSI或VLL根据该复制的报文刷新MAC地址列表,并在VSI或VLL内部对所述报文进行转发。Determine that the message is a multicast message, copy the message (that is, a multicast message), and send the copied message to the VSI or VLL of the current node, so that the VSI or VLL can refresh the MAC address according to the copied message list, and forward the message inside the VSI or VLL.

(2)单播;(2) Unicast;

确定该报文为单播报文,根据该报文中的标签交换路径标签确定需要交换(swap)时,执行“根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将该报文转发给下一跳节点”的步骤;根据该报文中的标签交换路径标签确定为POP时,将该报文发送给当前节点的VSI或VLL,以便VSI或VLL根据该报文刷新MAC地址列表,并在VSI或VLL内部对该报文进行转发。It is determined that the packet is a unicast packet, and when it is determined that swap is required according to the label switching path label in the packet, execute "query the preset non-interworking list to determine whether the message needs to be forwarded to the next hop node” step; when the label switching path label in the message is determined to be POP, the message is sent to the VSI or VLL of the current node, So that the VSI or VLL refreshes the MAC address list according to the message, and forwards the message inside the VSI or VLL.

需说明的是,对于未知的单播报文,也按照组播进行处理,在此不再赘述。It should be noted that, for unknown unicast packets, they are also processed according to multicast, which will not be repeated here.

其中,处理器在将该报文转发给下一跳节点时,可以进行链路检测和节点检测,若均正常(即无故障),则直接通过工作环将该报文转发给下一跳节点,否则,若发现链路故障或节点故障,则进行保护倒换,即:Among them, when the processor forwards the message to the next hop node, it can perform link detection and node detection. If both are normal (that is, there is no fault), the message is directly forwarded to the next hop node through the working ring , otherwise, if a link failure or node failure is found, protection switching is performed, namely:

处理器,具体用于对所述MPLS-TP环网的工作环的链路和下一跳节点进行检测;若检测到链路故障,则进行保护倒换,通过MPLS-TP环网的保护环将所述报文发送给下一跳节点;若检测到下一跳节点故障,则进行保护倒换,通过MPLS-TP环网的保护环,利用绕过故障节点的路径将所述报文发送给下一跳节点的下一跳节点;若既没有检测到链路故障也没有检测到下一跳节点故障,则通过MPLS-TP环网的工作环将所述报文转发给下一跳节点。The processor is specifically used to detect the link and the next hop node of the working ring of the MPLS-TP ring network; if a link failure is detected, then protection switching is performed, and the protection ring of the MPLS-TP ring network will The message is sent to the next hop node; if a failure of the next hop node is detected, protection switching is performed, and the message is sent to the next hop node through the protection ring of the MPLS-TP ring network by using a path bypassing the faulty node. The next hop node of the first hop node; if neither the link failure nor the next hop node failure is detected, the message is forwarded to the next hop node through the working ring of the MPLS-TP ring network.

另外,需说明的是,该MPLS-TP环网可以是单环的,也可以是多环如双环。其中,双环可以包括核心工作环和接入工作环,其中,核心工作环和接入工作环可以包括两个相交环点,一个为主相交环点,另一个为备相交环点,其中,对于主相交环点和备相交环点这两个节点的VSI或VLL来说,既需要分别挂接在核心工作环上,也需要挂接在接入工作环上,但是,对于备相交环点而言,其VSI或VLL挂接在接入工作环的初始状态为阻塞,只有当主相交环点通知备相交环点挂接阻塞点时,或者,备相交环点感知主相交环点故障时,备相交环点才会接通(即挂接)阻塞点。In addition, it should be noted that the MPLS-TP ring network may be a single ring or multiple rings such as double rings. Wherein, the dual ring may include a core working ring and an access working ring, wherein the core working ring and the access working ring may include two intersecting ring points, one is a primary intersecting ring point, and the other is a standby intersecting ring point, wherein, for For the VSI or VLL of the two nodes, the primary intersecting ring point and the standby intersecting ring point, they need to be mounted on the core working ring and the access working ring respectively. However, for the standby intersecting ring point In other words, the initial state of its VSI or VLL connected to the working ring is blocked. Only when the master intersecting ring notifies the standby intersecting ring to attach the blocking point, or when the standby intersecting ring detects that the main intersecting ring fails, the backup Intersecting ring points will connect (that is, hook up) the choke point.

若该MPLS-TP环网的工作环包括核心工作环和接入工作环,则处理器,具体可以用于:若下一跳节点位于核心工作环上,且为主相交环点,则在确定与该下一跳节点相关的多条链路发生故障(即发生多点故障)时,或在确定所述下一跳节点发生故障时,通过MPLS-TP环网的保护环,利用该备相交环点将该报文传输到接入工作环中;具体可以如下:If the working ring of the MPLS-TP ring network includes a core working ring and an access working ring, the processor can specifically be used to: if the next-hop node is located on the core working ring and is the main intersecting ring point, then determine When multiple links related to the next-hop node fail (that is, a multi-point failure occurs), or when it is determined that the next-hop node fails, use the backup intersecting link through the protection ring of the MPLS-TP ring network The ring point transmits the message to the access working ring; the details can be as follows:

在确定与该下一跳节点相关的多条链路发生故障时,由所述下一跳节点通知备相交环点挂接接入工作环的阻塞点,以便通过MPLS-TP环网的保护环,利用该备相交环点将所述报文传输到接入工作环中。When it is determined that multiple links related to the next hop node fail, the next hop node notifies the standby intersecting ring point to connect to the blocking point of the working ring, so as to pass through the protection ring of the MPLS-TP ring network , using the backup intersecting ring point to transmit the message to the access working ring.

在确定该下一跳节点发生故障时,由备相交环点感知主相交环点故障并挂接接入工作环的阻塞点,以便通过MPLS-TP环网的保护环,利用该备相交环点将所述报文传输到接入工作环中。When it is determined that the next hop node fails, the standby intersecting ring point senses the failure of the primary intersecting ring point and connects to the blocking point of the working ring, so as to use the backup intersecting ring point through the protection ring of the MPLS-TP ring network The message is transmitted to the access working ring.

此外,根据当前节点的位置的不通,其所需要执行的后续处理也会有所不同,例如,处理器,还可以用于执行如下操作:In addition, depending on the position of the current node, the subsequent processing it needs to perform will also be different. For example, the processor can also be used to perform the following operations:

若当前节点位于核心工作环上,且为主相交环点,则在将该报文发送给位于接入工作环上的下一跳节点时,还需要刷新相交点表项,其中,该相交点表项可以包括环标识和节点标识,主要用于当从其他接口接收到的以该当前节点作为源节点的报文时,判断是否终结该报文(即此时为环回)。If the current node is on the core working ring and is the main intersecting ring point, when sending the message to the next-hop node on the access working ring, it is also necessary to refresh the intersection point entry, where the intersection point The entry may include a ring identifier and a node identifier, and is mainly used for judging whether to terminate the packet (that is, loopback at this time) when a packet with the current node as the source node is received from another interface.

而若当前节点位于核心工作环上,且为备相交环点,则当该当前节点与所述当前节点的VSI或VLL的连接关系由阻塞变为不阻塞,或由不阻塞变为阻塞时,还需要清除该当前节点上的所有表项,其中,VSI或VLL挂接到接入工作环的初始状态为阻塞。And if the current node is located on the core working ring and is a standby intersecting ring point, then when the connection relationship between the current node and the VSI or VLL of the current node changes from blocking to non-blocking, or from non-blocking to blocking, It is also necessary to clear all entries on the current node, where the initial state of the VSI or VLL attached to the access working ring is blocked.

以上各个设备的具体实施可参见前面的实施例,在此不再赘述。For the specific implementation of each of the above devices, reference may be made to the foregoing embodiments, and details are not repeated here.

由上可知,本实施例的网络设备采用在MPLS-TP环网的工作环上接收报文,其中,该报文采用MPLS进行封装,报文中包括环标签、标签交换路径标签、伪线标签和净荷,而标签交换路径标签包括目的环的环标识和目的节点的节点标识,伪线标签包括源环的环标识和源节点的节点标识,然后,根据该报文中的环标签、标签交换路径标签、伪线标签查询预置的不互通列表,以确定是否需要将该报文转发给下一跳节点,若需要,则将该报文转发给下一跳节点,若不需要,则省略将该报文转发给下一跳节点的操作;由于在该方案中,采用的是MPLS对报文进行封装,因此在环网上对报文进行传输时,无需刷新MAC表,所以可以提高倒换速度;而且,由于在该方案中,维护了一张不互通列表,并通过查询该不互通列表来确定节点之间是否可以互通,因此,不仅可以简单且灵活地实现节点间的互通和不互通,提高传输效率,而且,也便于后续的维护。As can be seen from the above, the network device in this embodiment receives messages on the working ring of the MPLS-TP ring network, wherein the messages are encapsulated using MPLS, and the messages include ring labels, label switching path labels, and pseudowire labels. and payload, while the label switched path label includes the ring ID of the destination ring and the node ID of the destination node, and the pseudowire label includes the ring ID of the source ring and the node ID of the source node. Then, according to the ring label, label Switch the path label and pseudowire label to query the preset non-communication list to determine whether the message needs to be forwarded to the next-hop node, if necessary, forward the message to the next-hop node, if not, then Omit the operation of forwarding the message to the next hop node; because in this scheme, MPLS is used to encapsulate the message, so when the message is transmitted on the ring network, there is no need to refresh the MAC table, so the switching speed can be improved. speed; moreover, since in this scheme, a non-communication list is maintained, and whether nodes can communicate with each other is determined by querying the non-communication list, therefore, not only the intercommunication and non-communication between nodes can be realized simply and flexibly , improve transmission efficiency, and also facilitate subsequent maintenance.

本领域普通技术人员可以理解上述实施例的各种方法中的全部或部分步骤是可以通过程序来指令相关的硬件来完成,该程序可以存储于一计算机可读存储介质中,存储介质可以包括:只读存储器(ROM,Read Only Memory)、随机存取记忆体(RAM,RandomAccess Memory)、磁盘或光盘等。Those of ordinary skill in the art can understand that all or part of the steps in the various methods of the above-mentioned embodiments can be completed by instructing related hardware through a program, and the program can be stored in a computer-readable storage medium, and the storage medium can include: Read Only Memory (ROM, Read Only Memory), Random Access Memory (RAM, Random Access Memory), disk or CD, etc.

以上对本发明实施例所提供的一种环网中的数据传输方法、装置和系统进行了详细介绍,本文中应用了具体个例对本发明的原理及实施方式进行了阐述,以上实施例的说明只是用于帮助理解本发明的方法及其核心思想;同时,对于本领域的技术人员,依据本发明的思想,在具体实施方式及应用范围上均会有改变之处,综上所述,本说明书内容不应理解为对本发明的限制。The data transmission method, device and system in a ring network provided by the embodiments of the present invention are described above in detail. In this paper, specific examples are used to illustrate the principle and implementation of the present invention. The description of the above embodiments is only It is used to help understand the method and its core idea of the present invention; at the same time, for those skilled in the art, according to the idea of the present invention, there will be changes in the specific implementation and scope of application. In summary, this specification The content should not be construed as a limitation of the invention.

Claims (19)

1. the data transmission method in a kind of looped network, it is characterised in that including:
Message is received on the building ring of the transmission subset MPLS-TP looped networks of multiprotocol label switching, the message includes ring Label, label switched path label, pseudo line tag and payload, the ring mark of the label switched path label including purpose ring and The node identification of destination node, the pseudo line tag includes the ring mark of source ring and the node identification of source node;
Ring label, label switched path label, pseudo line tag in the message inquire about preset not intercommunication list, with true It is fixed whether to need for the message to be transmitted to next-hop node;The not intercommunication list be used to indicate between node whether intercommunication;
If it is determined that the message is transmitted to next-hop node by needs, then the message is transmitted to next-hop node;
If it is determined that the message need not be transmitted into next-hop node, then omit and the message is transmitted to next-hop node Operation.
2. method according to claim 1, it is characterised in that ring label, the Tag switching in the message Path label, pseudo line tag inquire about preset not intercommunication list, to determine whether the message needs to be transmitted to next-hop node Before, methods described also includes:
Label switched path tag queries termination loopback message list in the message, to determine whether being loop;
If it is determined that being loop, then dropping packets;
If it is determined that not being loop, then triggering performs ring label, label switched path label, the pseudo-wire in the message The preset not intercommunication list of tag queries, to determine whether the message needs to be transmitted to the operation of next-hop node.
3. method according to claim 2, it is characterised in that ring label, the Tag switching in the message Path label, pseudo line tag inquire about preset not intercommunication list, to determine the need for for the message being transmitted to next-hop section Before point, methods described also includes:
Determine that the message is multicast message;
The message is replicated, and the message of duplication is sent to the Virtual Switch Instance or virtual leased line of present node.
4. method according to claim 2, it is characterised in that ring label, the Tag switching in the message Path label, pseudo line tag inquire about preset not intercommunication list, to determine the need for for the message being transmitted to next-hop section Before point, methods described also includes:
Determine that the message is unicast message;
When label switched path label in the message determines to need to exchange, triggering performs the ring in the message Label, label switched path label, pseudo line tag inquire about preset not intercommunication list, to determine the need for turning the message Issue the operation of next-hop node;
When label switched path label in the message is defined as bullet and falls POP, the message is sent to present node Virtual Switch Instance or virtual leased line.
5. the method according to any one of Claims 1-4, it is characterised in that described that the message is transmitted to next-hop Node, including:
Link and next-hop node to the building ring of the MPLS-TP looped networks are detected;
If detecting link failure, pretection switch is carried out, be sent to down the message by the protection ring of MPLS-TP looped networks One hop node;
If detecting next-hop node failure, pretection switch is carried out, it is former using bypassing by the protection ring of MPLS-TP looped networks The message is sent to the next-hop node of next-hop node in the path for hindering node;
If both not detected link failure or not detected next-hop node failure, by the work of MPLS-TP looped networks The message is transmitted to next-hop node by ring.
6. the method according to any one of Claims 1-4, it is characterised in that if the building ring bag of the MPLS-TP looped networks Include core work ring and cut-in operation ring, then it is described that the message is transmitted to next-hop node, including:
If next-hop node be located at core work ring on, and based on intersect circling point, then it is determined that related to the next-hop node Multilink when breaking down, or when it is determined that the next-hop node breaks down, by the protection of MPLS-TP looped networks Ring, using standby intersecting circling point by the message transmissions to cut-in operation ring.
7. method according to claim 6, it is characterised in that it is determined that the multilink related to the next-hop node When breaking down, by the protection ring of MPLS-TP looped networks, using the standby circling point that intersects by the message transmissions to cut-in operation In ring, including:
When it is determined that the multilink related to the next-hop node breaks down, notify standby intersecting by the next-hop node Circling point mounts the choke point of cut-in operation ring, will pass through the protection ring of MPLS-TP looped networks, using the standby circling point that intersects by institute Message transmissions are stated in cut-in operation ring.
8. method according to claim 6, it is characterised in that when it is determined that the next-hop node breaks down, pass through The protection ring of MPLS-TP looped networks, using the standby intersecting circling point by the message transmissions to cut-in operation ring, including:
When it is determined that the next-hop node breaks down, perceived main intersecting circling point failure and mounted access work by standby intersecting circling point Make the choke point of ring, will pass through the protection ring of MPLS-TP looped networks, using the standby intersecting circling point by the message transmissions to connecing In entering building ring.
9. the method according to any one of Claims 1-4, it is characterised in that if the building ring bag of the MPLS-TP looped networks Core work ring and cut-in operation ring are included, then:
If present node be located at core work ring on, and based on intersect circling point, then by the message be sent to positioned at access work When making the next-hop node on ring, refresh joining list item;
If present node is located on core work ring, and is standby intersecting circling point, then when the present node and the present node The annexation of Virtual Switch Instance/virtual leased line be changed into not blocking from blocking, or when being changed into obstruction from not blocking, remove All list items on the present node, the Virtual Switch Instance/virtual leased line is articulated to the initial shape of cut-in operation ring State is obstruction.
10. the data transmission device in a kind of looped network, it is characterised in that including:
Receiving unit, it is described for receiving message on the building ring of the transmission subset MPLS-TP looped networks of multiprotocol label switching Message includes ring label, label switched path label, pseudo line tag and payload, and the label switched path label includes purpose The ring mark and the node identification of destination node of ring, the pseudo line tag include the ring mark of source ring and the node mark of source node Know;
Query unit, it is preset not for the ring label in the message, label switched path label, pseudo line tag inquiry Intercommunication list, to determine the need for for the message being transmitted to next-hop node;The not intercommunication list be used for indicate node it Between whether intercommunication;
Transmitting element, for when the query unit determines to need for the message to be transmitted to next-hop node, by the report Text is transmitted to next-hop node;
Blocking unit, for being omitted institute when the query unit determines the message need not be transmitted into next-hop node State the operation that message is transmitted to next-hop node.
Data transmission device in 11. looped networks according to claim 10, it is characterised in that also including determining unit;
The determining unit, in the message label switched path tag queries terminate loopback message list, with Determine whether to be loop, if loop, then dropping packets;If not during loop, then triggering query unit and performing according to the report Whether ring label, label switched path label, pseudo line tag in text inquire about preset not intercommunication list, to determine the message Need to be transmitted to the operation of next-hop node.
Data transmission device in 12. looped networks according to claim 11, it is characterised in that
The transmitting element, is additionally operable to determine the message for multicast message, replicates the message, and the message that will be replicated sends To the Virtual Switch Instance or virtual leased line of present node.
Data transmission device in 13. looped networks according to claim 11, it is characterised in that
The transmitting element, is additionally operable to determine that the message is unicast message;Label switched path mark in the message When signing determination and needing to exchange, trigger ring label, label switched path label that the query unit performed in the message, Pseudo line tag inquires about preset not intercommunication list, to determine the need for being transmitted to the message operation of next-hop node; When label switched path label in the message is defined as bullet and falls POP, the message is sent to the void of present node Intend forwarding instance or virtual leased line.
Data transmission device in 14. looped network according to any one of claim 10 to 13, it is characterised in that the transmission Unit, specifically for:
Link and next-hop node to the building ring of the MPLS-TP looped networks are detected;
If detecting link failure, pretection switch is carried out, be sent to down the message by the protection ring of MPLS-TP looped networks One hop node;If detecting next-hop node failure, carry out pretection switch, by the protection ring of MPLS-TP looped networks, using around The message is sent to the next-hop node of next-hop node in the path for crossing malfunctioning node;
If both not detected link failure or not detected next-hop node failure, by the work of MPLS-TP looped networks The message is transmitted to next-hop node by ring.
Data transmission device in 15. looped network according to any one of claim 10 to 13, it is characterised in that if described The building ring of MPLS-TP looped networks includes core work ring and cut-in operation ring, then the transmitting element, specifically for:
If next-hop node be located at core work ring on, and based on intersect circling point, then it is determined that related to the next-hop node Multilink when breaking down, or when it is determined that the next-hop node breaks down, by the protection of MPLS-TP looped networks Ring, using standby intersecting circling point by the message transmissions to cut-in operation ring.
Data transmission device in 16. looped networks according to claim 15, it is characterised in that the transmitting element, specifically For:
If next-hop node be located at core work ring on, and based on intersect circling point, then it is determined that related to the next-hop node Multilink when breaking down, notify that standby intersecting circling point mounts the choke point of cut-in operation ring by the next-hop node, with The protection ring of MPLS-TP looped networks is will pass through, using the standby intersecting circling point by the message transmissions to cut-in operation ring.
Data transmission device in 17. looped networks according to claim 15, it is characterised in that the transmitting element, specifically For:
If next-hop node be located at core work ring on, and based on intersect circling point, then it is determined that the next-hop node occur therefore During barrier, perceived main intersecting circling point failure and mounted the choke point of cut-in operation ring by standby intersecting circling point, will pass through MPLS-TP rings The protection ring of net, using the standby intersecting circling point by the message transmissions to cut-in operation ring.
Data transmission device in 18. looped network according to any one of claim 10 to 13, it is characterised in that if described The building ring of MPLS-TP looped networks includes core work ring and cut-in operation ring, then the data transmission device in the looped network is also wrapped Refresh unit is included, specifically for:
If present node be located at core work ring on, and based on intersect circling point, then the message is sent to positioned at cut-in operation During next-hop node on ring, refresh joining list item;
If present node is located on core work ring, and is standby intersecting circling point, then when the present node and the present node The annexation of Virtual Switch Instance/virtual leased line be changed into not blocking from blocking, or when being changed into obstruction from not blocking, remove All list items on the present node, the Virtual Switch Instance/virtual leased line is articulated to the initial shape of cut-in operation ring State is obstruction.
19. a kind of communication systems, it is characterised in that including at least two data transmission devices, at least two data transfer Each device in device is the data transmission device as described in claim 10 to 18 is any.
CN201310722942.6A 2013-12-24 2013-12-24 Data transmission method, device and system in a kind of looped network Active CN103856404B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201310722942.6A CN103856404B (en) 2013-12-24 2013-12-24 Data transmission method, device and system in a kind of looped network

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310722942.6A CN103856404B (en) 2013-12-24 2013-12-24 Data transmission method, device and system in a kind of looped network

Publications (2)

Publication Number Publication Date
CN103856404A CN103856404A (en) 2014-06-11
CN103856404B true CN103856404B (en) 2017-06-27

Family

ID=50863637

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310722942.6A Active CN103856404B (en) 2013-12-24 2013-12-24 Data transmission method, device and system in a kind of looped network

Country Status (1)

Country Link
CN (1) CN103856404B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106533741B (en) * 2016-10-31 2019-07-26 盛科网络(苏州)有限公司 Realize that MPLS-TP shares the method and device of ring protection MSRP Ring protection system based on OpenFlow
CN106899439B (en) * 2017-02-27 2021-09-10 上海易杵行智能科技有限公司 Intelligent construction method of single-ring network
CN106941445B (en) * 2017-02-27 2019-11-26 烽火通信科技股份有限公司 The method and system of the quick stratification pretection switch of MPLS-TP
CN120238422A (en) * 2023-12-28 2025-07-01 中兴通讯股份有限公司 Transmission link failure processing method, electronic device and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101895455A (en) * 2010-07-19 2010-11-24 南京邮电大学 Method for fast protecting ring network based on multi-protocol label switching transport profile (MPLS-TP)
CN102123101A (en) * 2011-03-21 2011-07-13 中兴通讯股份有限公司 Message processing method and device
CN102201985A (en) * 2011-05-06 2011-09-28 杭州华三通信技术有限公司 Ring protection switching method adopting multi-protocol label switching transport profile (MPLS TP) and node
CN102291316A (en) * 2011-09-14 2011-12-21 中兴通讯股份有限公司 Method for realizing zero label popup during MPLS (Multi-Protocol Label Switching) and edge equipment
CN102684973A (en) * 2011-03-09 2012-09-19 中兴通讯股份有限公司 Method and system for protecting looped network

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101895455A (en) * 2010-07-19 2010-11-24 南京邮电大学 Method for fast protecting ring network based on multi-protocol label switching transport profile (MPLS-TP)
CN102684973A (en) * 2011-03-09 2012-09-19 中兴通讯股份有限公司 Method and system for protecting looped network
CN102123101A (en) * 2011-03-21 2011-07-13 中兴通讯股份有限公司 Message processing method and device
CN102201985A (en) * 2011-05-06 2011-09-28 杭州华三通信技术有限公司 Ring protection switching method adopting multi-protocol label switching transport profile (MPLS TP) and node
CN102291316A (en) * 2011-09-14 2011-12-21 中兴通讯股份有限公司 Method for realizing zero label popup during MPLS (Multi-Protocol Label Switching) and edge equipment

Also Published As

Publication number Publication date
CN103856404A (en) 2014-06-11

Similar Documents

Publication Publication Date Title
EP3713162B1 (en) Route processing method and apparatus
US9137099B2 (en) Method, device, and system for link aggregation failure protection
CN102299835B (en) Ring network failover method and device
WO2019120042A1 (en) Method and node for transmitting packet in network
US20130272114A1 (en) Pseudo wire switching method and device
CN102882780B (en) Looped network tunnel configuration method based on overlapping trees, ring network protection method and system
WO2012028029A1 (en) Switching method and system
CN101999224A (en) Redundant Ethernet automatic protection switching access to virtual private lan services
CN102025541A (en) Method and system for realizing multicast protection
WO2020024828A1 (en) Communication method, communication device and communication system
WO2011060667A1 (en) Method and device for link protection in virtual private local area network
WO2013113218A1 (en) Intersecting ring protection method, device and system
CN101227399A (en) Message transmission method, system and forwarding node
CN102546357B (en) Message forwarding method and network device
WO2016034127A1 (en) System and method for achieving dual-node interconnection pseudo-wire
CN103856404B (en) Data transmission method, device and system in a kind of looped network
CN101783743B (en) A service protection method and switching node
CN102185712B (en) The reverse method of VPLS network and ethernet ring network and device
CN102868605B (en) A kind of looped network data guard method and device
CN111885630B (en) Data transmission method and communication device
CN107968753A (en) The method and apparatus for changing Media Access Control Address forwarding table
CN101729361B (en) Method and device for message processing
CN104702498B (en) A kind of method and device reducing equipment room light connects quantity by harmonious protection
CN100446500C (en) Spanning tree network connection ring network protection method and its applied network nodes
WO2013007124A1 (en) Method and system for advertising virtual router redundancy protocol link protection

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant