WO2024045537A1 - Message transmission method and network device - Google Patents

Message transmission method and network device Download PDF

Info

Publication number
WO2024045537A1
WO2024045537A1 PCT/CN2023/079614 CN2023079614W WO2024045537A1 WO 2024045537 A1 WO2024045537 A1 WO 2024045537A1 CN 2023079614 W CN2023079614 W CN 2023079614W WO 2024045537 A1 WO2024045537 A1 WO 2024045537A1
Authority
WO
WIPO (PCT)
Prior art keywords
header
message
node
multicast
information
Prior art date
Application number
PCT/CN2023/079614
Other languages
French (fr)
Chinese (zh)
Inventor
谢经荣
段方红
张耀坤
Original Assignee
华为技术有限公司
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 华为技术有限公司 filed Critical 华为技术有限公司
Publication of WO2024045537A1 publication Critical patent/WO2024045537A1/en

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/02Details
    • H04L12/16Arrangements for providing special services to substations
    • H04L12/18Arrangements for providing special services to substations for broadcast or conference, e.g. multicast
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/46Interconnection of networks

Definitions

  • This application relates to the field of communications, and in particular to message transmission methods and network equipment.
  • multicast technology can provide point-to-multipoint forwarding in the network, effectively reducing network redundant traffic and reducing network load.
  • it can reduce the load on servers and processors in the application platform, reducing the impact of the increase in the number of users. Impact on multicast sources.
  • the network frame based on multicast technology can include user networks and backbone networks.
  • the backbone network can use different tunnels for packet transmission.
  • the backbone network can support one or more tunnels. Multicast packets from user networks need to be encapsulated when entering the backbone network. The encapsulated packets are transmitted through the tunnel in the backbone network.
  • the backbone network can be a network running a Multicast Virtual Private Network VPN (MVPN) or an Ethernet Virtual Private Network (Ethernet VPN, EVPN).
  • MVPN Multicast Virtual Private Network VPN
  • EVPN Ethernet Virtual Private Network
  • This application provides a message transmission method and network equipment, which can reduce the transmission overhead of multicast messages in the backbone network.
  • this application provides a message transmission method, including: an entry node receives a first message sent by a user edge device, where the first message includes a first message header and a payload, and the first message
  • the message header includes multicast source group information; the entry node obtains tunnel information according to the multicast source group information and the corresponding relationship, where the corresponding relationship includes the multicast source group information and the tunnel information;
  • the entry node obtains a second message according to the payload and the tunnel information.
  • the second message includes the payload and a second message header corresponding to the tunnel information.
  • the second message does not include the The first message header is provided; the ingress node sends the second message through the tunnel corresponding to the tunnel information.
  • the method provided by this application is applicable to a network architecture based on multicast technology.
  • the network architecture may include a user network and a backbone network.
  • the backbone network includes an entry node, an intermediate node, and an exit node.
  • the entry node and the exit node are the same as those in the backbone network.
  • the edge node of the user network for message exchange.
  • the message sent by the CE device is recorded as the first message.
  • the entrance node encapsulates the received first message to obtain the second message header, and adds the first message header of the first message to Delete, get the second message and forward it.
  • the second message may be forwarded to the egress node through one or more intermediate nodes, or the second message may be forwarded by the ingress node to the egress node.
  • the egress node When the second packet reaches the egress node, the egress node The packet is encapsulated to obtain the first packet header, and the second packet header is deleted to obtain the first packet.
  • the first header in the first message may be an Internet Protocol version 6 (IPv6) header or an Internet Protocol version 4 (IPv4) header.
  • IPv6 Internet Protocol version 6
  • IPv4 Internet Protocol version 4
  • the corresponding relationship is the relationship between the multicast source group information and the tunnel information of each node in the backbone network, and can be established by the ingress node. Furthermore, the tunnel information determined based on the correspondence relationship corresponds to the second packet header.
  • the tunnel information and the second packet header can be expressed in different ways, such as In a scenario where an IP multicast tunnel is used between an ingress node and an egress node, for example, the ingress node encapsulates based on Internet Protocol (IP).
  • IP Internet Protocol
  • the ingress node can encapsulate based on IPv6, and the resulting second message header includes IPv6 header, the IPv6 header includes the source address and destination address corresponding to the tunnel information, where the destination address is the multicast group address corresponding to the multicast tree; bit index based on IPv6 encapsulation is explicitly copied between the ingress node and the egress node.
  • Bit Index Explicit Replication IPv6 Encapsulation, BIERv6 Bit Index Explicit Replication IPv6 Encapsulation, BIERv6
  • the BIERv6 header includes the source address and destination address corresponding to the tunnel information, where the destination address is a unicast address, or the BIERv6 header may include the source address corresponding to the tunnel information.
  • the source address excluding the destination address; in the scenario where a Multiprotocol Label Switching point-to-multipoint (MPLS P2MP) tunnel is used between the ingress node and the egress node, the tunnel information and the second report
  • MPLS P2MP Multiprotocol Label Switching point-to-multipoint
  • the header corresponds to the MPLS label.
  • the tunnel information and the second header correspond to the upstream MPLS label.
  • the second message header includes an IPv6 header and a Generic Routing Encapsulation (GRE) header
  • the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  • GRE Generic Routing Encapsulation
  • the second message header includes an IPv4 header and a GRE header
  • the IPv4 header includes a source address and a destination address corresponding to the tunnel information.
  • the second message header includes an IPv6 header and an IPv6 extension header
  • the IPv6 header includes a source address and a destination address corresponding to the tunnel information
  • the second message header includes an IPv6 header
  • the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  • the destination address is the address of the next hop of the entry node in the multicast tree or the destination address is the multicast group address corresponding to the multicast tree.
  • the second message header corresponding to the tunnel information is a Multiprotocol Label Switching (MPLS) header
  • MPLS header includes the entry node in the multicast tree.
  • the second message header corresponding to the tunnel information includes a Bit Index Explicit Replication (BIER) header and a label
  • BIER Bit Index Explicit Replication
  • the BIER header includes the information related to the tunnel information.
  • the identifier of the egress node corresponding to the information, and the label is used to identify the multicast source group information.
  • the method further includes: the ingress node notifying the egress node of the corresponding relationship.
  • the corresponding relationship may be static configuration of the entry node and the exit node respectively.
  • the method further includes: the ingress node notifying the egress node of indication information, where the indication information is used to instruct restoration of the multicast source group information.
  • the indication information is used to instruct to restore the multicast source group information, that is, the indication information is at least used to instruct the egress node to restore the multicast source group information of the first packet header, so that The egress node obtains the first message according to the indication information and the second message.
  • the ingress node notifying the corresponding relationship to the egress node includes: the ingress node sends a Border Gateway Protocol (Border Gateway Protocol, BGP) message to the egress node, and the BGP message includes the corresponding relationship.
  • BGP Border Gateway Protocol
  • the BGP message is Border Gateway Protocol-Multicast VPN (BGP-MVPN) signaling or Border Gateway Protocol-Ethernet VPN (BGP-EVPN) ) signaling.
  • the entrance node deletes the first message header and encapsulates the second message header to obtain a second message.
  • the second message is transmitted in the backbone network.
  • the egress node deletes the second message.
  • Second packet header restore the first packet header to obtain the first packet. In this way, during the transmission of the backbone network, the second packet no longer needs to carry the first packet header, which can reduce the time of packet transmission in the backbone network. overhead.
  • this application provides a message transmission method, including: an egress node receiving a second message, the second message including a payload and a second message header corresponding to tunnel information; the egress node Obtain multicast source group information according to the corresponding relationship and the tunnel information corresponding to the second message header, where the corresponding relationship includes the tunnel information and the multicast source group information; the egress node obtains the multicast source group information according to the Multicast source group information and the payload are obtained in a first message, the first message includes a first message header and the payload, the first message header includes the multicast source group information, and the The first message does not include the second message header.
  • the second message header includes an IPv6 header and a GRE header
  • the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  • the second message header includes an IPv4 header and a GRE header
  • the IPv4 header includes a source address and a destination address corresponding to the tunnel information.
  • the second message header includes an IPv6 header and an IPv6 extension header
  • the IPv6 header includes a source address and a destination address corresponding to the tunnel information
  • the second message header includes an IPv6 header
  • the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  • the destination address is the address of the next hop of the entry node in the multicast tree or the destination address is the multicast group address corresponding to the multicast tree.
  • the method before the egress node obtains the first message according to the multicast source group information and the payload, the method further includes: the egress node receives a third message, and the third message
  • the message includes the payload and a third message header corresponding to the tunnel information; the egress node obtains the multicast source group information according to the corresponding relationship and the tunnel information corresponding to the third message header,
  • the third message header is an MPLS header, and the MPLS header includes the MPLS label allocated by the egress node for the multicast tree or the MPLS label corresponding to the multicast tree.
  • the second message header corresponding to the tunnel information includes a BIER header and a label
  • the BIER header includes an identification of the egress node corresponding to the tunnel information
  • the label is To identify the multicast source group information.
  • the method further includes: the egress node obtains the corresponding relationship advertised by the ingress node.
  • the method further includes: the egress node receiving indication information advertised by the ingress node, where the indication information is used to instruct restoration of the multicast source group information.
  • the egress node obtaining the corresponding relationship advertised by the ingress node includes: The egress node receives the BGP message sent by the ingress node, and the BGP message includes the corresponding relationship.
  • the BGP message is BGP-MVPN signaling or BGP-EVPN signaling.
  • the present application provides a network device.
  • the network device is provided at an entrance node.
  • the network device includes: a receiving module configured to receive a first message sent by a user edge device.
  • the first message Containing a first packet header and a payload, the first packet header including multicast source group information; a processing module configured to obtain tunnel information according to the multicast source group information and a corresponding relationship, the corresponding relationship including all The multicast source group information and the tunnel information;
  • the processing module is also configured to obtain a second message according to the load and the tunnel information, where the second message includes the payload and the tunnel information.
  • the second message header includes an IPv6 header and a GRE header
  • the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  • the second message header includes an IPv4 header and a GRE header
  • the IPv4 header includes a source address and a destination address corresponding to the tunnel information.
  • the second message header includes an IPv6 header and an IPv6 extension header
  • the IPv6 header includes a source address and a destination address corresponding to the tunnel information
  • the second message header includes an IPv6 header
  • the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  • the destination address is the address of the next hop of the entry node in the multicast tree or the destination address is the multicast group address corresponding to the multicast tree.
  • the second message header is an MPLS header
  • the MPLS header includes the MPLS label of the next hop node of the entry node in the multicast tree or the MPLS label corresponding to the multicast tree.
  • the second message header includes a BIER header and a label
  • the BIER header includes an identification of the egress node corresponding to the tunnel information
  • the label is used to identify the group Source group information.
  • the sending module is also configured to notify the egress node of the corresponding relationship.
  • the sending module is further configured to notify the egress node of indication information, where the indication information is used to instruct restoration of the multicast source group information.
  • the sending module is specifically configured to send a BGP message to the egress node, where the BGP message includes the corresponding relationship.
  • the BGP message is BGP-MVPN signaling or Border Gateway Protocol-BGP-EVPN signaling.
  • the present application provides a network device.
  • the network device is provided at an egress node.
  • the network device includes: a receiving module configured to receive a second message.
  • the second message includes a payload and a tunnel link. a second message header corresponding to the information;
  • a processing module configured to obtain multicast source group information according to the corresponding relationship and the tunnel information corresponding to the second message header, where the corresponding relationship includes the tunnel information and the tunnel information corresponding to the second message header;
  • the processing module is also configured to obtain a first message according to the multicast source group information and the payload, where the first message includes a first message header and the payload,
  • the first message header includes the multicast source group information, and the first message does not include the second message header.
  • the second packet header corresponding to the tunnel information includes an IPv6 header and a GRE header
  • the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  • the second message header corresponding to the tunnel information includes an IPv4 header and GRE header
  • the IPv4 header includes the source address and destination address corresponding to the tunnel information.
  • the second packet header corresponding to the tunnel information includes an IPv6 header and an IPv6 extension header
  • the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  • the second packet header corresponding to the tunnel information includes an IPv6 header
  • the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  • the destination address is the address of the next hop of the entry node in the multicast tree or the destination address is the multicast group address corresponding to the multicast tree.
  • the receiving module is also configured to receive a third message, the third message including the payload and a third message header corresponding to the tunnel information; the processing module , and is further configured to obtain the multicast source group information according to the corresponding relationship and the tunnel information corresponding to the third message header, where the third message header is a multi-protocol label switching MPLS header, and the The MPLS header includes the MPLS label allocated by the egress node for the multicast tree or the MPLS label corresponding to the multicast tree.
  • the second message header corresponding to the tunnel information includes a BIER header and a label
  • the BIER header includes an identification of the egress node corresponding to the tunnel information
  • the label is To identify the multicast source group information.
  • the receiving module is also configured to obtain the corresponding relationship advertised by the entry node.
  • the receiving module is further configured to receive indication information advertised by the ingress node, where the indication information is used to instruct restoration of the multicast source group information.
  • the receiving module is specifically configured to receive a BGP message sent by the ingress node, where the BGP message includes the corresponding relationship.
  • the BGP message is BGP-MVPN signaling or BGP-EVPN signaling.
  • the present application provides a network device.
  • the network device includes a communication interface and a processor.
  • the communication interface is used to execute the method described in any of the foregoing aspects and any possible implementation of any aspect.
  • the processor is configured to perform other operations other than the transceiver operation involved in the method described in any of the above aspects and any possible implementation of any aspect.
  • the processor is configured to obtain tunnel information according to the multicast source group information and the corresponding relationship, and the corresponding relationship includes The multicast source group information and the tunnel information are used to obtain a second message according to the payload and the tunnel information.
  • the second message includes the payload and a second message corresponding to the tunnel information.
  • header, the second message does not include the first message header
  • the communication interface is used to receive the first message sent by the user edge device, the first message includes the first message header and payload, The first message header includes multicast source group information, and a second message is obtained according to the payload and the tunnel information.
  • the second message includes the payload and a second message corresponding to the tunnel information.
  • header, the second message does not include the first message header.
  • the communication interface is used to receive a second message, and the second message includes a payload and a second message corresponding to the tunnel information.
  • the processor is configured to obtain multicast source group information according to the corresponding relationship and the tunnel information corresponding to the second message header, where the corresponding relationship includes the tunnel information and the multicast source group Information, obtain a first message according to the multicast source group information and the payload, the first message includes a first message header and the payload, the first message header includes the multicast source Group information, the first message does not include the second message header.
  • this application provides a communication system used for message transmission, including: a network device provided at an entry node provided by the third aspect, and a network provided at an exit node provided by the fourth aspect.
  • Equipment the network equipment provided at the entry node is used to perform some or all of the operations performed by the first device in the first aspect and any possible implementation of the first aspect; the network equipment provided at the exit node For performing part or all of the operations performed by the second device in the second aspect and any possible implementation of the second aspect.
  • the system further includes a network device provided at the intermediate node, configured to receive the second message forwarded by the network device provided at the entrance node, and forward the second message .
  • the present application provides a computer-readable storage medium that stores instructions that, when run on a processor, implement the method described in any of the foregoing aspects and any of the foregoing aspects. Some or all of the operations included in any possible implementation of the aspect.
  • the application provides a computer program product, which includes instructions that, when run on a processor, implement the method described in any of the foregoing aspects and any possible method of any of the foregoing aspects. Some or all of the operations included in the implementation.
  • this application provides a chip including: an interface circuit and a processor.
  • the interface circuit is connected to the processor, and the processor is configured to cause the chip to perform some or all of the operations included in the method described in any of the foregoing aspects and any possible implementation of any of the foregoing aspects. .
  • Figure 1 is a schematic structural diagram of a backbone network provided by an embodiment of the present application.
  • Figure 2 is a schematic diagram of a network architecture provided by an embodiment of the present application.
  • Figure 3 is a schematic flowchart of a message transmission method provided by an embodiment of the present application.
  • Figure 4 is a schematic structural diagram of an encapsulated and decapsulated message provided by an embodiment of the present application.
  • Figure 5 is a schematic flow chart of another message transmission method provided by an embodiment of the present application.
  • Figure 6 is a schematic structural diagram of another encapsulated and decapsulated message provided by an embodiment of the present application.
  • Figure 7 is a schematic structural diagram of another encapsulation and decapsulation message provided by an embodiment of the present application.
  • Figure 8 is a schematic structural diagram of another encapsulated and decapsulated message provided by an embodiment of the present application.
  • Figure 9 is a configuration method provided by an embodiment of the present application.
  • Figure 10 is a schematic structural diagram of another encapsulated and decapsulated message provided by an embodiment of the present application.
  • Figure 11 is a schematic structural diagram of an entry node provided by an embodiment of the present application.
  • Figure 12 is a schematic structural diagram of an exit node provided by an embodiment of the present application.
  • Figure 13 is a schematic structural diagram of a network device 30 provided by an embodiment of the present application.
  • FIG. 14 is a schematic structural diagram of a network device 40 provided by an embodiment of the present application.
  • a and/or B can mean: A exists alone, A and B exist simultaneously, and they exist alone. B these three situations.
  • first and second in the description and claims of the embodiments of this application are used to distinguish different objects, rather than to describe a specific order of objects.
  • first target object, the second target object, etc. are used to distinguish different target objects, rather than to describe a specific order of the target objects.
  • multiple processing units refer to two or more processing units; multiple systems refer to two or more systems.
  • Multicast technology can effectively save network bandwidth and reduce the network load of data transmission.
  • PIM-SSM is an extension of the traditional PIM protocol and supports receiving multicast service flows from multicast sources.
  • SSM represents the multicast service of a specific source. In SSM, only the multicast packets of the specific source requested by the receiver can be forwarded. To the receiver, the multicast receiver can specify to receive or reject traffic from a specific multicast source when joining the multicast source.
  • Tunneling technology is a way of transmitting data between networks by using the Internet infrastructure, including the entire process of data encapsulation, transmission and decapsulation.
  • the logical path that encapsulated data takes when transmitted over the network is called a tunnel.
  • the GRE protocol encapsulates data packets of network layer protocols (such as IPv4 and IPv6) so that these encapsulated data packets can be transmitted in network layer protocols such as IP.
  • GRE uses tunneling technology. Depending on the transmission protocol, , can be divided into two tunnel modes: GRE over IPv4 and GRE over IPv6.
  • MPLS is a tunnel technology suitable for networks such as the backbone network in this application. It can perform label switching on the backbone network.
  • MPLS can support multiple network protocols, such as IPv4, IPv6, and Internet Packet Exchange (IPX). protocol and connectionless network protocol (ConnectionLess Network Protocol, CLNP), etc.
  • the backbone network is equivalent to the BIER domain.
  • the BIER domain includes routers with three roles: The ingress router that receives multicast packets is the Bit Forwarding Ingress Router (BFIR), the last hop router leaving the BIER domain is the Bit Forwarding Egress Router (BFER), and other intermediate routers are collectively called Bit Forwarding Egress Router (BFER). Bit Forwarding Router (BFR), where, BFIR and BFER belong to edge BFR.
  • BFIR Bit Forwarding Ingress Router
  • BFER Bit Forwarding Egress Router
  • BFR Bit Forwarding Router
  • BFIR is set at the entrance node position
  • BFER is set at the exit node position
  • BFR is set at the intermediate node position.
  • BIER multicast tunnel multicast packet transmission is a kind of stateless multicast forwarding. Since BFR does not have any multicast information, there is no need to maintain the multicast status or establish a multicast forwarding tree. Relying on The bit string in the forwarding table and multicast message is copied and forwarded.
  • BitString The bits in BitString are used to correspond to the identification of BFER. Since each edge BFR of the BIER domain is configured with a BIER Forwarding Router Identifier (BFR-ID), the BFR-ID value range is an integer from 1 to 65535. , therefore, the BitString composed of the BFR-ID of the bit forwarding egress router forms the egress node set, and the position or index of each Bit in the BitString is used to determine the BFER.
  • BFR-ID BIER Forwarding Router Identifier
  • BIERv6 is a new multicast technology.
  • the backbone network encapsulates the set of egress nodes in a message in the form of a bit string and sends it to the intermediate node.
  • the intermediate node does not need To maintain multicast status, there is no need to build a multicast distribution tree. Instead, copying and forwarding are completed based on the bit strings carried in the packets matching the forwarding table.
  • the IPv6 extension header is an optional header.
  • the IPv6 extension header includes the routing header (Routing Header, RH), the destination options header (Destination Options Header, DOH), etc.
  • the embodiments of the present application may be applied to a multicast network, which includes a user network and a backbone network.
  • the user network may be a network running IPv6 or IPv4, and the backbone network may be a network running MVPN or EVPN.
  • the backbone network provided by the embodiments of this application can use different tunnels for packet transmission.
  • a backbone network can support the use of one or more tunnels.
  • multicast packets in the user network enter the backbone. When the packet is connected to the network, it can be encapsulated according to the encapsulation method corresponding to the tunnel used by the backbone network. When the packet leaves the backbone network, it can be decapsulated in the method corresponding to the encapsulation.
  • FIG. 1 is a schematic structural diagram of a backbone network provided by an embodiment of the present application.
  • the backbone network includes a network device 100 disposed at an entry node, abbreviated as the entry node 100, and a network device 200 disposed at an intermediate node.
  • the entry node 100 receives the message sent by the user network and encapsulates the message, and sends it to the intermediate node 200 , after being forwarded or copied and forwarded by the intermediate node 200, it is sent to the egress node 300, and then the egress node 300 decapsulates the message and sends the decapsulated message to the user network.
  • the backbone network uses different tunnel corresponding scenarios, it supports multiple encapsulation methods, such as IP+GRE encapsulation, IP encapsulation, MPLS encapsulation, etc.
  • the backbone network can also support the use of BIER encapsulation (RFC8279, RFC8296, RFC8556) or the use of BIERv6 encapsulation.
  • the entry node 100 can encapsulate the received message using IP+GRE, and the message is encapsulated with an IP header+GRE header; or use IP for encapsulation, and the message is encapsulated with an IP header; or use It is encapsulated in MPLS mode, and the packet is encapsulated with an MPLS header.
  • the overhead of transmitting the message in the backbone network will increase, which will put certain pressure on the network bandwidth.
  • the multicast service in the user network is based on IPv6, and the multicast packet received from the user network is an IPv6 packet.
  • the entrance node 100 After the entrance node 100 receives the IPv6 packet, it will For IP tunnels, determine to use IPv6 encapsulation method to encapsulate the received packets. That is, an IPv6 header is encapsulated on the IPv6 message. Therefore, the multicast message is encapsulated with two IPv6 headers, which will occupy a total of 80 bytes, which is equivalent to adding 40 bytes of transmission overhead after entering the backbone network; for another example, The multicast message received by the entrance node 100 is an IPv6 message.
  • the tunnel adopted by the backbone network it is an IP tunnel and supports the IPv6 + extension header encapsulation method. Therefore, the IPv6 header + extension header needs to be encapsulated on the IPv6 message, where , the extension header can be DOH, and the header length of the encapsulated IPv6 message can reach 128 bytes, which is equivalent to an increase of 84 bytes of transmission overhead.
  • the entrance node will delete the source address and destination address in the received multicast packet.
  • this method will make the multicast packet not conform to the standard format. Problems that are prone to message errors are difficult to locate and affect the deployment and use of the solution.
  • FIG. 2 is a schematic diagram of a network architecture provided by an embodiment of the present application. As shown in Figure 2, the network architecture includes a backbone network and a user network.
  • the backbone network includes an entrance node 1000, intermediate nodes (including intermediate nodes 2001 and Intermediate node 2002), exit node (including exit node 1 marked as 3001 in Figure 2, exit node 2 marked as 3002 in Figure 2, and exit node 3 marked as 3003 in Figure 2), the user network includes Customer Edge (CE) equipment ( Including CE device 1 marked as 4001 in Figure 2, CE device 2 marked as 4002 in Figure 2, and CE device 3 marked as 4003 in Figure 2), the user network may also include a server connected to each CE device.
  • the packet sent by CE1 to the backbone network is a multicast packet encapsulated with an IP header as an example.
  • the entry node 1000 encapsulates the multicast packet sent by CE device 1.
  • the IP header of the multicast message is deleted.
  • the ingress node 1000 forwards the encapsulated message.
  • the encapsulated message is forwarded by the intermediate node 2001 and the intermediate node 2002.
  • it can be decapsulated by the egress node 1 and encapsulate the IP header. , obtain the multicast message, and then send it to the CE device corresponding to the multicast address of the multicast message in the user network, such as sending it to CE device 2.
  • the destination address of the multicast message received by the entrance node 1000 is multicast group address 1, and both CE device 2 and CE device 3 are added to the multicast group address, then the following figure can be used: As shown in 2, egress node 1 sends a multicast message to CE device 2 according to the destination address of the multicast message, and egress node 3 sends a multicast message to CE device 3 according to the destination address of the multicast message.
  • the method provided by the embodiment of the present application can be applied to the scenario provided in Figure 2, but is not limited thereto.
  • Figure 3 is a schematic flowchart of a message transmission method provided by an embodiment of the present application. As shown in Figure 3, the method includes:
  • the entry node receives a first message sent by the user edge device.
  • the first message includes a first message header and a payload, and the first message header includes multicast source group information.
  • the first message is a multicast message including multicast source group information.
  • the multicast source group information includes the source address S and the destination address in the multicast message.
  • the destination address is the multicast group address, denoted as G, multicast
  • the source group information is denoted as (S, G).
  • the entrance node 1000 can be used to receive the multicast message sent by the CE device 1, and this message can be recorded as the first message.
  • the first header in the first message received by the entrance node 1000 may belong to the IPv6 header or the IPv4 header.
  • the first message header belongs to the IPv6 header, that is, the C-IP Header belongs to IPv6.
  • Table 1 shows IPv6. An illustration of each header field.
  • the IPv6 header includes the following parts:
  • Version number (Version, Ver): The version number of IPv6 is 6, and Ver occupies 4 bits;
  • Transmission type (Traffic Class, TC): used to distinguish the types and priorities of different IPv6 messages, TC accounts for 8 bits;
  • a "flow” identifies the packet from the source address to the destination address.
  • the "flow” from source address A to destination address B is the same "flow” and its packets have the same flow label, FL.
  • Payload Length used to identify the length of other parts of the message except the IPv6 header. If the message is encapsulated with an extension header, the length of the PL identifier is the length of the extension header plus the payload. PL occupies 16 bits. (bit).
  • Next Header It can indicate the next header field immediately following this IPv6 header and is used to describe the existence and type of other extension headers after the IPv6 header. NH occupies 8 bits;
  • Hop Limit used to set the upper limit of the number of routers that packets can pass through. It can be initialized to a value. Each router reduces the value by 1 when forwarding packets. When it is reduced to 0, the limit is reached. Discard the message, HL occupies 8 bits;
  • SA Source Address
  • DA Destination Address: carries the address of the user equipment that receives IPv6 messages. DA occupies 128 bits.
  • the first packet header belongs to the IPv4 header, that is, the C-IP Header belongs to IPv4.
  • Table 2 shows the fields of the IPv4 header. As shown in Table 2, the IPv4 header includes the following parts:
  • the IPv4 header includes the following parts:
  • Version number (version, Ver): The version number of IPv4 is 4, set to 0100, Ver accounts for 4 bits;
  • IHL Internet Header Length
  • TOS Type of Service
  • the first 6 bits of this field are the differentiated service field, and the last 2 bits are the congestion notification field or indication bit, used to indicate the quality of service, and TOS occupies 8 bits;
  • Total Length Used to identify the total length of the message, in bytes. Through the total length field and the IHL field, the starting position and length of the data part of the message can be determined, and then the start of the data part can be determined. and the end position, the total length accounts for 16 bits (bit);
  • Identifier is used to identify the group to which the segment belongs. Segment identifiers in the same group are the same, and the identifier occupies 16 bits;
  • Flags Represents fragmentation-related information, and flags occupy 3 bits
  • Fragment Offset is used for reordering and identifying the position of each fragment being fragmented relative to the original data.
  • FO occupies 13 bits;
  • Time to Live is used to identify the maximum survival time. Each time a packet passes through a router, the TTL field is subtracted by 1 until it reaches 0 and is discarded. Usually measured in hops, TTL accounts for 8 bits;
  • Protocol is used to identify the upper layer protocol type encapsulated by the IP layer.
  • the protocol occupies 8 bits;
  • Header Checksum (Header Checksum), this field is a checksum code calculated based on the IP header. It is used for header error checking. The data part is not checked. The header checksum occupies 16 bits;
  • SA Source Address
  • DA Destination Address: carries the address of the user equipment that receives IPv4 messages. DA occupies 128 bits;
  • Optional fields are used to provide some control functions, and the length of optional fields is variable;
  • the header length may not be an integer multiple of 32 bits.
  • the 32 bits are padded by filling in 0 in the padding field.
  • Each field in the IPv4 header may be as shown in Table 2, or there may be no optional fields and padding fields.
  • Table 2 is not used as an example.
  • the entrance node obtains tunnel information according to the multicast source group information and the corresponding relationship.
  • the corresponding relationship includes the multicast source group information and tunnel information.
  • the tunnel information includes information indicating the tunnel through which the message is propagated in the backbone network.
  • the tunnel information is expressed in the second message header in a corresponding form.
  • the entry node establishes a corresponding relationship.
  • the first message header includes multicast source group information (S1, G1), where the source address in the multicast source group information corresponds to the address of CE device 1 or the server connected to CE device 1, denoted as S1, the group address in the multicast source group information is denoted as G1, CE device 2 and CE Device 3 has all joined the multicast group; or, if the entrance node 1000 receives the first message sent by CE device 1, the multicast source group information included in the first message header is (S1, G2), where , the source address in the multicast source group information corresponds to the address of CE device 1 or the server connected to CE device 1, denoted as S1, the group address in the multicast source group information is G2, and CE device 2 has joined the multicast group.
  • S1, G1 multicast source group information
  • the embodiment of the present application is not limited to the CE device shown in Figure 2.
  • the user network may also be equipped with CE devices such as CE device 4 and CE device 5.
  • the multicast source group information in the first message header is the multicast source group information.
  • S1, G3 where S1 indicates that the source address in the multicast source group information is CE device 1 or the address of the server connected to CE device 1, the group address in the multicast source group information is G3, CE device 3 and CE Device 4 has joined the multicast group. From the above example, we can know that the group addresses G1, G2, and G3 in the multicast source group information respectively represent the multicast addresses obtained by different CE devices joining the multicast group.
  • the entrance node obtains a second message according to the payload and tunnel information.
  • the second message includes the payload and the second message header corresponding to the tunnel information.
  • the second message does not include the first message header.
  • the tunnel information determined based on the correspondence relationship corresponds to the second packet header.
  • the tunnel information and the second packet header can correspond to different representation methods.
  • the ingress node can be encapsulated based on IPv6.
  • the obtained second message header includes an IPv6 header, and the IPv6 header includes the source address and destination address corresponding to the tunnel information, where the destination The address is the multicast group address corresponding to the multicast tree.
  • the entry node establishes a corresponding relationship between the multicast source group information (S1, G1) and the tunnel information (S, D) in the IPv6 header, which is recorded as the first corresponding relationship, where the multicast source group information (S1, G1)
  • Tunnel information (S, D) refer to the scene in Figure 2.
  • the source address S in the tunnel information corresponds to the entry node, which can be recorded as S-P1, and the destination address D of the tunnel information. is the multicast group address, which can be recorded as D-P1.
  • Exit node 1, exit node 2 and exit node 3 have all joined the multicast group corresponding to D-P1.
  • the tunnel information can be recorded as (S-P1 , D-P1), or the source address corresponds to the ingress node, recorded as S-P1, and the group address is recorded as D-P2. Both egress node 1 and egress node 2 have joined the multicast group corresponding to D-P2. In this case Under, the tunnel information can be recorded as (S-P1, D-P2).
  • S-P1, D-P2 the tunnel information can be recorded as (S-P1, D-P2).
  • the source address in the tunnel information corresponds to this entry node, which can be recorded as S-P2, and the group address is recorded as D-P2.
  • the tunnel information can be recorded as (S-P2, D-P2).
  • the tunnel information obtained according to the first correspondence is (S-P1, D-P1)
  • the second message includes (S-P1, D-P1) corresponding second message header.
  • the tunnel information obtained according to the first correspondence is (S1, G3)
  • the tunnel information obtained according to the first correspondence is (S-P2, D-P2)
  • the second message includes the same as (S -P2, D-P2) corresponding second message header.
  • Table 3 is an example of a first correspondence relationship adapted to the above scenario, and the specific implementation is not limited to the use of Table 3.
  • the second packet header is the BIERv6 header.
  • the BIERv6 header includes the source address and destination address corresponding to the tunnel information, where the destination address is a unicast address.
  • the BIERv6 header may only include the source address corresponding to the tunnel information, but not the destination address.
  • the entry node establishes a corresponding relationship between the multicast source group information (S, G) and the tunnel information in the BIERv6 header, which is recorded as the second correspondence.
  • the BIERv6 header includes the source address and destination address corresponding to the tunnel information.
  • the next hop of the entry node is an intermediate node
  • the unicast address is sent to the intermediate node in the message, and the intermediate node determines the address according to the group.
  • the address of the next hop of the broadcast tree is changed until the intermediate node sends the unicast address to the exit node, and the unicast address is changed to the address corresponding to the exit node.
  • the tunnel information may change during the transmission of the message.
  • the ingress node obtains the information based on the multicast source group information (S1, G1) and the second corresponding relationship.
  • the tunnel information is (S-P1, D-P1).
  • This tunnel information can be recorded as the first tunnel information.
  • the entrance node obtains the second message based on the first tunnel information (S-P1, D-P1).
  • the second message The header includes the source address S-P1 and the destination address D-P1 corresponding to the first tunnel information, where the destination address D-P1 is the address of the intermediate node corresponding to the next hop of the entry node in the multicast tree.
  • the second message is After the intermediate node of the next hop receives the message, the intermediate node obtains the destination address based on the address of the next hop of the multicast tree.
  • the next hop of the intermediate node is an exit node, it obtains the destination address based on the address of the exit node and obtains a new
  • the tunnel information can be recorded as the second tunnel information.
  • the intermediate node updates the destination address corresponding to the second tunnel information in the second message header according to the second tunnel information to obtain the third message.
  • the intermediate node sends the third message to the egress node. After receiving the third message, the egress node decapsulates the message.
  • the second packet header is a BIERv6 header.
  • the second correspondence established by the entrance node includes the multicast source group information (S1, G1) and the tunnel information source address in the BIERv6 header, that is, the BIERv6 header only includes When the source address corresponding to the tunnel information does not include the destination address, since the BIERv6 header does not include the destination address, there is no need for the intermediate node to change the destination address.
  • the intermediate node only forwards the second message.
  • the second message established on the egress node The corresponding relationship is the same as that of the ingress node, including multicast source group information (S1, G1) and the tunnel information source address in the BIERv6 header, such as S-P1.
  • the egress node after receiving the second message, obtains the multicast source group information (S1, G1) based on the tunnel information source address S-P1 in the BIERv6 header and the second corresponding relationship, and then obtains the multicast source group information (S1, G1) based on the multicast source group information ( S1, G1) encapsulates the first message header and deletes the BIERv6 header to obtain the first message.
  • the third correspondence established by the ingress node includes the correspondence between the multicast source group information (S1, G1) and the MPLS label.
  • the MPLS label includes the first MPLS label value.
  • the second packet header encapsulated by the entry node may be an MPLS header.
  • the MPLS header includes an MPLS label corresponding to the tunnel information.
  • the MPLS label may be represented by the first MPLS label value.
  • the entry node can establish a fourth corresponding relationship based on the multicast source group information (S, G) obtained from the first message and the identification of the MPLS P2MP tree (tunnel).
  • S, G multicast source group information
  • the ingress node also saves all bifurcation information of the MPLS P2MP tree, and the bifurcation information includes one or more bifurcation information of each node on the MPLS P2MP tree (tunnel), where, The nodes on the MPLS P2MP tree (tunnel) correspond to the entry node, intermediate node or exit node in the backbone network. One or more bifurcations of each node correspond to the path between nodes in the backbone network.
  • the entry node can be based on the MPLS P2MP tree.
  • the bifurcation information of the (tunnel) corresponds to assigning the first label value to the identifier of the MPLS P2MP tree (tunnel) to establish the fifth correspondence between the identifier of the MPLS P2MP tree (tunnel) and the first label value.
  • the entry node can According to the fourth corresponding relationship between the multicast source group information (S, G) and the identifier of the MPLS P2MP tree (tunnel), and the fifth corresponding relationship between the identifier of the MPLS P2MP tree (tunnel) and the first MPLS label value, the multicast source is established The third correspondence between the group information (S, G) and the first MPLS label value.
  • the intermediate node will respond according to the next branch of the MPLS P2MP tree (tunnel). fork, update the MPLS label corresponding to the tunnel information in the second message header, and obtain the third message. Assume that the next fork of the intermediate node in the MPLS P2MP tree (tunnel) corresponds to the egress node, then the intermediate node forwards to the egress node The third message is sent, and the egress node decapsulates the third message after receiving it.
  • the egress node may establish a fourth corresponding relationship based on the advertisement of the ingress node.
  • the egress node may also establish a sixth corresponding relationship between the identifier of the MPLS P2MP tree (tunnel) and the second MPLS label value, where the second MPLS label value may be egress point is the label value assigned to the identifier of the MPLS P2MP tree (tunnel).
  • the egress node can establish the multicast source group information (S, G) and the second MPLS label value based on the fourth correspondence relationship and the sixth correspondence relationship.
  • the seventh correspondence is the multicast source group information (S, G) and the second MPLS label value based on the fourth correspondence relationship and the sixth correspondence relationship.
  • the entry node and the egress node respectively establish a third corresponding relationship based on the identity of the MPLS P2MP tree (tunnel), and the seventh correspondence relationship, the same multicast source group information (S, G) can be determined correspondingly.
  • the second MPLS label value corresponding to the multicast source group information in the seventh correspondence relationship on different egress nodes can be different, as long as the second MPLS label value can be received after receiving the first After three messages, the multicast source group information (S1, G1) can be determined by establishing the seventh corresponding relationship on the egress node and the second MPLS label value in the third message header.
  • the second packet header includes the upstream MPLS label, and the tunnel information corresponds to the second packet header through the upstream MPLS label.
  • the second packet encapsulated by the ingress node The header can be a BIER header + an upstream MPLS label.
  • the ingress node is the upstream node
  • the upstream MPLS label is the MPLS label of the ingress node.
  • the ingress node can establish the eighth correspondence between the multicast source group information (S, G) and the upstream MPLS label, such as , the entry node establishes the eighth correspondence between the multicast source group information (S1, G1) and the upstream MPLS label, and determines the upstream MPLS label according to the multicast source group information (S1, G1) in the first message and the eighth correspondence. , fill in the corresponding label value in the upstream MPLS label that encapsulates the second message; the eighth correspondence established on the egress node includes the correspondence between the multicast source group information (S, G) and the upstream MPLS label.
  • the egress node is based on The upstream MPLS label encapsulated in the second packet determines the multicast source group information (S, G), and the eighth correspondence relationship established on the egress node may be established based on parameters advertised by the ingress node.
  • S, G multicast source group information
  • the second message obtained by the entry node can be encapsulated according to the encapsulation format supported by the tunnel.
  • the following describes in detail how the entry node obtains the second message by giving examples of different encapsulation formats.
  • the backbone network can use PIM-SSM signaling to establish a network capable of running MVPN.
  • packets whose encapsulation format refers to RFC6513 12.1.1 can be transmitted, such as packets encapsulated with IPv4 headers. , packets encapsulated with IPv6 header, packets encapsulated with IPv6 header + GRE header, etc.
  • the entrance node encapsulates the received message.
  • the encapsulated part of the entrance node is mainly used to transmit the message in the tunnel of the backbone network, so the message reaches the egress When the node is connected, the encapsulated part is deleted.
  • FIG 4 is a schematic structural diagram of an encapsulation and decapsulation message provided by an embodiment of the present application.
  • the multicast message received by the entry node is as shown in Figure 4
  • the multicast message is the first message, including the first message header and payload.
  • the first message header is used to encapsulate and transmit the message in the user network, so it can be recorded As the C-IP header (Header), in the same way, the payload can also be recorded as C-Payload.
  • the entry node deletes the C-IP Header of the first message and encapsulates the second message header.
  • the second message header includes P- IP Header+GRE header, where the second message header is suitable for transmission in the backbone network, and the P-IP Header belongs to the IPv6 header.
  • the second message obtained by the entry node includes P-IP Header, GRE header and C-Payload, and the second message does not include the C-IP Header.
  • the egress node changes the P- Deleting the IP Header and GRE header and encapsulating the C-IP Header is equivalent to the egress node restoring the second message to the first message including the C-IP Header and C-Payload, excluding the P-IP Header and GRE header.
  • the entry node deletes the first message header (C-IP Header).
  • the entry node deletes the C-IP Header
  • the C-IP Header needs to be encapsulated at the exit node. Therefore, after the entry node deletes the C-IP Header, the encapsulated second message
  • the header should at least include the source address and destination address corresponding to the tunnel information.
  • the destination address can be a multicast address, so that the egress node can obtain the C-IP Header based on the first corresponding relationship established between the tunnel information and the egress node. Multicast source group information, encapsulating C-IP Header.
  • the second message header includes the P-IP Header+GRE belonging to the IPv6 header.
  • the Header is applicable to the scenario where an IP multicast tunnel is used between the ingress node and the egress node.
  • the first corresponding relationship established between the ingress node and the egress node can refer to the above example, and refer to Table 3.
  • the ingress node sets the The tunnel information obtained from the information (S1, G2) and the first correspondence is (S-P1, D-P2).
  • the source address corresponding to the second packet header and the tunnel information is S-P1 and the destination address is D-P2.
  • the egress node after the egress node receives the second message, it can obtain the first message header based on the source address corresponding to the second message header and the tunnel information, which is S-P1, the destination address is D-P2, and the first correspondence.
  • Corresponding multicast source group information (S1, G2).
  • the first corresponding relationship can be a static configuration of the ingress node and the egress node, or it can be announced by the ingress node to the egress node.
  • the ingress node can notify the egress node by sending a BGP message to the egress node.
  • BGP The message includes a first correspondence relationship, where the BGP message may be BGP-MVPN signaling or BGP-EVPN signaling.
  • the backbone network is a network running MVPN as an example, and the BGP message is BGP-MVPN signaling. In practical applications, the implementation is not limited to using BGP-MVPN.
  • the first header of the first message includes the C-IP Header, and the C-IP Header belongs to the IPv6 header.
  • the second header of the second message includes the P-IP Header+GRE header, and the P-IP Header belongs to IPv6 header is explained.
  • the entry node deletes the C-IP Header of the first message as shown in Figure 4(a).
  • the entry node encapsulates the second message header.
  • the second message header includes the P-IP Header and GRE header.
  • the second message obtained after encapsulation is shown in Figure 4(b), including P-IP Header, GRE header and C-Payload.
  • the entry node encapsulates the second message header, that is, the P-IP Header and the GRE header
  • a possible example of filling in the content in each field is as follows:
  • IPv6 The version number of IPv6 is 6.
  • TC of P-IP Header Copy the TC field in the C-IP Header to the TC field of the P-IP Header, or set the TC value according to the local configuration policy. If the TC value in the local configuration policy is equal to 1, set it to 1. .
  • FL of P-IP Header Copy the FL field in the C-IP Header to the FL field of the P-IP Header, or set the FL value according to the local configuration policy.
  • PL of P-IP Header It can be obtained based on the PL field value in C-IP Header plus the length of the GRE header.
  • NH of P-IP Header indicates the next header field that follows, that is, indicates the GRE header.
  • HL of P-IP Header Copy the HL field in the C-IP Header to the HL field of the P-IP Header, or set the HL value according to the local configuration policy.
  • SA and DA of P-IP Header Set the SA field and DA field through the SA field and DA field in the C-IP Header and the corresponding relationship. For example, you can obtain multicast through the SA field and DA field in the C-IP Header.
  • Source group information S1, G2
  • the tunnel information is (S-P1, D-P2).
  • Protocol of the GRE header Convert the Protocol value of the GRE header according to the NH value in the C-IP Header.
  • the NH in the C-IP Header is 4, indicating that the C-Payload is a message with an IPv4 header.
  • the Protocol value can be set to 0x0800 according to the format.
  • the local configuration policy can be that the ingress node configures preset values for different fields. For example, the preset value of the TC field configured in the local configuration policy is equal to 1.
  • the ingress node may notify the egress node of indication information, and the indication information is used to instruct the restoration of the multicast source group information.
  • the indication information may instruct the egress node to restore the multicast source group information according to the first correspondence relationship and the second message header obtained by the egress node. tunnel information, obtain the multicast source group information, and fill in the contents of the SA field and DA field of the C-IP Header when encapsulating the first message header based on the multicast source group information, which is equivalent to restoring the deletion of the entry node.
  • the first message header of multicast source group information may also notify the egress node of deletion and restoration instruction information.
  • the deletion and restoration instruction information may further instruct the egress node to delete the second message header and obtain the first message according to the fields of the second message header or the local configuration policy. Contents that need to be set for each field in the header, such as instructing the egress node to obtain the value of the NH field in the first header based on the Protocol field of the GRE header, etc.
  • the egress node can save the indication information, and after receiving the second message, obtain the first message according to the indication information and the second message.
  • a relationship can be established between the entry node and the exit node. After the relationship is established, the entry node can notify the exit node to use the same encapsulation method as the entry node to decapsulate the second message. It can also notify the exit node that the entry node.
  • the encapsulation method corresponding to the first message header of the received first message is such that the egress node encapsulates the first message according to the encapsulation method corresponding to the first message header.
  • This encapsulation method can be defined as compact. ) encapsulation method, or the encapsulation method called delete-restore.
  • the entrance node sends the second message through the tunnel corresponding to the tunnel information.
  • the entrance node can send the second message through the tunnel corresponding to the tunnel information (S-P1, D-P2). If the destination address D-P2 of the IPv6 header in the second message header is the multicast group address corresponding to the multicast tree, Returning to the scenario shown in Figure 2, both egress node 1 and egress node 2 have joined the multicast group corresponding to D-P2, which is equivalent to when egress node 1 and egress node 2 receive the second message. The header is deleted and the first header is encapsulated to obtain the first message.
  • the destination address of the tunnel information can also be the next hop address of the entry node in the multicast tree.
  • the destination address is the unicast address of the next hop node
  • the ingress node sends the second message through the tunnel corresponding to the tunnel information. When it reaches the corresponding egress node, the corresponding egress node may receive the third message.
  • the corresponding egress node may receive the second message according to the tunnel information in the third message. Obtain the multicast source group information and encapsulate the first message header; in the second message sent by the ingress node through the tunnel corresponding to the tunnel information, if the second message header corresponds to the tunnel information source address does not include the destination address, the egress node What is received is the second message. The egress node obtains the multicast source group information based on the second correspondence and the tunnel information source address, and encapsulates the first message header.
  • both P-IP Header and C-IP Header headers belong to IPv6 headers.
  • the entry node deletes the C-IP Header header in Figure 4(a) and encapsulates the P-IP header as shown in Figure 4(b). Header and GRE header, the effect is equivalent to "replacing" the C-IP Header with the P-IP Header and GRE header, instead of adding the encapsulated P-IP Header and GRE header when the message enters the backbone network, which can reduce The overhead of packet transmission in the backbone network.
  • FIG. 5 is a schematic flowchart of another message transmission method provided by an embodiment of the present application. As shown in Figure 5, the method includes:
  • the egress node receives a second message, where the second message includes a payload and a second message header corresponding to the tunnel information.
  • the exit node receives the second message as shown in Figure 4(b).
  • the second message includes C-Payload, P-IP Header and GRE header, but does not include C-IP Header.
  • the exit node deletes the P-IP Header and GRE header of the second message and encapsulates the C-IP Header to obtain the first message including C-IP Header and C-Payload, which is quite The first message is restored at the egress node.
  • the encapsulation method provided by the embodiments of this application can send messages that comply with the standard format to the CE device.
  • the egress node obtains multicast source group information based on the tunnel information and corresponding relationship corresponding to the second packet header.
  • the corresponding relationship includes tunnel information and multicast source group information.
  • the corresponding relationship may be a first corresponding relationship, including tunnel information and multicast source group information, and the egress node Based on the tunnel information corresponding to the packet header and the first correspondence, the multicast source group information can be obtained.
  • the exit node 3 receives the second message, the tunnel information (S-P1, D-P2) obtained according to the second message header, where the destination address included in the second message header is the multicast group address corresponding to the multicast tree, where the multicast tree It includes an ingress node 1000, an egress node 1 and an egress node 3.
  • the egress node 3 can obtain the multicast source group information (S1, G2) based on the tunnel information (S-P1, D-P2) and the first corresponding relationship.
  • the intermediate node since the entrance node to the intermediate node 2001, the intermediate node 2002, the exit node 1 and the exit node 3, since the entrance node to the intermediate node 2001, the intermediate node 2001 to the intermediate node 2002, the intermediate node
  • the packets sent from node 2002 to egress node 1 and from intermediate node 2002 to egress node 3 all belong to IPv6 headers, and the destination addresses in the IPv6 headers are all unicast addresses.
  • the second purpose of the packets sent from entry node 1000 to intermediate node 2001 is The address belongs to intermediate node 2001.
  • intermediate node 2001 sends the third message to intermediate node 2002, the destination address of the third message is changed to that of intermediate node 2002.
  • the destination address of the fourth message sent by the intermediate node to exit node 1 is changed to exit node 1.
  • the intermediate node 2002 sends the fifth message to the egress node 3
  • the destination address of the fifth message is changed to that of the egress node 3.
  • the fourth and fifth messages received are both "BIERv6 tunnel" messages, and the group is determined based on the source address and the second correspondence in the tunnel information of the message.
  • the first message can be obtained by using the multicast source group information.
  • the egress The node can obtain the group source group information (S, G) based on the source address of the tunnel information and the second corresponding relationship, and can encapsulate the first message header accordingly to obtain the first message.
  • first correspondence relationship and the second correspondence relationship can be static configurations of the egress node, or they can be saved after obtaining the first correspondence relationship or the second correspondence relationship advertised by the entry node.
  • the egress node can receive the information sent by the entry node.
  • BGP message the BGP message includes the first corresponding relationship or the BGP message includes the second corresponding relationship.
  • the BGP message is BGP-MVPN signaling or BGP-EVPN signaling.
  • the egress node receives the indication information advertised by the ingress node, and the indication information is used to instruct to restore the multicast source group information.
  • the egress node can restore the multicast source group information according to the instruction information, and set the first message header (C-IP Header in the following example) based on the source address in the multicast source group information.
  • SA field set the DA field of the first packet header (C-IP Header in the following example) based on the multicast group address in the multicast source group information.
  • the egress node obtains the first message according to the multicast source group information and payload.
  • the first message includes the first message header and payload.
  • the first message header includes the multicast source group information.
  • the first message does not include the first message. Two message headers.
  • the second header of the second message received by the egress node includes the IPv6 header and the GRE header. Delete them as shown in Figure 4(b).
  • the P-IP Header and GRE header are encapsulated into the C-IP Header to obtain the first message as shown in Figure 4(c).
  • the first message includes C-IP Header and C-Payload.
  • the exit node When encapsulating the first message header, that is, the C-IP Header, an example of encapsulating each field of the C-IP Header is as follows:
  • IPv6 The version number of IPv6 is 6.
  • TC of C-IP Header Copy the TC field in the P-IP Header to the TC field of the C-IP Header, or set the TC value according to the local configuration policy. If the ingress node sets the TC value in the P-IP Header according to the local configuration policy, The TC field is set to 1, and the egress node can copy 1. There is no need to restore the TC field content when the first packet entered the backbone network;
  • FL of C-IP Header Copy the FL field in the P-IP Header to the FL field of the C-IP Header, or set the FL value according to the local configuration policy.
  • PL of C-IP Header It can be obtained by subtracting the length of the GRE header from the PL field value in the P-IP Header.
  • NH of C-IP Header indicates the next header field, which needs to be converted according to the Protocol field in the GRE header. For example, the Protocol value of the GRE header is 0x0800, indicating that the C-Payload carries IPv4. Then NH is 4.
  • HL of C-IP Header Copy the HL field in the P-IP Header to the HL field of the C-IP Header, or set the HL value according to the local configuration policy.
  • SA and DA of C-IP Header Set the SA field and DA field through the SA field and DA field in the P-IP Header and the corresponding relationship. For example, you can obtain the tunnel information through the SA field and DA field in the P-IP Header ( S-P1, D-P2), find the first corresponding relationship to obtain the multicast source group information (S1, G2), fill in the SA field of the C-IP Header with S1, and fill in the DA field of the C-IP Header with G2.
  • the settings of each field when encapsulating the first packet header may be statically configured by the egress node, and the local configuration policy for setting the fields may also be preset in advance.
  • the egress node fills in the corresponding field of the multicast source group information in the first message header during encapsulation according to the instruction information sent by the ingress node, or the egress node fills in the corresponding field of the multicast source group information in the first message header according to the deletion and restoration instruction information sent by the ingress node. Indicates how the fields in the first packet header are set according to the fields in the second packet header or the local configuration policy.
  • the local configuration policy for setting fields is preset in advance, and the egress node receives the instruction information and can set the corresponding fields according to the correspondence indicated by the instruction information and other configured information. Further, after receiving the indication information, the egress node can save it first, and when receiving the second message, obtain the first message according to the instruction of the indication information. For example, if the egress node receives indication information through BGP-MVPN signaling, the indication information may be the first corresponding relationship or the second corresponding relationship. The egress node can also restore the second message to the first message through preset configuration.
  • the embodiments of this application are only illustrative and not limiting.
  • the egress node provided by the embodiment of this application can obtain the first message based on the received second message, and then send the first message to the CE device, which can ensure that the message sent to the user network is consistent with the message received by the backbone network entry node.
  • the message format is consistent. In this way, the format of the message received by the user network is standardized and does not affect the message analyzer on the network link to parse the message, thereby ensuring the maintainability of the message transmission solution (such as facilitating Locating packet errors) will not affect the deployment and application of the packet transmission solution.
  • the backbone network uses the tunnel type established by PIM-SSM signaling as the MVPN tunnel bearer.
  • the packet encapsulation format can refer to the encapsulation format of RFC6513 12.1.1.
  • Figure 6 is provided by the embodiment of this application. Another schematic diagram of the encapsulation and decapsulation message structure is shown in Figure 6.
  • the message received by the entry node is in the format shown in Figure 6(a).
  • the first message includes the first message header (C-IP Header) and C-Payload, C-IP Header belongs to the IPv6 header.
  • the entry node deletes the C-IP Header of the received first message and encapsulates the second message header, as shown in Figure 6(b).
  • the second message includes C-Payload, P-IP Header and GRE header, and , the second message does not include the C-IP Header.
  • P-IP Header belongs to IPv4 header.
  • the egress node deletes the P-IP Header and GRE header of the second message, encapsulates the C-IP Header, and obtains the first message as shown in Figure 6(c).
  • the first message Including C-IP Header and C-Payload.
  • the following description takes the first packet header (C-IP Header) as an IPv6 header, the second packet header as a P-IP Header and a GRE header, and the P-IP Header as an IPv4 header.
  • the entry node receives the Delete C-IP after one message Header, the entrance node determines that the second message header includes an IPv4 header and a GRE header, where the IPv4 header includes the source address and destination address corresponding to the tunnel information.
  • the source address and destination address corresponding to the tunnel information can be based on the C-IP Header.
  • the multicast source group information and the first corresponding relationship are determined.
  • the first corresponding relationship can refer to the above embodiment and will not be repeated here.
  • the entrance node encapsulates the IPv4 header and the GRE header to obtain the second message, as shown in Figure 5(b)
  • the second message includes C-Payload, P-IP Header and GRE header.
  • the first message header is recorded as C-IP Header
  • the IPv4 header of the second message header is recorded as P-IP Header
  • an example of each field when encapsulating P-IP Header and GRE header is as follows:
  • IPv4 version number is 4;
  • IHL of P-IP Header can be set to 5 according to the requirements of IPv4 header
  • TOS of P-IP Header Copy the TC field (8bit) in the C-IP Header to the TOS field (8bit) of the P-IP Header, or set the TOS value according to the local configuration policy;
  • Total Length of P-IP Header It can be obtained according to the Payload Length field value in C-IP Header, plus the length of the GRE header and the length of the IPv4 header;
  • P-IP Header's Identifier Set according to the requirements of the IPv4 header, and set to 0 considering non-fragmentation;
  • Flags of P-IP Header Set according to the requirements of the IPv4 header, and set to 010 (binary) considering the situation of non-fragmentation;
  • P-IP Header's FO Set according to the requirements of the IPv4 header, and set to 0 considering the case of no fragmentation;
  • TTL of P-IP Header Copy the HL field (8bit) in C-IP to the TTL field (8bit) of P-IP, or set the TTL value according to the local configuration policy;
  • Protocol of P-IP Header Set according to the Next Header value in C-IP.
  • the Next Header in C-IP Header is 17, indicating that the C-Payload is a payload with a UDP header, and the P-IP header is Protocol value is set to 17;
  • SA and DA of P-IP Header Set the SA field and DA field through the SA field and DA field in the C-IP Header and the corresponding relationship. You can refer to the above example.
  • GRE header Protocol Convert the GRE header Protocol value based on the NH value in C-IP.
  • the settings of each field can be configured statically, and the local configuration policy can also be preset in advance.
  • the values exemplified here are examples.
  • the specific field settings can be adjusted according to the needs of the actual usage scenario, except Values other than the version number are not limited to this.
  • the P-IP Header belongs to the IPv4 header and the C-IP Header belongs to the IPv6 header. Therefore, the entry node deletes the C-IP Header and then encapsulates the P-IP Header and GRE header, as shown in Figure 6(b), which is equivalent to The C-IP Header is "replaced" with the P-IP Header.
  • the egress node deletes the P-IP Header and GRE header to restore the C-IP Header.
  • the egress node can pass the aforementioned MVPN
  • the signaling transfers the corresponding relationship and indication information.
  • the indication information is used to instruct the restoration of the multicast source group information.
  • Encapsulation and decapsulation in the backbone network are completed by the ingress node and egress node, thereby reducing the time required for message transmission in the backbone network. overhead.
  • the first correspondence relationship can be a static configuration of the egress node, or it can be pre-stored after obtaining the first correspondence relationship advertised by the ingress node.
  • the multicast source group information is obtained through the first correspondence relationship and the tunnel information, and the third correspondence relationship is set.
  • the method of a message header can be configured by the egress node or saved after receiving the indication information.
  • the first packet header is recorded as C-IP Header, and the egress node deletes the P-IP Header and GRE header.
  • An example of each field when encapsulating the C-IP Header is as follows:
  • IPv6 version number is 6;
  • TC of C-IP Header Copy the TOS field in the P-IP Header to the TC field of the C-IP Header, or set the TC value according to the local configuration policy;
  • C-IP Header's FL Set the FL value according to the local configuration policy
  • PL of C-IP Header It can be obtained by subtracting the length of the GRE header from the PL field value in the P-IP Header and then subtracting the length of the IPv4 header;
  • NH of C-IP Header Copy the Protocol field (8bit) in the P-IP Header to the Next Header field (8bit) of the C-IP Header;
  • HL of C-IP Header Copy the TTL field in the P-IP Header to the HL field of the C-IP Header, or set the HL value according to the local configuration policy;
  • SA and DA of C-IP Header Set the SA field and DA field through the SA field and DA field in the P-IP Header and the corresponding relationship. The method is as shown in the above example and will not be repeated here.
  • each field when encapsulating the first message header can be statically configured by the egress node, and the local configuration policy used to set the fields can also be preset in advance.
  • each field may also be determined by the egress node based on the instruction information sent by the ingress node or the instruction to delete and restore the instruction information.
  • the IPv4 header includes the source address and destination address corresponding to the tunnel information.
  • the DA field listed in the above example, which is the multicast group address corresponding to the multicast tree, the DA field can also be the entry node next to the multicast tree. Jump address.
  • the first packet header (C-IP Header) belongs to the IPv6 header
  • the P-IP Header in the second packet header belongs to the IPv6 header and IPv4 header respectively.
  • the first packet header (C-IP Header) belongs to If the IPv4 header and the P-IP Header in the second header belong to the IPv6 header or the IPv4 header, you can refer to the above example and by analogy to obtain the values of each field in the second header and the fields when restoring the first header. The value of will not be described in detail.
  • the embodiments of this application provide all examples, taking the first packet header (C-IP Header) as an example of an IPv6 header.
  • the first packet header (C-IP Header) belongs to the IPv6 header.
  • IP Header belongs to the IPv4 header
  • IP Header belongs to the IPv4 header
  • C-IP Header belongs to the IPv4 header
  • the encapsulation of backbone network packets can refer to the encapsulation method of RFC6513 12.1.3.
  • the first packet header (C-IP Header) belongs to the IPv6 header
  • the second packet header is the MPLS header.
  • the MPLS header may include three layers of labels.
  • the embodiment of this application takes the MPLS header including one layer of labels as an example for explanation.
  • the C-Payload may include one layer of IPv4 header or IPv6 header.
  • Figure 7 is a schematic structural diagram of another encapsulation and decapsulation message provided by the embodiment of the present application.
  • the C-Payload includes the IPv6 header.
  • the entry node receives the first message as shown in Figure 7(a), deletes the C-IP Header of the first message, and then performs MPLS encapsulation, that is, encapsulates the second message. header (P-MPLS header), and obtain the second message as shown in Figure 7(b).
  • the second message includes the P-MPLS header and C-Payload.
  • the egress node deletes the P- MPLS header, encapsulate the C-IP Header to obtain the first message as shown in Figure 7(c).
  • the entry node performs MPLS encapsulation.
  • This embodiment of the present application performs MPLS encapsulation.
  • Table 4 shows the fields included in the MPLS header.
  • the MPLS header includes the following parts:
  • Label value Label used to set the label number, Label occupies 20 bits;
  • the bottom bit S of the stack is used to indicate whether the current label is at the bottom of the stack.
  • MPLS can encapsulate labels up to three times in the data packet, and S occupies 1 bit;
  • Time to live TTL The TTL field or Hop Limit field value in the C-IP Header is copied to the TTL field in the label stack. TTL occupies 8 bits.
  • the second header corresponding to the tunnel information is an MPLS header.
  • the MPLS header can refer to the format of Table 4.
  • the MPLS header includes the MPLS label corresponding to the multicast tree or the MPLS header includes the next hop node of the entry node in the multicast tree.
  • MPLS label indicates the next hop node or multicast tree of the entry node in the multicast tree through the label value. Since the tunnel is established based on the protocol through hop-by-hop nodes, back to the scenario in Figure 2, assume that the tunnel is the entrance node 1000, its next-hop intermediate node 2001, the next-hop node 2002 of the intermediate node 2001, and the intermediate node The next hop egress node 1 of 2002 was established and supported the establishment of the RFC6513 protocol.
  • the backbone network used the same control plane tunnel identifier, but each node would assign a different data plane identifier based on the tunnel identifier.
  • the control plane is used to control and manage the operation of all network protocols, and the data plane is used for data processing and data forwarding. Therefore, the MPLS labels of each hop in the backbone network are different.
  • the entry node establishes the third corresponding relationship with reference to the method in the above embodiment.
  • the entry node 1000 can allocate the label 10001 to the next hop node, that is, the intermediate node 2001; , the entry node can allocate labels of 10001 to all nodes in the multicast tree corresponding to (S1, G1) in the MPLS label distribution tree for the multicast source group information (S1, G1).
  • the multicast source group information obtained by the entry node can be obtained from the C-IP Header to be deleted or from the IPv6 header contained in the C-Payload.
  • the group information obtained by the entry node The source group information obtains the multicast source group information from the C-IP Header.
  • the first packet header is recorded as C-IP Header
  • the second packet header (MPLS header) is recorded as P-MPLS header.
  • MPLS header is recorded as P-MPLS header.
  • the corresponding MPLS label is obtained and the MPLS label field is set, such as setting 10001;
  • Exp of the P-MPLS header Set a value according to the requirements of the P-MPLS header to represent the quality of service
  • S in the P-MPLS header includes a layer of labels based on the P-MPLS header, set to 1;
  • TTL of P-MPLS header Copy the HL field (8 bits) in C-IP to the TTL field (8 bits) of P-IP, or set the TTL value according to the local configuration policy.
  • the settings of each field can be configured statically, and the local configuration policy can also be preset in advance.
  • the setting values exemplified here are examples.
  • the specific field setting values can be adjusted according to the needs of the actual usage scenario.
  • the numerical value required in the above example is limited.
  • the C-IP Header belongs to the IPv6 header, so the entry node deletes the C-IP Header and then encapsulates P-MPLS.
  • the effect of the header is equivalent to "replacing" the C-IP Header with the MPLS header.
  • the egress node then replaces the P-IP header as shown in Figure 7(b).
  • the MPLS header is deleted, and the C-IP Header shown in Figure 7(c) is encapsulated to obtain the first message.
  • the egress node can receive the instruction information transmitted by the ingress node through BGP-MVPN signaling or BGP-EVPN to obtain the fourth correspondence relationship and restore the multicast source group information.
  • the egress node After the egress node obtains the fourth correspondence relationship advertised by the ingress node, it can obtain the fourth correspondence relationship according to the egress node
  • the established sixth corresponding relationship and the received fourth corresponding relationship are obtained and saved.
  • the entry node establishing the third corresponding relationship and the exit node establishing the seventh corresponding relationship can refer to the above example, which will not be described again here.
  • the egress node can also pre-store the indication information, store it after receiving the indication information, and when receiving the second message, obtain the first message header according to the restored multicast source group information indicated by the indication information and the seventh corresponding relationship. Encapsulation and decapsulation in the backbone network are completed by the ingress node and egress node, thereby reducing the overhead of packet transmission in the backbone network.
  • the second packet header is recorded as the P-MPLS header
  • the first message header is recorded as the C-IP Header.
  • An example of the setting of each field when encapsulating the C-IP Header is as follows:
  • IPv6 version number is 6;
  • C-IP Header's TC Set the TC value according to the local configuration policy
  • C-IP Header's FL Set the FL value according to the local configuration policy
  • C-IP Header's PL It can be set according to the IPv4 or IPv6 header in C-Payload.
  • the encapsulation header included in C-Payload belongs to the IPv6 header, and it can be set through the Payload Length field of the IPv6 header in C-Payload. Add the IPv6 header length 40 to get the Payload Length field as the C-IP header.
  • the encapsulation header included in the C-Payload belongs to the IPv4 header, you can add the Payload Length field of the IPv4 header in the C-Payload.
  • the IPv4 header length is obtained as the Payload Length field of the C-IP header;
  • C-IP Header's NH needs to be set according to the IPv4 header or IPv6 header in C-Payload. For example, the encapsulation header included in C-Payload belongs to the IPv6 header, then the Next Header field is set to 41. Similarly, if the encapsulation header included in C-Payload If the included encapsulation header belongs to the IPv4 header, the Next Header field is set to 4;
  • C-IP Header's HL Set the HL value according to the local configuration policy
  • SA and DA of C-IP Header Set the SA field and DA field through the MPLS label value and the seventh corresponding relationship.
  • the multicast source group information S1, G2 can be obtained from the third corresponding relationship through the MPLS label value of 10001. ), set the SA field and DA field accordingly.
  • FIG 8 is a schematic structural diagram of another encapsulation and decapsulation message provided by the embodiment of the present application.
  • the encapsulation format of the backbone network message can refer to the encapsulation method of draft-xie-bier-ipv6-encapsulation-09.
  • the message received by the entry node is as shown in Figure 8(a).
  • the first message includes C-IP Header and C-Payload.
  • the entry node deletes the C- of the first message received.
  • IP Header encapsulates P-IP Header and extension header to obtain the second message header, as shown in Figure 8(b).
  • the second message includes P-IP Header, extension header and C-Payload, and, the second message The message does not include the C-IP Header.
  • the egress node deletes the P-IP Header and extension header of the second message and encapsulates the C-IP Header to obtain the first message, as shown in Figure 8 ( As shown in c), the first message includes C-IP Header and C-Payload.
  • the entry node encapsulates P-IP Header and extension header.
  • the currently defined and used IPv6 extension headers include Hop-by-hop Options Header, DOH, Routing Header, and Fragment Header. ), authentication header (Authentication Header) and Encapsulated Security Payload Header (ESP).
  • the extension header is DOH as an example for explanation.
  • DOH carries optional information specific to the destination address of the data packet.
  • DOH carries the optional information of the destination address through the BIER option of stateless forwarding or BitString.
  • These 3 destination node sets can be represented by setting a 256-bit or 32-byte BitString. Each bit in the BitString is used to identify a BFER, such as the exit node in Figure 2.
  • the target address can be set in the DA field of the IPv6 header.
  • the BFER identified by different bits in the BitString can also be used to indicate that the packet is to leave the backbone network and be sent to The CE device is the corresponding egress node.
  • the extension header is DOH
  • DOH contains the BIER option or BitString for stateless forwarding as an example.
  • the first header is recorded as C-IP Header
  • the second header includes P-IP Header and DOH.
  • An example of setting each field when encapsulating P-IP Header and DOH is as follows :
  • IPv6 The version number of IPv6 is 6;
  • TC of P-IP Header Copy the TC field in the C-IP Header to the TC field of the P-IP Header, or set the TC value according to the local configuration policy. If the TC value in the local configuration policy is equal to 1, set it to 1. ;
  • FL of P-IP Header Copy the FL field in the C-IP Header to the FL field of the P-IP Header, or set the FL value according to the local configuration policy;
  • P-IP Header's PL The setting of the Payload Length field can be obtained based on the Payload Length field value in the C-IP Header plus the length of the DOH;
  • NH of P-IP Header indicates the next header field that follows, in this case, indicates DOH;
  • HL of P-IP Header Copy the HL field in the C-IP Header to the HL field of the P-IP Header, or set the HL value according to the local configuration policy;
  • SA and DA of P-IP Header Set the SA field and DA field through the SA field and DA field in the C-IP Header and the corresponding relationship. For example, you can obtain multicast through the SA field and DA field in the C-IP Header.
  • Source group information S1, G2
  • the tunnel information is (S-P1, D-P2), fill in the SA field with S-P1, and fill in the DA field with D-P2;
  • DOH Contains BIER options or BitString for stateless forwarding.
  • the above field settings are based on DOH as an example.
  • extension headers included in the P-IP Header belonging to the IPv6 header if it is necessary to set the Next Header field, copy the Next Header field in the C-IP Header. into it.
  • settings of each field in other types of extension headers included in the P-IP Header belonging to the IPv6 header refer to draft-xie-bier-ipv6-encapsulation, which will not be described in detail here.
  • the second message header obtained by the egress node includes an IPv6 header and an IPv6 extension header.
  • the IPv6 header includes a source address and a destination address corresponding to the tunnel information, where the destination address is the next hop of the ingress node in the multicast tree.
  • the address or destination address is the multicast group address corresponding to the multicast tree.
  • the second header of the second message received by the egress node includes P-IP Header and DOH. Delete the P-IP Header and DOH as shown in Figure 8(b), and encapsulate the C-IP Header to obtain Figure 8
  • the first message header is recorded as C-IP Header
  • the P-IP Header included in the second message header belongs to the IPv6 header, encapsulating C-IP
  • An example of setting each field of the Header is as follows:
  • IPv6 version number is 6;
  • TC of C-IP Header Copy the TC field in the P-IP Header to the TC field of the C-IP Header, or set the TC value according to the local configuration policy. If the ingress node sets the TC value in the P-IP Header according to the local configuration policy, Set the TC field to 1 and copy 1 to the egress node. There is no need to restore the TC field content when the first packet entered the backbone network;
  • FL of C-IP Header Copy the FL field in the P-IP Header to the FL field of the C-IP Header, or set the FL value according to the local configuration policy;
  • PL of C-IP Header It can be obtained by subtracting the length of DOH from the PL field value in P-IP Header;
  • NH of C-IP Header indicates the next header field that follows. If the encapsulation header contained in C-Payload belongs to the IPv6 header, NH is 41;
  • HL of C-IP Header Copy the HL field in the P-IP Header to the HL field of the C-IP Header, or set the HL value according to the local configuration policy;
  • SA and DA of C-IP Header Set the SA field and DA field through the SA field and DA field in the P-IP Header and the corresponding relationship. For example, you can obtain the tunnel information through the SA field and DA field in the P-IP Header. Yes (S-P1, D-P2) obtains the multicast source group information (S1, G2) based on the first corresponding relationship, fills in the SA field of the C-IP Header with S1, and fills in the DA field of the C-IP Header with G2.
  • the settings of each field may be statically configured by the egress node, and the local configuration policy used to set the fields may also be preset in advance.
  • the egress node fills in the corresponding field of the multicast source group information in the first message header during encapsulation according to the instruction information sent by the ingress node, or the egress node fills in the corresponding field of the multicast source group information in the first message header according to the deletion and restoration instruction information sent by the ingress node. Indicates how the fields in the first packet header are set based on the fields in the second packet header or the local configuration policy.
  • the local configuration policy for setting fields is preset in advance, and the instruction information received by the egress node can set the corresponding fields according to the corresponding relationship indicated by the instruction information and other configured information. Further, after receiving the indication information, the egress node can save it first, and when receiving the second message, restore the first message according to the instruction of the indication information. For example, if the egress node receives indication information through BGP-MVPN signaling, the indication information may indicate the first corresponding relationship. The egress node can also restore the second message to the first message through preset configuration.
  • the embodiments of this application are only illustrative and not limiting.
  • the entry node can dynamically forward all multicast traffic under the same virtual routing (Virtual Routing Forwarding, VRF). That is, corresponding tunnel information is allocated to the multicast source group information (S, G).
  • VRF Virtual Routing Forwarding
  • S, G multicast source group information
  • the VRF to which the multicast traffic belongs can also be indicated in the corresponding relationship, such as an identifier that can be used.
  • the identifier is VRF1.
  • the VRF to which the multicast traffic belongs can be identified by the name of the VRF and the integer corresponding to the ID number of the VRF.
  • the VRF identifier should meet the requirements of the message transmission protocol to ensure
  • the VRF identifier may be a routing table (route-target) identifier, which can be defined with reference to RFC4364.
  • the VRF identifier is recorded as VRF1.
  • Figure 9 is a configuration method provided by an embodiment of the present application. As shown in Figure 9, the method includes:
  • the entry node configures the VRF and establishes a corresponding relationship.
  • the entry node enables the SA field and DA field of the C-IP Header in Figure 8(a) to pop up, and dynamically allocates addresses from the address range of the local owner (locator a1) to correspond to each multicast traffic, for example,
  • the entry node notifies the exit node of the corresponding relationship.
  • node A and node D can establish a BGP neighbor relationship with each other.
  • Node A can send BGP messages to the egress node.
  • the BGP messages include corresponding relationships.
  • node A can send BGP-MVPN's S-PMSI A-D routing message.
  • the S-PMSI A-D routing message contains (VRF identification, C-IP Header's SA field, C-IP Header's DA field, P-IP Header's IPv6 address), where,
  • the SA field of the C-IP Header is the source address S1v6 in the multicast source group information
  • the DA field of the C-IP Header is the destination address G1v6 in the multicast source group information
  • the IPv6 address of the P-IP Header is the address 2001 of the tunnel information: A:1:1::1001.
  • the A node may also carry deletion and restoration indication information in the S-PMSI A-D routing message, and the deletion and restoration indication information may be used to instruct the D node to restore the first message header.
  • a node can carry this indication information through BGP attribute value type length (Type length value, TLV).
  • the egress node establishes the corresponding relationship between the multicast source group information and the tunnel information according to the advertisement.
  • the entry node is node A and the exit node is node D.
  • Node D receives the above message and establishes the corresponding relationship between the SA field and DA field of C-IP and P-IP.
  • the D node is configured with the VRF1 identifier.
  • VRF1 is the identifier of the local VRF1, which can be the name of VRF1, or the integer value of the ID number of VRF1.
  • the D node determines the corresponding message based on the VRF identifier in the message and its own configured VRF identifier.
  • VRF1 because the VRF identification of the D node is VRF1, which is the same as the VRF identification in the message, the D node can determine the VRF according to the (VRF identification, C-IP Header's SA, C-IP Header's DA, P-IP Header's IPv6 address), determine the following correspondence under VRF1: (2001:A:1:1::1001, VRF1, S1v6, G1v6), and node D saves this correspondence.
  • the entry node receives the first message, encapsulates the message according to the corresponding relationship, and obtains the second message.
  • the IPv6 header multicast message is received.
  • the multicast source group information that is, (VRF identification, C-IP Header SA field, C-IP Header's DA field, P-IP Header's IPv6 address) are encapsulated to obtain the second message.
  • the egress node receives the second message, deletes the second message header, encapsulates the first message header, and obtains the first message.
  • the egress node receives the second message.
  • the second message may be an encapsulation format in various examples provided by the embodiments of this application.
  • the tunnel information of the second message is set to 2001:A:1:1::1001, based on the pre-stored (VRF identification, C-IP Header's SA field, C-IP Header's DA field, the corresponding value of the P-IP Header's IPv6 address), such as (S1v6, G1v6, 2001:A:1:1::1001), you can get the multicast source group information (S1v6, G1v6), that is, the multicast source group information
  • the source address is S1v6, the multicast address of the multicast source group information is G1v6, set the corresponding field in the first packet header, obtain the first packet, and forward it to the CE device.
  • the content of other fields in the first message can be set according to the local configuration policy, or can be set according to the method indicated by the deletion and restoration instruction information, which is not
  • FIG 10 is a schematic structural diagram of another encapsulation and decapsulation message provided by the embodiment of the present application.
  • the BIER message can be encapsulated through MPLS. This kind of encapsulation can be called BIER-MPLS encapsulation.
  • the BIER message can be encapsulated through IPv6, and this encapsulation can be called BIERv6 encapsulation.
  • This application takes BIER-MPLS encapsulation as an example.
  • the entry node deletes the first message header and encapsulates the BIER header and the upstream label.
  • the upstream label is the upstream MPLS label.
  • the entry node is the upstream node.
  • the upstream label (upstream MPLS label) is the label of the ingress node.
  • the upstream MPLS label and upstream MPLS label encapsulation format can refer to the BIER-MPLS MVPN encapsulation method using RFC8296 and RFC8556.
  • BIER is suitable for MPLS networks.
  • the message received by the entry node is in the format shown in Figure 10(a).
  • the first message includes the first message header (C-IP Header) and C-Payload.
  • C-IP Header Belonging to the IPv6 header the entry node deletes the C-IP Header of the received first message, and encapsulates the P-BIER Header and upstream label to obtain the second message.
  • the second message is shown in Figure 10(b), including C -Payload, P-BIER Header and upstream label, and the second message does not include the C-IP Header.
  • the upstream label as the upstream MPLS label as an example
  • the egress node will The P-BIER Header and upstream label are deleted, and the C-IP Header is encapsulated to obtain the first message as shown in Figure 10(c).
  • the first message includes C-IP Header and C-Payload.
  • the entry node encapsulates BIER Header.
  • Table 5 shows the fields of the BIER Header encapsulated by the entry node:
  • BIER Header includes the following parts:
  • Bit Index Forwarding Table identification used for bit index forwarding.
  • the egress node can determine which SD the message belongs to, the BSL used and the method for forwarding the message based on the BIFT ID in the BIER Header.
  • BIFT-ID can correspond to a combination of sub-domain (Sub-Domain, SD), bit string length (Bit String Length, BSL) and set identifier (Set Identifier, SI). Different BIFT IDs can correspond to different SD, BSL and SI combinations;
  • BSL is the length of the bit string included in the BIER Header
  • Bit string BitString used to identify the multicast service BFER set, so that the egress node determines whether the received second message is a message sent to the node based on the BitString field;
  • the BIER header can also include Ver, Differentiated Services Code Point (DSCP), TTL, Entropy, Operation Administration and Maintenance (OAM), TC, stack (S)
  • DSCP Differentiated Services Code Point
  • OAM Operation Administration and Maintenance
  • TC stack
  • S stack
  • the second header corresponding to the tunnel information includes a BIER header and an upstream label, such as an upstream MPLS label.
  • the BIER header includes the identity of the egress node corresponding to the tunnel information.
  • the upstream MPLS label is used to identify the multicast source group information.
  • the BIER header refers to The format of Table 5, the upstream MPLS label refers to the MPLS header format of Table 4.
  • the upstream MPLS label can be used to identify the multicast source group information, and then determine the VPN to which the corresponding CE device belongs based on the multicast source group information.
  • the upstream MPLS label can be used to identify the multicast source group.
  • information please refer to the example of the MPLS label, which will not be described again here.
  • the entry node can set the assigned label value in the Label field of the encapsulated upstream MPLS label.
  • the field settings of the upstream MPLS label refer to the settings of each field in the MPLS header encapsulation in the above example, which will not be described again here.
  • the BIER header includes the identification of the exit node corresponding to the tunnel information.
  • the settings of other fields in the BIER header can refer to the requirements of RFC8296 and RFC8556, and are set according to the C-IP Header field in the first received message, or according to the local configuration policy settings, which will not be expanded.
  • the egress node receives the second message, deletes the encapsulated BIER header and upstream MPLS label, restores the first message header, and obtains the first message.
  • the second message header includes the P-BIER Header and the upstream MPLS label.
  • the first message The header is recorded as C-IP Header.
  • An example of setting each field when encapsulating C-IP Header is as follows:
  • IPv6 version number is 6;
  • C-IP Header's TC Set the TC value according to the local configuration policy
  • C-IP Header's FL Set the FL value according to the local configuration policy
  • C-IP Header's PL It can be set according to whether the encapsulation header contained in C-Payload belongs to IPv4 header or IPv6 header. For example, if the encapsulation header contained in C-Payload belongs to IPv6 header, it can be added through the Payload Length field of IPv6 header. The IPv6 header length 40 is used to obtain the Payload Length field of the C-IP header. Similarly, if the encapsulation header contained in the C-Payload belongs to the IPv4 header, the Payload Length field of the IPv4 header plus the IPv4 header length can be used to obtain the C-IP header. -Payload Length field of IP header;
  • C-IP Header's NH needs to be set according to the IPv4 header or IPv6 header in C-Payload. For example, the encapsulation header contained in C-Payload belongs to the IPv6 header, then the Next Header field is set to 41. Similarly, if the C-Payload If the included encapsulation header belongs to the IPv4 header, the Next Header field is set to 4;
  • C-IP Header's HL Set the HL value according to the local configuration policy
  • SA and DA of C-IP Header Set the SA field and DA field through the Label field and the corresponding relationship. For example, you can obtain the multicast source group information (S1, G2) from the corresponding relationship through 10001 in the Label field. The obtained The source address of the multicast source group information corresponds to the SA field, and the destination address corresponds to the DA field.
  • the C-Payload received by the entry node can be a payload with a User Datagram Protocol (UDP) header. It can also be a complete packet containing an IPv4 or IPv6 header, and the format of the C-Payload after the upstream MPLS label will not affect the forwarding process of the packet.
  • UDP User Datagram Protocol
  • the first message header belongs to the IPv6 header
  • the second message header is the P-BIER Header and the upstream label.
  • the entry node deletes the C-IP Header header and encapsulates the P-BIER Header and upstream label, the effect is equivalent to "replacing" the C-IP Header with the P-BIER Header and upstream label.
  • the egress node then deletes the P-BIER Header and the upstream label, and encapsulates the C-IP Header.
  • the upstream label is an upstream MPLS label as an example. The effect is equivalent to the egress node recovering the first packet and entering it into the backbone.
  • the first message of the network has the same format as the first message after leaving the backbone network, and the transmission overhead in the backbone network can be reduced.
  • Embodiments of the present application provide a network device.
  • the network device is installed at an entry node and can be used to implement the corresponding functions of the entry node in the above method.
  • Figure 11 is a schematic structural diagram of a network device 10 provided by an embodiment of the present application.
  • the network device It can be used to perform methods S101 to S104 or S201 to S205 in the above embodiments. When the network device is used to perform methods S101 to S104 or methods S201 to S205 in the above embodiments, it is equivalent to the examples in this method.
  • the network device 10 includes: a receiving module 101, a processing module 102 and a sending module 103:
  • the receiving module 101 is configured to receive a first message sent by the user edge device.
  • the first message includes a first message header and a payload, and the first message header includes multicast source group information.
  • the processing module 102 is configured to obtain tunnel information according to multicast source group information and corresponding relationships, where the corresponding relationships include multicast source group information and tunnel information.
  • the processing module 102 is also configured to obtain a second message according to the payload and the tunnel information.
  • the second message includes the payload and the second message header corresponding to the tunnel information.
  • the second message does not include the first message header.
  • the sending module 103 is configured to send the second message through the tunnel corresponding to the tunnel information.
  • the second packet header corresponding to the tunnel information includes an IPv6 header and a GRE header
  • the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  • the second packet header corresponding to the tunnel information includes an IPv4 header and a GRE header
  • the IPv4 header includes a source address and a destination address corresponding to the tunnel information.
  • the second message header corresponding to the tunnel information includes an IPv6 header and an IPv6 extension header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  • the second packet header corresponding to the tunnel information includes an IPv6 header
  • the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  • the destination address is the next hop address of the entry node in the multicast tree or the destination address is the multicast group address corresponding to the multicast tree.
  • the second message header corresponding to the tunnel information is a multi-protocol label switching MPLS header.
  • the MPLS header includes the MPLS label of the next hop node of the entry node in the multicast tree or the MPLS corresponding to the multicast tree. Label.
  • the second message header corresponding to the tunnel information includes a bit index explicit copy BIER header and a label.
  • the BIER header includes the identity of the egress node corresponding to the tunnel information.
  • the label is used to identify the multicast source group. information.
  • the sending module 103 is also used to notify the egress node of the corresponding relationship.
  • the sending module 103 is also configured to notify the egress node of indication information, where the indication information is used to instruct the restoration of the multicast source group information.
  • the sending module 103 is specifically configured to send a BGP message to the egress node, where the BGP message includes the corresponding relationship.
  • the BGP message is BGP-MVPN signaling or BGP-EVPN signaling.
  • the network device 10 When the network device 10 is used to perform the above method, it can be applied to the application scenarios shown in Figures 2 to 11, for example, it can be the entry node 1000 in the scenario shown in Figure 2.
  • the division of modules in the embodiment of the present application is schematic and is only a logical function division. In actual implementation, there may be other division methods.
  • Each functional module in the embodiment of the present application can be integrated into one processing module, or each module can exist physically alone, or two or more modules can be integrated into one module.
  • the sending module, receiving module and processing module may be the same module or different modules.
  • the above integrated modules can be implemented in the form of hardware, such as chips, or in the form of software function modules.
  • the embodiment of the present application also provides a network device.
  • the network device is installed at the egress node.
  • the network device can be used to execute the methods S105 to S107 in the above embodiment, or perform S201 to S205.
  • Figure 12 is an embodiment of the present application.
  • a schematic structural diagram of a network device 20 is provided. When the network device is used to execute methods S105 to S107 or methods S201 to S205 in the above embodiment, it is equivalent to the egress node exemplified in the method.
  • the network device 20 includes: a receiving module 201 and a processing module 202.
  • the receiving module 201 is configured to receive a second message, where the second message includes a payload and a second message header corresponding to the tunnel information.
  • the processing module 202 is configured to obtain the multicast source group information according to the tunnel information corresponding to the second message header and the corresponding relationship.
  • the corresponding relationship includes the tunnel information and the multicast source group information.
  • the processing module 202 is also configured to obtain a first message according to the multicast source group information and payload.
  • the first message includes a first message header and a payload.
  • the first message header includes multicast source group information.
  • the first message Does not include the second header.
  • the second packet header corresponding to the tunnel information includes an IPv6 header and a GRE header
  • the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  • the second packet header corresponding to the tunnel information includes an IPv4 header and a GRE header
  • the IPv4 header includes a source address and a destination address corresponding to the tunnel information.
  • the second message header corresponding to the tunnel information includes an IPv6 header and an IPv6 extension header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  • the second packet header corresponding to the tunnel information includes an IPv6 header
  • the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  • the destination address is the next hop address of the entry node in the multicast tree or the destination address is the multicast group address corresponding to the multicast tree.
  • the receiving module 201 is also configured to receive a third message, the third message includes a payload and a third message header corresponding to the tunnel information; the processing module 202 is also configured to receive the third message according to the third message.
  • the tunnel information and corresponding relationship corresponding to the header are used to obtain the multicast source group information.
  • the corresponding relationship includes tunnel information and multicast source group information.
  • the third header corresponding to the tunnel information is the multi-protocol label switching MPLS header.
  • the MPLS header includes The MPLS label assigned by the egress node to the multicast tree or the MPLS label corresponding to the multicast tree.
  • the second message header corresponding to the tunnel information includes a bit index explicit copy BIER header and a label.
  • the BIER header includes the identity of the egress node corresponding to the tunnel information.
  • the label is used to identify the multicast source group. information.
  • the receiving module 201 is also used to obtain the corresponding relationship advertised by the entry node.
  • the receiving module 201 is also configured to receive indication information advertised by the entry node, where the indication information is used to instruct restoration of the multicast source group information.
  • the receiving module 201 is specifically configured to receive a Border Gateway Protocol BGP message sent by the ingress node, where the BGP message includes a corresponding relationship.
  • the BGP message is BGP-MVPN signaling or BGP-EVPN signaling.
  • the network device 20 When the network device 20 is used to perform the above method, it can be applied to the application scenarios shown in Figures 2 to 11, for example, it can be the egress node 200 in the scenario shown in Figure 2.
  • the division of modules in the embodiment of the present application is schematic and is only a logical function division. In actual implementation, there may be other division methods.
  • Each functional module in the embodiment of the present application can be integrated into one processing module, or each module can exist physically alone, or two or more modules can be integrated into one module.
  • the receiving module and the processing module may be the same module or different modules.
  • the above integrated modules can be implemented in the form of hardware, such as chips, or in the form of software function modules.
  • FIG. 13 is a schematic structural diagram of the network device 30 provided by the embodiment of the present application.
  • the network device 30 includes a communication interface 301 and a processor 302 connected to the communication interface 301 .
  • the communication interface is, for example, a device such as a transceiver.
  • the network device 30 can be used to perform the method in the above embodiment.
  • the network device 30 may be configured at the ingress node to perform the operations performed by the ingress node in methods S101 to S104 and S201 to S205.
  • the network device 30 may also be configured at the egress node to perform the operations at the egress from methods S105 to S107 and S201 to S205.
  • the communication interface 301 is used to perform the sending and receiving operations by the entry node in the method.
  • the processor 302 is configured to perform operations other than the sending and receiving operations performed by the entry node in the method.
  • the communication interface 301 is used to perform the sending and receiving operations performed by the entry node in methods S101 to S104 and S201 to S205.
  • the processor 302 is configured to perform operations other than the sending and receiving operations performed by the entry node in methods S101 to S104 and S201 to S205. For example, when the network device 30 is configured at the entrance node to perform an operation, tunnel information is obtained according to the multicast source group information and the corresponding relationship.
  • the corresponding relationship includes the multicast source group information and tunnel information, and is also used to obtain the third channel information based on the load and tunnel information.
  • Two packets the second packet includes the payload and the second packet header corresponding to the tunnel information, and the second packet does not include the first packet header.
  • Communication interface 301 is used to receive the first message sent by the user edge device.
  • the first message includes a first message header and a payload.
  • the first message header includes multicast source group information. It is also used to pass the corresponding tunnel information. tunnel to send the second message.
  • the communication interface 301 is used to perform the sending and receiving operations performed by the egress node in methods S105 to S107 and S201 to S205.
  • the processor 302 is configured to perform operations other than the sending and receiving operations performed by the egress node in methods S105 to S107 and S201 to S205.
  • the communication interface 301 is configured to receive a second message, where the second message includes a payload and a second message header corresponding to the tunnel information.
  • the processor 302 is configured to obtain the multicast source group information according to the tunnel information and the corresponding relationship corresponding to the second message header.
  • the corresponding relationship includes the tunnel information and the multicast source group information, and is also used to obtain the multicast source group information according to the multicast source group information and the load.
  • the first message includes a first message header and a payload, the first message header includes multicast source group information, and the first message does not include a second message header.
  • FIG. 14 is a schematic structural diagram of a network device 40 provided by an embodiment of the present application.
  • the network device 40 may include a processor 401, a memory 402 coupled to the processor 401, and a transceiver 403.
  • the transceiver 403 may be a communication interface, an optical module, etc., and is used to receive messages or data information, etc.
  • the processor 401 may be a central processing unit (CPU), a network processor (NP), or a combination of a CPU and an NP, and is used to perform steps related to forwarding processing in the device exemplified in the above embodiments.
  • the processor may also be an application-specific integrated circuit (application-specific integrated circuit). specific integrated circuit (ASIC), programmable logic device (PLD) or a combination thereof.
  • ASIC application-specific integrated circuit
  • PLD programmable logic device
  • the above-mentioned PLD can be a complex programmable logic device (CPLD), a field-programmable gate array (FPGA), a general array logic (GAL) or any combination thereof.
  • the processor 401 may refer to one processor or may include multiple processors.
  • the memory 402 may include volatile memory (volatile memory), such as random-access memory (RAM); the memory may also include non-volatile memory (non-volatile memory), such as read-only memory (read- only memory (ROM), flash memory (flash memory), hard disk drive (HDD) or solid-state drive (SSD); the memory 402 may also include a combination of the above types of memory.
  • volatile memory volatile memory
  • non-volatile memory non-volatile memory
  • ROM read-only memory
  • flash memory flash memory
  • HDD hard disk drive
  • SSD solid-state drive
  • the memory 402 may refer to one memory or may include multiple memories for storing program instructions.
  • computer readable instructions are stored in the memory 402, and the computer readable instructions include a plurality of software modules, such as a sending module, a processing module and a receiving module. After executing each software module, the processor 401 can perform corresponding operations according to the instructions of each software module.
  • the operations performed by the software module actually refer to operations performed by the processor 401 according to the instructions of the software module.
  • the processor 401 can also store program codes or instructions for executing the solutions of the embodiments of the present application. In this case, the processor 401 does not need to read the program codes or instructions from the memory 402.
  • the network device 40 can be used to perform the method in the above embodiment. Specifically, the network device 40 can be configured at the entry node to perform operations performed by the entry node in methods S101 to S104 and S201 to S205, and the network device 40 can be configured at the exit node to perform operations from methods S105 to S107 and S201 to S205 by the exit node. The operation performed. For example, when the network device 40 performs operations as a device set at an ingress node, the processor 401 is configured to execute relevant instructions in the memory 402 to obtain tunnel information according to the multicast source group information and the corresponding relationship. The corresponding relationship includes the multicast source group information and tunnel information, and obtain a second message based on the payload and tunnel information.
  • the second message includes the payload and the second message header corresponding to the tunnel information.
  • the second message does not include the first message header.
  • the processor 401 is configured to execute relevant instructions in the memory 402 and obtain the multicast source group information according to the tunnel information and corresponding relationship corresponding to the second message header.
  • the corresponding relationship includes tunnel information and multicast source group information
  • the first message is obtained according to the multicast source group information and payload.
  • the first message includes the first message header and payload, and the first message header includes the multicast source group.
  • Information, the first packet does not include the second packet header.
  • Embodiments of the present application also provide a computer-readable storage medium. Instructions are stored in the computer-readable storage medium. When run on a processor, any one of the methods in any of the foregoing embodiments can be implemented. some or all operations.
  • Embodiments of the present application also provide a computer program product, including a computer program that, when run on a processor, implements part or all of the operations in any of the methods in any of the foregoing embodiments.
  • Embodiments of the present application also provide a message transmission system, which can be applied in the scenario shown in Figure 2, including: the system includes at least one network device provided at the entry node and at least one network device provided at the exit node. equipment. As shown in Figure 2, the system may also include network equipment and CE equipment provided at intermediate nodes. Among them, the network device provided at the entry node is a network device corresponding to Figure 11, Figure 13 or Figure 14, and the network device provided at the entry node is a network device with a structure corresponding to Figure 12, Figure 13 or Figure 14.
  • the above communication system is used to implement part or all of the operations in any of the methods of any of the foregoing embodiments.
  • the embodiment of the present application also provides another communication system, including at least one memory and at least one processor.
  • the at least one memory stores instructions, and the at least one processor executes the instructions, so that the communication system implements the foregoing embodiments. Some or all of the operations in any of the methods of any of the embodiments.
  • An embodiment of the present application also provides a chip, including: an interface circuit and a processor.
  • the interface circuit is connected to a processor, and the processor is used to cause the chip to perform part or all of the operations in any of the methods of any of the foregoing embodiments.
  • Embodiments of the present application also provide a chip system, including: a processor, the processor is coupled to a memory, and the memory is used to store programs or instructions. When the programs or instructions are executed by the processor, the chip system implements any of the foregoing embodiments. Some or all of the operations in any of the methods of an embodiment.
  • processors in the chip system there may be one or more processors in the chip system.
  • the processor can be implemented in hardware or software.
  • the processor may be a logic circuit, an integrated circuit, or the like.
  • the processor may be a general-purpose processor implemented by reading software code stored in memory.
  • the memory may be integrated with the processor or may be provided separately from the processor, which is not limited by the embodiments of the present application.
  • the memory may be a non-transitory processor, such as a read-only memory ROM, which may be integrated with the processor on the same chip, or may be separately provided on different chips.
  • the embodiment of the present application covers the type of memory, and The arrangement of the memory and processor is not specifically limited.
  • the chip system can be an FPGA, an ASIC, a system on chip (SoC), a CPU, an NP, or a digital signal processing circuit (digital signal processor, DSP), it can also be a microcontroller unit (MCU), a programmable logic device (PLD) or other integrated chips.
  • SoC system on chip
  • DSP digital signal processor
  • MCU microcontroller unit
  • PLD programmable logic device
  • the size of the sequence numbers of the above-mentioned processes does not mean the order of execution.
  • the execution order of each process should be determined by its functions and internal logic, and should not be used in the embodiments of the present application.
  • the implementation process constitutes any limitation.
  • Computer-readable media includes computer storage media and communication media including any medium that facilitates transfer of a computer program from one place to another.
  • Storage media can be any available media that can be accessed by a general purpose or special purpose computer.

Abstract

Provided in the embodiments of the present application are a message transmission method and a network device. The method comprises: an ingress node receiving a first message, which is sent by a user edge device, wherein the first message contains a first message header and a payload, and the first message header comprises multicast source group information; the ingress node acquiring tunnel information according to the multicast source group information and a correlation, wherein the correlation comprises the multicast source group information and the tunnel information; the ingress node obtaining a second message according to the payload and the tunnel information, wherein the second message contains the payload and a second message header, which corresponds to the tunnel information, and the second message does not comprise the first message header; and the ingress node sending the second message through a tunnel corresponding to the tunnel information.

Description

报文传输的方法和网络设备Message transmission methods and network equipment
本申请要求于2022年8月31日提交中国国家知识产权局、申请号为202211063430.9、申请名称为“报文传输的方法和网络设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims priority to the Chinese patent application filed with the State Intellectual Property Office of China on August 31, 2022, with application number 202211063430.9 and application name "Message transmission method and network equipment", the entire content of which is incorporated by reference. in this application.
技术领域Technical field
本申请涉及通信领域,特别涉及报文传输的方法和网络设备。This application relates to the field of communications, and in particular to message transmission methods and network equipment.
背景技术Background technique
随着通信技术的发展,组播技术在视频直播、视频会议等场景下的使用需求日渐增加。组播技术一方面能够在网络中提供点到多点的转发,有效减少网络冗余流量,降低网络负载,另一方面能够在应用平台中减轻服务器和处理器的负荷,减少因用户量的增长对组播源的造成的影响。基于组播技术的网络架可以包括用户网络和骨干网络。骨干网络可以采用不同的隧道进行报文传输,比如骨干网络可以支持采用一种或多种隧道。用户网络的组播报文在进入骨干网络时进行需进行封装。封装后的报文通过隧道在骨干网络中传输。封装后的报文离开骨干网络时通过解封装获得组播报文。组播报文被转发至组播接收者所在的用户网络。骨干网络可以是运行组播虚拟专用网络(Multicast Virtual Private Network VPN,MVPN)或以太虚拟专用网络(Ethernet VPN,EVPN)的网络。上述组播报文的传输方法存在传输开销较大的问题。With the development of communication technology, the demand for the use of multicast technology in scenarios such as live video broadcast and video conferencing is increasing. On the one hand, multicast technology can provide point-to-multipoint forwarding in the network, effectively reducing network redundant traffic and reducing network load. On the other hand, it can reduce the load on servers and processors in the application platform, reducing the impact of the increase in the number of users. Impact on multicast sources. The network frame based on multicast technology can include user networks and backbone networks. The backbone network can use different tunnels for packet transmission. For example, the backbone network can support one or more tunnels. Multicast packets from user networks need to be encapsulated when entering the backbone network. The encapsulated packets are transmitted through the tunnel in the backbone network. When the encapsulated packet leaves the backbone network, the multicast packet is obtained through decapsulation. Multicast packets are forwarded to the user network where the multicast receiver is located. The backbone network can be a network running a Multicast Virtual Private Network VPN (MVPN) or an Ethernet Virtual Private Network (Ethernet VPN, EVPN). The above-mentioned multicast packet transmission method has the problem of high transmission overhead.
发明内容Contents of the invention
本申请提供了一种报文传输的方法和网络设备,能够减少组播报文在骨干网中传输的开销。This application provides a message transmission method and network equipment, which can reduce the transmission overhead of multicast messages in the backbone network.
第一方面,本申请提供了一种报文传输的方法,包括:入口节点接收用户边缘设备发送的第一报文,所述第一报文包含第一报文头和载荷,所述第一报文头包括组播源组信息;所述入口节点根据所述组播源组信息和对应关系,获取隧道信息,所述对应关系包括所述组播源组信息和所述隧道信息;所述入口节点根据所述载荷和所述隧道信息获得第二报文,所述第二报文包含所述载荷和与所述隧道信息对应的第二报文头,所述第二报文不包括所述第一报文头;所述入口节点通过与所述隧道信息对应的隧道发送所述第二报文。In a first aspect, this application provides a message transmission method, including: an entry node receives a first message sent by a user edge device, where the first message includes a first message header and a payload, and the first message The message header includes multicast source group information; the entry node obtains tunnel information according to the multicast source group information and the corresponding relationship, where the corresponding relationship includes the multicast source group information and the tunnel information; The entry node obtains a second message according to the payload and the tunnel information. The second message includes the payload and a second message header corresponding to the tunnel information. The second message does not include the The first message header is provided; the ingress node sends the second message through the tunnel corresponding to the tunnel information.
本申请提供的方法适用基于组播技术的网络架构,该网络架构可以包括用户网络和骨干网络,骨干网络包括入口节点、中间节点和出口节点,其中,入口节点和出口节点是骨干网络中的与用户网络进行报文交互的边缘节点。本申请实施例中将CE设备发送的报文记作第一报文,入口节点对接收到的第一报文进行封装得到第二报文头,并将第一报文的第一报文头删除,得到第二报文并转发。在骨干网络中,根据入口节点、中间节点与出口节点的实际设置情况,第二报文可能经过一个或多个中间节点转发到达出口节点,或者,第二报文由入口节点转发至出口节点。在第二报文到达出口节点时,由出口节点对第二报 文进行封装得到第一报文头,并删除第二报文头,得到第一报文。其中,第一报文中的第一报文头可以是第六版互联网协议(Internet Protocol version 6,IPv6)头或第四版互联网协议(Internet Protocol version 4,IPv4)头。组播源组信息是第一报文中的源地址和目的地址,该目的地址是组播组地址。The method provided by this application is applicable to a network architecture based on multicast technology. The network architecture may include a user network and a backbone network. The backbone network includes an entry node, an intermediate node, and an exit node. The entry node and the exit node are the same as those in the backbone network. The edge node of the user network for message exchange. In the embodiment of this application, the message sent by the CE device is recorded as the first message. The entrance node encapsulates the received first message to obtain the second message header, and adds the first message header of the first message to Delete, get the second message and forward it. In the backbone network, depending on the actual settings of the ingress node, intermediate node, and egress node, the second message may be forwarded to the egress node through one or more intermediate nodes, or the second message may be forwarded by the ingress node to the egress node. When the second packet reaches the egress node, the egress node The packet is encapsulated to obtain the first packet header, and the second packet header is deleted to obtain the first packet. The first header in the first message may be an Internet Protocol version 6 (IPv6) header or an Internet Protocol version 4 (IPv4) header. The multicast source group information is the source address and destination address in the first message, and the destination address is the multicast group address.
对应关系是组播源组信息与骨干网络中各节点的隧道信息的之间的关系,可以是入口节点建立的。进一步地,基于对应关系确定的隧道信息对应第二报文头,在入口节点和出口节点之间采用不同的隧道对应的场景时,隧道信息与第二报文头可以采用不同的表示方式,如在入口节点和出口节点之间采用IP组播隧道的场景中,如入口节点基于互联网协议(Internet Protocol,IP)进行封装,进一步地,入口节点可以基于IPv6封装,得到的第二报文头包括IPv6头,IPv6头包括与隧道信息对应的源地址和目的地址,其中,目的地址是组播树对应的组播组地址;在入口节点和出口节点之间采用基于IPv6封装的位索引显式复制(Bit Index Explicit Replication IPv6 Encapsulation,BIERv6)组播隧道的场景中,BIERv6头包括与隧道信息对应的源地址和目的地址,其中,目的地址是单播地址,或者,BIERv6头可以包括与隧道信息对应的源地址,不包括目的地址;在入口节点和出口节点之间采用多协议标签交换点到多点(Multiprotocol Label Switching point-to-multipoint,MPLS P2MP)隧道的场景中,隧道信息与第二报文头通过MPLS标签对应,在入口节点和出口节点之间采用BIER组播隧道的场景中,隧道信息与第二报文头通过上游MPLS标签对应。The corresponding relationship is the relationship between the multicast source group information and the tunnel information of each node in the backbone network, and can be established by the ingress node. Furthermore, the tunnel information determined based on the correspondence relationship corresponds to the second packet header. When different tunnel correspondence scenarios are adopted between the ingress node and the egress node, the tunnel information and the second packet header can be expressed in different ways, such as In a scenario where an IP multicast tunnel is used between an ingress node and an egress node, for example, the ingress node encapsulates based on Internet Protocol (IP). Further, the ingress node can encapsulate based on IPv6, and the resulting second message header includes IPv6 header, the IPv6 header includes the source address and destination address corresponding to the tunnel information, where the destination address is the multicast group address corresponding to the multicast tree; bit index based on IPv6 encapsulation is explicitly copied between the ingress node and the egress node. (Bit Index Explicit Replication IPv6 Encapsulation, BIERv6) In the scenario of a multicast tunnel, the BIERv6 header includes the source address and destination address corresponding to the tunnel information, where the destination address is a unicast address, or the BIERv6 header may include the source address corresponding to the tunnel information. The source address, excluding the destination address; in the scenario where a Multiprotocol Label Switching point-to-multipoint (MPLS P2MP) tunnel is used between the ingress node and the egress node, the tunnel information and the second report The header corresponds to the MPLS label. In the scenario where a BIER multicast tunnel is used between the ingress node and the egress node, the tunnel information and the second header correspond to the upstream MPLS label.
在一种可能实现的方式中,所述第二报文头包括IPv6头和通用路由封装(Generic Routing Encapsulation,GRE)头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。In a possible implementation manner, the second message header includes an IPv6 header and a Generic Routing Encapsulation (GRE) header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能实现的方式中,所述第二报文头包括IPv4头和GRE头,所述IPv4头包括与所述隧道信息对应的源地址和目的地址。In a possible implementation manner, the second message header includes an IPv4 header and a GRE header, and the IPv4 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能实现的方式中,所述第二报文头包括IPv6头和IPv6扩展头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。In a possible implementation manner, the second message header includes an IPv6 header and an IPv6 extension header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能实现的方式中,所述第二报文头包括IPv6头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。In a possible implementation manner, the second message header includes an IPv6 header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能实现的方式中,所述目的地址为所述入口节点在组播树的下一跳的地址或者所述目的地址为组播树对应的组播组地址。In a possible implementation manner, the destination address is the address of the next hop of the entry node in the multicast tree or the destination address is the multicast group address corresponding to the multicast tree.
在一种可能实现的方式中,与所述隧道信息对应的所述第二报文头为多协议标签交换(Multiprotocol Label Switching,MPLS)头,所述MPLS头包括所述入口节点在组播树的下一跳节点的MPLS标签或组播树对应的MPLS标签。In a possible implementation manner, the second message header corresponding to the tunnel information is a Multiprotocol Label Switching (MPLS) header, and the MPLS header includes the entry node in the multicast tree. The MPLS label of the next hop node or the MPLS label corresponding to the multicast tree.
在一种可能实现的方式中,与所述隧道信息对应的所述第二报文头包括位索引显式复制(Bit Index Explicit Replication,BIER)头和标签,所述BIER头包括与所述隧道信息对应的所述出口节点的标识,所述标签用于标识所述组播源组信息。In a possible implementation manner, the second message header corresponding to the tunnel information includes a Bit Index Explicit Replication (BIER) header and a label, and the BIER header includes the information related to the tunnel information. The identifier of the egress node corresponding to the information, and the label is used to identify the multicast source group information.
在一种可能实现的方式中,所述方法还包括:所述入口节点向出口节点通告所述对应关系。在另一种可能实现的方式中,对应关系可以是入口节点和出口节点各自静态配置。In a possible implementation manner, the method further includes: the ingress node notifying the egress node of the corresponding relationship. In another possible implementation manner, the corresponding relationship may be static configuration of the entry node and the exit node respectively.
在一种可能实现的方式中,所述方法还包括:所述入口节点向出口节点通告指示信息,所述指示信息用于指示还原所述组播源组信息。其中,指示信息用于指示还原所述组播源组信息,即指示信息至少用于指示出口节点能够还原出第一报文头的组播源组信息,使得 出口节点根据指示信息和第二报文得到第一报文。In a possible implementation manner, the method further includes: the ingress node notifying the egress node of indication information, where the indication information is used to instruct restoration of the multicast source group information. Wherein, the indication information is used to instruct to restore the multicast source group information, that is, the indication information is at least used to instruct the egress node to restore the multicast source group information of the first packet header, so that The egress node obtains the first message according to the indication information and the second message.
在一种可能实现的方式中,所述入口节点向出口节点通告所述对应关系包括:所述入口节点向所述出口节点发送边界网关协议(Border Gateway Protocol,BGP)消息,所述BGP消息包括所述对应关系。比如,所述BGP消息为边界网关协议-组播虚拟专用网络(Border Gateway Protocol-Multicast VPN,BGP-MVPN)信令或者边界网关协议-以太虚拟专用网络(Border Gateway Protocol-Ethernet VPN,BGP-EVPN)信令。In a possible implementation manner, the ingress node notifying the corresponding relationship to the egress node includes: the ingress node sends a Border Gateway Protocol (Border Gateway Protocol, BGP) message to the egress node, and the BGP message includes the corresponding relationship. For example, the BGP message is Border Gateway Protocol-Multicast VPN (BGP-MVPN) signaling or Border Gateway Protocol-Ethernet VPN (BGP-EVPN) ) signaling.
本申请实施例以入口节点删除第一报文头,并封装第二报文头得到第二报文,由第二报文在骨干网络中进行传输,到达出口节点时,再由出口节点删除第二报文头,恢复第一报文头得到第一报文,这样,在骨干网络的传输中,第二报文不需再携带第一报文头,能够减少报文在骨干网络中传输的开销。In the embodiment of this application, the entrance node deletes the first message header and encapsulates the second message header to obtain a second message. The second message is transmitted in the backbone network. When it reaches the egress node, the egress node deletes the second message. Second packet header, restore the first packet header to obtain the first packet. In this way, during the transmission of the backbone network, the second packet no longer needs to carry the first packet header, which can reduce the time of packet transmission in the backbone network. overhead.
第二方面,本申请提供了一种报文传输的方法,包括:出口节点接收第二报文,所述第二报文包括载荷和与隧道信息对应的第二报文头;所述出口节点根据对应关系和所述第二报文头对应的所述隧道信息,获取组播源组信息,所述对应关系包括所述隧道信息和所述组播源组信息;所述出口节点根据所述组播源组信息和所述载荷获得第一报文,所述第一报文包含第一报文头和所述载荷,所述第一报文头包括所述组播源组信息,所述第一报文不包括所述第二报文头。In a second aspect, this application provides a message transmission method, including: an egress node receiving a second message, the second message including a payload and a second message header corresponding to tunnel information; the egress node Obtain multicast source group information according to the corresponding relationship and the tunnel information corresponding to the second message header, where the corresponding relationship includes the tunnel information and the multicast source group information; the egress node obtains the multicast source group information according to the Multicast source group information and the payload are obtained in a first message, the first message includes a first message header and the payload, the first message header includes the multicast source group information, and the The first message does not include the second message header.
在一种可能实现的方式中,所述第二报文头包括IPv6头和GRE头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。In a possible implementation manner, the second message header includes an IPv6 header and a GRE header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能实现的方式中,所述第二报文头包括IPv4头和GRE头,所述IPv4头包括与所述隧道信息对应的源地址和目的地址。In a possible implementation manner, the second message header includes an IPv4 header and a GRE header, and the IPv4 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能实现的方式中,所述第二报文头包括IPv6头和IPv6扩展头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。In a possible implementation manner, the second message header includes an IPv6 header and an IPv6 extension header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能实现的方式中,所述第二报文头包括IPv6头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。In a possible implementation manner, the second message header includes an IPv6 header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能实现的方式中,所述目的地址为所述入口节点在组播树的下一跳的地址或者所述目的地址为组播树对应的组播组地址。In a possible implementation manner, the destination address is the address of the next hop of the entry node in the multicast tree or the destination address is the multicast group address corresponding to the multicast tree.
在一种可能实现的方式中,所述出口节点根据所述组播源组信息和所述载荷获得第一报文之前,还包括:所述出口节点接收第三报文,所述第三报文包括所述载荷和与所述隧道信息对应的第三报文头;所述出口节点根据对应关系和所述第三报文头对应的所述隧道信息,获取所述组播源组信息,所述第三报文头为MPLS头,所述MPLS头包括所述出口节点为组播树分配的MPLS标签或所述组播树对应的MPLS标签。In a possible implementation manner, before the egress node obtains the first message according to the multicast source group information and the payload, the method further includes: the egress node receives a third message, and the third message The message includes the payload and a third message header corresponding to the tunnel information; the egress node obtains the multicast source group information according to the corresponding relationship and the tunnel information corresponding to the third message header, The third message header is an MPLS header, and the MPLS header includes the MPLS label allocated by the egress node for the multicast tree or the MPLS label corresponding to the multicast tree.
在一种可能实现的方式中,与所述隧道信息对应的所述第二报文头包括BIER头和标签,所述BIER头包括与所述隧道信息对应的出口节点的标识,所述标签用于标识所述组播源组信息。In a possible implementation manner, the second message header corresponding to the tunnel information includes a BIER header and a label, the BIER header includes an identification of the egress node corresponding to the tunnel information, and the label is To identify the multicast source group information.
在一种可能实现的方式中,所述方法还包括:所述出口节点获取所述入口节点通告的所述对应关系。In a possible implementation manner, the method further includes: the egress node obtains the corresponding relationship advertised by the ingress node.
在一种可能实现的方式中,所述方法还包括:所述出口节点接收所述入口节点通告的指示信息,所述指示信息用于指示还原所述组播源组信息。In a possible implementation manner, the method further includes: the egress node receiving indication information advertised by the ingress node, where the indication information is used to instruct restoration of the multicast source group information.
在一种可能实现的方式中,所述出口节点获取所述入口节点通告的所述对应关系包括: 所述出口节点接收所述入口节点发送的BGP消息,所述BGP消息包括所述对应关系。In a possible implementation manner, the egress node obtaining the corresponding relationship advertised by the ingress node includes: The egress node receives the BGP message sent by the ingress node, and the BGP message includes the corresponding relationship.
在一种可能实现的方式中,所述BGP消息为BGP-MVPN信令或者BGP-EVPN信令。In a possible implementation manner, the BGP message is BGP-MVPN signaling or BGP-EVPN signaling.
第三方面,本申请提供了一种网络设备,所述网络设备设置于入口节点,所述网络设备包括:接收模块,用于接收用户边缘设备发送的第一报文,所述第一报文包含第一报文头和载荷,所述第一报文头包括组播源组信息;处理模块,用于根据所述组播源组信息和对应关系,获取隧道信息,所述对应关系包括所述组播源组信息和所述隧道信息;所述处理模块,还用于根据所述载荷和所述隧道信息获得第二报文,所述第二报文包含所述载荷和与所述隧道信息对应的第二报文头,所述第二报文不包括所述第一报文头;发送模块,用于通过与所述隧道信息对应的隧道发送所述第二报文。In a third aspect, the present application provides a network device. The network device is provided at an entrance node. The network device includes: a receiving module configured to receive a first message sent by a user edge device. The first message Containing a first packet header and a payload, the first packet header including multicast source group information; a processing module configured to obtain tunnel information according to the multicast source group information and a corresponding relationship, the corresponding relationship including all The multicast source group information and the tunnel information; the processing module is also configured to obtain a second message according to the load and the tunnel information, where the second message includes the payload and the tunnel information. a second message header corresponding to the information, the second message not including the first message header; and a sending module configured to send the second message through the tunnel corresponding to the tunnel information.
在一种可能实现的方式中,所述第二报文头包括IPv6头和GRE头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。In a possible implementation manner, the second message header includes an IPv6 header and a GRE header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能实现的方式中,所述第二报文头包括IPv4头和GRE头,所述IPv4头包括与所述隧道信息对应的源地址和目的地址。In a possible implementation manner, the second message header includes an IPv4 header and a GRE header, and the IPv4 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能实现的方式中,所述第二报文头包括IPv6头和IPv6扩展头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。In a possible implementation manner, the second message header includes an IPv6 header and an IPv6 extension header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能实现的方式中,所述第二报文头包括IPv6头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。In a possible implementation manner, the second message header includes an IPv6 header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能实现的方式中,所述目的地址为所述入口节点在组播树的下一跳的地址或者所述目的地址为组播树对应的组播组地址。In a possible implementation manner, the destination address is the address of the next hop of the entry node in the multicast tree or the destination address is the multicast group address corresponding to the multicast tree.
在一种可能实现的方式中,所述第二报文头为MPLS头,所述MPLS头包括所述入口节点在组播树的下一跳节点的MPLS标签或组播树对应的MPLS标签。In a possible implementation manner, the second message header is an MPLS header, and the MPLS header includes the MPLS label of the next hop node of the entry node in the multicast tree or the MPLS label corresponding to the multicast tree.
在一种可能实现的方式中,所述第二报文头包括BIER头和标签,所述BIER头包括与所述隧道信息对应的所述出口节点的标识,所述标签用于标识所述组播源组信息。In a possible implementation manner, the second message header includes a BIER header and a label, the BIER header includes an identification of the egress node corresponding to the tunnel information, and the label is used to identify the group Source group information.
在一种可能实现的方式中,所述发送模块还用于向出口节点通告所述对应关系。In a possible implementation manner, the sending module is also configured to notify the egress node of the corresponding relationship.
在一种可能实现的方式中,所述发送模块还用于向出口节点通告指示信息,所述指示信息用于指示还原所述组播源组信息。In a possible implementation manner, the sending module is further configured to notify the egress node of indication information, where the indication information is used to instruct restoration of the multicast source group information.
在一种可能实现的方式中,所述发送模块具体用于向所述出口节点发送BGP消息,所述BGP消息包括所述对应关系。In a possible implementation manner, the sending module is specifically configured to send a BGP message to the egress node, where the BGP message includes the corresponding relationship.
在一种可能实现的方式中,所述BGP消息为BGP-MVPN信令或者边界网关协议-以BGP-EVPN信令。In a possible implementation manner, the BGP message is BGP-MVPN signaling or Border Gateway Protocol-BGP-EVPN signaling.
第四方面,本申请提供了一种网络设备,所述网络设备设置于出口节点,所述网络设备包括:接收模块,用于接收第二报文,所述第二报文包括载荷和与隧道信息对应的第二报文头;处理模块,用于根据对应关系和所述第二报文头对应的所述隧道信息,获取组播源组信息,所述对应关系包括所述隧道信息和所述组播源组信息;所述处理模块,还用于根据所述组播源组信息和所述载荷获得第一报文,所述第一报文包含第一报文头和所述载荷,所述第一报文头包括所述组播源组信息,所述第一报文不包括所述第二报文头。In a fourth aspect, the present application provides a network device. The network device is provided at an egress node. The network device includes: a receiving module configured to receive a second message. The second message includes a payload and a tunnel link. a second message header corresponding to the information; a processing module configured to obtain multicast source group information according to the corresponding relationship and the tunnel information corresponding to the second message header, where the corresponding relationship includes the tunnel information and the tunnel information corresponding to the second message header; The multicast source group information; the processing module is also configured to obtain a first message according to the multicast source group information and the payload, where the first message includes a first message header and the payload, The first message header includes the multicast source group information, and the first message does not include the second message header.
在一种可能实现的方式中,与所述隧道信息对应的所述第二报文头包括IPv6头和GRE头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。In a possible implementation manner, the second packet header corresponding to the tunnel information includes an IPv6 header and a GRE header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能实现的方式中,与所述隧道信息对应的所述第二报文头包括IPv4头和 GRE头,所述IPv4头包括与所述隧道信息对应的源地址和目的地址。In a possible implementation manner, the second message header corresponding to the tunnel information includes an IPv4 header and GRE header, the IPv4 header includes the source address and destination address corresponding to the tunnel information.
在一种可能实现的方式中,与所述隧道信息对应的所述第二报文头包括IPv6头和IPv6扩展头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。In a possible implementation manner, the second packet header corresponding to the tunnel information includes an IPv6 header and an IPv6 extension header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能实现的方式中,与所述隧道信息对应的所述第二报文头包括IPv6头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。In a possible implementation manner, the second packet header corresponding to the tunnel information includes an IPv6 header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能实现的方式中,所述目的地址为所述入口节点在组播树的下一跳的地址或者所述目的地址为组播树对应的组播组地址。In a possible implementation manner, the destination address is the address of the next hop of the entry node in the multicast tree or the destination address is the multicast group address corresponding to the multicast tree.
在一种可能实现的方式中,所述接收模块还用于接收第三报文,所述第三报文包括所述载荷和与所述隧道信息对应的第三报文头;所述处理模块,还用于根据所述对应关系和所述第三报文头对应的所述隧道信息,获取所述组播源组信息,所述第三报文头为多协议标签交换MPLS头,所述MPLS头包括所述出口节点为组播树分配的MPLS标签或所述组播树对应的MPLS标签。In a possible implementation manner, the receiving module is also configured to receive a third message, the third message including the payload and a third message header corresponding to the tunnel information; the processing module , and is further configured to obtain the multicast source group information according to the corresponding relationship and the tunnel information corresponding to the third message header, where the third message header is a multi-protocol label switching MPLS header, and the The MPLS header includes the MPLS label allocated by the egress node for the multicast tree or the MPLS label corresponding to the multicast tree.
在一种可能实现的方式中,与所述隧道信息对应的所述第二报文头包括BIER头和标签,所述BIER头包括与所述隧道信息对应的出口节点的标识,所述标签用于标识所述组播源组信息。In a possible implementation manner, the second message header corresponding to the tunnel information includes a BIER header and a label, the BIER header includes an identification of the egress node corresponding to the tunnel information, and the label is To identify the multicast source group information.
在一种可能实现的方式中,所述接收模块,还用于获取所述入口节点通告的所述对应关系。In a possible implementation manner, the receiving module is also configured to obtain the corresponding relationship advertised by the entry node.
在一种可能实现的方式中,所述接收模块,还用于接收所述入口节点通告的指示信息,所述指示信息用于指示还原所述组播源组信息。In a possible implementation manner, the receiving module is further configured to receive indication information advertised by the ingress node, where the indication information is used to instruct restoration of the multicast source group information.
在一种可能实现的方式中,所述接收模块,具体用于接收所述入口节点发送的BGP消息,所述BGP消息包括所述对应关系。In a possible implementation manner, the receiving module is specifically configured to receive a BGP message sent by the ingress node, where the BGP message includes the corresponding relationship.
在一种可能实现的方式中,所述BGP消息为BGP-MVPN信令或者BGP-EVPN信令。In a possible implementation manner, the BGP message is BGP-MVPN signaling or BGP-EVPN signaling.
第五方面,本申请提供一种网络设备,所述网络设备包括通信接口和处理器,所述通信接口用于执行前述任一方面所述的方法以及任一方面的任一可能的实现方式中所涉及的收发操作,所述处理器用于执行以上任一方面所述的方法以及任一方面的任一可能的实现方式中所涉及的除收发操作之外的其它操作。例如,第五方面所述的网络设备设置于入口节点执行第一方面所述的方法时,所述处理器用于根据所述组播源组信息和对应关系,获取隧道信息,所述对应关系包括所述组播源组信息和所述隧道信息,根据所述载荷和所述隧道信息获得第二报文,所述第二报文包含所述载荷和与所述隧道信息对应的第二报文头,所述第二报文不包括所述第一报文头,所述通信接口用于接收用户边缘设备发送的第一报文,所述第一报文包含第一报文头和载荷,所述第一报文头包括组播源组信息,根据所述载荷和所述隧道信息获得第二报文,所述第二报文包含所述载荷和与所述隧道信息对应的第二报文头,所述第二报文不包括所述第一报文头。第五方面所述的网络设备设置于出口节点执行第二方面所述的方法时,所述通信接口用于接收第二报文,所述第二报文包括载荷和与隧道信息对应的第二报文头,所述处理器用于根据对应关系和所述第二报文头对应的所述隧道信息,获取组播源组信息,所述对应关系包括所述隧道信息和所述组播源组信息,根据所述组播源组信息和所述载荷获得第一报文,所述第一报文包含第一报文头和所述载荷,所述第一报文头包括所述组播源组信息,所述第一报文不包括所述第二报文头。 In a fifth aspect, the present application provides a network device. The network device includes a communication interface and a processor. The communication interface is used to execute the method described in any of the foregoing aspects and any possible implementation of any aspect. Regarding the transceiver operation involved, the processor is configured to perform other operations other than the transceiver operation involved in the method described in any of the above aspects and any possible implementation of any aspect. For example, when the network device described in the fifth aspect is configured at the entrance node to execute the method described in the first aspect, the processor is configured to obtain tunnel information according to the multicast source group information and the corresponding relationship, and the corresponding relationship includes The multicast source group information and the tunnel information are used to obtain a second message according to the payload and the tunnel information. The second message includes the payload and a second message corresponding to the tunnel information. header, the second message does not include the first message header, the communication interface is used to receive the first message sent by the user edge device, the first message includes the first message header and payload, The first message header includes multicast source group information, and a second message is obtained according to the payload and the tunnel information. The second message includes the payload and a second message corresponding to the tunnel information. header, the second message does not include the first message header. When the network device described in the fifth aspect is configured at the egress node to perform the method described in the second aspect, the communication interface is used to receive a second message, and the second message includes a payload and a second message corresponding to the tunnel information. message header, the processor is configured to obtain multicast source group information according to the corresponding relationship and the tunnel information corresponding to the second message header, where the corresponding relationship includes the tunnel information and the multicast source group Information, obtain a first message according to the multicast source group information and the payload, the first message includes a first message header and the payload, the first message header includes the multicast source Group information, the first message does not include the second message header.
第六方面,本申请提供了一种通信系统,该通信系统用于报文的传输,包括:第三方面提供的设置于入口节点的网络设备,和第四方面提供的设置于出口节点的网络设备,该设置于入口节点的网络设备用于执行第一方面以及第一方面任一可能的实现方式中由所述第一设备所执行的部分或全部操作;所述设置于出口节点的网络设备用于执行第二方面以及第二方面任一可能的实现方式中由所述第二设备所执行的部分或全部操作。In a sixth aspect, this application provides a communication system used for message transmission, including: a network device provided at an entry node provided by the third aspect, and a network provided at an exit node provided by the fourth aspect. Equipment, the network equipment provided at the entry node is used to perform some or all of the operations performed by the first device in the first aspect and any possible implementation of the first aspect; the network equipment provided at the exit node For performing part or all of the operations performed by the second device in the second aspect and any possible implementation of the second aspect.
在一种可能实现的方式中,所述系统还包括,设置于中间节点的网络设备,用于接收设置于入口节点的网络设备转发的所述第二报文,并转发所述第二报文。In a possible implementation manner, the system further includes a network device provided at the intermediate node, configured to receive the second message forwarded by the network device provided at the entrance node, and forward the second message .
第七方面,本申请提供了一种计算机可读存储介质,所述计算机可读存储介质中存储有指令,当其在处理器上运行时,实现前述任一方面所述的方法以及前述任一方面的任一可能的实现方式中所包括的部分或全部操作。In a seventh aspect, the present application provides a computer-readable storage medium that stores instructions that, when run on a processor, implement the method described in any of the foregoing aspects and any of the foregoing aspects. Some or all of the operations included in any possible implementation of the aspect.
第八方面,本申请提供了一种计算机程序产品,所述计算机程序产品包含指令,当其在处理器上运行时,实现前述任一方面所述的方法以及前述任一方面的任一可能的实现方式中所包括的部分或全部操作。In an eighth aspect, the application provides a computer program product, which includes instructions that, when run on a processor, implement the method described in any of the foregoing aspects and any possible method of any of the foregoing aspects. Some or all of the operations included in the implementation.
第九方面,本申请提供了一种芯片,包括:接口电路和处理器。所述接口电路和所述处理器相连接,所述处理器用于使得所述芯片执行前述任一方面所述的方法以及前述任一方面的任一可能的实现方式中所包括的部分或全部操作。In a ninth aspect, this application provides a chip including: an interface circuit and a processor. The interface circuit is connected to the processor, and the processor is configured to cause the chip to perform some or all of the operations included in the method described in any of the foregoing aspects and any possible implementation of any of the foregoing aspects. .
附图说明Description of drawings
为了更清楚地说明本申请实施例的技术方案,下面将对本申请实施例的描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。In order to explain the technical solutions of the embodiments of the present application more clearly, the drawings needed to be used in the description of the embodiments of the present application will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present application. , for those of ordinary skill in the art, other drawings can also be obtained based on these drawings without exerting creative labor.
图1为本申请实施例提供的一种骨干网络结构示意图;Figure 1 is a schematic structural diagram of a backbone network provided by an embodiment of the present application;
图2为本申请实施例提供的一种网络架构的示意图;Figure 2 is a schematic diagram of a network architecture provided by an embodiment of the present application;
图3为本申请实施例提供的报文的传输方法的流程示意图;Figure 3 is a schematic flowchart of a message transmission method provided by an embodiment of the present application;
图4为本申请实施例提供的一种封装和解封装报文结构示意图;Figure 4 is a schematic structural diagram of an encapsulated and decapsulated message provided by an embodiment of the present application;
图5为本申请实施例提供的报文的另一种传输方法的流程示意图;Figure 5 is a schematic flow chart of another message transmission method provided by an embodiment of the present application;
图6为本申请实施例提供的另一种封装和解封装报文结构示意图;Figure 6 is a schematic structural diagram of another encapsulated and decapsulated message provided by an embodiment of the present application;
图7为本申请实施例提供的另一种封装和解封装报文结构示意图;Figure 7 is a schematic structural diagram of another encapsulation and decapsulation message provided by an embodiment of the present application;
图8为本申请实施例提供的另一种封装和解封装报文结构示意图;Figure 8 is a schematic structural diagram of another encapsulated and decapsulated message provided by an embodiment of the present application;
图9为本申请实施例提供的一种配置方法;Figure 9 is a configuration method provided by an embodiment of the present application;
图10为本申请实施例提供的另一种封装和解封装报文结构示意图;Figure 10 is a schematic structural diagram of another encapsulated and decapsulated message provided by an embodiment of the present application;
图11为本申请实施例提供的一种入口节点结构示意图;Figure 11 is a schematic structural diagram of an entry node provided by an embodiment of the present application;
图12为本申请实施例提供的一种出口节点结构示意图;Figure 12 is a schematic structural diagram of an exit node provided by an embodiment of the present application;
图13为本申请实施例提供的一种网络设备30的结构示意图;Figure 13 is a schematic structural diagram of a network device 30 provided by an embodiment of the present application;
图14为本申请实施例提供的一种网络设备40的结构示意图。FIG. 14 is a schematic structural diagram of a network device 40 provided by an embodiment of the present application.
具体实施方式Detailed ways
为了使本技术领域的人员更好地理解本申请中的方案,下面将结合本申请实施例中的 附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅是本申请一部分实施例,而不是全部的实施例。In order to enable those skilled in the art to better understand the solutions in this application, the following will be combined with the examples in this application The accompanying drawings clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only some of the embodiments of the present application, rather than all of the embodiments.
本文中术语“和/或”,仅仅是一种描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况。The term "and/or" in this article is just an association relationship that describes related objects, indicating that three relationships can exist. For example, A and/or B can mean: A exists alone, A and B exist simultaneously, and they exist alone. B these three situations.
本申请实施例的说明书和权利要求书中的术语“第一”和“第二”等是用于区别不同的对象,而不是用于描述对象的特定顺序。例如,第一目标对象和第二目标对象等是用于区别不同的目标对象,而不是用于描述目标对象的特定顺序。The terms “first” and “second” in the description and claims of the embodiments of this application are used to distinguish different objects, rather than to describe a specific order of objects. For example, the first target object, the second target object, etc. are used to distinguish different target objects, rather than to describe a specific order of the target objects.
在本申请实施例中,“示例性的”或者“例如”等词用于表示作例子、例证或说明。本申请实施例中被描述为“示例性的”或者“例如”的任何实施例或设计方案不应被解释为比其它实施例或设计方案更优选或更具优势。确切而言,使用“示例性的”或者“例如”等词旨在以具体方式呈现相关概念。In the embodiments of this application, words such as "exemplary" or "for example" are used to represent examples, illustrations or explanations. Any embodiment or design described as "exemplary" or "such as" in the embodiments of the present application is not to be construed as preferred or advantageous over other embodiments or designs. Rather, use of the words "exemplary" or "such as" is intended to present the concept in a concrete manner.
在本申请实施例的描述中,除非另有说明,“多个”的含义是指两个或两个以上。例如,多个处理单元是指两个或两个以上的处理单元;多个系统是指两个或两个以上的系统。In the description of the embodiments of this application, unless otherwise specified, the meaning of “plurality” refers to two or more. For example, multiple processing units refer to two or more processing units; multiple systems refer to two or more systems.
为了便于理解,下面先对本申请实施例所使用到的相关名词或术语进行解释说明:In order to facilitate understanding, the relevant nouns or terms used in the embodiments of this application are explained below:
1、组播技术1. Multicast technology
一种在网络中能够实现点到多点的高效传送的技术,通过组播技术能有效地节约网络带宽、降低数据传播的网络负载。A technology that can achieve efficient point-to-multipoint transmission in the network. Multicast technology can effectively save network bandwidth and reduce the network load of data transmission.
2、指定源模式协议无关组播(Protocol Independent Multicast-Source-Specific Multicast,PIM-SSM)2. Specified source mode protocol independent multicast (Protocol Independent Multicast-Source-Specific Multicast, PIM-SSM)
PIM-SSM是对传统PIM协议的扩展,支持从组播源接收组播业务流,SSM代表特定源的组播服务,在SSM中,仅接收者所请求的特定源的组播报文能转发给接收者,使得组播接收者在加入组播源时,可以指定接收或者拒绝来自特定组播源的流量。PIM-SSM is an extension of the traditional PIM protocol and supports receiving multicast service flows from multicast sources. SSM represents the multicast service of a specific source. In SSM, only the multicast packets of the specific source requested by the receiver can be forwarded. To the receiver, the multicast receiver can specify to receive or reject traffic from a specific multicast source when joining the multicast source.
3、隧道(Tunnel)3. Tunnel
隧道技术是一种通过使用互联网络的基础设施在网络之间传递数据的方式,包括数据封装,传输和解封装的全过程。被封装的数据在网络上传递时所经过的逻辑路径称为隧道。Tunneling technology is a way of transmitting data between networks by using the Internet infrastructure, including the entire process of data encapsulation, transmission and decapsulation. The logical path that encapsulated data takes when transmitted over the network is called a tunnel.
4、GRE4. GRE
GRE协议是对网络层协议(如IPv4和IPv6)的数据报文进行封装,使这些被封装的数据报文能够在如IP的网络层协议中传输,GRE采用了隧道技术,根据传输协议的不同,可以分为GRE over IPv4和GRE over IPv6两种隧道模式。The GRE protocol encapsulates data packets of network layer protocols (such as IPv4 and IPv6) so that these encapsulated data packets can be transmitted in network layer protocols such as IP. GRE uses tunneling technology. Depending on the transmission protocol, , can be divided into two tunnel modes: GRE over IPv4 and GRE over IPv6.
5、MPLS5. MPLS
MPLS是一种适用于网络如本申请中的骨干网络的隧道技术,可以在骨干网络上进行标签交换,MPLS能够支持多种网络协议,如IPv4、IPv6、互联网分组交换(Internet Packet Exchange,IPX)协议和无连接网络协议(ConnectionLess Network Protocol,CLNP)等。MPLS is a tunnel technology suitable for networks such as the backbone network in this application. It can perform label switching on the backbone network. MPLS can support multiple network protocols, such as IPv4, IPv6, and Internet Packet Exchange (IPX). protocol and connectionless network protocol (ConnectionLess Network Protocol, CLNP), etc.
6、BIER6.BIER
是一种基于位索引显式复制的新型组播技术,在入口节点和出口节点之间采用BIER组播隧道的场景中,骨干网络相当于BIER域,通常BIER域中包括三种角色的路由器:接收组播报文的入口路由器为位转发入口路由器(Bit Forwarding Ingress Router,BFIR),离开BIER域的最后一跳路由器为位转发出口路由器(Bit Forwarding Engress Router,BFER),其他中间路由器统称为位转发路由器(Bit Forwarding Router,BFR),其中, BFIR和BFER属于边缘BFR。例如,对应于本申请实施例提供的骨干网络,BFIR设置于入口节点位置,BFER设置于出口节点位置,BFR设置于中间节点位置。采用BIER组播隧道的场景中,组播报文传输是一种无状态的组播转发,由于BFR没有任何组播信息,因此不需要维护组播状态,也不需要建立组播转发树,依靠转发表和组播报文中的比特串(Bit String)来复制和转发。It is a new multicast technology based on bit index explicit replication. In the scenario where BIER multicast tunnel is used between the entry node and the exit node, the backbone network is equivalent to the BIER domain. Usually, the BIER domain includes routers with three roles: The ingress router that receives multicast packets is the Bit Forwarding Ingress Router (BFIR), the last hop router leaving the BIER domain is the Bit Forwarding Egress Router (BFER), and other intermediate routers are collectively called Bit Forwarding Egress Router (BFER). Bit Forwarding Router (BFR), where, BFIR and BFER belong to edge BFR. For example, corresponding to the backbone network provided by the embodiment of the present application, BFIR is set at the entrance node position, BFER is set at the exit node position, and BFR is set at the intermediate node position. In the scenario where BIER multicast tunnel is used, multicast packet transmission is a kind of stateless multicast forwarding. Since BFR does not have any multicast information, there is no need to maintain the multicast status or establish a multicast forwarding tree. Relying on The bit string in the forwarding table and multicast message is copied and forwarded.
7、比特串(BitString)7. BitString
BitString中的bit用来对应BFER的标识,由于BIER域的每个边缘BFR配置有BIER转发路由器标识符(BIER Forwarding Router Identifier,BFR-ID),BFR-ID取值范围为1到65535内的整数,因此,位转发出口路由器的BFR-ID组成的BitString就形成了出口节点集合,BitString中的每个Bit所在的位置或索引用于确定BFER。The bits in BitString are used to correspond to the identification of BFER. Since each edge BFR of the BIER domain is configured with a BIER Forwarding Router Identifier (BFR-ID), the BFR-ID value range is an integer from 1 to 65535. , therefore, the BitString composed of the BFR-ID of the bit forwarding egress router forms the egress node set, and the position or index of each Bit in the BitString is used to determine the BFER.
8、基于IPv6封装的比特位索引显式复制(Bit Index Explicit Replication IPv6 encapsulation,BIERv6)8. Bit Index Explicit Replication IPv6 encapsulation (BIERv6) based on IPv6 encapsulation
BIERv6是一种新型组播技术,在入口节点和出口节点之间采用BIERv6隧道的场景中,骨干网络通过将出口节点的集合以比特串的方式封装报文中发送给中间节点,中间节点不需要维护组播状态,也无需建立组播分发树,而是根据报文携带的比特串匹配转发表来完成复制和转发。BIERv6 is a new multicast technology. In the scenario where BIERv6 tunnel is used between the ingress node and the egress node, the backbone network encapsulates the set of egress nodes in a message in the form of a bit string and sends it to the intermediate node. The intermediate node does not need To maintain multicast status, there is no need to build a multicast distribution tree. Instead, copying and forwarding are completed based on the bit strings carried in the packets matching the forwarding table.
9、IPv6扩展头9. IPv6 extension header
IPv6扩展头是可选报头,IPv6扩展头包括路由头(Routing Header,RH),目的选项头(Destination Options Header,DOH)等。The IPv6 extension header is an optional header. The IPv6 extension header includes the routing header (Routing Header, RH), the destination options header (Destination Options Header, DOH), etc.
本申请实施例可以适用于组播网络,该网络包括用户网络和骨干网络,其中,用户网络可以是运行IPv6或IPv4的网络,骨干网络可以是运行MVPN或EVPN的网络。本申请实施例提供的骨干网络可以采用不同的隧道进行报文传输,一个骨干网络可以支持采用一种或多种隧道,在这种网络架构下,用户网络中的组播报文,在进入骨干网络时,可以根据骨干网络采用的隧道对应的封装方式进行封装,报文在离开骨干网络时,以该封装对应的方式进行解封装。图1为本申请实施例提供的一种骨干网络结构示意图,如图1所示,该骨干网络包括设置于入口节点的网络设备100,简记为入口节点100、设置于中间节点的网络设备200,简记为中间节点200和设置于出口节点的网络设备300,简记为出口节点300,其中,入口节点100收到用户网络发送的报文后对该报文进行封装,发送至中间节点200,由中间节点200转发或复制转发后,发送至出口节点300,再由出口节点300对该报文解封装,将解封装后的报文发送给用户网络。在一些实例中,骨干网络采用不同的隧道对应的场景时,分别支持多种封装方式,如支持IP+GRE封装方式、IP封装方式、MPLS封装方式等,随着无状态组播的提出,骨干网络还可以支持使用BIER封装(RFC8279、RFC8296、RFC8556)或者使用BIERv6封装的方式。举例来说,入口节点100可以用IP+GRE的方式对接收到的报文进行封装,报文被封装有IP头+GRE头;或者使用IP进行封装,报文被封装有IP头;或者使用MPLS的方式进行封装,报文被封装有MPLS头。但是入口节点100对报文进行封装后,报文在骨干网络中传输的开销会增大,这会对网络带宽造成一定的压力。如,用户网络中的组播业务是基于IPv6的组播业务,从用户网络中接收到的组播报文属于IPv6报文,入口节点100接收到该IPv6报文后,根据骨干网络采用的隧道为IP隧道,确定使用IPv6封装的方式对接收到的报文进行封装, 即在IPv6报文上封装一个IPv6头,因此,该组播报文封装有两个IPv6头,共会占用80字节,相当于进入骨干网络后增加了40字节的传输开销;再如,入口节点100收到的组播报文属于IPv6报文,根据骨干网络采用的隧道为IP隧道,支持IPv6+扩展头的封装方式,因此需要再在该IPv6报文上封装IPv6头+扩展头,其中,扩展头可以是DOH,封装后的IPv6报文的头部长度可达128字节,相当于增加了84字节的传输开销。为了减少报文在骨干网络中的传输开销,在一些实例中,入口节点会将接收到的组播报文中的源地址和目的地址删除,但这种方法会使得组播报文不符合规范格式、容易出现报文错误的问题难以定位、影响方案的部署和使用等问题。因此,本申请实施例提供了一种报文的传输方法,能够在报文格式符合规范的基础上,有效减小骨干网络中报文传输的开销,解决带宽浪费的问题。图2为本申请实施例提供的一种网络架构的示意图,如图2所示,网络架构中包括骨干网络和用户网络,其中,骨干网络中包括入口节点1000、中间节点(包括中间节点2001和中间节点2002)、出口节点(包括出口节点1图2中标为3001、出口节点2图2中标为3002和出口节点3图2中标为3003),用户网络包括用户边缘(Customer Edge,CE)设备(包括CE设备1图2中标为4001、CE设备2图2中标为4002和CE设备3图2中标为4003),用户网络还可以包括连接各CE设备的服务器。在图2提供的网络架构场景中,以CE1向骨干网络发送的报文是封装有IP头的组播报文为例进行说明,入口节点1000对CE设备1发送的组播报文进行封装,同时将组播报文的IP头删除,入口节点1000转发封装后的报文,该封装后的报文经过中间节点2001和中间节点2002转发,最后可以由出口节点1解封装,并封装IP头,得到组播报文,再向用户网络中组播报文的组播地址对应的CE设备发送,如向CE设备2发送。进一步地,若入口节点1000接收到的组播报文中,组播报文的目的地址为组播组地址1,且CE设备2和CE设备3均加入到该组播组地址中,则可以如图2所示,由出口节点1根据组播报文的目的地址,向CE设备2发送组播报文,由出口节点3根据组播报文的目的地址,向CE设备3发送组播报文。本申请实施例提供的方法,可以适用于图2提供的场景,但不以此为限定。The embodiments of the present application may be applied to a multicast network, which includes a user network and a backbone network. The user network may be a network running IPv6 or IPv4, and the backbone network may be a network running MVPN or EVPN. The backbone network provided by the embodiments of this application can use different tunnels for packet transmission. A backbone network can support the use of one or more tunnels. Under this network architecture, multicast packets in the user network enter the backbone. When the packet is connected to the network, it can be encapsulated according to the encapsulation method corresponding to the tunnel used by the backbone network. When the packet leaves the backbone network, it can be decapsulated in the method corresponding to the encapsulation. Figure 1 is a schematic structural diagram of a backbone network provided by an embodiment of the present application. As shown in Figure 1, the backbone network includes a network device 100 disposed at an entry node, abbreviated as the entry node 100, and a network device 200 disposed at an intermediate node. , abbreviated as the intermediate node 200 and the network device 300 set at the egress node, abbreviated as the egress node 300, wherein the entry node 100 receives the message sent by the user network and encapsulates the message, and sends it to the intermediate node 200 , after being forwarded or copied and forwarded by the intermediate node 200, it is sent to the egress node 300, and then the egress node 300 decapsulates the message and sends the decapsulated message to the user network. In some instances, when the backbone network uses different tunnel corresponding scenarios, it supports multiple encapsulation methods, such as IP+GRE encapsulation, IP encapsulation, MPLS encapsulation, etc. With the introduction of stateless multicast, the backbone network The network can also support the use of BIER encapsulation (RFC8279, RFC8296, RFC8556) or the use of BIERv6 encapsulation. For example, the entry node 100 can encapsulate the received message using IP+GRE, and the message is encapsulated with an IP header+GRE header; or use IP for encapsulation, and the message is encapsulated with an IP header; or use It is encapsulated in MPLS mode, and the packet is encapsulated with an MPLS header. However, after the entry node 100 encapsulates the message, the overhead of transmitting the message in the backbone network will increase, which will put certain pressure on the network bandwidth. For example, the multicast service in the user network is based on IPv6, and the multicast packet received from the user network is an IPv6 packet. After the entrance node 100 receives the IPv6 packet, it will For IP tunnels, determine to use IPv6 encapsulation method to encapsulate the received packets. That is, an IPv6 header is encapsulated on the IPv6 message. Therefore, the multicast message is encapsulated with two IPv6 headers, which will occupy a total of 80 bytes, which is equivalent to adding 40 bytes of transmission overhead after entering the backbone network; for another example, The multicast message received by the entrance node 100 is an IPv6 message. According to the tunnel adopted by the backbone network, it is an IP tunnel and supports the IPv6 + extension header encapsulation method. Therefore, the IPv6 header + extension header needs to be encapsulated on the IPv6 message, where , the extension header can be DOH, and the header length of the encapsulated IPv6 message can reach 128 bytes, which is equivalent to an increase of 84 bytes of transmission overhead. In order to reduce the transmission overhead of packets in the backbone network, in some instances, the entrance node will delete the source address and destination address in the received multicast packet. However, this method will make the multicast packet not conform to the standard format. Problems that are prone to message errors are difficult to locate and affect the deployment and use of the solution. Therefore, embodiments of the present application provide a message transmission method, which can effectively reduce the message transmission overhead in the backbone network and solve the problem of bandwidth waste on the basis that the message format conforms to the specifications. Figure 2 is a schematic diagram of a network architecture provided by an embodiment of the present application. As shown in Figure 2, the network architecture includes a backbone network and a user network. The backbone network includes an entrance node 1000, intermediate nodes (including intermediate nodes 2001 and Intermediate node 2002), exit node (including exit node 1 marked as 3001 in Figure 2, exit node 2 marked as 3002 in Figure 2, and exit node 3 marked as 3003 in Figure 2), the user network includes Customer Edge (CE) equipment ( Including CE device 1 marked as 4001 in Figure 2, CE device 2 marked as 4002 in Figure 2, and CE device 3 marked as 4003 in Figure 2), the user network may also include a server connected to each CE device. In the network architecture scenario provided in Figure 2, the packet sent by CE1 to the backbone network is a multicast packet encapsulated with an IP header as an example. The entry node 1000 encapsulates the multicast packet sent by CE device 1. At the same time, the IP header of the multicast message is deleted. The ingress node 1000 forwards the encapsulated message. The encapsulated message is forwarded by the intermediate node 2001 and the intermediate node 2002. Finally, it can be decapsulated by the egress node 1 and encapsulate the IP header. , obtain the multicast message, and then send it to the CE device corresponding to the multicast address of the multicast message in the user network, such as sending it to CE device 2. Further, if the destination address of the multicast message received by the entrance node 1000 is multicast group address 1, and both CE device 2 and CE device 3 are added to the multicast group address, then the following figure can be used: As shown in 2, egress node 1 sends a multicast message to CE device 2 according to the destination address of the multicast message, and egress node 3 sends a multicast message to CE device 3 according to the destination address of the multicast message. The method provided by the embodiment of the present application can be applied to the scenario provided in Figure 2, but is not limited thereto.
图3为本申请实施例提供的报文的传输方法的流程示意图,如图3所示,该方法包括:Figure 3 is a schematic flowchart of a message transmission method provided by an embodiment of the present application. As shown in Figure 3, the method includes:
S101、入口节点接收用户边缘设备发送的第一报文,第一报文包含第一报文头和载荷,第一报文头包括组播源组信息。S101. The entry node receives a first message sent by the user edge device. The first message includes a first message header and a payload, and the first message header includes multicast source group information.
第一报文是包括组播源组信息的组播报文,其组播源组信息包括组播报文中的源地址S和目的地址,该目的地址是组播组地址,记作G,组播源组信息记作(S,G)。以图2所示场景为例,入口节点1000可以用于接收CE设备1发送的组播报文,该报文可以记作第一报文。入口节点1000接收到的第一报文中的第一报文头可以属于IPv6头或IPv4头,举例来说,第一报文头属于IPv6头,即C-IP Header属于IPv6,表1为IPv6头各字段的示意。
The first message is a multicast message including multicast source group information. The multicast source group information includes the source address S and the destination address in the multicast message. The destination address is the multicast group address, denoted as G, multicast The source group information is denoted as (S, G). Taking the scenario shown in Figure 2 as an example, the entrance node 1000 can be used to receive the multicast message sent by the CE device 1, and this message can be recorded as the first message. The first header in the first message received by the entrance node 1000 may belong to the IPv6 header or the IPv4 header. For example, the first message header belongs to the IPv6 header, that is, the C-IP Header belongs to IPv6. Table 1 shows IPv6. An illustration of each header field.
表1 Table 1
如表1所示,IPv6头包括如下部分:As shown in Table 1, the IPv6 header includes the following parts:
版本号(Version,Ver):IPv6的版本号为6,Ver占4比特(bit);Version number (Version, Ver): The version number of IPv6 is 6, and Ver occupies 4 bits;
传输类型(Traffic Class,TC):用于区分不同的IPv6报文的类别和优先级,TC占8比特(bit);Transmission type (Traffic Class, TC): used to distinguish the types and priorities of different IPv6 messages, TC accounts for 8 bits;
流标识(Flow Label,FL):一条“流”标识源地址到目的地址的报文,从A源地址到B目的地址的“流”为同一条“流”其报文的流标识相同,FL占20比特(bit);Flow Label (FL): A "flow" identifies the packet from the source address to the destination address. The "flow" from source address A to destination address B is the same "flow" and its packets have the same flow label, FL. Occupies 20 bits;
载荷长度(Payload Length,PL):用于标识报文中除IPv6头之外的其他部分的长度,如果报文封装有扩展头,则PL标识的长度为扩展头加载荷长度,PL占16比特(bit)。Payload Length (PL): used to identify the length of other parts of the message except the IPv6 header. If the message is encapsulated with an extension header, the length of the PL identifier is the length of the extension header plus the payload. PL occupies 16 bits. (bit).
下一个头部(Next Header,NH):可以指示紧跟在本IPv6头后的下一个头部字段,用于说明IPv6头之后其他扩展头的存在和类型,NH占8比特(bit);Next Header (NH): It can indicate the next header field immediately following this IPv6 header and is used to describe the existence and type of other extension headers after the IPv6 header. NH occupies 8 bits;
跳数极限(Hop Limit,HL):用于设置报文可以经过的路由器数量的上限,可以初始化为一个值,每台路由器在转发报文时将该值减1,减到0则到达极限,丢弃报文,HL占8比特(bit);Hop Limit (HL): used to set the upper limit of the number of routers that packets can pass through. It can be initialized to a value. Each router reduces the value by 1 when forwarding packets. When it is reduced to 0, the limit is reached. Discard the message, HL occupies 8 bits;
源地址(Source Address,SA):承载有发送IPv6报文的用户设备的地址,SA占128比特(bit);Source Address (SA): carries the address of the user equipment sending IPv6 messages, SA occupies 128 bits;
目的地址(Destination Address,DA):承载有接收IPv6报文的用户设备的地址,DA占128比特(bit)。Destination Address (DA): carries the address of the user equipment that receives IPv6 messages. DA occupies 128 bits.
举例来说,第一报文头属于IPv4头,即C-IP Header属于IPv4。表2为IPv4头各字段的示意,如表2所示,IPv4头包括如下部分:
For example, the first packet header belongs to the IPv4 header, that is, the C-IP Header belongs to IPv4. Table 2 shows the fields of the IPv4 header. As shown in Table 2, the IPv4 header includes the following parts:
表2Table 2
如表2所示,IPv4头包括如下部分:As shown in Table 2, the IPv4 header includes the following parts:
版本号(version,Ver):IPv4的版本号为4,设置为0100,Ver占4比特(bit);Version number (version, Ver): The version number of IPv4 is 4, set to 0100, Ver accounts for 4 bits;
报头长度(Internet Header Length,IHL):IHL用来标识IPv4头的长度,以32比特位为单位,最多可以有15个32位字,且有效报头的最小值为5,IHL占4比特(bit);Header length (Internet Header Length, IHL): IHL is used to identify the length of the IPv4 header, in 32-bit units. It can have up to 15 32-bit words, and the minimum value of a valid header is 5. IHL occupies 4 bits. );
服务类型(Type of Service,TOS):该字段的前6位被为区分服务字段,后2位是显示拥塞通知字段或指示位,用于表示服务质量,TOS占8比特(bit);Type of Service (TOS): The first 6 bits of this field are the differentiated service field, and the last 2 bits are the congestion notification field or indication bit, used to indicate the quality of service, and TOS occupies 8 bits;
总长度(Total Length):用于标识报文的总长度,单位为字节,通过这个总长度字段和IHL字段,可以确定报文的数据部分的开始位置及长度,进而确定数据部分的起始和结束位置,总长度占16比特(bit); Total Length: Used to identify the total length of the message, in bytes. Through the total length field and the IHL field, the starting position and length of the data part of the message can be determined, and then the start of the data part can be determined. and the end position, the total length accounts for 16 bits (bit);
标识符(Identifier),用于识别分段所属的组,同一组的分段标识符相同,标识符占16比特(bit);Identifier is used to identify the group to which the segment belongs. Segment identifiers in the same group are the same, and the identifier occupies 16 bits;
标志(Flags):表示分片相关信息,标志占3比特(bit);Flags: Represents fragmentation-related information, and flags occupy 3 bits;
分段偏移(Fragment Offset,FO)用来重排序,用于标识被分片的每个分段相对于原始数据的位置,FO占13比特(bit);Fragment Offset (FO) is used for reordering and identifying the position of each fragment being fragmented relative to the original data. FO occupies 13 bits;
生存时间(Time to Live,TTL)用于标识最大存活时间,报文每经过一台路由器则TTL字段减去1,直到为0被丢弃。通常以跳数为衡量单位,TTL占8比特(bit);Time to Live (TTL) is used to identify the maximum survival time. Each time a packet passes through a router, the TTL field is subtracted by 1 until it reaches 0 and is discarded. Usually measured in hops, TTL accounts for 8 bits;
协议(Protocol),用来标识IP层所封装的上层协议类型,协议占8比特(bit);Protocol is used to identify the upper layer protocol type encapsulated by the IP layer. The protocol occupies 8 bits;
报头校验和(Header Checksum),该字段根据IP头计算得到的校验和码,用于首部查错,不对数据部分进行校验,报头校验和占16比特(bit);Header Checksum (Header Checksum), this field is a checksum code calculated based on the IP header. It is used for header error checking. The data part is not checked. The header checksum occupies 16 bits;
源地址(Source Address,SA):承载有发送IPv4报文的用户设备的地址,SA占32比特(bit);Source Address (SA): carries the address of the user device that sends IPv4 messages, SA occupies 32 bits;
目的地址(Destination Address,DA):承载有接收IPv4报文的用户设备的地址,DA占128比特(bit);Destination Address (DA): carries the address of the user equipment that receives IPv4 messages. DA occupies 128 bits;
可选字段(options)用于提供一些控制功能,可选字段长度可变;Optional fields (options) are used to provide some control functions, and the length of optional fields is variable;
填充(padding)在具有可选字段的情况下,头部长度可能不是32比特(bit)的整数倍,通过在填充字段填入0,补齐32比特(bit)。Padding: In the case of optional fields, the header length may not be an integer multiple of 32 bits. The 32 bits are padded by filling in 0 in the padding field.
IPv4头中的各字段可以如表2所示,也可以没有可选字段和填充字段,不以表2举例为限定。Each field in the IPv4 header may be as shown in Table 2, or there may be no optional fields and padding fields. Table 2 is not used as an example.
S102、入口节点根据组播源组信息和对应关系,获取隧道信息,对应关系包括组播源组信息和隧道信息。S102. The entrance node obtains tunnel information according to the multicast source group information and the corresponding relationship. The corresponding relationship includes the multicast source group information and tunnel information.
其中,隧道信息包括指示报文在骨干网络中传播的隧道的信息,隧道信息在骨干网络采用不同的隧道时,以对应的形式表示在第二报文头中。The tunnel information includes information indicating the tunnel through which the message is propagated in the backbone network. When the backbone network uses different tunnels, the tunnel information is expressed in the second message header in a corresponding form.
在一些实例中,入口节点建立对应关系,回到图2场景中,若入口节点1000接收到CE设备1发送的第一报文,该第一报文头中包括组播源组信息(S1,G1),其中,组播源组信息中的源地址对应CE设备1或者连接CE设备1的服务器的地址,记作S1,组播源组信息中的组地址记作G1,CE设备2和CE设备3均加入了该组播组;或者,若入口节点1000接收到CE设备1发送的第一报文,该第一报文头中包括的组播源组信息是(S1,G2),其中,组播源组信息中的源地址对应CE设备1或者连接CE设备1的服务器的地址,记作S1,组播源组信息中的组地址为G2,CE设备2加入了该组播组,以上是适用于图2场景的举例,但本申请实施例不以图2所示的CE设备为限定,如一些其他的场景中,在基于图2所示的CE设备2和CE设备3上,用户网络中还可以设置有CE设备4、CE设备5等CE设备,入口节点接收到CE设备1发送的第一报文中,第一报文头的组播源组信息是组播源组信息(S1,G3),其中,S1表示组播源组信息中的源地址为CE设备1或者连接CE设备1的服务器的地址,组播源组信息中的组地址为G3,CE设备3和CE设备4均加入了该组播组。从上述举例可以获知,组播源组信息中的组地址G1、G2和G3分别表示不同CE设备加入组播组得到的组播地址。In some examples, the entry node establishes a corresponding relationship. Returning to the scenario in Figure 2, if the entry node 1000 receives the first message sent by CE device 1, the first message header includes multicast source group information (S1, G1), where the source address in the multicast source group information corresponds to the address of CE device 1 or the server connected to CE device 1, denoted as S1, the group address in the multicast source group information is denoted as G1, CE device 2 and CE Device 3 has all joined the multicast group; or, if the entrance node 1000 receives the first message sent by CE device 1, the multicast source group information included in the first message header is (S1, G2), where , the source address in the multicast source group information corresponds to the address of CE device 1 or the server connected to CE device 1, denoted as S1, the group address in the multicast source group information is G2, and CE device 2 has joined the multicast group. The above are examples applicable to the scenario in Figure 2, but the embodiment of the present application is not limited to the CE device shown in Figure 2. For example, in some other scenarios, based on the CE device 2 and CE device 3 shown in Figure 2, The user network may also be equipped with CE devices such as CE device 4 and CE device 5. When the entry node receives the first message sent by CE device 1, the multicast source group information in the first message header is the multicast source group information. (S1, G3), where S1 indicates that the source address in the multicast source group information is CE device 1 or the address of the server connected to CE device 1, the group address in the multicast source group information is G3, CE device 3 and CE Device 4 has joined the multicast group. From the above example, we can know that the group addresses G1, G2, and G3 in the multicast source group information respectively represent the multicast addresses obtained by different CE devices joining the multicast group.
S103、入口节点根据载荷和隧道信息获得第二报文,第二报文包含载荷和与隧道信息对应的第二报文头,第二报文不包括第一报文头。 S103. The entrance node obtains a second message according to the payload and tunnel information. The second message includes the payload and the second message header corresponding to the tunnel information. The second message does not include the first message header.
基于对应关系确定的隧道信息对应第二报文头,在入口节点和出口节点之间采用不同的隧道对应的场景时,隧道信息与第二报文头可以对应不同的表示方式,如在入口节点和出口节点之间采用IP组播隧道的场景中,如入口节点可以基于IPv6封装,得到的第二报文头包括IPv6头,IPv6头包括与隧道信息对应的源地址和目的地址,其中,目的地址是组播树对应的组播组地址。这种情况下,入口节点建立组播源组信息(S1,G1)与IPv6头中隧道信息(S,D)的对应关系,记作第一对应关系,其中,组播源组信息(S1,G1)参照上例,在此不再展开赘述,隧道信息(S,D),参照图2场景,隧道信息中源地址S对应入口节点,可以记作S-P1,隧道信息的的目的地址D是组播组地址,可以记作D-P1,出口节点1、出口节点2和出口节点3均加入了D-P1对应的组播组,这种情况下,隧道信息可以记作(S-P1,D-P1),或者,源地址对应入口节点,记作S-P1,组地址记作D-P2,出口节点1和出口节点2均加入了D-P2对应的组播组,这种情况下,隧道信息可以记作(S-P1,D-P2),以上是适用于图2场景的举例,但本申请实施例不以图2所示的入口节点和出口节点设置为限定,如基于图2所示的入口节点外,骨干网络中还可以设置有其他的入口节点,这种情况下,隧道信息中源地址对应这个入口节点,可以记作S-P2,组地址记作D-P2,出口节点1和出口节点2加入了D-P2对应的组播组,这种情况下,隧道信息可以记作(S-P2,D-P2)。The tunnel information determined based on the correspondence relationship corresponds to the second packet header. When different tunnel correspondences are used between the ingress node and the egress node, the tunnel information and the second packet header can correspond to different representation methods. For example, at the ingress node In the scenario where an IP multicast tunnel is used between the ingress node and the egress node, for example, the ingress node can be encapsulated based on IPv6. The obtained second message header includes an IPv6 header, and the IPv6 header includes the source address and destination address corresponding to the tunnel information, where the destination The address is the multicast group address corresponding to the multicast tree. In this case, the entry node establishes a corresponding relationship between the multicast source group information (S1, G1) and the tunnel information (S, D) in the IPv6 header, which is recorded as the first corresponding relationship, where the multicast source group information (S1, G1) Refer to the above example, which will not be elaborated here. Tunnel information (S, D), refer to the scene in Figure 2. The source address S in the tunnel information corresponds to the entry node, which can be recorded as S-P1, and the destination address D of the tunnel information. is the multicast group address, which can be recorded as D-P1. Exit node 1, exit node 2 and exit node 3 have all joined the multicast group corresponding to D-P1. In this case, the tunnel information can be recorded as (S-P1 , D-P1), or the source address corresponds to the ingress node, recorded as S-P1, and the group address is recorded as D-P2. Both egress node 1 and egress node 2 have joined the multicast group corresponding to D-P2. In this case Under, the tunnel information can be recorded as (S-P1, D-P2). The above are examples applicable to the scenario in Figure 2. However, the embodiment of the present application is not limited to the entry node and exit node settings shown in Figure 2. For example, based on In addition to the entry node shown in Figure 2, other entry nodes can be set up in the backbone network. In this case, the source address in the tunnel information corresponds to this entry node, which can be recorded as S-P2, and the group address is recorded as D-P2. , egress node 1 and egress node 2 join the multicast group corresponding to D-P2. In this case, the tunnel information can be recorded as (S-P2, D-P2).
对应关系的一种示例,如第一对应关系的一种示例可以如表3所示:
An example of the corresponding relationship, such as an example of the first corresponding relationship, can be shown in Table 3:
表3table 3
入口节点如果根据第一报文得到的组播源组信息是(S1,G1),则根据第一对应关系,获取的隧道信息是(S-P1,D-P1),第二报文包括与(S-P1,D-P1)对应的第二报文头。如果根据第一报文得到的组播源组信息是(S1,G3),则根据第一对应关系,获取的隧道信息是(S-P2,D-P2),第二报文包括与(S-P2,D-P2)对应的第二报文头。表3是适应上述场景中的一种第一对应关系的举例,具体实施方案并不限定于使用表3。If the multicast source group information obtained by the entrance node according to the first message is (S1, G1), then the tunnel information obtained according to the first correspondence is (S-P1, D-P1), and the second message includes (S-P1, D-P1) corresponding second message header. If the multicast source group information obtained according to the first message is (S1, G3), then the tunnel information obtained according to the first correspondence is (S-P2, D-P2), and the second message includes the same as (S -P2, D-P2) corresponding second message header. Table 3 is an example of a first correspondence relationship adapted to the above scenario, and the specific implementation is not limited to the use of Table 3.
在入口节点和出口节点之间采用BIERv6组播隧道的的场景中,第二报文头是BIERv6头,BIERv6头包括与隧道信息对应的源地址和目的地址,其中,目的地址是单播地址,或者,BIERv6头可以只包括与隧道信息对应的源地址,不包括目的地址。入口节点建立组播源组信息(S,G)与BIERv6头中隧道信息的对应关系,记作第二对应关系,举例来说,BIERv6头包括与隧道信息对应的源地址和目的地址,该目的地址是单播地址时,可以是入口节点在组播树的下一跳的地址,入口节点的下一跳是中间节点时,该单播地址在报文发送到中间节点,由中间节点根据组播树的下一跳的地址进行更改,直至中间节点向出口节点发送的时,单播地址被更改为出口节点对应的地址。在这种情况下,该隧道信息在报文的传输中可以改变,如入口节点根据组播源组信息(S1,G1)和第二对应关系,获取的 隧道信息是(S-P1,D-P1),该隧道信息可以记作第一隧道信息,入口节点根据第一隧道信息(S-P1,D-P1)获得第二报文,第二报文头包括与第一隧道信息对应的源地址S-P1和目的地址D-P1,其中,目的地址D-P1是入口节点在组播树下一跳对应的中间节点的地址,第二报文由下一跳的中间节点接收后,中间节点根据其在组播树的下一跳的地址,假设中间节点的下一跳是一个出口节点,则根据该出口节点的地址得到目的地址,获得一个新的隧道信息,可以记作第二隧道信息,中间节点根据第二隧道信息更新第二报文头中与第二隧道信息对应的目的地址,得到第三报文,中间节点向出口节点发送第三报文,由出口节点接收第三报文后,解封装。再举例来说,第二报文头是BIERv6头,优选地,入口节点建立的第二对应关系包括组播源组信息(S1,G1)与BIERv6头中隧道信息源地址,即BIERv6头只包括与隧道信息对应的源地址,不包括目的地址时,由于BIERv6头不包括目的地址,无需中间节点更改目的地址,中间节点只转发第二报文即可,同理,出口节点上建立的第二对应关系与入口节点相同,包括组播源组信息(S1,G1)与BIERv6头中隧道信息源地址,如S-P1。进一步地,出口节点接收到第二报文后,根据BIERv6头中隧道信息源地址S-P1和第二对应关系,得到组播源组信息(S1,G1),再根据组播源组信息(S1,G1)封装第一报文头,删除BIERv6头得到第一报文。In the scenario where a BIERv6 multicast tunnel is used between the ingress node and the egress node, the second packet header is the BIERv6 header. The BIERv6 header includes the source address and destination address corresponding to the tunnel information, where the destination address is a unicast address. Alternatively, the BIERv6 header may only include the source address corresponding to the tunnel information, but not the destination address. The entry node establishes a corresponding relationship between the multicast source group information (S, G) and the tunnel information in the BIERv6 header, which is recorded as the second correspondence. For example, the BIERv6 header includes the source address and destination address corresponding to the tunnel information. The destination When the address is a unicast address, it can be the next hop address of the entry node in the multicast tree. When the next hop of the entry node is an intermediate node, the unicast address is sent to the intermediate node in the message, and the intermediate node determines the address according to the group. The address of the next hop of the broadcast tree is changed until the intermediate node sends the unicast address to the exit node, and the unicast address is changed to the address corresponding to the exit node. In this case, the tunnel information may change during the transmission of the message. For example, the ingress node obtains the information based on the multicast source group information (S1, G1) and the second corresponding relationship. The tunnel information is (S-P1, D-P1). This tunnel information can be recorded as the first tunnel information. The entrance node obtains the second message based on the first tunnel information (S-P1, D-P1). The second message The header includes the source address S-P1 and the destination address D-P1 corresponding to the first tunnel information, where the destination address D-P1 is the address of the intermediate node corresponding to the next hop of the entry node in the multicast tree. The second message is After the intermediate node of the next hop receives the message, the intermediate node obtains the destination address based on the address of the next hop of the multicast tree. Assuming that the next hop of the intermediate node is an exit node, it obtains the destination address based on the address of the exit node and obtains a new The tunnel information can be recorded as the second tunnel information. The intermediate node updates the destination address corresponding to the second tunnel information in the second message header according to the second tunnel information to obtain the third message. The intermediate node sends the third message to the egress node. After receiving the third message, the egress node decapsulates the message. For another example, the second packet header is a BIERv6 header. Preferably, the second correspondence established by the entrance node includes the multicast source group information (S1, G1) and the tunnel information source address in the BIERv6 header, that is, the BIERv6 header only includes When the source address corresponding to the tunnel information does not include the destination address, since the BIERv6 header does not include the destination address, there is no need for the intermediate node to change the destination address. The intermediate node only forwards the second message. Similarly, the second message established on the egress node The corresponding relationship is the same as that of the ingress node, including multicast source group information (S1, G1) and the tunnel information source address in the BIERv6 header, such as S-P1. Further, after receiving the second message, the egress node obtains the multicast source group information (S1, G1) based on the tunnel information source address S-P1 in the BIERv6 header and the second corresponding relationship, and then obtains the multicast source group information (S1, G1) based on the multicast source group information ( S1, G1) encapsulates the first message header and deletes the BIERv6 header to obtain the first message.
在入口节点和出口节点之间采用MPLS P2MP隧道的场景中,入口节点建立的第三对应关系包括组播源组信息(S1,G1)和MPLS标签的对应关系,MPLS标签包括第一MPLS标签值,入口节点封装的第二报文头可以是MPLS头,MPLS头中包括与隧道信息对应的MPLS标签,MPLS标签可以以第一MPLS标签值表示,进一步地,MPLS P2MP隧道的场景中对应各节点建立有组播树,如MPLS P2MP树(隧道),入口节点可以根据从第一报文中得到组播源组信息(S,G)与MPLS P2MP树(隧道)的标识建立第四对应关系,并将第四对应关系通告出口节点;入口节点还保存有MPLS P2MP树的所有分叉信息,分叉信息包括MPLS P2MP树(隧道)上每个节点的一个或多个分叉的信息,其中,MPLS P2MP树(隧道)上的节点对应骨干网络中的入口节点、中间节点或出口节点,每个节点的一个或多个分叉对应骨干网络中各节点间的路径,入口节点可以根据MPLS P2MP树(隧道)的分叉信息对应为MPLS P2MP树(隧道)的标识分配第一标签值,以建立MPLS P2MP树(隧道)的标识与第一标签值的第五对应关系,综上,入口节点可以根据组播源组信息(S,G)与MPLS P2MP树(隧道)的标识的第四对应关系,MPLS P2MP树(隧道)的标识与第一MPLS标签值的第五对应关系,建立组播源组信息(S,G)和第一MPLS标签值的第三对应关系。需要说明的是,入口节点发送的第二报文由入口节点在MPLS P2MP树(隧道)中下一个分叉对应的中间节点接收后,中间节点根据其在MPLS P2MP树(隧道)的下一个分叉,更新第二报文头中与隧道信息对应的MPLS标签,得到第三报文,假设中间节点在MPLS P2MP树(隧道)中下一个分叉对应的是出口节点,则中间节点向出口节点发送第三报文,由出口节点接收第三报文后解封装。出口节点可以根据入口节点的通告建立第四对应关系,出口节点上还会建立MPLS P2MP树(隧道)的标识与第二MPLS标签值的第六对应关系,其中,第二MPLS标签值可以是出口点为MPLS P2MP树(隧道)的标识分配的标签值,综上,出口节点根据第四对应关系和第六对应关系,可以建立组播源组信息(S,G)和第二MPLS标签值的第七对应关系。由于MPLS P2MP树(隧道)的标识是确定的,因此,入口节点和出口节点基于MPLS P2MP树(隧道)的标识分别建立的第三对应关系,和第七对应 关系,可以对应确定出同一个组播源组信息(S,G)。需要说明的是,不同的出口节点上第七对应关系中对应于组播源组信息如,组播源组信息(S1,G1)的第二MPLS标签值可以不同,只需能在接收到第三报文后,通过本出口节点建立第七对应关系和第三报文头中的第二MPLS标签值确定出组播源组信息(S1,G1)即可。In the scenario where an MPLS P2MP tunnel is used between the ingress node and the egress node, the third correspondence established by the ingress node includes the correspondence between the multicast source group information (S1, G1) and the MPLS label. The MPLS label includes the first MPLS label value. , the second packet header encapsulated by the entry node may be an MPLS header. The MPLS header includes an MPLS label corresponding to the tunnel information. The MPLS label may be represented by the first MPLS label value. Further, in the MPLS P2MP tunnel scenario, the corresponding node When a multicast tree is established, such as an MPLS P2MP tree (tunnel), the entry node can establish a fourth corresponding relationship based on the multicast source group information (S, G) obtained from the first message and the identification of the MPLS P2MP tree (tunnel). And notify the egress node of the fourth corresponding relationship; the ingress node also saves all bifurcation information of the MPLS P2MP tree, and the bifurcation information includes one or more bifurcation information of each node on the MPLS P2MP tree (tunnel), where, The nodes on the MPLS P2MP tree (tunnel) correspond to the entry node, intermediate node or exit node in the backbone network. One or more bifurcations of each node correspond to the path between nodes in the backbone network. The entry node can be based on the MPLS P2MP tree. The bifurcation information of the (tunnel) corresponds to assigning the first label value to the identifier of the MPLS P2MP tree (tunnel) to establish the fifth correspondence between the identifier of the MPLS P2MP tree (tunnel) and the first label value. In summary, the entry node can According to the fourth corresponding relationship between the multicast source group information (S, G) and the identifier of the MPLS P2MP tree (tunnel), and the fifth corresponding relationship between the identifier of the MPLS P2MP tree (tunnel) and the first MPLS label value, the multicast source is established The third correspondence between the group information (S, G) and the first MPLS label value. It should be noted that after the second message sent by the entrance node is received by the intermediate node corresponding to the next branch of the entrance node in the MPLS P2MP tree (tunnel), the intermediate node will respond according to the next branch of the MPLS P2MP tree (tunnel). fork, update the MPLS label corresponding to the tunnel information in the second message header, and obtain the third message. Assume that the next fork of the intermediate node in the MPLS P2MP tree (tunnel) corresponds to the egress node, then the intermediate node forwards to the egress node The third message is sent, and the egress node decapsulates the third message after receiving it. The egress node may establish a fourth corresponding relationship based on the advertisement of the ingress node. The egress node may also establish a sixth corresponding relationship between the identifier of the MPLS P2MP tree (tunnel) and the second MPLS label value, where the second MPLS label value may be egress point is the label value assigned to the identifier of the MPLS P2MP tree (tunnel). In summary, the egress node can establish the multicast source group information (S, G) and the second MPLS label value based on the fourth correspondence relationship and the sixth correspondence relationship. The seventh correspondence. Since the identity of the MPLS P2MP tree (tunnel) is determined, the entry node and the egress node respectively establish a third corresponding relationship based on the identity of the MPLS P2MP tree (tunnel), and the seventh correspondence relationship, the same multicast source group information (S, G) can be determined correspondingly. It should be noted that the second MPLS label value corresponding to the multicast source group information in the seventh correspondence relationship on different egress nodes, such as the multicast source group information (S1, G1), can be different, as long as the second MPLS label value can be received after receiving the first After three messages, the multicast source group information (S1, G1) can be determined by establishing the seventh corresponding relationship on the egress node and the second MPLS label value in the third message header.
在入口节点和出口节点之间采用BIER组播隧道的场景中,第二报文头包括上游MPLS标签,隧道信息与第二报文头通过上游MPLS标签对应,如,入口节点封装的第二报文头可以是BIER头+上游MPLS标签。在骨干网络中,入口节点为上游节点,上游MPLS标签为入口节点的MPLS标签,该场景中,入口节点可以建立组播源组信息(S,G)与上游MPLS标签的第八对应关系,如,入口节点建立组播源组信息(S1,G1)与上游MPLS标签的第八对应关系,根据第一报文中的组播源组信息(S1,G1)和第八对应关系确定上游MPLS标签,在封装第二报文的上游MPLS标签中填入相应的标签值;出口节点上建立的第八对应关系包括组播源组信息(S,G)和上游MPLS标签的对应关系,出口节点根据封装在第二报文上的上游MPLS标签确定组播源组信息(S,G),出口节点上建立的第八对应关系可以是根据入口节点通告的参数建立的。In the scenario where a BIER multicast tunnel is used between the ingress node and the egress node, the second packet header includes the upstream MPLS label, and the tunnel information corresponds to the second packet header through the upstream MPLS label. For example, the second packet encapsulated by the ingress node The header can be a BIER header + an upstream MPLS label. In the backbone network, the ingress node is the upstream node, and the upstream MPLS label is the MPLS label of the ingress node. In this scenario, the ingress node can establish the eighth correspondence between the multicast source group information (S, G) and the upstream MPLS label, such as , the entry node establishes the eighth correspondence between the multicast source group information (S1, G1) and the upstream MPLS label, and determines the upstream MPLS label according to the multicast source group information (S1, G1) in the first message and the eighth correspondence. , fill in the corresponding label value in the upstream MPLS label that encapsulates the second message; the eighth correspondence established on the egress node includes the correspondence between the multicast source group information (S, G) and the upstream MPLS label. The egress node is based on The upstream MPLS label encapsulated in the second packet determines the multicast source group information (S, G), and the eighth correspondence relationship established on the egress node may be established based on parameters advertised by the ingress node.
入口节点获得的第二报文可以根据隧道支持的封装格式进行封装,下面通过例举不同封装格式,详细描述入口节点如何获得第二报文。The second message obtained by the entry node can be encapsulated according to the encapsulation format supported by the tunnel. The following describes in detail how the entry node obtains the second message by giving examples of different encapsulation formats.
举例来说,骨干网络可以使用PIM-SSM的信令建立能够运行MVPN的网络,骨干网络支持的隧道中,可以传输封装格式参照RFC6513的12.1.1的报文,如封装有IPv4头的报文,封装有IPv6头的报文、封装有IPv6头+GRE头的报文等。在用户网络中的组播报文发送至入口节点时,入口节点对接到的报文进行封装,入口节点封装的部分主要用于在骨干网络的隧道中传输报文,因此该报文在到达出口节点时,删除该封装的部分,本申请实施例提供的传输方法能够减少入口节点进行封装造成的报文在骨干网络中的传输的开销。图4为本申请实施例提供的一种封装和解封装报文结构示意图,以入口节点封装IPv6头+GRE头为例,如图4所示,入口节点收到的组播报文为如图4(a)所示,该组播报文为第一报文,包括第一报文头和载荷,其中,第一报文头是用户网络中对报文封装并传输报文的,因此可以记作C-IP头(Header),同理,载荷也可以记作C-Payload,入口节点删除第一报文的C-IP Header,并封装第二报文头,第二报文头包括P-IP Header+GRE头,其中,第二报文头适用于在骨干网络中传输,P-IP Header属于IPv6头,如图4(b)所示,入口节点得到的第二报文包括P-IP Header、GRE头和C-Payload,且,第二报文不包括C-IP Header,第二报文到达出口节点后,如图4(c)所示,出口节点将第二报文的P-IP Header和GRE头删除,封装C-IP Header,相当于出口节点将第二报文恢复为包括C-IP Header和C-Payload、不包括P-IP Header和GRE头的第一报文。在本申请实施例提供的封装方法中,入口节点删除了第一报文头(C-IP Header),第二报文在骨干网络中传输时,不包括第一报文头,因此减小了第二报文在骨干网络中传输的开销。For example, the backbone network can use PIM-SSM signaling to establish a network capable of running MVPN. In the tunnel supported by the backbone network, packets whose encapsulation format refers to RFC6513 12.1.1 can be transmitted, such as packets encapsulated with IPv4 headers. , packets encapsulated with IPv6 header, packets encapsulated with IPv6 header + GRE header, etc. When a multicast message in the user network is sent to the entrance node, the entrance node encapsulates the received message. The encapsulated part of the entrance node is mainly used to transmit the message in the tunnel of the backbone network, so the message reaches the egress When the node is connected, the encapsulated part is deleted. The transmission method provided by the embodiment of the present application can reduce the overhead of transmitting messages in the backbone network caused by encapsulation by the entry node. Figure 4 is a schematic structural diagram of an encapsulation and decapsulation message provided by an embodiment of the present application. Taking the entry node encapsulating the IPv6 header + GRE header as an example, as shown in Figure 4, the multicast message received by the entry node is as shown in Figure 4 As shown in (a), the multicast message is the first message, including the first message header and payload. The first message header is used to encapsulate and transmit the message in the user network, so it can be recorded As the C-IP header (Header), in the same way, the payload can also be recorded as C-Payload. The entry node deletes the C-IP Header of the first message and encapsulates the second message header. The second message header includes P- IP Header+GRE header, where the second message header is suitable for transmission in the backbone network, and the P-IP Header belongs to the IPv6 header. As shown in Figure 4(b), the second message obtained by the entry node includes P-IP Header, GRE header and C-Payload, and the second message does not include the C-IP Header. After the second message reaches the egress node, as shown in Figure 4(c), the egress node changes the P- Deleting the IP Header and GRE header and encapsulating the C-IP Header is equivalent to the egress node restoring the second message to the first message including the C-IP Header and C-Payload, excluding the P-IP Header and GRE header. In the encapsulation method provided by the embodiment of this application, the entry node deletes the first message header (C-IP Header). When the second message is transmitted in the backbone network, it does not include the first message header, thus reducing the The cost of transmitting the second packet in the backbone network.
进一步地,由于入口节点删除了C-IP Header,第二报文传输至出口节点时,需要在出口节点封装C-IP Header,因此,入口节点删除C-IP Header后,在封装的第二报文头中,应至少包括与隧道信息对应的源地址和目的地址,该目的地址可以是组播地址,以使得出口节点能够根据该隧道信息和出口节点建立的第一对应关系得到C-IP Header的组播源组信息,封装C-IP Header。需要说明的是,第二报文头包括属于IPv6头的P-IP Header+GRE 头,适用于入口节点和出口节点之间采用IP组播隧道的场景中,入口节点和出口节点建立的第一对应关系可以参照上例,以及参照表3,如,入口节点根据组播源组信息(S1,G2)和第一对应关系获取的隧道信息是(S-P1,D-P2),第二报文头与隧道信息对应的源地址是S-P1和目的地址是D-P2,同理,出口节点接收到第二报文后,可以根据第二报文头与隧道信息对应的源地址是S-P1、目的地址是D-P2和第一对应关系,得到第一报文头对应的组播源组信息(S1,G2)。Further, since the entry node deletes the C-IP Header, when the second message is transmitted to the exit node, the C-IP Header needs to be encapsulated at the exit node. Therefore, after the entry node deletes the C-IP Header, the encapsulated second message The header should at least include the source address and destination address corresponding to the tunnel information. The destination address can be a multicast address, so that the egress node can obtain the C-IP Header based on the first corresponding relationship established between the tunnel information and the egress node. Multicast source group information, encapsulating C-IP Header. It should be noted that the second message header includes the P-IP Header+GRE belonging to the IPv6 header. Header is applicable to the scenario where an IP multicast tunnel is used between the ingress node and the egress node. The first corresponding relationship established between the ingress node and the egress node can refer to the above example, and refer to Table 3. For example, the ingress node sets the The tunnel information obtained from the information (S1, G2) and the first correspondence is (S-P1, D-P2). The source address corresponding to the second packet header and the tunnel information is S-P1 and the destination address is D-P2. In the same way, after the egress node receives the second message, it can obtain the first message header based on the source address corresponding to the second message header and the tunnel information, which is S-P1, the destination address is D-P2, and the first correspondence. Corresponding multicast source group information (S1, G2).
需要说明的是,第一对应关系可以是入口节点和出口节点各自静态配置,也可以由入口节点向出口节点通告,如入口节点向出口节点通告可以通过入口节点向出口节点发送BGP消息实现,BGP消息中包括第一对应关系,其中,BGP消息可以是BGP-MVPN信令或者BGP-EVPN信令,本申请实施例以骨干网络是运行MVPN的网络为例,BGP消息是BGP-MVPN信令,实际应用中,实施方案并不限定于使用BGP-MVPN。It should be noted that the first corresponding relationship can be a static configuration of the ingress node and the egress node, or it can be announced by the ingress node to the egress node. For example, the ingress node can notify the egress node by sending a BGP message to the egress node. BGP The message includes a first correspondence relationship, where the BGP message may be BGP-MVPN signaling or BGP-EVPN signaling. In the embodiment of this application, the backbone network is a network running MVPN as an example, and the BGP message is BGP-MVPN signaling. In practical applications, the implementation is not limited to using BGP-MVPN.
下面以第一报文的第一报文头包括C-IP Header,C-IP Header属于IPv6头,第二报文的第二报文头包括P-IP Header+GRE头,P-IP Header属于IPv6头进行说明,入口节点删除如图4(a)所示的第一报文的C-IP Header,入口节点封装第二报文头,第二报文头包括P-IP Header和GRE头,封装后得到的第二报文如图4(b)所示,包括P-IP Header、GRE头和C-Payload。下文示例中,入口节点在封装第二报文头即P-IP Header和GRE头时,各字段中填入内容的一种可能的示例如下:In the following, the first header of the first message includes the C-IP Header, and the C-IP Header belongs to the IPv6 header. The second header of the second message includes the P-IP Header+GRE header, and the P-IP Header belongs to IPv6 header is explained. The entry node deletes the C-IP Header of the first message as shown in Figure 4(a). The entry node encapsulates the second message header. The second message header includes the P-IP Header and GRE header. The second message obtained after encapsulation is shown in Figure 4(b), including P-IP Header, GRE header and C-Payload. In the example below, when the entry node encapsulates the second message header, that is, the P-IP Header and the GRE header, a possible example of filling in the content in each field is as follows:
P-IP Header的Ver:IPv6的版本号为6。P-IP Header Ver: The version number of IPv6 is 6.
P-IP Header的TC:将C-IP Header中的TC字段拷贝到P-IP Header的TC字段中,或者根据本地配置策略设置TC值,如本地配置策略中TC值等于1,则设置为1。TC of P-IP Header: Copy the TC field in the C-IP Header to the TC field of the P-IP Header, or set the TC value according to the local configuration policy. If the TC value in the local configuration policy is equal to 1, set it to 1. .
P-IP Header的FL:将C-IP Header中的FL字段拷贝到P-IP Header的FL字段中,或者根据本地配置策略设置FL值。FL of P-IP Header: Copy the FL field in the C-IP Header to the FL field of the P-IP Header, or set the FL value according to the local configuration policy.
P-IP Header的PL:可以根据C-IP Header中的PL字段值加上GRE头的长度得到。PL of P-IP Header: It can be obtained based on the PL field value in C-IP Header plus the length of the GRE header.
P-IP Header的NH:指示紧跟着的下一个头部字段,即指示GRE头。NH of P-IP Header: indicates the next header field that follows, that is, indicates the GRE header.
P-IP Header的HL:将C-IP Header中的HL字段拷贝到P-IP Header的HL字段中,或者根据本地配置策略设置HL值。HL of P-IP Header: Copy the HL field in the C-IP Header to the HL field of the P-IP Header, or set the HL value according to the local configuration policy.
P-IP Header的SA和DA:通过C-IP Header中的SA字段和DA字段和对应关系,设置SA字段和DA字段,如,可以通过C-IP Header中的SA字段和DA字段得到组播源组信息(S1,G2),根据组播源组信息(S1,G2)和第一对应关系得到隧道信息是(S-P1,D-P2),P-IP Header的SA字段填入S-P1,P-IP Header的DA字段填入D-P2。SA and DA of P-IP Header: Set the SA field and DA field through the SA field and DA field in the C-IP Header and the corresponding relationship. For example, you can obtain multicast through the SA field and DA field in the C-IP Header. Source group information (S1, G2). According to the multicast source group information (S1, G2) and the first corresponding relationship, the tunnel information is (S-P1, D-P2). Fill in the SA field of the P-IP Header with S- P1, fill in the DA field of P-IP Header with D-P2.
GRE头的Protocol:根据C-IP Header中的NH值转换出GRE头的Protocol值,如,C-IP Header中的NH为4、指示C-Payload是带有IPv4头的报文,GRE头的Protocol值可以根据格式设置为0x0800。Protocol of the GRE header: Convert the Protocol value of the GRE header according to the NH value in the C-IP Header. For example, the NH in the C-IP Header is 4, indicating that the C-Payload is a message with an IPv4 header. The Protocol value can be set to 0x0800 according to the format.
封装第二报文头时各字段的设置可以静态配置,本地配置策略可以是入口节点对不同字段配置预设值,如本地配置策略中对TC字段配置的预设值等于1。When encapsulating the second header, the settings of each field can be configured statically. The local configuration policy can be that the ingress node configures preset values for different fields. For example, the preset value of the TC field configured in the local configuration policy is equal to 1.
进一步地,入口节点可以向出口节点通告指示信息,指示信息用于指示还原组播源组信息,如,指示信息可以指示出口节点根据第一对应关系,以及出口节点获取的第二报文头对应的隧道信息,获得组播源组信息,并根据组播源组信息,在封装第一报文头时,填入C-IP Header的SA字段和DA字段的内容,相当于还原了入口节点删除的第一报文头 的组播源组信息。进一步地,入口节点还可以向出口节点通告删除还原指示信息,该删除还原指示信息可以进一步指示出口节点删除第二报文头,并根据第二报文头的字段或本地配置策略得到第一报文头中各字段需设置的内容,如指示出口节点根据GRE头的Protocol字段得到第一报文头中的NH字段的值等。Further, the ingress node may notify the egress node of indication information, and the indication information is used to instruct the restoration of the multicast source group information. For example, the indication information may instruct the egress node to restore the multicast source group information according to the first correspondence relationship and the second message header obtained by the egress node. tunnel information, obtain the multicast source group information, and fill in the contents of the SA field and DA field of the C-IP Header when encapsulating the first message header based on the multicast source group information, which is equivalent to restoring the deletion of the entry node. The first message header of multicast source group information. Further, the ingress node may also notify the egress node of deletion and restoration instruction information. The deletion and restoration instruction information may further instruct the egress node to delete the second message header and obtain the first message according to the fields of the second message header or the local configuration policy. Contents that need to be set for each field in the header, such as instructing the egress node to obtain the value of the NH field in the first header based on the Protocol field of the GRE header, etc.
需要说明的是,出口节点接收到指示信息后,可以保存指示信息,在接收到第二报文后,根据指示信息和第二报文得到第一报文。可选的,入口节点和出口节点间可以建立关系,建立关系之后,入口节点可以通知出口节点采用与入口节点相同的封装方式,对第二报文进行解封装,还可以通知出口节点,入口节点接收到的第一报文的第一报文头对应的封装方式,以使得出口节点根据第一报文头对应的封装方式封装得到第一报文,这种封装方法可以定义为紧凑型(compact)封装方法,或称为删除还原(delete-restore)的封装方法。It should be noted that after receiving the indication information, the egress node can save the indication information, and after receiving the second message, obtain the first message according to the indication information and the second message. Optionally, a relationship can be established between the entry node and the exit node. After the relationship is established, the entry node can notify the exit node to use the same encapsulation method as the entry node to decapsulate the second message. It can also notify the exit node that the entry node The encapsulation method corresponding to the first message header of the received first message is such that the egress node encapsulates the first message according to the encapsulation method corresponding to the first message header. This encapsulation method can be defined as compact. ) encapsulation method, or the encapsulation method called delete-restore.
S104、入口节点通过与隧道信息对应的隧道发送第二报文。S104. The entrance node sends the second message through the tunnel corresponding to the tunnel information.
入口节点可以通过隧道信息(S-P1,D-P2)对应的隧道发送第二报文,如果第二报文头中IPv6头的目的地址D-P2是组播树对应的组播组地址,回到图2所示的场景中,出口节点1和出口节点2均加入了D-P2对应的组播组,相当于出口节点1和出口节点2接收到第二报文时,将第二报文头删除,并封装第一报文头,得到第一报文。The entrance node can send the second message through the tunnel corresponding to the tunnel information (S-P1, D-P2). If the destination address D-P2 of the IPv6 header in the second message header is the multicast group address corresponding to the multicast tree, Returning to the scenario shown in Figure 2, both egress node 1 and egress node 2 have joined the multicast group corresponding to D-P2, which is equivalent to when egress node 1 and egress node 2 receive the second message. The header is deleted and the first header is encapsulated to obtain the first message.
隧道信息的目的地址也可以为入口节点在组播树的下一跳的地址,如回到图2所示的场景中,在入口节点1000、中间节点2001、中间节点2002、出口节点1和出口节点3之间采用BIERv6组播隧道的情况,参照上例中在入口节点和出口节点之间采用BIERv6组播隧道的的场景的举例,如果目的地址为下一跳节点单播地址的情况下,入口节点通过与隧道信息对应的隧道发送第二报文,到达对应的出口节点时,对应的出口节点接收到的可能是第三报文,对应的出口节点可以根据第三报文中的隧道信息得到组播源组信息,封装第一报文头;入口节点通过与隧道信息对应的隧道发送的第二报文中,第二报文头如果对应隧道信息源地址不包括目的地址,则出口节点接收到的是第二报文,出口节点根据第二对应关系和隧道信息源地址得到组播源组信息,封装第一报文头。The destination address of the tunnel information can also be the next hop address of the entry node in the multicast tree. For example, in the scenario shown in Figure 2, the entry node 1000, the intermediate node 2001, the intermediate node 2002, the exit node 1 and the exit For the case of using a BIERv6 multicast tunnel between nodes 3, refer to the example above of using a BIERv6 multicast tunnel between the ingress node and the egress node. If the destination address is the unicast address of the next hop node, The ingress node sends the second message through the tunnel corresponding to the tunnel information. When it reaches the corresponding egress node, the corresponding egress node may receive the third message. The corresponding egress node may receive the second message according to the tunnel information in the third message. Obtain the multicast source group information and encapsulate the first message header; in the second message sent by the ingress node through the tunnel corresponding to the tunnel information, if the second message header corresponds to the tunnel information source address does not include the destination address, the egress node What is received is the second message. The egress node obtains the multicast source group information based on the second correspondence and the tunnel information source address, and encapsulates the first message header.
本申请实施例以P-IP Header和C-IP Header头均属于IPv6头,入口节点删除如图4(a)中C-IP Header头,并在如图4(b)所示封装P-IP Header和GRE头,其效果等同于将C-IP Header“替换”成了P-IP Header和GRE头,而不是在报文进入骨干网络时增加封装的P-IP Header和GRE头,这样可以减少报文在骨干网络中传输的开销。In the embodiment of this application, both P-IP Header and C-IP Header headers belong to IPv6 headers. The entry node deletes the C-IP Header header in Figure 4(a) and encapsulates the P-IP header as shown in Figure 4(b). Header and GRE header, the effect is equivalent to "replacing" the C-IP Header with the P-IP Header and GRE header, instead of adding the encapsulated P-IP Header and GRE header when the message enters the backbone network, which can reduce The overhead of packet transmission in the backbone network.
图5为本申请实施例提供的报文的另一种传输方法的流程示意图,如图5所示,该方法包括:Figure 5 is a schematic flowchart of another message transmission method provided by an embodiment of the present application. As shown in Figure 5, the method includes:
S105、出口节点接收第二报文,第二报文包括载荷和与隧道信息对应的第二报文头。S105. The egress node receives a second message, where the second message includes a payload and a second message header corresponding to the tunnel information.
出口节点接收如图4(b)所示的第二报文,第二报文包括C-Payload、P-IP Header和GRE头,不包括C-IP Header。出口节点如图4(c)所示,将第二报文的P-IP Header和GRE头删除,并封装C-IP Header,得到包括C-IP Header和C-Payload的第一报文,相当于出口节点还原了第一报文。本申请实施例提供的封装方法能够向CE设备发送符合规范格式的报文。The exit node receives the second message as shown in Figure 4(b). The second message includes C-Payload, P-IP Header and GRE header, but does not include C-IP Header. As shown in Figure 4(c), the exit node deletes the P-IP Header and GRE header of the second message and encapsulates the C-IP Header to obtain the first message including C-IP Header and C-Payload, which is quite The first message is restored at the egress node. The encapsulation method provided by the embodiments of this application can send messages that comply with the standard format to the CE device.
S106、出口节点根据第二报文头对应的隧道信息和对应关系,获取组播源组信息,对应关系包括隧道信息和组播源组信息。S106. The egress node obtains multicast source group information based on the tunnel information and corresponding relationship corresponding to the second packet header. The corresponding relationship includes tunnel information and multicast source group information.
该对应关系可以是第一对应关系,包括隧道信息和组播源组信息,出口节点根据第二 报文头对应的隧道信息和第一对应关系,可以得到组播源组信息。回到图2所示的场景中,在入口节点1000、中间节点2001、中间节点2002、出口节点1和出口节点3之间采用IP组播隧道的场景中,如,出口节点3接收到第二报文,根据第二报文头得到的隧道信息(S-P1,D-P2),其中,第二报文头包括的目的地址是组播树对应的组播组地址,其中,组播树包括入口节点1000、出口节点1和出口节点3,出口节点3可以根据隧道信息(S-P1,D-P2)和第一对应关系,得到组播源组信息(S1,G2)。The corresponding relationship may be a first corresponding relationship, including tunnel information and multicast source group information, and the egress node Based on the tunnel information corresponding to the packet header and the first correspondence, the multicast source group information can be obtained. Returning to the scenario shown in Figure 2, in the scenario where an IP multicast tunnel is used between the entry node 1000, the intermediate node 2001, the intermediate node 2002, the exit node 1 and the exit node 3, for example, the exit node 3 receives the second message, the tunnel information (S-P1, D-P2) obtained according to the second message header, where the destination address included in the second message header is the multicast group address corresponding to the multicast tree, where the multicast tree It includes an ingress node 1000, an egress node 1 and an egress node 3. The egress node 3 can obtain the multicast source group information (S1, G2) based on the tunnel information (S-P1, D-P2) and the first corresponding relationship.
或者,在入口节点1000、中间节点2001、中间节点2002、出口节点1和出口节点3之间采用BIERv6组播隧道的场景中,由于入口节点到中间节点2001、中间节点2001到中间节点2002,中间节点2002到出口节点1、中间节点2002到出口节点3的报文,均属于IPv6头,且IPv6头中的目的地址均是单播地址,入口节点1000向中间节点2001发送是第二报文目的地址是中间节点2001的,中间节点2001向中间节点2002发送的时候第三报文目的地址更改为中间节点2002的,中间节点向出口节点1发送的第四报文的目的地址更改为出口节点1的,中间节点2002向出口节点3发送的时候第五报文目的地址更改为出口节点3的。但是对于出口节点1和出口节点3来说,接收到的第四报文和第五报文都是“BIERv6隧道”报文,根据报文的隧道信息中的源地址和第二对应关系确定组播源组信息,即可得到第一报文,由于第二对应关系是组播源组信息(S,G)与隧道信息中源地址的对应关系,不论报文中的目的地址是否更改,出口节点只要根据隧道信息的源地址和第二对应关系,就可以得到组源组信息(S,G),并可以据此封装第一报文头,得到第一报文。Or, in the scenario where BIERv6 multicast tunnel is used between the entrance node 1000, the intermediate node 2001, the intermediate node 2002, the exit node 1 and the exit node 3, since the entrance node to the intermediate node 2001, the intermediate node 2001 to the intermediate node 2002, the intermediate node The packets sent from node 2002 to egress node 1 and from intermediate node 2002 to egress node 3 all belong to IPv6 headers, and the destination addresses in the IPv6 headers are all unicast addresses. The second purpose of the packets sent from entry node 1000 to intermediate node 2001 is The address belongs to intermediate node 2001. When intermediate node 2001 sends the third message to intermediate node 2002, the destination address of the third message is changed to that of intermediate node 2002. The destination address of the fourth message sent by the intermediate node to exit node 1 is changed to exit node 1. , when the intermediate node 2002 sends the fifth message to the egress node 3, the destination address of the fifth message is changed to that of the egress node 3. However, for egress node 1 and egress node 3, the fourth and fifth messages received are both "BIERv6 tunnel" messages, and the group is determined based on the source address and the second correspondence in the tunnel information of the message. The first message can be obtained by using the multicast source group information. Since the second correspondence is the correspondence between the multicast source group information (S, G) and the source address in the tunnel information, regardless of whether the destination address in the message changes or not, the egress The node can obtain the group source group information (S, G) based on the source address of the tunnel information and the second corresponding relationship, and can encapsulate the first message header accordingly to obtain the first message.
需要说明的是,第一对应关系和第二对应关系可以是出口节点静态配置,也可以是获取入口节点通告的第一对应关系或第二对应关系后保存的,出口节点可以接收入口节点发送的BGP消息,BGP消息包括第一对应关系或BGP消息包括第二对应关系。其中,BGP消息为BGP-MVPN信令或者BGP-EVPN信令。It should be noted that the first correspondence relationship and the second correspondence relationship can be static configurations of the egress node, or they can be saved after obtaining the first correspondence relationship or the second correspondence relationship advertised by the entry node. The egress node can receive the information sent by the entry node. BGP message, the BGP message includes the first corresponding relationship or the BGP message includes the second corresponding relationship. The BGP message is BGP-MVPN signaling or BGP-EVPN signaling.
进一步地,出口节点接收入口节点通告的指示信息,指示信息用于指示还原组播源组信息。出口节点在接收到第二报文时,可以根据指示信息的指示还原组播源组信息,基于组播源组信息中的源地址设置第一报文头(下例中的C-IP Header)的SA字段,基于组播源组信息中的组播组地址设置第一报文头(下例中的C-IP Header)的DA字段。Further, the egress node receives the indication information advertised by the ingress node, and the indication information is used to instruct to restore the multicast source group information. When the egress node receives the second message, it can restore the multicast source group information according to the instruction information, and set the first message header (C-IP Header in the following example) based on the source address in the multicast source group information. SA field, set the DA field of the first packet header (C-IP Header in the following example) based on the multicast group address in the multicast source group information.
S107、出口节点根据组播源组信息和载荷获得第一报文,第一报文包含第一报文头和载荷,第一报文头包括组播源组信息,第一报文不包括第二报文头。S107. The egress node obtains the first message according to the multicast source group information and payload. The first message includes the first message header and payload. The first message header includes the multicast source group information. The first message does not include the first message. Two message headers.
下面以P-IP Header和C-IP Header都属于IPv6头为例进行说明,出口节点收到的第二报文的第二报文头包括IPv6头和GRE头,删除如图4(b)中的P-IP Header头和GRE头,封装C-IP Header得到如图4(c)所示的第一报文,第一报文包括C-IP Header和C-Payload,下文示例中,出口节点在封装第一报文头即C-IP Header时,封装C-IP Header的各字段的一种示例如下:The following takes the P-IP Header and C-IP Header as both IPv6 headers as an example. The second header of the second message received by the egress node includes the IPv6 header and the GRE header. Delete them as shown in Figure 4(b). The P-IP Header and GRE header are encapsulated into the C-IP Header to obtain the first message as shown in Figure 4(c). The first message includes C-IP Header and C-Payload. In the example below, the exit node When encapsulating the first message header, that is, the C-IP Header, an example of encapsulating each field of the C-IP Header is as follows:
C-IP Header的Version:IPv6的版本号为6。C-IP Header Version: The version number of IPv6 is 6.
C-IP Header的TC:将P-IP Header中的TC字段拷贝到C-IP Header的TC字段中,或者根据本地配置策略设置TC值,如果入口节点根据本地配置策略在P-IP Header中的TC字段设置为1,出口节点拷贝1即可,不用恢复第一报文进入骨干网络时的TC字段内容; TC of C-IP Header: Copy the TC field in the P-IP Header to the TC field of the C-IP Header, or set the TC value according to the local configuration policy. If the ingress node sets the TC value in the P-IP Header according to the local configuration policy, The TC field is set to 1, and the egress node can copy 1. There is no need to restore the TC field content when the first packet entered the backbone network;
C-IP Header的FL:将P-IP Header中的FL字段拷贝到C-IP Header的FL字段中,或者根据本地配置策略设置FL值。FL of C-IP Header: Copy the FL field in the P-IP Header to the FL field of the C-IP Header, or set the FL value according to the local configuration policy.
C-IP Header的PL:可以根据P-IP Header中的PL字段值减去GRE头的长度得到。PL of C-IP Header: It can be obtained by subtracting the length of the GRE header from the PL field value in the P-IP Header.
C-IP Header的NH:指示紧跟着的下一个头部字段,需要根据GRE头中的Protocol字段做相应的转换获得,如,GRE头的Protocol值为0x0800,指示C-Payload带有IPv4,则NH为4。NH of C-IP Header: indicates the next header field, which needs to be converted according to the Protocol field in the GRE header. For example, the Protocol value of the GRE header is 0x0800, indicating that the C-Payload carries IPv4. Then NH is 4.
C-IP Header的HL:将P-IP Header中的HL字段拷贝到C-IP Header的HL字段中,或者根据本地配置策略设置HL值。HL of C-IP Header: Copy the HL field in the P-IP Header to the HL field of the C-IP Header, or set the HL value according to the local configuration policy.
C-IP Header的SA和DA:通过P-IP Header中的SA字段和DA字段和对应关系设置SA字段和DA字段,如,可以通过P-IP Header中的SA字段和DA字段得到隧道信息(S-P1,D-P2),查找第一对应关系得到组播源组信息(S1,G2),C-IP Header的SA字段填入S1,C-IP Header的DA字段填入G2。SA and DA of C-IP Header: Set the SA field and DA field through the SA field and DA field in the P-IP Header and the corresponding relationship. For example, you can obtain the tunnel information through the SA field and DA field in the P-IP Header ( S-P1, D-P2), find the first corresponding relationship to obtain the multicast source group information (S1, G2), fill in the SA field of the C-IP Header with S1, and fill in the DA field of the C-IP Header with G2.
在一种示例中,封装第一报文头时各字段的设置可以是出口节点静态配置的,用于设置字段的本地配置策略也可以是提前预设的。在另一种示例中,出口节点根据入口节点发送的指示信息在封装时填入第一报文头中组播源组信息的对应字段,或者,出口节点根据入口节点发送的删除还原指示信息的指示,来确定第一报文头中的字段是如何根据第二报文头的字段或本地配置策略进行设置的。在另一种示例中,用于设置字段的本地配置策略是提前预设的,出口节点接收到指示信息,可以根据指示信息指示的对应关系和配置的其他信息设置相应字段。进一步地,出口节点接收到指示信息后,可以先保存,在接收到第二报文时,根据指示信息的指示得到第一报文。举例来说,出口节点如果通过BGP-MVPN信令收到指示信息,该指示信息可以是第一对应关系或第二对应关系。出口节点也可以通过预先设置的配置将第二报文恢复为第一报文。本申请实施例仅为举例说明,不以举例为限定。In one example, the settings of each field when encapsulating the first packet header may be statically configured by the egress node, and the local configuration policy for setting the fields may also be preset in advance. In another example, the egress node fills in the corresponding field of the multicast source group information in the first message header during encapsulation according to the instruction information sent by the ingress node, or the egress node fills in the corresponding field of the multicast source group information in the first message header according to the deletion and restoration instruction information sent by the ingress node. Indicates how the fields in the first packet header are set according to the fields in the second packet header or the local configuration policy. In another example, the local configuration policy for setting fields is preset in advance, and the egress node receives the instruction information and can set the corresponding fields according to the correspondence indicated by the instruction information and other configured information. Further, after receiving the indication information, the egress node can save it first, and when receiving the second message, obtain the first message according to the instruction of the indication information. For example, if the egress node receives indication information through BGP-MVPN signaling, the indication information may be the first corresponding relationship or the second corresponding relationship. The egress node can also restore the second message to the first message through preset configuration. The embodiments of this application are only illustrative and not limiting.
本申请实施例提供的出口节点可以根据接收的第二报文得到第一报文,再向CE设备发送第一报文,能够保证发送至用户网络的报文与骨干网络入口节点接收到的报文格式一致,这样一来,用户网络接收到的报文格式规范,不影响网络链路上的报文分析器对该报文进行解析,从而保障报文传输方案的可维护性,(如便于定位报文出错的问题),不会影响报文传输方案的部署和应用。The egress node provided by the embodiment of this application can obtain the first message based on the received second message, and then send the first message to the CE device, which can ensure that the message sent to the user network is consistent with the message received by the backbone network entry node. The message format is consistent. In this way, the format of the message received by the user network is standardized and does not affect the message analyzer on the network link to parse the message, thereby ensuring the maintainability of the message transmission solution (such as facilitating Locating packet errors) will not affect the deployment and application of the packet transmission solution.
在一些实例中,骨干网络使用PIM-SSM的信令建立的隧道类型作为MVPN的隧道承载,其报文的封装格式可以参照RFC6513的12.1.1的封装格式,图6为本申请实施例提供的另一种封装和解封装报文结构示意图,如图6所示,入口节点收到的报文为如图6(a)所示的格式,第一报文包括第一报文头(C-IP Header)和C-Payload,C-IP Header属于IPv6头。入口节点删除接收到的第一报文的C-IP Header,封装第二报文头,如图6(b)所示,第二报文包括C-Payload、P-IP Header和GRE头,且,第二报文不包括C-IP Header。P-IP Header属于IPv4头。第二报文到达出口节点后,出口节点删除第二报文的P-IP Header和GRE头,封装C-IP Header,得到如图6(c)所示的第一报文,第一报文包括C-IP Header和C-Payload。In some examples, the backbone network uses the tunnel type established by PIM-SSM signaling as the MVPN tunnel bearer. The packet encapsulation format can refer to the encapsulation format of RFC6513 12.1.1. Figure 6 is provided by the embodiment of this application. Another schematic diagram of the encapsulation and decapsulation message structure is shown in Figure 6. The message received by the entry node is in the format shown in Figure 6(a). The first message includes the first message header (C-IP Header) and C-Payload, C-IP Header belongs to the IPv6 header. The entry node deletes the C-IP Header of the received first message and encapsulates the second message header, as shown in Figure 6(b). The second message includes C-Payload, P-IP Header and GRE header, and , the second message does not include the C-IP Header. P-IP Header belongs to IPv4 header. After the second message reaches the egress node, the egress node deletes the P-IP Header and GRE header of the second message, encapsulates the C-IP Header, and obtains the first message as shown in Figure 6(c). The first message Including C-IP Header and C-Payload.
下面以第一报文头(C-IP Header)属于IPv6头、第二报文头为P-IP Header和GRE头,其中P-IP Header属于IPv4头为例进行说明,入口节点收到的第一报文后删除C-IP  Header,入口节点确定第二报文头包括IPv4头和GRE头,其中,IPv4头包括与隧道信息对应的源地址和目的地址,隧道信息对应的源地址和目的地址可以根据C-IP Header中的组播源组信息和第一对应关系确定,其中,第一对应关系可以参照上述实施例,在此不再赘述,入口节点封装IPv4头和GRE头得到第二报文,如图5(b)所示,第二报文包括C-Payload、P-IP Header和GRE头,下文的字段示例中,将第一报文头记作C-IP Header,将第二报文头的IPv4头记作P-IP Header,封装P-IP Header和GRE头时各字段的一种示例如下:The following description takes the first packet header (C-IP Header) as an IPv6 header, the second packet header as a P-IP Header and a GRE header, and the P-IP Header as an IPv4 header. The entry node receives the Delete C-IP after one message Header, the entrance node determines that the second message header includes an IPv4 header and a GRE header, where the IPv4 header includes the source address and destination address corresponding to the tunnel information. The source address and destination address corresponding to the tunnel information can be based on the C-IP Header. The multicast source group information and the first corresponding relationship are determined. The first corresponding relationship can refer to the above embodiment and will not be repeated here. The entrance node encapsulates the IPv4 header and the GRE header to obtain the second message, as shown in Figure 5(b) As shown, the second message includes C-Payload, P-IP Header and GRE header. In the following field examples, the first message header is recorded as C-IP Header, and the IPv4 header of the second message header is recorded as P-IP Header, an example of each field when encapsulating P-IP Header and GRE header is as follows:
P-IP Header的Ver:IPv4的版本号为4;Ver of P-IP Header: IPv4 version number is 4;
P-IP Header的IHL:可以按照IPv4头的要求设置为5;IHL of P-IP Header: can be set to 5 according to the requirements of IPv4 header;
P-IP Header的TOS:将C-IP Header中的TC字段(8bit)拷贝到P-IP Header的TOS字段(8bit)中,或者根据本地配置策略设置TOS值;TOS of P-IP Header: Copy the TC field (8bit) in the C-IP Header to the TOS field (8bit) of the P-IP Header, or set the TOS value according to the local configuration policy;
P-IP Header的Total Length:可以按照C-IP Header中的Payload Length字段值,再加上GRE头的长度和IPv4头的长度得到;Total Length of P-IP Header: It can be obtained according to the Payload Length field value in C-IP Header, plus the length of the GRE header and the length of the IPv4 header;
P-IP Header的Identifier:按照IPv4头的要求设置,考虑不分段的情况设置为0;P-IP Header's Identifier: Set according to the requirements of the IPv4 header, and set to 0 considering non-fragmentation;
P-IP Header的Flags:按照IPv4头的要求设置,考虑不分段的情况设置为010(二进制);Flags of P-IP Header: Set according to the requirements of the IPv4 header, and set to 010 (binary) considering the situation of non-fragmentation;
P-IP Header的FO:按照IPv4头的要求设置,考虑不分段的情况设置0;P-IP Header's FO: Set according to the requirements of the IPv4 header, and set to 0 considering the case of no fragmentation;
P-IP Header的TTL:将C-IP中的HL字段(8bit)拷贝到P-IP的TTL字段(8bit)中,或者根据本地配置策略设置TTL值;TTL of P-IP Header: Copy the HL field (8bit) in C-IP to the TTL field (8bit) of P-IP, or set the TTL value according to the local configuration policy;
P-IP Header的Protocol:根据C-IP中的Next Header值进行设置,比如C-IP Header中的Next Header为17,指示C-Payload是带有UDP头部的净荷,P-IP头的Protocol值设置为17;Protocol of P-IP Header: Set according to the Next Header value in C-IP. For example, the Next Header in C-IP Header is 17, indicating that the C-Payload is a payload with a UDP header, and the P-IP header is Protocol value is set to 17;
P-IP Header的Header Checksum:该字段根据IPv4头计算得到的校验和设置,或者,设置为0;Header Checksum of P-IP Header: This field is set based on the checksum calculated from the IPv4 header, or is set to 0;
P-IP Header的SA和DA:通过C-IP Header中的SA字段和DA字段和对应关系设置SA字段和DA字段,可参照上例。SA and DA of P-IP Header: Set the SA field and DA field through the SA field and DA field in the C-IP Header and the corresponding relationship. You can refer to the above example.
GRE头的Protocol:根据C-IP中的NH值转换出GRE头的Protocol值。GRE header Protocol: Convert the GRE header Protocol value based on the NH value in C-IP.
封装第二报文头时各字段的设置可以静态配置,本地配置策略也可以是提前预设,此处例举的数值均为示例,具体的字段设置可以根据实际使用场景的需求进行调整,除了版本号外其他数值不以此为限定。When encapsulating the second packet header, the settings of each field can be configured statically, and the local configuration policy can also be preset in advance. The values exemplified here are examples. The specific field settings can be adjusted according to the needs of the actual usage scenario, except Values other than the version number are not limited to this.
本实施例中P-IP Header属于IPv4头、C-IP Header属于IPv6头,所以入口节点删除C-IP Header后封装P-IP Header和GRE头,如图6(b)中所示,等同于将C-IP Header“替换”成了P-IP Header,在骨干网络中传输到达出口节点后,出口节点再将P-IP Header和GRE头删除,恢复C-IP Header,出口节点可以通过前述MVPN信令传递对应关系和指示信息,指示信息用于指示还原组播源组信息,骨干网络中的封装和解封装是由入口节点和出口节点配合完成的,以此减少报文在骨干网络中传输的开销。需要说明的是,第一对应关系可以是出口节点静态配置,也可以是获取入口节点通告的第一对应关系后预存的,通过第一对应关系和隧道信息得到组播源组信息,并设置第一报文头的方法可以是出口节点配置,也可以是接收指示信息后保存的。 In this embodiment, the P-IP Header belongs to the IPv4 header and the C-IP Header belongs to the IPv6 header. Therefore, the entry node deletes the C-IP Header and then encapsulates the P-IP Header and GRE header, as shown in Figure 6(b), which is equivalent to The C-IP Header is "replaced" with the P-IP Header. After the transmission reaches the egress node in the backbone network, the egress node deletes the P-IP Header and GRE header to restore the C-IP Header. The egress node can pass the aforementioned MVPN The signaling transfers the corresponding relationship and indication information. The indication information is used to instruct the restoration of the multicast source group information. Encapsulation and decapsulation in the backbone network are completed by the ingress node and egress node, thereby reducing the time required for message transmission in the backbone network. overhead. It should be noted that the first correspondence relationship can be a static configuration of the egress node, or it can be pre-stored after obtaining the first correspondence relationship advertised by the ingress node. The multicast source group information is obtained through the first correspondence relationship and the tunnel information, and the third correspondence relationship is set. The method of a message header can be configured by the egress node or saved after receiving the indication information.
下文的字段示例中,将第一报文头记作C-IP Header,出口节点删除P-IP Header和GRE头,封装C-IP Header时各字段的一种示例如下:In the field examples below, the first packet header is recorded as C-IP Header, and the egress node deletes the P-IP Header and GRE header. An example of each field when encapsulating the C-IP Header is as follows:
C-IP Header的Version:IPv6的版本号为6;C-IP Header Version: IPv6 version number is 6;
C-IP Header的TC:将P-IP Header中的TOS字段拷贝到C-IP Header的TC字段中,或者根据本地配置策略设置TC值;TC of C-IP Header: Copy the TOS field in the P-IP Header to the TC field of the C-IP Header, or set the TC value according to the local configuration policy;
C-IP Header的FL:根据本地配置策略设置FL值;C-IP Header's FL: Set the FL value according to the local configuration policy;
C-IP Header的PL:可以根据P-IP Header中的PL字段值减去GRE头的长度、再减去IPv4头长度得到;PL of C-IP Header: It can be obtained by subtracting the length of the GRE header from the PL field value in the P-IP Header and then subtracting the length of the IPv4 header;
C-IP Header的NH:将P-IP Header中中的Protocol字段(8bit)拷贝到C-IP Header的Next Header字段中(8bit);NH of C-IP Header: Copy the Protocol field (8bit) in the P-IP Header to the Next Header field (8bit) of the C-IP Header;
C-IP Header的HL:将P-IP Header中的TTL字段拷贝到C-IP Header的HL字段中,或者根据本地配置策略设置HL值;HL of C-IP Header: Copy the TTL field in the P-IP Header to the HL field of the C-IP Header, or set the HL value according to the local configuration policy;
C-IP Header的SA和DA:通过P-IP Header中的SA字段和DA字段和对应关系设置SA字段和DA字段,方法参照上例,在此不再赘述。SA and DA of C-IP Header: Set the SA field and DA field through the SA field and DA field in the P-IP Header and the corresponding relationship. The method is as shown in the above example and will not be repeated here.
封装第一报文头时各字段的值,可以是出口节点静态配置的,用于设置字段的本地配置策略也可以是提前预设的。封装第一报文头时,各字段还可以是出口节点根据入口节点发送的指示信息或删除还原指示信息的指示来确定的。The values of each field when encapsulating the first message header can be statically configured by the egress node, and the local configuration policy used to set the fields can also be preset in advance. When encapsulating the first message header, each field may also be determined by the egress node based on the instruction information sent by the ingress node or the instruction to delete and restore the instruction information.
进一步地,IPv4头包括与隧道信息对应的源地址和目的地址,除了以上示例所列举的DA字段为组播树对应的组播组地址,DA字段还可以为入口节点在组播树的下一跳的地址。Further, the IPv4 header includes the source address and destination address corresponding to the tunnel information. In addition to the DA field listed in the above example, which is the multicast group address corresponding to the multicast tree, the DA field can also be the entry node next to the multicast tree. Jump address.
以上示例以第一报文头(C-IP Header)属于IPv6头,第二报文头中的P-IP Header分别属于IPv6头和IPv4头举例,第一报文头(C-IP Header)属于IPv4头,第二报文头中的P-IP Header属于IPv6头或IPv4头的情况,可以参照上述示例,类推得到第二报文头中各字段的值和恢复第一报文头时各字段的值,不再展开详述,同理,本申请实施例提供所有示例,均以第一报文头(C-IP Header)均属于IPv6头为例进行说明,第一报文头(C-IP Header)属于IPv4头的情况可以根据本申请提供的示例类推,本申请实施例中不再赘述,但第一报文头(C-IP Header)属于IPv4头的情况也在本申请保护范围之内。In the above example, the first packet header (C-IP Header) belongs to the IPv6 header, and the P-IP Header in the second packet header belongs to the IPv6 header and IPv4 header respectively. The first packet header (C-IP Header) belongs to If the IPv4 header and the P-IP Header in the second header belong to the IPv6 header or the IPv4 header, you can refer to the above example and by analogy to obtain the values of each field in the second header and the fields when restoring the first header. The value of will not be described in detail. Similarly, the embodiments of this application provide all examples, taking the first packet header (C-IP Header) as an example of an IPv6 header. The first packet header (C-IP Header) belongs to the IPv6 header. The situation that IP Header) belongs to the IPv4 header can be deduced based on the examples provided in this application. It will not be repeated in the embodiments of this application. However, the situation that the first message header (C-IP Header) belongs to the IPv4 header is also within the protection scope of this application. Inside.
在一些实例中,骨干网络的报文的封装可以参照RFC6513的12.1.3的封装方式,下面以第一报文头(C-IP Header)属于IPv6头,第二报文头为MPLS头,记作P-MPLS头,MPLS头可以包括三层标签,本申请实施例以MPLS头包括一层标签为例进行说明,进一步地,C-Payload中可以包括一层IPv4头或IPv6头。图7为本申请实施例提供的另一种封装和解封装报文结构示意图,回到图2的场景中,以CE设备1向入口节点发送的第一报文的第一报文头IPv6头,且C-Payload中包括IPv6头为例,入口节点接收到如图7(a)所示的第一报文,删除第一报文的C-IP Header后,进行MPLS封装,即封装第二报文头(P-MPLS头),得到如图7(b)所示的第二报文,第二报文包括P-MPLS头和C-Payload,出口节点接收到第二报文后删除P-MPLS头,封装C-IP Header得到如图7(c)所示的第一报文。In some examples, the encapsulation of backbone network packets can refer to the encapsulation method of RFC6513 12.1.3. In the following, the first packet header (C-IP Header) belongs to the IPv6 header, and the second packet header is the MPLS header. Note: As a P-MPLS header, the MPLS header may include three layers of labels. The embodiment of this application takes the MPLS header including one layer of labels as an example for explanation. Furthermore, the C-Payload may include one layer of IPv4 header or IPv6 header. Figure 7 is a schematic structural diagram of another encapsulation and decapsulation message provided by the embodiment of the present application. Returning to the scenario of Figure 2, take the first message header IPv6 header of the first message sent by CE device 1 to the entrance node, As an example, the C-Payload includes the IPv6 header. The entry node receives the first message as shown in Figure 7(a), deletes the C-IP Header of the first message, and then performs MPLS encapsulation, that is, encapsulates the second message. header (P-MPLS header), and obtain the second message as shown in Figure 7(b). The second message includes the P-MPLS header and C-Payload. After receiving the second message, the egress node deletes the P- MPLS header, encapsulate the C-IP Header to obtain the first message as shown in Figure 7(c).
入口节点进行MPLS封装,本申请实施例进行MPLS封装,表4为MPLS头包括的字段。
The entry node performs MPLS encapsulation. This embodiment of the present application performs MPLS encapsulation. Table 4 shows the fields included in the MPLS header.
表4Table 4
如表4所示,MPLS头包括如下部分:As shown in Table 4, the MPLS header includes the following parts:
标签值Label:用于设置标签号,Label占20比特(bit);Label value Label: used to set the label number, Label occupies 20 bits;
实验位Exp:可用于代表服务质量,Exp占3比特(bit);Experimental bit Exp: can be used to represent service quality, Exp occupies 3 bits (bit);
栈底位S:用来表示当前标签是否位于栈底,通过栈底位设置数值不同,多个标签可以编入同数据包中,形成标签栈,如IPv6报文可以确定为S为0的标签栈数据包,MPLS最大可以在数据包中封装3次标签,S占1比特(bit);The bottom bit S of the stack is used to indicate whether the current label is at the bottom of the stack. By setting different values at the bottom bit of the stack, multiple labels can be included in the same packet to form a label stack. For example, an IPv6 packet can be determined to have a label with S = 0. To stack data packets, MPLS can encapsulate labels up to three times in the data packet, and S occupies 1 bit;
生存时间TTL:C-IP Header中的TTL字段或者Hop Limit字段值复制到标签栈中的TTL字段中,TTL占8比特(bit)。Time to live TTL: The TTL field or Hop Limit field value in the C-IP Header is copied to the TTL field in the label stack. TTL occupies 8 bits.
与隧道信息对应的第二报文头为MPLS头,该MPLS头可以参照表4的格式,MPLS头包括组播树对应的MPLS标签或者MPLS头包括入口节点在组播树的下一跳节点的MPLS标签,如通过标签值指示入口节点在组播树的下一跳节点或组播树。由于隧道是通过逐跳的节点基于协议建立起来的,回到图2场景中,假设隧道是入口节点1000,及其下一跳的中间节点2001、中间节点2001的下一跳节点2002以及中间节点2002的下一跳的出口节点1建立起的,且支持建立RFC6513协议,RFC6513协议建立的时候,骨干网络使用相同的控制面的隧道标识,但各节点会基于隧道标识分配不同的数据面标识,其中,控制面用于控制和管理所有网络协议的运行,数据面用于进行数据处理和处理数据的转发,因此,MPLS标签在骨干网络中每一跳的MPLS标签都不同。入口节点参照上述实施例中的方法建立第三对应关系。举例来说,MPLS头中的标签值指示入口节点在组播树的下一跳节点时,入口节点1000可以为下一跳节点即中间节点2001分配10001的标签;该标签值指示组播树时,入口节点可以针对组播源组信息(S1,G1)在MPLS标签分发树中,将所有节点为(S1,G1)对应的组播树分配均为10001的标签。The second header corresponding to the tunnel information is an MPLS header. The MPLS header can refer to the format of Table 4. The MPLS header includes the MPLS label corresponding to the multicast tree or the MPLS header includes the next hop node of the entry node in the multicast tree. MPLS label, for example, indicates the next hop node or multicast tree of the entry node in the multicast tree through the label value. Since the tunnel is established based on the protocol through hop-by-hop nodes, back to the scenario in Figure 2, assume that the tunnel is the entrance node 1000, its next-hop intermediate node 2001, the next-hop node 2002 of the intermediate node 2001, and the intermediate node The next hop egress node 1 of 2002 was established and supported the establishment of the RFC6513 protocol. When the RFC6513 protocol was established, the backbone network used the same control plane tunnel identifier, but each node would assign a different data plane identifier based on the tunnel identifier. Among them, the control plane is used to control and manage the operation of all network protocols, and the data plane is used for data processing and data forwarding. Therefore, the MPLS labels of each hop in the backbone network are different. The entry node establishes the third corresponding relationship with reference to the method in the above embodiment. For example, when the label value in the MPLS header indicates that the entry node is the next hop node of the multicast tree, the entry node 1000 can allocate the label 10001 to the next hop node, that is, the intermediate node 2001; , the entry node can allocate labels of 10001 to all nodes in the multicast tree corresponding to (S1, G1) in the MPLS label distribution tree for the multicast source group information (S1, G1).
需要说明的是,入口节点获得的组播源组信息,既可以从要删除的C-IP Header中获取,也可以从C-Payload中包含的IPv6头中获取,优选地,入口节点获得的组播源组信息从C-IP Header中获取组播源组信息。It should be noted that the multicast source group information obtained by the entry node can be obtained from the C-IP Header to be deleted or from the IPv6 header contained in the C-Payload. Preferably, the group information obtained by the entry node The source group information obtains the multicast source group information from the C-IP Header.
下文的字段设置示例中,将第一报文头记作C-IP Header,将第二报文头(MPLS头)记作P-MPLS头,封装P-MPLS头时各字段的设置的一种示例如下:In the field setting examples below, the first packet header is recorded as C-IP Header, and the second packet header (MPLS header) is recorded as P-MPLS header. This is a type of setting of each field when encapsulating the P-MPLS header. Examples are as follows:
P-MPLS头的Label:根据C-IP Header中的SA字段和DA字段和第三对应关系,对应获得对应的MPLS标签,设置MPLS标签字段,如设置10001;Label of P-MPLS header: According to the SA field and DA field in the C-IP Header and the third corresponding relationship, the corresponding MPLS label is obtained and the MPLS label field is set, such as setting 10001;
P-MPLS头的Exp:按照P-MPLS头的要求,设置一个值,代表服务质量;Exp of the P-MPLS header: Set a value according to the requirements of the P-MPLS header to represent the quality of service;
P-MPLS头的S:根据P-MPLS头包括一层标签,设置为1;S in the P-MPLS header: includes a layer of labels based on the P-MPLS header, set to 1;
P-MPLS头的TTL:将C-IP中的HL字段(8bit)拷贝到P-IP的TTL字段(8bit)中,或者根据本地配置策略设置TTL值。TTL of P-MPLS header: Copy the HL field (8 bits) in C-IP to the TTL field (8 bits) of P-IP, or set the TTL value according to the local configuration policy.
封装P-MPLS时各字段的设置可以静态配置,本地配置策略也可以是提前预设,此处例举的设置数值均为示例,具体的字段设置数值可以根据实际使用场景的需求进行调整,不以上例要求的数值为限定。When encapsulating P-MPLS, the settings of each field can be configured statically, and the local configuration policy can also be preset in advance. The setting values exemplified here are examples. The specific field setting values can be adjusted according to the needs of the actual usage scenario. The numerical value required in the above example is limited.
本实施例中C-IP Header属于IPv6头,所以入口节点删除C-IP Header后封装P-MPLS 头的效果,等同于将C-IP Header“替换”成了MPLS头,在骨干网络中,第二报文传输到达出口节点后,出口节点再将如图7(b)中所示的P-MPLS头删除,封装如图7(c)所示的C-IP Header得到第一报文。出口节点可以接收入口节点通过BGP-MVPN信令或BGP-EVPN传递的指示信息获取第四对应关系和还原组播源组信息,出口节点获取入口节点通告的第四对应关系后,可以根据出口节点建立的第六对应关系和接收的第四对应关系,得到第七对应关系并保存,入口节点建立第三对应关系和出口节点建立第七对应关系可以参照上述举例,在此不再赘述。出口节点也可以预存指示信息,接收到指示信息后预存,并在接收到第二报文时,根据指示信息指示的还原组播源组信息和第七对应关系得到第一报文头。骨干网络中的封装和解封装是由入口节点和出口节点配合完成的,以此减少报文在骨干网络中传输的开销。In this embodiment, the C-IP Header belongs to the IPv6 header, so the entry node deletes the C-IP Header and then encapsulates P-MPLS. The effect of the header is equivalent to "replacing" the C-IP Header with the MPLS header. In the backbone network, after the second packet is transmitted and reaches the egress node, the egress node then replaces the P-IP header as shown in Figure 7(b). The MPLS header is deleted, and the C-IP Header shown in Figure 7(c) is encapsulated to obtain the first message. The egress node can receive the instruction information transmitted by the ingress node through BGP-MVPN signaling or BGP-EVPN to obtain the fourth correspondence relationship and restore the multicast source group information. After the egress node obtains the fourth correspondence relationship advertised by the ingress node, it can obtain the fourth correspondence relationship according to the egress node The established sixth corresponding relationship and the received fourth corresponding relationship are obtained and saved. The entry node establishing the third corresponding relationship and the exit node establishing the seventh corresponding relationship can refer to the above example, which will not be described again here. The egress node can also pre-store the indication information, store it after receiving the indication information, and when receiving the second message, obtain the first message header according to the restored multicast source group information indicated by the indication information and the seventh corresponding relationship. Encapsulation and decapsulation in the backbone network are completed by the ingress node and egress node, thereby reducing the overhead of packet transmission in the backbone network.
下文的字段设置示例中,将第二报文头记作P-MPLS头,第一报文头记作C-IP Header,封装C-IP Header时各字段的设置的一种示例如下:In the following field setting examples, the second packet header is recorded as the P-MPLS header, and the first message header is recorded as the C-IP Header. An example of the setting of each field when encapsulating the C-IP Header is as follows:
C-IP Header的Version:IPv6的版本号为6;C-IP Header Version: IPv6 version number is 6;
C-IP Header的TC:根据本地配置策略设置TC值;C-IP Header's TC: Set the TC value according to the local configuration policy;
C-IP Header的FL:根据本地配置策略设置FL值;C-IP Header's FL: Set the FL value according to the local configuration policy;
C-IP Header的PL:可以按照C-Payload中的IPv4或者IPv6头部进行设置,比如C-Payload中包括的封装头属于IPv6头,则可以通过C-Payload中的IPv6头的Payload Length字段再加上IPv6头长度40得到作为C-IP头的Payload Length字段,同理,如果C-Payload中包括的封装头属于IPv4头,则可以通过C-Payload中的IPv4头的Payload Length字段再加上IPv4头长度得到作为C-IP头的Payload Length字段;C-IP Header's PL: It can be set according to the IPv4 or IPv6 header in C-Payload. For example, the encapsulation header included in C-Payload belongs to the IPv6 header, and it can be set through the Payload Length field of the IPv6 header in C-Payload. Add the IPv6 header length 40 to get the Payload Length field as the C-IP header. Similarly, if the encapsulation header included in the C-Payload belongs to the IPv4 header, you can add the Payload Length field of the IPv4 header in the C-Payload. The IPv4 header length is obtained as the Payload Length field of the C-IP header;
C-IP Header的NH:需要根据C-Payload中的IPv4头或者IPv6头进行设置,比如C-Payload中包括的封装头属于IPv6头,则Next Header字段设置41,同理,如果C-Payload中包括的封装头属于IPv4头,则Next Header字段设置4;C-IP Header's NH: needs to be set according to the IPv4 header or IPv6 header in C-Payload. For example, the encapsulation header included in C-Payload belongs to the IPv6 header, then the Next Header field is set to 41. Similarly, if the encapsulation header included in C-Payload If the included encapsulation header belongs to the IPv4 header, the Next Header field is set to 4;
C-IP Header的HL:根据本地配置策略设置HL值;C-IP Header's HL: Set the HL value according to the local configuration policy;
C-IP Header的SA和DA:通过MPLS标签值和第七对应关系,设置SA字段和DA字段,如,可以通过MPLS标签值为10001从第三对应关系得到组播源组信息(S1,G2),对应设置SA字段和DA字段。SA and DA of C-IP Header: Set the SA field and DA field through the MPLS label value and the seventh corresponding relationship. For example, the multicast source group information (S1, G2) can be obtained from the third corresponding relationship through the MPLS label value of 10001. ), set the SA field and DA field accordingly.
图8为本申请实施例提供的另一种封装和解封装报文结构示意图,在一些实例中,骨干网络的报文的封装格式可以参照draft-xie-bier-ipv6-encapsulation-09的封装方式,如图8所示,入口节点收到的报文为如图8(a)所示,第一报文包括C-IP Header和C-Payload,入口节点删除接收到的第一报文的C-IP Header,封装P-IP Header和扩展头,得到第二报文头,如图8(b)所示,第二报文包括P-IP Header、扩展头和C-Payload,且,第二报文不包括C-IP Header,第二报文到达出口节点后,出口节点删除第二报文的P-IP Header和扩展头,并封装C-IP Header,得到第一报文,如图8(c)所示,第一报文包括C-IP Header和C-Payload。Figure 8 is a schematic structural diagram of another encapsulation and decapsulation message provided by the embodiment of the present application. In some examples, the encapsulation format of the backbone network message can refer to the encapsulation method of draft-xie-bier-ipv6-encapsulation-09. As shown in Figure 8, the message received by the entry node is as shown in Figure 8(a). The first message includes C-IP Header and C-Payload. The entry node deletes the C- of the first message received. IP Header, encapsulates P-IP Header and extension header to obtain the second message header, as shown in Figure 8(b). The second message includes P-IP Header, extension header and C-Payload, and, the second message The message does not include the C-IP Header. After the second message reaches the egress node, the egress node deletes the P-IP Header and extension header of the second message and encapsulates the C-IP Header to obtain the first message, as shown in Figure 8 ( As shown in c), the first message includes C-IP Header and C-Payload.
入口节点进行P-IP Header和扩展头封装,目前已经定义和使用的IPv6扩展头包括逐跳选项头(Hop-by-hop Options Header)、DOH、路由头(Routing Header)、分片头(Fragment Header)、认证头(Authentication Header)和封装安全有效载荷头(ESP),本申请实施例以扩展头为DOH举例进行说明。DOH由于承载特别针对数据包目的地址的可选信息, 本例中,DOH通过无状态转发的BIER选项或BitString承载目的地址的可选信息,如图2所示的场景中,有4个边缘BFR,每个边缘BFR需要配置1~256的唯一值,其中,有3个BFER,这3个目的节点集合就可以设置256比特(bit)或32字节的BitString来表示,BitString中的每个bit用来标识1个BFER,例如图2中的出口节点1的BFR-ID=1,出口节点2的BFR-ID=2,出口节点3的BFR-ID=3,其中,BFR-ID=1在BitString中可以用最右位的bit为1来标识,BFR-ID=2在BitString中可以用从右往左第2个bit为1来标识1,BFR-ID=3在BitString从右往左第3个bit为1来标识。本申请实施例中,目标地址可以设置在IPv6头的DA字段中,在一些未封装有目标地址的报文中,BitString中不同bit标识的BFER也可以用于指示报文要离开骨干网络发往CE设备时对应的出口节点。The entry node encapsulates P-IP Header and extension header. The currently defined and used IPv6 extension headers include Hop-by-hop Options Header, DOH, Routing Header, and Fragment Header. ), authentication header (Authentication Header) and Encapsulated Security Payload Header (ESP). In the embodiment of this application, the extension header is DOH as an example for explanation. DOH carries optional information specific to the destination address of the data packet. In this example, DOH carries the optional information of the destination address through the BIER option of stateless forwarding or BitString. In the scenario shown in Figure 2, there are 4 edge BFRs, and each edge BFR needs to be configured with a unique value of 1 to 256. Among them, there are 3 BFERs. These 3 destination node sets can be represented by setting a 256-bit or 32-byte BitString. Each bit in the BitString is used to identify a BFER, such as the exit node in Figure 2. The BFR-ID of 1=1, the BFR-ID of egress node 2=2, and the BFR-ID of egress node 3=3. Among them, BFR-ID=1 can be identified by using the rightmost bit as 1 in BitString. BFR-ID=2 can be identified by using the second bit from right to left as 1 in BitString. BFR-ID=3 can be identified by using the third bit from right to left as 1 in BitString. In the embodiment of this application, the target address can be set in the DA field of the IPv6 header. In some packets that are not encapsulated with the target address, the BFER identified by different bits in the BitString can also be used to indicate that the packet is to leave the backbone network and be sent to The CE device is the corresponding egress node.
以C-IP Header属于IPv6头,P-IP Header属于IPv6头,扩展头是DOH,DOH含有用于无状态转发的BIER选项或BitString为例。下文的字段设置示例中,将第一报文头记作C-IP Header,第二报文头包括P-IP Header和DOH,封装P-IP Header和DOH时各字段的设置的一种示例如下:Take the C-IP Header as an IPv6 header, the P-IP Header as an IPv6 header, the extension header is DOH, and DOH contains the BIER option or BitString for stateless forwarding as an example. In the field setting examples below, the first header is recorded as C-IP Header, and the second header includes P-IP Header and DOH. An example of setting each field when encapsulating P-IP Header and DOH is as follows :
P-IP Header的Ver:IPv6的版本号为6;P-IP Header's Ver: The version number of IPv6 is 6;
P-IP Header的TC:将C-IP Header中的TC字段拷贝到P-IP Header的TC字段中,或者根据本地配置策略设置TC值,如本地配置策略中TC值等于1,则设置为1;TC of P-IP Header: Copy the TC field in the C-IP Header to the TC field of the P-IP Header, or set the TC value according to the local configuration policy. If the TC value in the local configuration policy is equal to 1, set it to 1. ;
P-IP Header的FL:将C-IP Header中的FL字段拷贝到P-IP Header的FL字段中,或者根据本地配置策略设置FL值;FL of P-IP Header: Copy the FL field in the C-IP Header to the FL field of the P-IP Header, or set the FL value according to the local configuration policy;
P-IP Header的PL:Payload Length字段的设置可以根据C-IP Header中的Payload Length字段值加上DOH的长度得到;P-IP Header's PL: The setting of the Payload Length field can be obtained based on the Payload Length field value in the C-IP Header plus the length of the DOH;
P-IP Header的NH:指示紧跟着的下一个头部字段,本例中为指示DOH;NH of P-IP Header: indicates the next header field that follows, in this case, indicates DOH;
P-IP Header的HL:将C-IP Header中的HL字段拷贝到P-IP Header的HL字段中,或者根据本地配置策略设置HL值;HL of P-IP Header: Copy the HL field in the C-IP Header to the HL field of the P-IP Header, or set the HL value according to the local configuration policy;
P-IP Header的SA和DA:通过C-IP Header中的SA字段和DA字段和对应关系,设置SA字段和DA字段,如,可以通过C-IP Header中的SA字段和DA字段得到组播源组信息(S1,G2),根据第一对应关系得到隧道信息是(S-P1,D-P2),SA字段填入S-P1,DA字段填入D-P2;SA and DA of P-IP Header: Set the SA field and DA field through the SA field and DA field in the C-IP Header and the corresponding relationship. For example, you can obtain multicast through the SA field and DA field in the C-IP Header. Source group information (S1, G2), according to the first corresponding relationship, the tunnel information is (S-P1, D-P2), fill in the SA field with S-P1, and fill in the DA field with D-P2;
DOH:含有用于无状态转发的BIER选项或BitString。DOH: Contains BIER options or BitString for stateless forwarding.
需要说明的是,上述字段设置以DOH举例,在属于IPv6头的P-IP Header包含的其他类型扩展头中,若有需要设置Next Header字段的,则将C-IP Header中的Next Header字段拷贝到其中。属于IPv6头的P-IP Header包含的其他类型扩展头中的各字段的设置参考draft-xie-bier-ipv6-encapsulation,在此不再展开详述。It should be noted that the above field settings are based on DOH as an example. Among other types of extension headers included in the P-IP Header belonging to the IPv6 header, if it is necessary to set the Next Header field, copy the Next Header field in the C-IP Header. into it. For the settings of each field in other types of extension headers included in the P-IP Header belonging to the IPv6 header, refer to draft-xie-bier-ipv6-encapsulation, which will not be described in detail here.
进一步地,出口节点得到的第二报文头包括IPv6头和IPv6扩展头,IPv6头中包括与隧道信息对应的源地址和目的地址,其中,目的地址为入口节点在组播树的下一跳的地址或者目的地址为组播树对应的组播组地址。Further, the second message header obtained by the egress node includes an IPv6 header and an IPv6 extension header. The IPv6 header includes a source address and a destination address corresponding to the tunnel information, where the destination address is the next hop of the ingress node in the multicast tree. The address or destination address is the multicast group address corresponding to the multicast tree.
出口节点收到的第二报文的第二报文头包括P-IP Header和DOH,删除如图8(b)所示的P-IP Header和DOH,封装C-IP Header,得到如图8(c)所示的第一报文,下文的字段设置示例中,将第一报文头记作C-IP Header,第二报文头包括的P-IP Header属于IPv6头,封装C-IP Header的各字段的设置的一种示例如下: The second header of the second message received by the egress node includes P-IP Header and DOH. Delete the P-IP Header and DOH as shown in Figure 8(b), and encapsulate the C-IP Header to obtain Figure 8 For the first message shown in (c), in the field setting example below, the first message header is recorded as C-IP Header, and the P-IP Header included in the second message header belongs to the IPv6 header, encapsulating C-IP An example of setting each field of the Header is as follows:
C-IP Header的Version:IPv6的版本号为6;C-IP Header Version: IPv6 version number is 6;
C-IP Header的TC:将P-IP Header中的TC字段拷贝到C-IP Header的TC字段中,或者根据本地配置策略设置TC值,如果入口节点根据本地配置策略在P-IP Header中的TC字段设置1,出口节点拷贝1即可,不用恢复第一报文进入骨干网络时的TC字段内容;TC of C-IP Header: Copy the TC field in the P-IP Header to the TC field of the C-IP Header, or set the TC value according to the local configuration policy. If the ingress node sets the TC value in the P-IP Header according to the local configuration policy, Set the TC field to 1 and copy 1 to the egress node. There is no need to restore the TC field content when the first packet entered the backbone network;
C-IP Header的FL:将P-IP Header中的FL字段拷贝到C-IP Header的FL字段中,或者根据本地配置策略设置FL值;FL of C-IP Header: Copy the FL field in the P-IP Header to the FL field of the C-IP Header, or set the FL value according to the local configuration policy;
C-IP Header的PL:可以根据P-IP Header中的PL字段值减去DOH的长度得到;PL of C-IP Header: It can be obtained by subtracting the length of DOH from the PL field value in P-IP Header;
C-IP Header的NH:指示紧跟着的下一个头部字段,如果C-Payload中包含的封装头属于IPv6头,则NH为41;NH of C-IP Header: indicates the next header field that follows. If the encapsulation header contained in C-Payload belongs to the IPv6 header, NH is 41;
C-IP Header的HL:将P-IP Header中的HL字段拷贝到C-IP Header的HL字段中,或者根据本地配置策略设置HL值;HL of C-IP Header: Copy the HL field in the P-IP Header to the HL field of the C-IP Header, or set the HL value according to the local configuration policy;
C-IP Header的SA和DA:通过P-IP Header中的SA字段和DA字段和对应关系,设置SA字段和DA字段,如,可以通过P-IP Header中的SA字段和DA字段得到隧道信息是(S-P1,D-P2)根据第一对应关系得到组播源组信息(S1,G2),C-IP Header的SA字段填入S1,C-IP Header的DA字段填入G2。SA and DA of C-IP Header: Set the SA field and DA field through the SA field and DA field in the P-IP Header and the corresponding relationship. For example, you can obtain the tunnel information through the SA field and DA field in the P-IP Header. Yes (S-P1, D-P2) obtains the multicast source group information (S1, G2) based on the first corresponding relationship, fills in the SA field of the C-IP Header with S1, and fills in the DA field of the C-IP Header with G2.
在一种示例中,封装第一报文头时,各字段的设置可以是出口节点静态配置的,用于设置字段的本地配置策略也可以是提前预设的。在另一种示例中,出口节点根据入口节点发送的指示信息在封装时填入第一报文头中组播源组信息的对应字段,或者,出口节点根据入口节点发送的删除还原指示信息的指示来确定第一报文头中的字段是如何根据第二报文头的字段或本地配置策略进行设置的。在另一种示例中,用于设置字段的本地配置策略是提前预设的,出口节点接收到的指示信息,可以根据指示信息指示的对应关系和配置的其他信息设置相应字段。进一步地,出口节点接收到指示信息后,可以先保存,在接收到第二报文时,根据指示信息的指示还原第一报文。举例来说,出口节点如果通过BGP-MVPN信令收到指示信息,该指示信息可以指示第一对应关系。出口节点也可以通过预先设置的配置将第二报文恢复为第一报文。本申请实施例仅为举例说明,不以举例为限定。In one example, when encapsulating the first message header, the settings of each field may be statically configured by the egress node, and the local configuration policy used to set the fields may also be preset in advance. In another example, the egress node fills in the corresponding field of the multicast source group information in the first message header during encapsulation according to the instruction information sent by the ingress node, or the egress node fills in the corresponding field of the multicast source group information in the first message header according to the deletion and restoration instruction information sent by the ingress node. Indicates how the fields in the first packet header are set based on the fields in the second packet header or the local configuration policy. In another example, the local configuration policy for setting fields is preset in advance, and the instruction information received by the egress node can set the corresponding fields according to the corresponding relationship indicated by the instruction information and other configured information. Further, after receiving the indication information, the egress node can save it first, and when receiving the second message, restore the first message according to the instruction of the indication information. For example, if the egress node receives indication information through BGP-MVPN signaling, the indication information may indicate the first corresponding relationship. The egress node can also restore the second message to the first message through preset configuration. The embodiments of this application are only illustrative and not limiting.
进一步地,本申请实施例提供一种能够适用于上述各种封装格式的静态配置指示信息的示例,入口节点可以动态地为同一虚拟路由转发(Virtual Routing Forwarding,VRF)下所有的组播流量,即为组播源组信息(S,G)分配对应的隧道信息。可选的,入口节点进行配置时,还可以在对应关系中表示出组播流量所属的VRF,如可以用的标识,例如,该标识为VRF1。组播流量所属的VRF的标识可以是VRF的名字、VRF的ID号对应的整数来标识,需要说明的是,在报文发送的过程中,该VRF标识应满足报文传输协议的要求,以VRF标识可以是为路由表(route-target)标识,可参考RFC4364定义,VRF标识记作VRF1,图9为本申请实施例提供的一种配置方法,如图9所示,该方法包括:Further, the embodiment of this application provides an example of static configuration indication information that can be applied to various encapsulation formats mentioned above. The entry node can dynamically forward all multicast traffic under the same virtual routing (Virtual Routing Forwarding, VRF). That is, corresponding tunnel information is allocated to the multicast source group information (S, G). Optionally, when configuring the entry node, the VRF to which the multicast traffic belongs can also be indicated in the corresponding relationship, such as an identifier that can be used. For example, the identifier is VRF1. The VRF to which the multicast traffic belongs can be identified by the name of the VRF and the integer corresponding to the ID number of the VRF. It should be noted that during the message sending process, the VRF identifier should meet the requirements of the message transmission protocol to ensure The VRF identifier may be a routing table (route-target) identifier, which can be defined with reference to RFC4364. The VRF identifier is recorded as VRF1. Figure 9 is a configuration method provided by an embodiment of the present application. As shown in Figure 9, the method includes:
S201、入口节点配置VRF,建立对应关系。S201. The entry node configures the VRF and establishes a corresponding relationship.
其具体的配置如下所示:

Its specific configuration is as follows:

即,入口节点使能图8(a)中C-IP Header的SA字段、DA字段弹出,并从本地所有(locator a1)的地址范围内动态分配地址,以对应每个组播流量,例如,入口节点得到的对应关系可以是(2001:A:1:1::1001,VRF1,S1v6,G1v6),其中,图8(b)P-IP Header的IPv6地址=2001:A:1:1::1001,即第二报文头中的隧道信息为2001:A:1:1::1001,VRF1可以是根据RFC4364定义的路由表对象,C-IP Header的组播源组信息中源地址为S1v6,即第一报文头的SA字段为S1v6,C-IP Header的组播源组信息中目的地址,即组播地址为G1v6,即第一报文头的DA字段为G1v6。That is, the entry node enables the SA field and DA field of the C-IP Header in Figure 8(a) to pop up, and dynamically allocates addresses from the address range of the local owner (locator a1) to correspond to each multicast traffic, for example, The corresponding relationship obtained by the entry node can be (2001:A:1:1::1001, VRF1, S1v6, G1v6), where the IPv6 address of the P-IP Header in Figure 8(b) = 2001:A:1:1: :1001, that is, the tunnel information in the second header is 2001:A:1:1::1001, VRF1 can be a routing table object defined according to RFC4364, and the source address in the multicast source group information of the C-IP Header is S1v6, that is, the SA field in the first packet header is S1v6, and the destination address in the multicast source group information of the C-IP Header, that is, the multicast address is G1v6, that is, the DA field in the first packet header is G1v6.
S202、入口节点向出口节点通告对应关系。S202. The entry node notifies the exit node of the corresponding relationship.
以入口节点为A节点,出口节点为D节点为例,A节点与D节点间可以相互建立BGP邻居关系,A节点可以向出口节点发送BGP消息,BGP消息包括对应关系,如,A节点可以发送BGP-MVPN的S-PMSI A-D路由消息,该S-PMSI A-D路由消息包含(VRF标识,C-IP Header的SA字段,C-IP Header的DA字段,P-IP Header的IPv6地址),其中,C-IP Header的SA字段是组播源组信息中源地址S1v6,C-IP Header的DA字段是组播源组信息中目的地址G1v6,P-IP Header的IPv6地址是隧道信息的地址2001:A:1:1::1001。A节点还可以在该S-PMSI A-D路由消息中携带删除还原指示信息,该删除还原指示信息可以用于指示D节点还原第一报文头的方法。A节点可以通过BGP属性值类型长度(Type length value,TLV)来携带此指示信息。Taking the ingress node as node A and the egress node as node D as an example, node A and node D can establish a BGP neighbor relationship with each other. Node A can send BGP messages to the egress node. The BGP messages include corresponding relationships. For example, node A can send BGP-MVPN's S-PMSI A-D routing message. The S-PMSI A-D routing message contains (VRF identification, C-IP Header's SA field, C-IP Header's DA field, P-IP Header's IPv6 address), where, The SA field of the C-IP Header is the source address S1v6 in the multicast source group information, the DA field of the C-IP Header is the destination address G1v6 in the multicast source group information, and the IPv6 address of the P-IP Header is the address 2001 of the tunnel information: A:1:1::1001. The A node may also carry deletion and restoration indication information in the S-PMSI A-D routing message, and the deletion and restoration indication information may be used to instruct the D node to restore the first message header. A node can carry this indication information through BGP attribute value type length (Type length value, TLV).
S203、出口节点根据通告建立组播源组信息与隧道信息的对应关系。S203. The egress node establishes the corresponding relationship between the multicast source group information and the tunnel information according to the advertisement.
如,入口节点为A节点,出口节点为D节点,D节点收到上述消息,建立起C-IP和P-IP的SA字段和DA字段的对应关系。例如D节点上配置有VRF1标识,VRF1是本机VRF1的标识,可以是VRF1的名字,或者VRF1的ID号整数值,D节点根据消息中的VRF标识和自身配置的VRF标识,确定该消息对应哪个VRF,由于D节点的VRF标识为VRF1,与该消息中的VRF标识相同,则D节点可以根据消息中的(VRF标识,C-IP Header的SA,C-IP Header的DA,P-IP Header的IPv6地址),确定VRF1下的如下对应关系:(2001:A:1:1::1001,VRF1,S1v6,G1v6),D节点保存该对应关系。For example, the entry node is node A and the exit node is node D. Node D receives the above message and establishes the corresponding relationship between the SA field and DA field of C-IP and P-IP. For example, the D node is configured with the VRF1 identifier. VRF1 is the identifier of the local VRF1, which can be the name of VRF1, or the integer value of the ID number of VRF1. The D node determines the corresponding message based on the VRF identifier in the message and its own configured VRF identifier. Which VRF, because the VRF identification of the D node is VRF1, which is the same as the VRF identification in the message, the D node can determine the VRF according to the (VRF identification, C-IP Header's SA, C-IP Header's DA, P-IP Header's IPv6 address), determine the following correspondence under VRF1: (2001:A:1:1::1001, VRF1, S1v6, G1v6), and node D saves this correspondence.
S204、入口节点收到第一报文,并根据对应关系封装报文,得到第二报文。S204. The entry node receives the first message, encapsulates the message according to the corresponding relationship, and obtains the second message.
如,入口节点收到图2中的CE设备1发送的第一报文时IPv6头组播报文,根据组播源组信息和入口节点中的对应关系即(VRF标识,C-IP Header的SA字段,C-IP Header的DA字段,P-IP Header的IPv6地址)封装得到第二报文,例如该IPv6组播报文的第一报文头中SA=S1v6、DA=G1v6,根据对应关系,可以在第二报文头的隧道信息中对应设置P-IP Header的IPv6地址为2001:A:1:1::1001,封装第二报文头并删除第一报文头,得到第二报文。For example, when the entrance node receives the first message sent by CE device 1 in Figure 2, the IPv6 header multicast message is received. According to the corresponding relationship between the multicast source group information and the entrance node, that is, (VRF identification, C-IP Header SA field, C-IP Header's DA field, P-IP Header's IPv6 address) are encapsulated to obtain the second message. For example, in the first header of the IPv6 multicast message, SA=S1v6, DA=G1v6, according to the corresponding relationship, you can set the IPv6 address of the P-IP Header to 2001:A:1:1::1001 in the tunnel information of the second header, encapsulate the second header and delete the first header to get the Two messages.
S205、出口节点收到第二报文,删除第二报文头,封装第一报文头,得到第一报文。S205. The egress node receives the second message, deletes the second message header, encapsulates the first message header, and obtains the first message.
出口节点收到第二报文,该第二报文可以是本申请实施例提供的各种实例中的封装格 式的报文,第二报文的隧道信息若设置为2001:A:1:1::1001,根据出口节点上预存的(VRF标识,C-IP Header的SA字段,C-IP Header的DA字段,P-IP Header的IPv6地址)的对应值,如(S1v6,G1v6,2001:A:1:1::1001)可以得到组播源组信息(S1v6,G1v6),即组播源组信息的源地址为S1v6,组播源组信息的组播地址为G1v6,设置第一报文头相应字段,得到第一报文,并向CE设备进行转发。第一报文其他字段的内容,可以根据本地配置策略设置,也可以根据删除还原指示信息指示的方法进行设置,本申请不做限定。The egress node receives the second message. The second message may be an encapsulation format in various examples provided by the embodiments of this application. For the message in the format, if the tunnel information of the second message is set to 2001:A:1:1::1001, based on the pre-stored (VRF identification, C-IP Header's SA field, C-IP Header's DA field, the corresponding value of the P-IP Header's IPv6 address), such as (S1v6, G1v6, 2001:A:1:1::1001), you can get the multicast source group information (S1v6, G1v6), that is, the multicast source group information The source address is S1v6, the multicast address of the multicast source group information is G1v6, set the corresponding field in the first packet header, obtain the first packet, and forward it to the CE device. The content of other fields in the first message can be set according to the local configuration policy, or can be set according to the method indicated by the deletion and restoration instruction information, which is not limited in this application.
图10为本申请实施例提供的另一种封装和解封装报文结构示意图,本申请实施例中BIER封装的类型可以有多种,在一个示例中,可以通过MPLS对BIER报文进行的封装,这种封装可以称为BIER-MPLS封装。在另一个示例中,可以通过IPv6对BIER报文进行的封装,这种封装可以称为BIERv6封装。本申请以BIER-MPLS封装为例入口节点在第删除第一报文头,并封装BIER头以及上游标签为例,该上游标签为上游MPLS标签,在骨干网络中,入口节点为上游节点,该上游标签(上游MPLS标签)为入口节点的标签。上游MPLS标签和上游MPLS标签封装格式可以参照使用RFC8296和RFC8556的BIER-MPLS MVPN封装方式,BIER适合于MPLS网络。如图10所示,入口节点收到的报文为如图10(a)所示的格式,第一报文包括第一报文头(C-IP Header)和C-Payload,C-IP Header属于IPv6头,入口节点删除接收到的第一报文的C-IP Header,并封装P-BIER Header和上游标签得到第二报文,第二报文如图10(b)所示,包括C-Payload、P-BIER Header和上游标签,且,第二报文不包括C-IP Header,以上游标签为上游MPLS标签为例,第二报文到达出口节点后,出口节点将第二报文的P-BIER Header和上游标签删除,封装C-IP Header得到第一报文如图10(c)所示,第一报文包括C-IP Header和C-Payload。Figure 10 is a schematic structural diagram of another encapsulation and decapsulation message provided by the embodiment of the present application. In the embodiment of the present application, there can be multiple types of BIER encapsulation. In one example, the BIER message can be encapsulated through MPLS. This kind of encapsulation can be called BIER-MPLS encapsulation. In another example, the BIER message can be encapsulated through IPv6, and this encapsulation can be called BIERv6 encapsulation. This application takes BIER-MPLS encapsulation as an example. The entry node deletes the first message header and encapsulates the BIER header and the upstream label. The upstream label is the upstream MPLS label. In the backbone network, the entry node is the upstream node. The upstream label (upstream MPLS label) is the label of the ingress node. The upstream MPLS label and upstream MPLS label encapsulation format can refer to the BIER-MPLS MVPN encapsulation method using RFC8296 and RFC8556. BIER is suitable for MPLS networks. As shown in Figure 10, the message received by the entry node is in the format shown in Figure 10(a). The first message includes the first message header (C-IP Header) and C-Payload. C-IP Header Belonging to the IPv6 header, the entry node deletes the C-IP Header of the received first message, and encapsulates the P-BIER Header and upstream label to obtain the second message. The second message is shown in Figure 10(b), including C -Payload, P-BIER Header and upstream label, and the second message does not include the C-IP Header. Taking the upstream label as the upstream MPLS label as an example, after the second message reaches the egress node, the egress node will The P-BIER Header and upstream label are deleted, and the C-IP Header is encapsulated to obtain the first message as shown in Figure 10(c). The first message includes C-IP Header and C-Payload.
入口节点进行BIER Header封装,表5为入口节点封装的BIER Header各字段的示意:
The entry node encapsulates BIER Header. Table 5 shows the fields of the BIER Header encapsulated by the entry node:
表5table 5
如表5所示,BIER Header包括如下部分:As shown in Table 5, BIER Header includes the following parts:
位索引转发表标识(Bit Index Forwarding Table identification,BIFT-ID):用于位索引转发,出口节点可以根据BIER Header中的BIFT ID确定该报文属于哪个SD,使用的BSL以及转发该报文的节点或配置的BFR ID组成的集合,BIFT-ID可以对应子域(Sub-Domain,SD)、比特串长度(Bit String Length,BSL)和集合标识(Set Identifier,SI)的组合,不同的BIFT ID可以对应于不同的SD、BSL和SI组合;Bit Index Forwarding Table identification (BIFT-ID): used for bit index forwarding. The egress node can determine which SD the message belongs to, the BSL used and the method for forwarding the message based on the BIFT ID in the BIER Header. A collection of node or configured BFR IDs. BIFT-ID can correspond to a combination of sub-domain (Sub-Domain, SD), bit string length (Bit String Length, BSL) and set identifier (Set Identifier, SI). Different BIFT IDs can correspond to different SD, BSL and SI combinations;
BSL:为BIER Header中包括的bit string的长度; BSL: is the length of the bit string included in the BIER Header;
Proto:可以设置2来表示BIER Header后面是“上游MPLS标签”,可以设置4表示BIER Header后面的CE设备发送的报文属于IPv4报文,或,设置6表示BIER Header后面的CE设备发送的报文属于IPv4报文;Proto: You can set 2 to indicate that the BIER Header is followed by the "upstream MPLS label", you can set 4 to indicate that the packets sent by the CE device behind the BIER Header are IPv4 packets, or you can set 6 to indicate that the packets sent by the CE device behind the BIER Header are IPv4 packets. The message is an IPv4 message;
比特串BitString:用于标识组播业务BFER集合,使得出口节点根据BitString字段确定接收到的第二报文是否为发送给本节点的报文;Bit string BitString: used to identify the multicast service BFER set, so that the egress node determines whether the received second message is a message sent to the node based on the BitString field;
BIER头中除了上述字段外,还可以包含Ver、差分服务代码点(Differentiated Services Code Point,DSCP)、TTL、Entropy、操作维护管理(Operation Administration and Maintenance,OAM)、TC、栈(stack,S)等字段,在此不展开详述,表5的字段示意仅为举例,不做限定。In addition to the above fields, the BIER header can also include Ver, Differentiated Services Code Point (DSCP), TTL, Entropy, Operation Administration and Maintenance (OAM), TC, stack (S) The fields are not described in detail here. The fields in Table 5 are only examples and are not limited.
与隧道信息对应的第二报文头包括BIER头和上游标签,如上游MPLS标签,BIER头包括与隧道信息对应的出口节点的标识,上游MPLS标签用于标识组播源组信息,BIER头参照表5的格式,该上游MPLS标签参照表4的MPLS头格式。The second header corresponding to the tunnel information includes a BIER header and an upstream label, such as an upstream MPLS label. The BIER header includes the identity of the egress node corresponding to the tunnel information. The upstream MPLS label is used to identify the multicast source group information. The BIER header refers to The format of Table 5, the upstream MPLS label refers to the MPLS header format of Table 4.
举例来说,上游MPLS标签可以用于标识组播源组信息,进而根据组播源组信息确定对应的CE设备所属的VPN。上游MPLS标签可以用于标识组播源组信息可以参照MPLS标签的举例,在此不再赘述。For example, the upstream MPLS label can be used to identify the multicast source group information, and then determine the VPN to which the corresponding CE device belongs based on the multicast source group information. The upstream MPLS label can be used to identify the multicast source group. For information, please refer to the example of the MPLS label, which will not be described again here.
入口节点可以将分配的标签值设置封装的上游MPLS标签的Label字段中,上游MPLS标签的字段设置参照上例中MPLS头封装时各字段的设置,在此不再赘述。BIER头包括与隧道信息对应的出口节点的标识,可以是在入口节点在BitString中对应设置出口节点的ID,如图2所示的出口节点ID分别是ID=1,ID=2和ID=3。BIER头其他字段的设置可参考RFC8296和RFC8556的要求,根据接收到的第一报文中的C-IP Header字段对应设置,或根据本地配置策略设置,也不再展开。The entry node can set the assigned label value in the Label field of the encapsulated upstream MPLS label. The field settings of the upstream MPLS label refer to the settings of each field in the MPLS header encapsulation in the above example, which will not be described again here. The BIER header includes the identification of the exit node corresponding to the tunnel information. The ID of the exit node can be set correspondingly in BitString at the entry node. As shown in Figure 2, the exit node IDs are ID=1, ID=2 and ID=3 respectively. . The settings of other fields in the BIER header can refer to the requirements of RFC8296 and RFC8556, and are set according to the C-IP Header field in the first received message, or according to the local configuration policy settings, which will not be expanded.
出口节点接收到第二报文,删除封装的BIER头和上游MPLS标签,恢复第一报文头,得到第一报文,第二报文头包括P-BIER Header和上游MPLS标签,第一报文头记作C-IP Header,封装C-IP Header时各字段的设置的一种示例如下:The egress node receives the second message, deletes the encapsulated BIER header and upstream MPLS label, restores the first message header, and obtains the first message. The second message header includes the P-BIER Header and the upstream MPLS label. The first message The header is recorded as C-IP Header. An example of setting each field when encapsulating C-IP Header is as follows:
C-IP Header的Version:IPv6的版本号为6;C-IP Header Version: IPv6 version number is 6;
C-IP Header的TC:根据本地配置策略设置TC值;C-IP Header's TC: Set the TC value according to the local configuration policy;
C-IP Header的FL:根据本地配置策略设置FL值;C-IP Header's FL: Set the FL value according to the local configuration policy;
C-IP Header的PL:可以按照C-Payload中包含的封装头属于IPv4头或者IPv6头进行设置,比如C-Payload中包含的封装头属于IPv6头,则可以通过IPv6头的Payload Length字段再加上IPv6头长度40得到作为C-IP头的Payload Length字段,同理,如果C-Payload中包含的封装头属于IPv4头,则可以通过IPv4头的Payload Length字段再加上IPv4头长度得到作为C-IP头的Payload Length字段;C-IP Header's PL: It can be set according to whether the encapsulation header contained in C-Payload belongs to IPv4 header or IPv6 header. For example, if the encapsulation header contained in C-Payload belongs to IPv6 header, it can be added through the Payload Length field of IPv6 header. The IPv6 header length 40 is used to obtain the Payload Length field of the C-IP header. Similarly, if the encapsulation header contained in the C-Payload belongs to the IPv4 header, the Payload Length field of the IPv4 header plus the IPv4 header length can be used to obtain the C-IP header. -Payload Length field of IP header;
C-IP Header的NH:需要根据C-Payload中的IPv4头或者IPv6头进行设置,比如C-Payload中包含的封装头属于IPv6头,则Next Header字段设置41,同理,如果C-Payload中包含的封装头属于IPv4头,则Next Header字段设置4;C-IP Header's NH: needs to be set according to the IPv4 header or IPv6 header in C-Payload. For example, the encapsulation header contained in C-Payload belongs to the IPv6 header, then the Next Header field is set to 41. Similarly, if the C-Payload If the included encapsulation header belongs to the IPv4 header, the Next Header field is set to 4;
C-IP Header的HL:根据本地配置策略设置HL值;C-IP Header's HL: Set the HL value according to the local configuration policy;
C-IP Header的SA和DA:通过Label字段和对应关系,设置SA字段和DA字段,如,可以通过Label字段中的10001从对应关系得到组播源组信息(S1,G2),将得到的组播源组信息源地址对应设置SA字段,目的地址对应设置DA字段。 SA and DA of C-IP Header: Set the SA field and DA field through the Label field and the corresponding relationship. For example, you can obtain the multicast source group information (S1, G2) from the corresponding relationship through 10001 in the Label field. The obtained The source address of the multicast source group information corresponds to the SA field, and the destination address corresponds to the DA field.
需要说明的是,这种封装格式不限制第一报文中的C-Payload内容,入口节点接收到的C-Payload可以是带有用户数据报协议(User Datagram Protocol,UDP)头的净荷,也可以是包含有IPv4或IPv6头的完整报文,且上游MPLS标签后的C-Payload的格式不会影响到报文的转发过程。It should be noted that this encapsulation format does not limit the C-Payload content in the first message. The C-Payload received by the entry node can be a payload with a User Datagram Protocol (UDP) header. It can also be a complete packet containing an IPv4 or IPv6 header, and the format of the C-Payload after the upstream MPLS label will not affect the forwarding process of the packet.
本申请实施例以第一报文头(C-IP Header)属于IPv6头,第二报文头是P-BIER Header和上游标签为例,入口节点删除C-IP Header头,并封装P-BIER Header和上游标签,其效果等同于将C-IP Header“替换”成了P-BIER Header和上游标签。再由出口节点将P-BIER Header和上游标签删除,封装C-IP Header,本申请实施例以上游标签是上游MPLS标签为例,其效果等同于出口节点将第一报文恢复回来,进入骨干网络的第一报文和离开骨干网络后的第一报文格式一致,且能够减小在骨干网络中的传输开销。In the embodiment of this application, the first message header (C-IP Header) belongs to the IPv6 header, and the second message header is the P-BIER Header and the upstream label. The entry node deletes the C-IP Header header and encapsulates the P-BIER Header and upstream label, the effect is equivalent to "replacing" the C-IP Header with the P-BIER Header and upstream label. The egress node then deletes the P-BIER Header and the upstream label, and encapsulates the C-IP Header. In the embodiment of this application, the upstream label is an upstream MPLS label as an example. The effect is equivalent to the egress node recovering the first packet and entering it into the backbone. The first message of the network has the same format as the first message after leaving the backbone network, and the transmission overhead in the backbone network can be reduced.
本申请实施例提供一种网络设备,网络设备设置于入口节点,可以用于实现上述方法中入口节点的相应功能,图11为本申请实施例提供的一种网络设备10结构示意图,该网络设备可以用于执行以上实施例中的方法S101至S104,或执行S201至S205,当网络设备用于执行以上实施例中的方法S101至S104,或方法S201至S205时,相当于该方法中例举的入口节点。网络设备10包括:接收模块101、处理模块102和发送模块103:Embodiments of the present application provide a network device. The network device is installed at an entry node and can be used to implement the corresponding functions of the entry node in the above method. Figure 11 is a schematic structural diagram of a network device 10 provided by an embodiment of the present application. The network device It can be used to perform methods S101 to S104 or S201 to S205 in the above embodiments. When the network device is used to perform methods S101 to S104 or methods S201 to S205 in the above embodiments, it is equivalent to the examples in this method. entry node. The network device 10 includes: a receiving module 101, a processing module 102 and a sending module 103:
接收模块101,用于接收用户边缘设备发送的第一报文,第一报文包含第一报文头和载荷,第一报文头包括组播源组信息。The receiving module 101 is configured to receive a first message sent by the user edge device. The first message includes a first message header and a payload, and the first message header includes multicast source group information.
处理模块102,用于根据组播源组信息和对应关系,获取隧道信息,对应关系包括组播源组信息和隧道信息。The processing module 102 is configured to obtain tunnel information according to multicast source group information and corresponding relationships, where the corresponding relationships include multicast source group information and tunnel information.
处理模块102,还用于根据载荷和隧道信息获得第二报文,第二报文包含载荷和与隧道信息对应的第二报文头,第二报文不包括第一报文头。The processing module 102 is also configured to obtain a second message according to the payload and the tunnel information. The second message includes the payload and the second message header corresponding to the tunnel information. The second message does not include the first message header.
发送模块103,用于通过与隧道信息对应的隧道发送第二报文。The sending module 103 is configured to send the second message through the tunnel corresponding to the tunnel information.
在一种可能的方式中,与隧道信息对应的第二报文头包括IPv6头和GRE头,IPv6头包括与隧道信息对应的源地址和目的地址。In a possible manner, the second packet header corresponding to the tunnel information includes an IPv6 header and a GRE header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能的方式中,与隧道信息对应的第二报文头包括IPv4头和GRE头,IPv4头包括与隧道信息对应的源地址和目的地址。In a possible manner, the second packet header corresponding to the tunnel information includes an IPv4 header and a GRE header, and the IPv4 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能的方式中,与隧道信息对应的第二报文头包括IPv6头和IPv6扩展头,IPv6头包括与隧道信息对应的源地址和目的地址。In a possible manner, the second message header corresponding to the tunnel information includes an IPv6 header and an IPv6 extension header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能的方式中,与隧道信息对应的第二报文头包括IPv6头,IPv6头包括与隧道信息对应的源地址和目的地址。In a possible manner, the second packet header corresponding to the tunnel information includes an IPv6 header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能的方式中,目的地址为入口节点在组播树的下一跳的地址或者目的地址为组播树对应的组播组地址。In one possible way, the destination address is the next hop address of the entry node in the multicast tree or the destination address is the multicast group address corresponding to the multicast tree.
在一种可能的方式中,与隧道信息对应的第二报文头为多协议标签交换MPLS头,MPLS头包括入口节点在组播树的下一跳节点的MPLS标签或组播树对应的MPLS标签。In one possible way, the second message header corresponding to the tunnel information is a multi-protocol label switching MPLS header. The MPLS header includes the MPLS label of the next hop node of the entry node in the multicast tree or the MPLS corresponding to the multicast tree. Label.
在一种可能的方式中,与隧道信息对应的第二报文头包括位索引显式复制BIER头和标签,BIER头包括与隧道信息对应的出口节点的标识,标签用于标识组播源组信息。In one possible way, the second message header corresponding to the tunnel information includes a bit index explicit copy BIER header and a label. The BIER header includes the identity of the egress node corresponding to the tunnel information. The label is used to identify the multicast source group. information.
在一种可能的方式中,发送模块103,还用于向出口节点通告对应关系。In one possible way, the sending module 103 is also used to notify the egress node of the corresponding relationship.
如,发送模块103,还用于向出口节点通告指示信息,指示信息用于指示还原组播源组信息。 For example, the sending module 103 is also configured to notify the egress node of indication information, where the indication information is used to instruct the restoration of the multicast source group information.
进一步地,发送模块103,具体用于向出口节点发送BGP消息,BGP消息包括对应关系。Further, the sending module 103 is specifically configured to send a BGP message to the egress node, where the BGP message includes the corresponding relationship.
在一种可能的方式中,BGP消息为BGP-MVPN信令或者BGP-EVPN信令。In a possible manner, the BGP message is BGP-MVPN signaling or BGP-EVPN signaling.
当网络设备10用于执行以上方法时,可以应用于图2-图11所示的应用场景中,例如可以是图2所示场景中的入口节点1000。需要说明的是,本申请实施例中对模块的划分是示意性的,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式。本申请实施例中的各功能模块可以集成在一个处理模块中,也可以是各个模块单独物理存在,也可以两个或两个以上模块集成在一个模块中。例如,上述实施例中,发送模块、接收模块和处理模块可以是同一个模块,也可以是不同的模块。上述集成的模块既可以采用硬件的形式实现,例如芯片,也可以采用软件功能模块的形式实现。When the network device 10 is used to perform the above method, it can be applied to the application scenarios shown in Figures 2 to 11, for example, it can be the entry node 1000 in the scenario shown in Figure 2. It should be noted that the division of modules in the embodiment of the present application is schematic and is only a logical function division. In actual implementation, there may be other division methods. Each functional module in the embodiment of the present application can be integrated into one processing module, or each module can exist physically alone, or two or more modules can be integrated into one module. For example, in the above embodiment, the sending module, receiving module and processing module may be the same module or different modules. The above integrated modules can be implemented in the form of hardware, such as chips, or in the form of software function modules.
另外,本申请实施例还提供一种网络设备,网络设备设置于出口节点,该网络设备可以用于执行以上实施例中的方法S105至S107,或执行S201至S205,图12为本申请实施例提供的一种网络设备20结构示意图,当网络设备用于执行以上实施例中的方法S105至S107,或方法S201至S205时,相当于该方法中例举的出口节点。网络设备20包括:接收模块201和处理模块202。In addition, the embodiment of the present application also provides a network device. The network device is installed at the egress node. The network device can be used to execute the methods S105 to S107 in the above embodiment, or perform S201 to S205. Figure 12 is an embodiment of the present application. A schematic structural diagram of a network device 20 is provided. When the network device is used to execute methods S105 to S107 or methods S201 to S205 in the above embodiment, it is equivalent to the egress node exemplified in the method. The network device 20 includes: a receiving module 201 and a processing module 202.
接收模块201,用于接收第二报文,第二报文包括载荷和与隧道信息对应的第二报文头。The receiving module 201 is configured to receive a second message, where the second message includes a payload and a second message header corresponding to the tunnel information.
处理模块202,用于根据第二报文头对应的隧道信息和对应关系,获取组播源组信息,对应关系包括隧道信息和组播源组信息。The processing module 202 is configured to obtain the multicast source group information according to the tunnel information corresponding to the second message header and the corresponding relationship. The corresponding relationship includes the tunnel information and the multicast source group information.
处理模块202,还用于根据组播源组信息和载荷获得第一报文,第一报文包含第一报文头和载荷,第一报文头包括组播源组信息,第一报文不包括第二报文头。The processing module 202 is also configured to obtain a first message according to the multicast source group information and payload. The first message includes a first message header and a payload. The first message header includes multicast source group information. The first message Does not include the second header.
在一种可能的方式中,与隧道信息对应的第二报文头包括IPv6头和GRE头,IPv6头包括与隧道信息对应的源地址和目的地址。In a possible manner, the second packet header corresponding to the tunnel information includes an IPv6 header and a GRE header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能的方式中,与隧道信息对应的第二报文头包括IPv4头和GRE头,IPv4头包括与隧道信息对应的源地址和目的地址。In a possible manner, the second packet header corresponding to the tunnel information includes an IPv4 header and a GRE header, and the IPv4 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能的方式中,与隧道信息对应的第二报文头包括IPv6头和IPv6扩展头,IPv6头包括与隧道信息对应的源地址和目的地址。In a possible manner, the second message header corresponding to the tunnel information includes an IPv6 header and an IPv6 extension header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能的方式中,与隧道信息对应的第二报文头包括IPv6头,IPv6头包括与隧道信息对应的源地址和目的地址。In a possible manner, the second packet header corresponding to the tunnel information includes an IPv6 header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
在一种可能的方式中,目的地址为入口节点在组播树的下一跳的地址或者目的地址为组播树对应的组播组地址。In one possible way, the destination address is the next hop address of the entry node in the multicast tree or the destination address is the multicast group address corresponding to the multicast tree.
在一种可能的方式中,接收模块201,还用于接收第三报文,第三报文包括载荷和与隧道信息对应的第三报文头;处理模块202,还用于根据第三报文头对应的隧道信息和对应关系,获取组播源组信息,对应关系包括隧道信息和组播源组信息,与隧道信息对应的第三报文头为多协议标签交换MPLS头,MPLS头包括出口节点为组播树分配的MPLS标签或组播树对应的MPLS标签。In a possible way, the receiving module 201 is also configured to receive a third message, the third message includes a payload and a third message header corresponding to the tunnel information; the processing module 202 is also configured to receive the third message according to the third message. The tunnel information and corresponding relationship corresponding to the header are used to obtain the multicast source group information. The corresponding relationship includes tunnel information and multicast source group information. The third header corresponding to the tunnel information is the multi-protocol label switching MPLS header. The MPLS header includes The MPLS label assigned by the egress node to the multicast tree or the MPLS label corresponding to the multicast tree.
在一种可能的方式中,与隧道信息对应的第二报文头包括位索引显式复制BIER头和标签,BIER头包括与隧道信息对应的出口节点的标识,标签用于标识组播源组信息。In one possible way, the second message header corresponding to the tunnel information includes a bit index explicit copy BIER header and a label. The BIER header includes the identity of the egress node corresponding to the tunnel information. The label is used to identify the multicast source group. information.
在一种可能的方式中,接收模块201,还用于获取入口节点通告的对应关系。 In one possible way, the receiving module 201 is also used to obtain the corresponding relationship advertised by the entry node.
如,接收模块201,还用于接收入口节点通告的指示信息,指示信息用于指示还原组播源组信息。For example, the receiving module 201 is also configured to receive indication information advertised by the entry node, where the indication information is used to instruct restoration of the multicast source group information.
进一步地,接收模块201,具体用于接收入口节点发送的边界网关协议BGP消息,BGP消息包括对应关系。Further, the receiving module 201 is specifically configured to receive a Border Gateway Protocol BGP message sent by the ingress node, where the BGP message includes a corresponding relationship.
在一种可能的方式中,BGP消息为BGP-MVPN信令或者BGP-EVPN信令。In a possible manner, the BGP message is BGP-MVPN signaling or BGP-EVPN signaling.
当网络设备20用于执行以上方法时,可以应用于图2-图11所示的应用场景中,例如可以是图2所示场景中的出口节点200。需要说明的是,本申请实施例中对模块的划分是示意性的,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式。本申请实施例中的各功能模块可以集成在一个处理模块中,也可以是各个模块单独物理存在,也可以两个或两个以上模块集成在一个模块中。例如,上述实施例中,接收模块和处理模块可以是同一个模块,也可以是不同的模块。上述集成的模块既可以采用硬件的形式实现,例如芯片,也可以采用软件功能模块的形式实现。When the network device 20 is used to perform the above method, it can be applied to the application scenarios shown in Figures 2 to 11, for example, it can be the egress node 200 in the scenario shown in Figure 2. It should be noted that the division of modules in the embodiment of the present application is schematic and is only a logical function division. In actual implementation, there may be other division methods. Each functional module in the embodiment of the present application can be integrated into one processing module, or each module can exist physically alone, or two or more modules can be integrated into one module. For example, in the above embodiment, the receiving module and the processing module may be the same module or different modules. The above integrated modules can be implemented in the form of hardware, such as chips, or in the form of software function modules.
此外,本申请实施例还提供了一种网络设备30,参见图13所示,图13为本申请实施例提供的一种网络设备30的结构示意图。该网络设备30包括通信接口301和与通信接口301连接的处理器302。通信接口例如为收发器一类的装置。该网络设备30可以用于执行以上实施例中的方法。具体来说,该网络设备30可以设置于入口节点执行方法S101至S104和S201至S205中由入口节点执行的操作,网络设备30还可以设置于出口节点执行方法S105至S107和S201至S205由出口节点执行的操作。其中,通信接口301用于执行方法中由入口节点的收发操作。处理器302用于执行方法中入口节点所执行的收发操作以外的操作。其中,通信接口301用于执行方法S101至S104和S201至S205中由入口节点所执行的收发操作。处理器302用于执行方法S101至S104和S201至S205中由入口节点所执行的收发操作以外的操作。例如,当网络设备30设置于入口节点执行操作时,根据组播源组信息和对应关系,获取隧道信息,对应关系包括组播源组信息和隧道信息,还用于根据载荷和隧道信息获得第二报文,第二报文包含载荷和与隧道信息对应的第二报文头,第二报文不包括第一报文头。通信接口301,用于接收用户边缘设备发送的第一报文,第一报文包含第一报文头和载荷,第一报文头包括组播源组信息,还用于通过与隧道信息对应的隧道发送第二报文。当网络设备30设置于出口节点执行操作时,通信接口301用于执行方法S105至S107和S201至S205中由出口节点所执行的收发操作。处理器302用于执行方法S105至S107和S201至S205中由出口节点所执行的收发操作以外的操作。通信接口301,用于接收第二报文,第二报文包括载荷和与隧道信息对应的第二报文头。处理器302用于根据第二报文头对应的隧道信息和对应关系,获取组播源组信息,对应关系包括隧道信息和组播源组信息,还用于根据组播源组信息和载荷获得第一报文,第一报文包含第一报文头和载荷,第一报文头包括组播源组信息,第一报文不包括第二报文头。In addition, the embodiment of the present application also provides a network device 30, as shown in FIG. 13. FIG. 13 is a schematic structural diagram of the network device 30 provided by the embodiment of the present application. The network device 30 includes a communication interface 301 and a processor 302 connected to the communication interface 301 . The communication interface is, for example, a device such as a transceiver. The network device 30 can be used to perform the method in the above embodiment. Specifically, the network device 30 may be configured at the ingress node to perform the operations performed by the ingress node in methods S101 to S104 and S201 to S205. The network device 30 may also be configured at the egress node to perform the operations at the egress from methods S105 to S107 and S201 to S205. The operation performed by the node. Among them, the communication interface 301 is used to perform the sending and receiving operations by the entry node in the method. The processor 302 is configured to perform operations other than the sending and receiving operations performed by the entry node in the method. Among them, the communication interface 301 is used to perform the sending and receiving operations performed by the entry node in methods S101 to S104 and S201 to S205. The processor 302 is configured to perform operations other than the sending and receiving operations performed by the entry node in methods S101 to S104 and S201 to S205. For example, when the network device 30 is configured at the entrance node to perform an operation, tunnel information is obtained according to the multicast source group information and the corresponding relationship. The corresponding relationship includes the multicast source group information and tunnel information, and is also used to obtain the third channel information based on the load and tunnel information. Two packets, the second packet includes the payload and the second packet header corresponding to the tunnel information, and the second packet does not include the first packet header. Communication interface 301 is used to receive the first message sent by the user edge device. The first message includes a first message header and a payload. The first message header includes multicast source group information. It is also used to pass the corresponding tunnel information. tunnel to send the second message. When the network device 30 is configured to perform operations at the egress node, the communication interface 301 is used to perform the sending and receiving operations performed by the egress node in methods S105 to S107 and S201 to S205. The processor 302 is configured to perform operations other than the sending and receiving operations performed by the egress node in methods S105 to S107 and S201 to S205. The communication interface 301 is configured to receive a second message, where the second message includes a payload and a second message header corresponding to the tunnel information. The processor 302 is configured to obtain the multicast source group information according to the tunnel information and the corresponding relationship corresponding to the second message header. The corresponding relationship includes the tunnel information and the multicast source group information, and is also used to obtain the multicast source group information according to the multicast source group information and the load. The first message includes a first message header and a payload, the first message header includes multicast source group information, and the first message does not include a second message header.
此外,本申请实施例还提供了一种网络设备40,参见图14所示,图14为本申请实施例提供的一种网络设备40的结构示意图。如图14所示,网络设备40可以包括处理器401,与所述处理器401耦合连接的存储器402,收发器403。收发器403可以是通信接口,光模块等,用于接收报文或数据信息等。处理器401可以是中央处理器(central processing unit,CPU),网络处理器(network processor,NP)或者CPU和NP的组合,用于执行上述实施例所举例的设备中转发处理相关步骤。处理器还可以是专用集成电路(application- specific integrated circuit,ASIC),可编程逻辑器件(programmable logic device,PLD)或其组合。上述PLD可以是复杂可编程逻辑器件(complex programmable logic device,CPLD),现场可编程逻辑门阵列(field-programmable gate array,FPGA),通用阵列逻辑(generic array logic,GAL)或其任意组合。处理器401可以是指一个处理器,也可以包括多个处理器。存储器402可以包括易失性存储器(volatile memory),例如随机存取存储器(random-access memory,RAM);存储器也可以包括非易失性存储器(non-volatile memory),例如只读存储器(read-only memory,ROM),快闪存储器(flash memory),硬盘(hard disk drive,HDD)或固态硬盘(solid-state drive,SSD);存储器402还可以包括上述种类的存储器的组合。存储器402可以是指一个存储器,也可以包括多个存储器,用于存储程序指令。在一个实施方式中,存储器402中存储有计算机可读指令,所述计算机可读指令包括多个软件模块,例如发送模块,处理模块和接收模块。处理器401执行各个软件模块后可以按照各个软件模块的指示进行相应的操作。在本实施例中,软件模块所执行的操作实际上是指处理器401根据所述软件模块的指示而执行的操作。可选地,处理器401也可以存储执行本申请实施例方案的程序代码或指令,在这种情况下处理器401不需要到存储器402中读取程序代码或指令。In addition, this embodiment of the present application also provides a network device 40, as shown in Figure 14. Figure 14 is a schematic structural diagram of a network device 40 provided by an embodiment of the present application. As shown in Figure 14, the network device 40 may include a processor 401, a memory 402 coupled to the processor 401, and a transceiver 403. The transceiver 403 may be a communication interface, an optical module, etc., and is used to receive messages or data information, etc. The processor 401 may be a central processing unit (CPU), a network processor (NP), or a combination of a CPU and an NP, and is used to perform steps related to forwarding processing in the device exemplified in the above embodiments. The processor may also be an application-specific integrated circuit (application-specific integrated circuit). specific integrated circuit (ASIC), programmable logic device (PLD) or a combination thereof. The above-mentioned PLD can be a complex programmable logic device (CPLD), a field-programmable gate array (FPGA), a general array logic (GAL) or any combination thereof. The processor 401 may refer to one processor or may include multiple processors. The memory 402 may include volatile memory (volatile memory), such as random-access memory (RAM); the memory may also include non-volatile memory (non-volatile memory), such as read-only memory (read- only memory (ROM), flash memory (flash memory), hard disk drive (HDD) or solid-state drive (SSD); the memory 402 may also include a combination of the above types of memory. The memory 402 may refer to one memory or may include multiple memories for storing program instructions. In one embodiment, computer readable instructions are stored in the memory 402, and the computer readable instructions include a plurality of software modules, such as a sending module, a processing module and a receiving module. After executing each software module, the processor 401 can perform corresponding operations according to the instructions of each software module. In this embodiment, the operations performed by the software module actually refer to operations performed by the processor 401 according to the instructions of the software module. Optionally, the processor 401 can also store program codes or instructions for executing the solutions of the embodiments of the present application. In this case, the processor 401 does not need to read the program codes or instructions from the memory 402.
该网络设备40可以用于执行以上实施例中的方法。具体来说,该网络设备40可以设置于入口节点执行方法S101至S104、S201至S205中由入口节点执行的操作,网络设备40可以设置于出口节点执行方法S105至S107、S201至S205由出口节点执行的操作。例如,当网络设备40作为设置于入口节点的设备执行操作时,处理器401用于执行存储器402中的相关指令,根据组播源组信息和对应关系,获取隧道信息,对应关系包括组播源组信息和隧道信息,根据载荷和隧道信息获得第二报文,第二报文包含载荷和与隧道信息对应的第二报文头,第二报文不包括第一报文头。例如,当网络设备40作为设置于出口节点的设备执行操作时,处理器401用于执行存储器402中的相关指令,根据第二报文头对应的隧道信息和对应关系,获取组播源组信息,对应关系包括隧道信息和组播源组信息,根据组播源组信息和载荷获得第一报文,第一报文包含第一报文头和载荷,第一报文头包括组播源组信息,第一报文不包括第二报文头。The network device 40 can be used to perform the method in the above embodiment. Specifically, the network device 40 can be configured at the entry node to perform operations performed by the entry node in methods S101 to S104 and S201 to S205, and the network device 40 can be configured at the exit node to perform operations from methods S105 to S107 and S201 to S205 by the exit node. The operation performed. For example, when the network device 40 performs operations as a device set at an ingress node, the processor 401 is configured to execute relevant instructions in the memory 402 to obtain tunnel information according to the multicast source group information and the corresponding relationship. The corresponding relationship includes the multicast source group information and tunnel information, and obtain a second message based on the payload and tunnel information. The second message includes the payload and the second message header corresponding to the tunnel information. The second message does not include the first message header. For example, when the network device 40 operates as a device set at an egress node, the processor 401 is configured to execute relevant instructions in the memory 402 and obtain the multicast source group information according to the tunnel information and corresponding relationship corresponding to the second message header. , the corresponding relationship includes tunnel information and multicast source group information, and the first message is obtained according to the multicast source group information and payload. The first message includes the first message header and payload, and the first message header includes the multicast source group. Information, the first packet does not include the second packet header.
本申请实施例还提供了一种计算机可读存储介质,计算机可读存储介质中存储有指令,当其在处理器上运行时,实现前述实施例中任一实施例的方法中任一方法中的部分或全部操作。Embodiments of the present application also provide a computer-readable storage medium. Instructions are stored in the computer-readable storage medium. When run on a processor, any one of the methods in any of the foregoing embodiments can be implemented. some or all operations.
本申请实施例还提供了一种计算机程序产品,包括计算机程序,当其在处理器上运行时,实现前述实施例中任一实施例的方法中任一方法中的部分或全部操作。Embodiments of the present application also provide a computer program product, including a computer program that, when run on a processor, implements part or all of the operations in any of the methods in any of the foregoing embodiments.
本申请实施例还提供一种报文的传输系统,该系统可以应用在如图2所示的场景中,包括:系统包括至少一个设置于入口节点的网络设备和至少一个设置于出口节点的网络设备。如图2所示,该系统还可以包括设置于中间节点的网络设备和CE设备。其中,设置于入口节点的网络设备如图11、图13或图14对应的网络设备,设置于入口节点的网络设备是结构如图12、图13或图14对应的网络设备。上述通信系统用于实现前述实施例中任一实施例的方法中任一方法中的部分或全部操作。Embodiments of the present application also provide a message transmission system, which can be applied in the scenario shown in Figure 2, including: the system includes at least one network device provided at the entry node and at least one network device provided at the exit node. equipment. As shown in Figure 2, the system may also include network equipment and CE equipment provided at intermediate nodes. Among them, the network device provided at the entry node is a network device corresponding to Figure 11, Figure 13 or Figure 14, and the network device provided at the entry node is a network device with a structure corresponding to Figure 12, Figure 13 or Figure 14. The above communication system is used to implement part or all of the operations in any of the methods of any of the foregoing embodiments.
本申请实施例还提供了另一种通信系统,包括至少一个存储器和至少一个处理器,该至少一个存储器存储有指令,该至少一个处理器执行指令,使得通信系统实现前述实施例 中任一实施例的方法中任一方法中的部分或全部操作。The embodiment of the present application also provides another communication system, including at least one memory and at least one processor. The at least one memory stores instructions, and the at least one processor executes the instructions, so that the communication system implements the foregoing embodiments. Some or all of the operations in any of the methods of any of the embodiments.
本申请实施例还提供了一种芯片,包括:接口电路和处理器。接口电路和处理器相连接,处理器用于使得芯片执行前述实施例中任一实施例的方法中任一方法中的部分或全部操作。An embodiment of the present application also provides a chip, including: an interface circuit and a processor. The interface circuit is connected to a processor, and the processor is used to cause the chip to perform part or all of the operations in any of the methods of any of the foregoing embodiments.
本申请实施例还提供一种芯片系统,包括:处理器,处理器与存储器耦合,存储器用于存储程序或指令,当程序或指令被处理器执行时,使得该芯片系统实现前述实施例中任一实施例的方法中任意方法中的部分或全部操作。Embodiments of the present application also provide a chip system, including: a processor, the processor is coupled to a memory, and the memory is used to store programs or instructions. When the programs or instructions are executed by the processor, the chip system implements any of the foregoing embodiments. Some or all of the operations in any of the methods of an embodiment.
可选地,该芯片系统中的处理器可以为一个或多个。该处理器可以通过硬件实现也可以通过软件实现。当通过硬件实现时,该处理器可以是逻辑电路、集成电路等。当通过软件实现时,该处理器可以是通用处理器,通过读取存储器中存储的软件代码来实现。Optionally, there may be one or more processors in the chip system. The processor can be implemented in hardware or software. When implemented in hardware, the processor may be a logic circuit, an integrated circuit, or the like. When implemented in software, the processor may be a general-purpose processor implemented by reading software code stored in memory.
可选地,该芯片系统中的存储器也可以为一个或多个。该存储器可以与处理器集成在一起,也可以和处理器分离设置,本申请实施例并不限定。示例性的,存储器可以是非瞬时性处理器,例如只读存储器ROM,其可以与处理器集成在同一块芯片上,也可以分别设置在不同的芯片上,本申请实施例对存储器的类型,以及存储器与处理器的设置方式不作具体限定。Optionally, there may be one or more memories in the chip system. The memory may be integrated with the processor or may be provided separately from the processor, which is not limited by the embodiments of the present application. For example, the memory may be a non-transitory processor, such as a read-only memory ROM, which may be integrated with the processor on the same chip, or may be separately provided on different chips. The embodiment of the present application covers the type of memory, and The arrangement of the memory and processor is not specifically limited.
示例性的,该芯片系统可以是FPGA,可以是ASIC,还可以是系统芯片(system on chip,SoC),还可以是CPU,还可以是NP,还可以是数字信号处理电路(digital signal processor,DSP),还可以是微控制器(micro controller unit,MCU),还可以是可编程控制器(programmable logic device,PLD)或其他集成芯片。For example, the chip system can be an FPGA, an ASIC, a system on chip (SoC), a CPU, an NP, or a digital signal processing circuit (digital signal processor, DSP), it can also be a microcontroller unit (MCU), a programmable logic device (PLD) or other integrated chips.
本申请的说明书和权利要求书及上述附图中的术语“第一”、“第二”、“第三”等(如果存在)是用于区别类似的对象,而不必用于描述特定的顺序或先后次序。应该理解这样使用的数据在适当情况下可以互换,以便这里描述的实施例能够以除了在这里图示或描述的内容以外的顺序实施。此外,术语“包括”和“具有”以及他们的任何变形,意图在于覆盖不排他的包含,例如,包含了一系列步骤或单元的过程、方法、系统、产品或设备不必限于清楚地列出的那些步骤或单元,而是可包括没有清楚地列出的或对于这些过程、方法、产品或设备固有的其它步骤或单元。The terms "first", "second", "third", etc. (if present) in the description and claims of this application and the above-mentioned drawings are used to distinguish similar objects and are not necessarily used to describe a specific sequence. Or sequence. It is to be understood that the data so used are interchangeable under appropriate circumstances so that the embodiments described herein can be practiced in sequences other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, e.g., a process, method, system, product, or apparatus that encompasses a series of steps or units and need not be limited to those explicitly listed. Those steps or elements may instead include other steps or elements not expressly listed or inherent to the process, method, product or apparatus.
应理解,在本申请的各种实施例中,上述各过程的序号的大小并不意味着执行顺序的先后,各过程的执行顺序应以其功能和内在逻辑确定,而不应对本申请实施例的实施过程构成任何限定。It should be understood that in the various embodiments of the present application, the size of the sequence numbers of the above-mentioned processes does not mean the order of execution. The execution order of each process should be determined by its functions and internal logic, and should not be used in the embodiments of the present application. The implementation process constitutes any limitation.
本领域技术人员应该可以意识到,在上述一个或多个示例中,本申请实施例所描述的功能可以用硬件、软件、固件或它们的任意组合来实现。当使用软件实现时,可以将这些功能存储在计算机可读介质中或者作为计算机可读介质上的一个或多个指令或代码进行传输。计算机可读介质包括计算机存储介质和通信介质,其中通信介质包括便于从一个地方向另一个地方传送计算机程序的任何介质。存储介质可以是通用或专用计算机能够存取的任何可用介质。Those skilled in the art should realize that in one or more of the above examples, the functions described in the embodiments of the present application can be implemented using hardware, software, firmware, or any combination thereof. When implemented using software, the functions may be stored on or transmitted over as one or more instructions or code on a computer-readable medium. Computer-readable media includes computer storage media and communication media including any medium that facilitates transfer of a computer program from one place to another. Storage media can be any available media that can be accessed by a general purpose or special purpose computer.
上面结合附图对本申请的实施例进行了描述,但是本申请并不局限于上述的具体实施方式,上述的具体实施方式仅仅是示意性的,而不是限制性的,本领域的普通技术人员在本申请的启示下,在不脱离本申请宗旨和权利要求所保护的范围情况下,还可做出很多形式,均属于本申请的保护之内。 The embodiments of the present application have been described above in conjunction with the accompanying drawings. However, the present application is not limited to the above-mentioned specific implementations. The above-mentioned specific implementations are only illustrative and not restrictive. Those of ordinary skill in the art will Inspired by this application, many forms can be made without departing from the purpose of this application and the scope protected by the claims, all of which fall within the protection of this application.

Claims (44)

  1. 一种报文的传输方法,其特征在于,包括:A message transmission method, characterized by including:
    入口节点接收用户边缘设备发送的第一报文,所述第一报文包含第一报文头和载荷,所述第一报文头包括组播源组信息;The entry node receives the first message sent by the user edge device, the first message includes a first message header and a payload, and the first message header includes multicast source group information;
    所述入口节点根据所述组播源组信息和对应关系,获取隧道信息,所述对应关系包括所述组播源组信息和所述隧道信息;The entry node obtains tunnel information according to the multicast source group information and the corresponding relationship, where the corresponding relationship includes the multicast source group information and the tunnel information;
    所述入口节点根据所述载荷和所述隧道信息获得第二报文,所述第二报文包含所述载荷和与所述隧道信息对应的第二报文头,所述第二报文不包括所述第一报文头;The entry node obtains a second message according to the payload and the tunnel information. The second message includes the payload and a second message header corresponding to the tunnel information. The second message does not including the first message header;
    所述入口节点通过与所述隧道信息对应的隧道发送所述第二报文。The ingress node sends the second message through the tunnel corresponding to the tunnel information.
  2. 根据权利要求1所述的方法,其特征在于,所述第二报文头包括第六版互联网协议IPv6头和通用路由封装GRE头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。The method according to claim 1, characterized in that the second message header includes an Internet Protocol version 6 IPv6 header and a general routing encapsulation GRE header, and the IPv6 header includes a source address corresponding to the tunnel information and Destination address.
  3. 根据权利要求1所述的方法,其特征在于,所述第二报文头包括第四版互联网协议IPv4头和GRE头,所述IPv4头包括与所述隧道信息对应的源地址和目的地址。The method of claim 1, wherein the second message header includes an Internet Protocol version 4 IPv4 header and a GRE header, and the IPv4 header includes a source address and a destination address corresponding to the tunnel information.
  4. 根据权利要求1所述的方法,其特征在于,所述第二报文头包括IPv6头和IPv6扩展头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。The method of claim 1, wherein the second message header includes an IPv6 header and an IPv6 extension header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  5. 根据权利要求1所述的方法,其特征在于,所述第二报文头包括IPv6头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。The method of claim 1, wherein the second message header includes an IPv6 header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  6. 根据权利要求2至5任一所述的方法,其特征在于,所述目的地址为所述入口节点在组播树的下一跳的地址或者所述目的地址为组播树对应的组播组地址。The method according to any one of claims 2 to 5, characterized in that the destination address is the address of the next hop of the entry node in the multicast tree or the destination address is the multicast group corresponding to the multicast tree. address.
  7. 根据权利要求1所述的方法,其特征在于,所述第二报文头包括多协议标签交换MPLS头,所述MPLS头包括所述入口节点在组播树的下一跳节点的MPLS标签或组播树对应的MPLS标签。The method according to claim 1, characterized in that the second message header includes a multi-protocol label switching MPLS header, and the MPLS header includes the MPLS label of the next hop node of the entry node in the multicast tree or MPLS label corresponding to the multicast tree.
  8. 根据权利要求1所述的方法,其特征在于,所述第二报文头包括位索引显式复制BIER头和标签,所述BIER头包括与所述隧道信息对应的所述出口节点的标识,所述标签用于标识所述组播源组信息。The method according to claim 1, wherein the second message header includes a bit index explicit copy BIER header and a label, and the BIER header includes an identification of the egress node corresponding to the tunnel information, The label is used to identify the multicast source group information.
  9. 根据权利要求1至8任一所述的方法,其特征在于,所述方法还包括:The method according to any one of claims 1 to 8, characterized in that the method further includes:
    所述入口节点向出口节点发送边界网关协议BGP消息,所述BGP消息包括所述对应关系。The ingress node sends a Border Gateway Protocol BGP message to the egress node, where the BGP message includes the corresponding relationship.
  10. 根据权利要求9所述的方法,其特征在于,所述方法还包括:The method of claim 9, further comprising:
    所述入口节点向出口节点通告指示信息,所述指示信息用于指示还原所述组播源组信息。The ingress node notifies the egress node of indication information, where the indication information is used to instruct restoration of the multicast source group information.
  11. 根据权利要求9或10所述的方法,其特征在于,所述BGP消息为边界网关协议-组播虚拟专用网络BGP-MVPN信令或者边界网关协议-以太虚拟专用网络BGP-EVPN信令。The method according to claim 9 or 10, characterized in that the BGP message is Border Gateway Protocol-Multicast Virtual Private Network BGP-MVPN signaling or Border Gateway Protocol-Ethernet Virtual Private Network BGP-EVPN signaling.
  12. 一种报文的传输方法,其特征在于,包括:A message transmission method, characterized by including:
    出口节点接收第二报文,所述第二报文包括载荷和与隧道信息对应的第二报文头;The egress node receives a second message, where the second message includes a payload and a second message header corresponding to the tunnel information;
    所述出口节点根据对应关系和所述第二报文头对应的所述隧道信息,获取组播源组信 息,所述对应关系包括所述隧道信息和所述组播源组信息;The egress node obtains the multicast source group information based on the corresponding relationship and the tunnel information corresponding to the second message header. Information, the corresponding relationship includes the tunnel information and the multicast source group information;
    所述出口节点根据所述组播源组信息和所述载荷获得第一报文,所述第一报文包含第一报文头和所述载荷,所述第一报文头包括所述组播源组信息,所述第一报文不包括所述第二报文头。The egress node obtains a first message according to the multicast source group information and the payload. The first message includes a first message header and the payload. The first message header includes the group Broadcast source group information, the first packet does not include the second packet header.
  13. 根据权利要求12所述的方法,其特征在于,所述第二报文头包括第六版互联网协议IPv6头和通用路由封装GRE头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。The method according to claim 12, characterized in that the second message header includes an Internet Protocol version 6 IPv6 header and a general routing encapsulation GRE header, and the IPv6 header includes a source address corresponding to the tunnel information and Destination address.
  14. 根据权利要求12所述的方法,其特征在于,所述第二报文头包括第四版互联网协议IPv4头和GRE头,所述IPv4头包括与所述隧道信息对应的源地址和目的地址。The method of claim 12, wherein the second message header includes an Internet Protocol version 4 IPv4 header and a GRE header, and the IPv4 header includes a source address and a destination address corresponding to the tunnel information.
  15. 根据权利要求12所述的方法,其特征在于,所述第二报文头包括IPv6头和IPv6扩展头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。The method according to claim 12, wherein the second message header includes an IPv6 header and an IPv6 extension header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  16. 根据权利要求12所述的方法,其特征在于,所述第二报文头包括IPv6头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。The method of claim 12, wherein the second message header includes an IPv6 header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  17. 根据权利要求13至16任一所述的方法,其特征在于,所述目的地址为所述入口节点在组播树的下一跳的地址或者所述目的地址为组播树对应的组播组地址。The method according to any one of claims 13 to 16, characterized in that the destination address is the address of the next hop of the entry node in the multicast tree or the destination address is the multicast group corresponding to the multicast tree. address.
  18. 根据权利要求12所述的方法,其特征在于,所述出口节点根据所述组播源组信息和所述载荷获得第一报文之前,还包括:The method according to claim 12, characterized in that before the egress node obtains the first message according to the multicast source group information and the payload, it further includes:
    所述出口节点接收第三报文,所述第三报文包括所述载荷和与所述隧道信息对应的第三报文头;The egress node receives a third message, where the third message includes the payload and a third message header corresponding to the tunnel information;
    所述出口节点根据所述对应关系和所述第三报文头对应的所述隧道信息,获取所述组播源组信息,所述第三报文头包括多协议标签交换MPLS头,所述MPLS头包括所述出口节点为组播树分配的MPLS标签或所述组播树对应的MPLS标签。The egress node obtains the multicast source group information according to the corresponding relationship and the tunnel information corresponding to the third message header, where the third message header includes a multi-protocol label switching MPLS header, and the The MPLS header includes the MPLS label allocated by the egress node for the multicast tree or the MPLS label corresponding to the multicast tree.
  19. 根据权利要求12所述的方法,其特征在于,所述第二报文头包括位索引显式复制BIER头和标签,所述BIER头包括与所述隧道信息对应的出口节点的标识,所述标签用于标识所述组播源组信息。The method according to claim 12, characterized in that the second message header includes a bit index explicit copy BIER header and a label, the BIER header includes an identification of an egress node corresponding to the tunnel information, and the The label is used to identify the multicast source group information.
  20. 根据权利要求12至19任一所述的方法,其特征在于,所述方法还包括:The method according to any one of claims 12 to 19, characterized in that the method further includes:
    所述出口节点获取所述入口节点发送的边界网关协议BGP消息,所述BGP消息包括所述对应关系。The egress node obtains the Border Gateway Protocol BGP message sent by the ingress node, and the BGP message includes the corresponding relationship.
  21. 根据权利要求20所述的方法,其特征在于,所述方法还包括:The method of claim 20, further comprising:
    所述出口节点接收所述入口节点通告的指示信息,所述指示信息用于指示还原所述组播源组信息。The egress node receives the indication information advertised by the ingress node, and the indication information is used to instruct to restore the multicast source group information.
  22. 根据权利要求20或21所述的方法,其特征在于,所述BGP消息为边界网关协议-组播虚拟专用网络BGP-MVPN信令或者边界网关协议-以太虚拟专用网络BGP-EVPN信令。The method according to claim 20 or 21, characterized in that the BGP message is Border Gateway Protocol-Multicast Virtual Private Network BGP-MVPN signaling or Border Gateway Protocol-Ethernet Virtual Private Network BGP-EVPN signaling.
  23. 一种网络设备,其特征在于,所述网络设备设置于入口节点,包括:A network device, characterized in that the network device is installed at an entry node and includes:
    接收模块,用于接收用户边缘设备发送的第一报文,所述第一报文包含第一报文头和载荷,所述第一报文头包括组播源组信息;A receiving module, configured to receive a first message sent by the user edge device, where the first message includes a first message header and a payload, and the first message header includes multicast source group information;
    处理模块,用于根据所述组播源组信息和对应关系,获取隧道信息,所述对应关系包括所述组播源组信息和所述隧道信息; A processing module configured to obtain tunnel information according to the multicast source group information and the corresponding relationship, where the corresponding relationship includes the multicast source group information and the tunnel information;
    所述处理模块,还用于根据所述载荷和所述隧道信息获得第二报文,所述第二报文包含所述载荷和与所述隧道信息对应的第二报文头,所述第二报文不包括所述第一报文头;The processing module is further configured to obtain a second message according to the payload and the tunnel information. The second message includes the payload and a second message header corresponding to the tunnel information. The second message does not include the first message header;
    发送模块,用于通过与所述隧道信息对应的隧道发送所述第二报文。A sending module, configured to send the second message through the tunnel corresponding to the tunnel information.
  24. 根据权利要求23所述的网络设备,其特征在于,所述第二报文头包括第六版互联网协议IPv6头和通用路由封装GRE头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。The network device according to claim 23, wherein the second message header includes an Internet Protocol version 6 IPv6 header and a general routing encapsulation GRE header, and the IPv6 header includes a source address corresponding to the tunnel information. and destination address.
  25. 根据权利要求23所述的网络设备,其特征在于,所述第二报文头包括第四版互联网协议IPv4头和GRE头,所述IPv4头包括与所述隧道信息对应的源地址和目的地址。The network device according to claim 23, wherein the second message header includes an Internet Protocol version 4 IPv4 header and a GRE header, and the IPv4 header includes a source address and a destination address corresponding to the tunnel information. .
  26. 根据权利要求23所述的网络设备,其特征在于,所述第二报文头包括IPv6头和IPv6扩展头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。The network device according to claim 23, wherein the second message header includes an IPv6 header and an IPv6 extension header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  27. 根据权利要求23所述的网络设备,其特征在于,所述第二报文头包括IPv6头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。The network device according to claim 23, wherein the second message header includes an IPv6 header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  28. 根据权利要求24至27任一所述的网络设备,其特征在于,所述目的地址为所述入口节点在组播树的下一跳的地址或者所述目的地址为组播树对应的组播组地址。The network device according to any one of claims 24 to 27, characterized in that the destination address is the address of the next hop of the entry node in the multicast tree or the destination address is the multicast corresponding to the multicast tree. Group address.
  29. 根据权利要求23所述的网络设备,其特征在于,所述第二报文头包括多协议标签交换MPLS头,所述MPLS头包括所述入口节点在组播树的下一跳节点的MPLS标签或组播树对应的MPLS标签。The network device according to claim 23, characterized in that the second message header includes a multi-protocol label switching MPLS header, and the MPLS header includes the MPLS label of the next hop node of the entry node in the multicast tree. Or the MPLS label corresponding to the multicast tree.
  30. 根据权利要求23所述的网络设备,其特征在于,所述第二报文头包括位索引显式复制BIER头和标签,所述BIER头包括与所述隧道信息对应的所述出口节点的标识,所述标签用于标识所述组播源组信息。The network device according to claim 23, wherein the second message header includes a bit index explicit copy BIER header and a label, and the BIER header includes an identification of the egress node corresponding to the tunnel information. , the label is used to identify the multicast source group information.
  31. 根据权利要求23至30任一所述的网络设备,其特征在于,The network device according to any one of claims 23 to 30, characterized in that,
    所述发送模块,还用于向出口节点发送边界网关协议BGP消息,所述BGP消息包括所述对应关系。The sending module is also configured to send a Border Gateway Protocol BGP message to the egress node, where the BGP message includes the corresponding relationship.
  32. 根据权利要求31所述的网络设备,其特征在于,The network device according to claim 31, characterized in that,
    所述发送模块,还用于向出口节点通告指示信息,所述指示信息用于指示还原所述组播源组信息。The sending module is also configured to notify the egress node of indication information, where the indication information is used to instruct restoration of the multicast source group information.
  33. 根据权利要求31或32所述的网络设备,其特征在于,所述BGP消息为边界网关协议-组播虚拟专用网络BGP-MVPN信令或者边界网关协议-以太虚拟专用网络BGP-EVPN信令。The network device according to claim 31 or 32, characterized in that the BGP message is Border Gateway Protocol-Multicast Virtual Private Network BGP-MVPN signaling or Border Gateway Protocol-Ethernet Virtual Private Network BGP-EVPN signaling.
  34. 一种网络设备,其特征在于,所述网络设备设置于出口节点,包括:A network device, characterized in that the network device is installed at an egress node, including:
    接收模块,用于接收第二报文,所述第二报文包括载荷和与隧道信息对应的第二报文头;A receiving module, configured to receive a second message, where the second message includes a payload and a second message header corresponding to the tunnel information;
    处理模块,用于根据对应关系和所述第二报文头对应的所述隧道信息,获取组播源组信息,所述对应关系包括所述隧道信息和所述组播源组信息;A processing module configured to obtain multicast source group information according to the corresponding relationship and the tunnel information corresponding to the second message header, where the corresponding relationship includes the tunnel information and the multicast source group information;
    所述处理模块,还用于根据所述组播源组信息和所述载荷获得第一报文,所述第一报文包含第一报文头和所述载荷,所述第一报文头包括所述组播源组信息,所述第一报文不包括所述第二报文头。The processing module is also configured to obtain a first message according to the multicast source group information and the payload. The first message includes a first message header and the payload. The first message header The multicast source group information is included, and the first message does not include the second message header.
  35. 根据权利要求34所述的网络设备,其特征在于,所述第二报文头包括第六版互联网协议IPv6头和通用路由封装GRE头,所述IPv6头包括与所述隧道信息对应的源地 址和目的地址。The network device according to claim 34, wherein the second message header includes an Internet Protocol version 6 IPv6 header and a general routing encapsulation GRE header, and the IPv6 header includes a source address corresponding to the tunnel information. address and destination address.
  36. 根据权利要求34所述的网络设备,其特征在于,所述第二报文头包括第四版互联网协议IPv4头和GRE头,所述IPv4头包括与所述隧道信息对应的源地址和目的地址。The network device according to claim 34, wherein the second message header includes a fourth version Internet Protocol IPv4 header and a GRE header, and the IPv4 header includes a source address and a destination address corresponding to the tunnel information. .
  37. 根据权利要求34所述的网络设备,其特征在于,所述第二报文头包括IPv6头和IPv6扩展头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。The network device according to claim 34, wherein the second message header includes an IPv6 header and an IPv6 extension header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  38. 根据权利要求34所述的网络设备,其特征在于,所述第二报文头包括IPv6头,所述IPv6头包括与所述隧道信息对应的源地址和目的地址。The network device according to claim 34, wherein the second message header includes an IPv6 header, and the IPv6 header includes a source address and a destination address corresponding to the tunnel information.
  39. 根据权利要求35至38任一所述的网络设备,其特征在于,所述目的地址为所述入口节点在组播树的下一跳的地址或者所述目的地址为组播树对应的组播组地址。The network device according to any one of claims 35 to 38, characterized in that the destination address is the address of the next hop of the entry node in the multicast tree or the destination address is the multicast corresponding to the multicast tree. Group address.
  40. 根据权利要求34所述的网络设备,其特征在于,The network device according to claim 34, characterized in that:
    所述接收模块,还用于接收第三报文,所述第三报文包括所述载荷和与所述隧道信息对应的第三报文头;The receiving module is also configured to receive a third message, where the third message includes the payload and a third message header corresponding to the tunnel information;
    所述处理模块,还用于根据所述对应关系和所述第三报文头对应的所述隧道信息,获取所述组播源组信息,所述第三报文头包括多协议标签交换MPLS头,所述MPLS头包括所述出口节点为组播树分配的MPLS标签或所述组播树对应的MPLS标签。The processing module is also configured to obtain the multicast source group information according to the corresponding relationship and the tunnel information corresponding to the third message header, where the third message header includes multi-protocol label switching MPLS The MPLS header includes the MPLS label allocated by the egress node for the multicast tree or the MPLS label corresponding to the multicast tree.
  41. 根据权利要求34所述的网络设备,其特征在于,所述第二报文头包括位索引显式复制BIER头和标签,所述BIER头包括与所述隧道信息对应的出口节点的标识,所述标签用于标识所述组播源组信息。The network device according to claim 34, wherein the second message header includes a bit index explicit copy BIER header and a label, and the BIER header includes an identification of an egress node corresponding to the tunnel information, so The label is used to identify the multicast source group information.
  42. 根据权利要求34至41任一所述的网络设备,其特征在于,The network device according to any one of claims 34 to 41, characterized in that,
    所述接收模块,还用于获取所述入口节点发送的边界网关协议BGP消息,所述BGP消息包括所述对应关系。The receiving module is also configured to obtain the Border Gateway Protocol BGP message sent by the entry node, where the BGP message includes the corresponding relationship.
  43. 根据权利要求42所述的网络设备,其特征在于,The network device according to claim 42, characterized in that:
    所述接收模块,还用于接收所述入口节点通告的指示信息,所述指示信息用于指示还原所述组播源组信息。The receiving module is also configured to receive indication information advertised by the entry node, where the indication information is used to instruct restoration of the multicast source group information.
  44. 根据权利要求42或43所述的网络设备,其特征在于,所述BGP消息为边界网关协议-组播虚拟专用网络BGP-MVPN信令或者边界网关协议-以太虚拟专用网络BGP-EVPN信令。 The network device according to claim 42 or 43, characterized in that the BGP message is Border Gateway Protocol-Multicast Virtual Private Network BGP-MVPN signaling or Border Gateway Protocol-Ethernet Virtual Private Network BGP-EVPN signaling.
PCT/CN2023/079614 2022-08-31 2023-03-03 Message transmission method and network device WO2024045537A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202211063430.9 2022-08-31
CN202211063430.9A CN117675440A (en) 2022-08-31 2022-08-31 Message transmission method and network equipment

Publications (1)

Publication Number Publication Date
WO2024045537A1 true WO2024045537A1 (en) 2024-03-07

Family

ID=90083293

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2023/079614 WO2024045537A1 (en) 2022-08-31 2023-03-03 Message transmission method and network device

Country Status (2)

Country Link
CN (1) CN117675440A (en)
WO (1) WO2024045537A1 (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080037498A1 (en) * 2006-08-10 2008-02-14 Motorola, Inc. Optimized tunneling methods in a network
US20080310344A1 (en) * 2007-06-15 2008-12-18 Telefonaktiebolaget Lm Ericsson (Publ) Tunnel overhead reduction
CN102820977A (en) * 2012-08-07 2012-12-12 福建星网锐捷网络有限公司 Multicast method, multicast device and network device
US20210058260A1 (en) * 2018-05-08 2021-02-25 Huawei Technologies Co., Ltd. Multicast Data Transmission Method, Related Apparatus, and System
WO2021082879A1 (en) * 2019-11-01 2021-05-06 华为技术有限公司 Method for transmitting multicast message, and related apparatus
CN114598635A (en) * 2020-12-02 2022-06-07 华为技术有限公司 Message transmission method and device

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080037498A1 (en) * 2006-08-10 2008-02-14 Motorola, Inc. Optimized tunneling methods in a network
US20080310344A1 (en) * 2007-06-15 2008-12-18 Telefonaktiebolaget Lm Ericsson (Publ) Tunnel overhead reduction
CN102820977A (en) * 2012-08-07 2012-12-12 福建星网锐捷网络有限公司 Multicast method, multicast device and network device
US20210058260A1 (en) * 2018-05-08 2021-02-25 Huawei Technologies Co., Ltd. Multicast Data Transmission Method, Related Apparatus, and System
WO2021082879A1 (en) * 2019-11-01 2021-05-06 华为技术有限公司 Method for transmitting multicast message, and related apparatus
CN114598635A (en) * 2020-12-02 2022-06-07 华为技术有限公司 Message transmission method and device

Also Published As

Publication number Publication date
CN117675440A (en) 2024-03-08

Similar Documents

Publication Publication Date Title
CN109218178B (en) Message processing method and network equipment
JP7208386B2 (en) Packet transfer method, packet transmitter, and packet receiver
US11902049B2 (en) BIER packet sending method and apparatus
CN109756425B (en) Multicast forwarding method, device and BFR
US8351352B1 (en) Methods and apparatus for RBridge hop-by-hop compression and frame aggregation
US8472438B2 (en) Efficient encapsulation of packets transmitted on a packet-pseudowire over a packet switched network
US8339973B1 (en) Multicast traceroute over MPLS/BGP IP multicast VPN
AU2011244044A1 (en) Efficient encapsulation of packets transmitted on a packet-pseudowire over a Packet Switched Network
WO2022062506A1 (en) Data processing method and apparatus, storage medium, and electronic apparatus
WO2009012688A1 (en) Method, system and apparatus for forwarding message in three-layer virtual private network
JP2023549797A (en) BIER packet forwarding methods, devices, and systems
CN112134776B (en) Method for generating multicast forwarding table item and access gateway
WO2022021818A1 (en) Method and device for processing data message, storage medium, and electronic device
WO2021093463A1 (en) Packet forwarding method, first network device, and first device group
WO2014082414A1 (en) Service forwarding method and device
WO2013082947A1 (en) Method and edge device for forwarding ipv6 multicast message across ipv4 network
US20220200820A1 (en) Packet Sending Method and Apparatus
WO2022117018A1 (en) Packet transmission method and apparatus
WO2022262579A1 (en) Packet transmission method and apparatus
WO2013107323A1 (en) Method and device for noticing link information
WO2024045537A1 (en) Message transmission method and network device
WO2021129023A1 (en) Message sending method, device and system
CN114520762A (en) Method for sending BIERv6 message and first network equipment
WO2023174188A1 (en) Packet processing method, routing announcement method, and related device
WO2022267875A1 (en) Packet transmission method and related device

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 23858580

Country of ref document: EP

Kind code of ref document: A1