WO2022042503A1 - 一种报文传输方法、装置及系统 - Google Patents

一种报文传输方法、装置及系统 Download PDF

Info

Publication number
WO2022042503A1
WO2022042503A1 PCT/CN2021/114150 CN2021114150W WO2022042503A1 WO 2022042503 A1 WO2022042503 A1 WO 2022042503A1 CN 2021114150 W CN2021114150 W CN 2021114150W WO 2022042503 A1 WO2022042503 A1 WO 2022042503A1
Authority
WO
WIPO (PCT)
Prior art keywords
network device
packet
identifier
address
message
Prior art date
Application number
PCT/CN2021/114150
Other languages
English (en)
French (fr)
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 华为技术有限公司
Priority to EP21860338.9A priority Critical patent/EP4195541A4/en
Publication of WO2022042503A1 publication Critical patent/WO2022042503A1/zh
Priority to US18/175,431 priority patent/US20230208757A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/02Network architectures or network communication protocols for network security for separating internal from external traffic, e.g. firewalls
    • H04L63/0272Virtual private networks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/56Routing software
    • H04L45/566Routing instructions carried by the data packet, e.g. active networks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/16Implementation or adaptation of Internet protocol [IP], of transmission control protocol [TCP] or of user datagram protocol [UDP]
    • 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
    • H04L12/4641Virtual LANs, VLANs, e.g. virtual private networks [VPN]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/74Address processing for routing
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/10Active monitoring, e.g. heartbeat, ping or trace-route
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/14Network architectures or network communication protocols for network security for detecting or protecting against malicious traffic
    • H04L63/1408Network architectures or network communication protocols for network security for detecting or protecting against malicious traffic by monitoring network traffic
    • H04L63/1425Traffic logging, e.g. anomaly detection

Definitions

  • the embodiments of the present application relate to the field of computers, and in particular, to a message transmission method, device, and system.
  • EVPN virtual private network
  • VPWS virtual private wireless service
  • LSP Label Switched Path
  • the EVPN VPWS Internet Packet Groper provides an EVPN VPWS tunnel detection solution in the EVPN VPWS scenario, which is used to detect whether the EVPN tunnel between the initiator device and the receiver device is normal.
  • the process includes: the initiating end device generates a probe (echo request) packet, the probe packet carries the identifiers (identifiers, ID) information of the tunnel to be detected, and sends the probe packet to the receiving end device through the EVPN VPWS tunnel.
  • the receiving end device receives the detection packet, performs detection and verification according to the identification information of the tunnel to be detected in the detection packet, and determines whether the tunnel to be detected is normal or abnormal; and encapsulates the detection and verification result in the response (echo reply) packet.
  • the response packet is then sent to the initiator device through the EVPN VPWS tunnel.
  • the initiator device receives the response packet, and obtains the current detection and verification result in the response packet.
  • the initiator device sends probe packets and receives response packets multiple times, and judges whether the EVPN VPWS tunnel between the initiator device and the receiver device is normal according to the detection and verification results in the multiple response packets.
  • the customer edge device (CE) 1 is dual-homed to the provider edge device (PE) 1 and PE2 , CE2 is single-homed to PE3, PE1 and PE2 are set to active-active mode; PE1 can communicate with PE3 through the EVPN VPWS tunnel, and PE2 can also communicate with PE3 through the EVPN VPWS tunnel; VPWS ID) is 100, and the EVPN VPWS tunnel ID on the PE3 side (remote EVPN VPWS ID) is 200.
  • PE1 initiates tunnel detection, it is used to detect whether the EVPN VPWS tunnels with tunnel IDs 100 to 200 are normal.
  • PE1 sends the detection packet to PE3 through the EVPN VPWS tunnel.
  • PE3 receives the detection packet, obtains the detection result according to the detection packet, and then sends the response packet including the detection result to the tunnel egress device through the EVPN VPWS tunnel. Since the tunnel IDs of PE1 and PE2 in this scenario are the same, PE1 may receive the response packet normally or may fail to receive the response packet, that is, the response packet is received by PE2.
  • the tunnels from 100 to 200 may be normal, but because the response packets are received by PE2 and cannot reach PE1, PE1 detects errors, and the accuracy of tunnel detection is low.
  • the present application provides a message transmission method, device and system, which improves the probability that the initiating end device of the detection message receives the response message of the sent detection message, and when the detection message is used to detect the tunnel state, it improves the The accuracy of tunnel detection is improved.
  • the present application provides a packet transmission method, the method is performed by a first network device, the method may include: sending a detection packet to a second network device, and the detection packet may include an identifier of the first network device, The identifier of the first network device is used to instruct the second network device to add the identifier of the first network device to the destination address of the response message of the probe message; the response message is received from the second network device, and the destination address of the response message is The identifier of the first network device; or, receiving an updated response message from the third network device, the destination address of the updated response message is the identifier of the first network device, and the third network device and the first network device are both the same as the first network device. Connect to the same user-side network device.
  • the receiving end device of the probe packet adds the identifier as the destination address of the response packet of the probe packet, so that even if When the non-initiator device receives the response packet, it can forward the response packet to the initiator device of the probe packet according to the destination address of the response packet, so as to ensure that the initiator device of the probe packet can receive the sent probe packet. response message.
  • the probe packet is used to detect the tunnel status, the detection error caused by the initiating end device of the probe packet being unable to receive the response packet of the probe packet is avoided, and the accuracy of tunnel detection is improved.
  • the non-initiator device since the location where the identifier is added is the destination address field of the response packet, when the non-initiator device receives the response packet, it can directly forward the response packet to the initiator device of the detection packet according to the traditional routing and forwarding mechanism. , without changing the packet forwarding behavior of the non-initiator device too much, which is beneficial to improve the compatibility and friendliness of the network operation.
  • the identifier of the first network device may include: an internet protocol (IP) address of the first network device; access control, MAC) address.
  • IP internet protocol
  • MAC access control
  • the IP address or the MAC address may be used as the identifier of the first network device, which achieves high flexibility.
  • the IP address of the first network device may include: the interface IP address of the first network device; or, the IP address of the first network device.
  • SID segment identifiers
  • the method before sending the detection packet to the second network device, may further include: generating a detection packet; wherein, The identifier of the first network device may be encapsulated in the data part of the probe packet in the type-length value TLV format; or, the identifier of the first network device may be encapsulated in the source IP address of the IP header of the probe packet.
  • the identifier of the first network device may be stored in different locations of the detection packet according to actual requirements, and the application range is wide.
  • the detection packet may further include an addition indication
  • the identity of the network device may be added.
  • the second network device may add the identifier of the first network device to the destination address of the response packet by adding an indication, which is simple to implement.
  • the method may further include: receiving other response packets;
  • the address other than the ID of the other response packets is forwarded to the network device indicated by the destination address of the other response packets, and the network device indicated by the destination address of the other response packets is connected to the user-side network device.
  • the network device indicated by the destination address of the other response packet may be, for example, the third network device in a multi-homing-multi-active scenario, or one or more other network devices that have a multi-homing relationship with the first network device.
  • the first network device, the second network device, and the third network device may be the operator edge device PE, and the user-side network The device may be a customer edge device CE.
  • the detection packet may be a detection packet in the Ethernet virtual private local area network (EVPN) virtual private wireless service VPWS scenario, and the response packet may be. It is the response packet of the EVPN VPWS scenario.
  • EVPN Ethernet virtual private local area network
  • the present application provides another packet transmission method, which can be performed by a second network device, and the method can include: receiving a detection packet sent by the first network device, where the detection packet includes the information of the first network device. identification; generate a response message of the detection message, the destination address of the response message includes the identification of the first network device; send the response message to the first network device or the third network device, both the third network device and the first network device Connect with the same user-side network device.
  • the receiving end device of the probe packet adds the identifier as the destination address of the response packet of the probe packet, so that even if When the non-initiator device receives the response packet, it can forward the response packet to the initiator device of the probe packet according to the destination address of the response packet, so as to ensure that the initiator device of the probe packet can receive the sent probe packet. response message.
  • the probe packet is used to detect the tunnel status, the detection error caused by the initiating end device of the probe packet being unable to receive the response packet of the probe packet is avoided, and the accuracy of tunnel detection is improved.
  • the non-initiator device can also ensure that when the non-initiator device receives the response packet, it can directly forward the response packet to the initiator of the detection packet according to the traditional routing and forwarding mechanism. It is beneficial to improve the compatibility and friendliness of the network operation.
  • the identifier of the first network device may include: an Internet Protocol IP address of the first network device; or, a media access control MAC address of the first network device.
  • the IP address or the MAC address may be used as the identifier of the first network device, which achieves high flexibility.
  • the IP address of the first network device may include: the interface IP address of the first network device; or, the IP address of the first network device.
  • different forms of IP addresses can be configured according to actual requirements to adapt to different application scenarios.
  • the identifier of the first network device may be encapsulated in the data part of the probe packet in the type-length-value TLV format;
  • the identification of a network device may be encapsulated in the source IP address of the IP header of the probe packet.
  • the identifier of the first network device may be stored in different locations of the detection packet according to actual requirements, and the application range is wide.
  • the detection packet may further include an addition instruction
  • the method may further include: according to the addition instruction and the identifier of the first network device , and add the identifier of the first network device to the destination address of the response packet.
  • the second network device may add the identifier of the first network device to the destination address of the response message by adding an indication, which is simple to implement.
  • generating a response message for the detection message may include: adding the first network to the destination IP address of the response message The IP address of the device; or, adding the MAC address of the first network device to the destination MAC address of the response packet.
  • sending a response packet to the first network device or the third network device may include: according to a load sharing algorithm, send a response message to the first network device.
  • a network device or a third network device sends a response message.
  • the first network device, the second network device, and the third network device may be the operator edge device PE, and the user-side network The device may be a customer edge device CE.
  • the detection packet may be a detection packet in the Ethernet virtual private local area network (EVPN) virtual private wireless service VPWS scenario, and the response packet may be. It is the response packet of the EVPN VPWS scenario.
  • EVPN Ethernet virtual private local area network
  • the present application also provides a message transmission apparatus, which may be the first network device in the first aspect or any possible implementation manner of the first aspect, or the apparatus may be deployed in the first aspect.
  • a network device may include a first sending unit and a first receiving unit. in:
  • the first sending unit is configured to send a probe packet to the second network device, where the probe packet includes an identifier of the first network device, and the identifier of the first network device is used to indicate that the second network device is in the response packet of the probe packet.
  • the identifier of the first network device is added to the destination address.
  • the first receiving unit is configured to receive a response message from the second network device, and the destination address of the response message is the identifier of the first network device; or, receive an updated response message from a third network device, and the updated response
  • the destination address of the packet is the identifier of the first network device, and both the third network device and the first network device are connected to the same user-side network device.
  • the identifier of the first network device includes:
  • the Internet Protocol IP address of the first network device or, the media access control MAC address of the first network device.
  • the IP address of the first network device includes: the interface IP address of the first network device; The loopback interface IP address of the first network device; or, the segment identifier SID in the form of the IP address of the first network device.
  • the apparatus before the first sending unit sends the probe packet to the second network device, the apparatus further includes:
  • a processing unit configured to generate the detection message; wherein, the identification of the first network device is encapsulated in the data part of the detection message in a type-length-value TLV format; or, the identification of the first network device is encapsulated in the source IP address of the IP header of the probe packet.
  • the detection packet further includes an addition indication, and the identifier of the first network device is used to indicate the second network device.
  • the network device adds the identifier of the first network device to the destination address of the response message of the probe packet, including: the identifier of the first network device and the addition indication are used to jointly indicate the second network
  • the device adds the identifier of the first network device to the destination address of the response message.
  • the apparatus further includes: a second receiving unit, configured to receive other response packets; a second sending unit, used forwarding the other response message to the network device indicated by the destination address of the other response message according to the destination address of the other response message being an address other than the identifier of the first network device, the The network device indicated by the destination address of the other response packets is connected to the user-side network device.
  • the first network device, the second network device, and the third network device are operator edge devices PE
  • the user side network device is a user edge device CE.
  • the detection packet is a detection packet of an Ethernet virtual private local area network (EVPN) virtual private wireless service VPWS scenario
  • the response The message is the response message of the EVPN VPWS scenario.
  • EVPN Ethernet virtual private local area network
  • the message transmission device provided in the third aspect is configured to execute the message transmission method provided in the above-mentioned first aspect, and the specific implementation may refer to the specific implementation of the above-mentioned first aspect.
  • the present application provides a message transmission apparatus, which may be the second network device in the second aspect or any possible implementation manner of the second aspect, or the apparatus may be deployed in the second network equipment.
  • the apparatus may include: a receiving unit, a processing unit and a sending unit. in:
  • the receiving unit is configured to receive a detection packet sent by the first network device, where the detection packet includes an identifier of the first network device.
  • the processing unit is configured to generate a response message of the detection message, where the destination address of the response message includes the identifier of the first network device.
  • the sending unit is configured to send a response message to the first network device or the third network device, where the third network device and the first network device are both connected to the same user-side network device.
  • the identifier of the first network device includes: the Internet Protocol IP address of the first network device; or, the media access control MAC address of the first network device .
  • the IP address of the first network device includes: the interface IP address of the first network device; The loopback interface IP address of the first network device; or, the segment identifier SID in the form of the IP address of the first network device.
  • the identifier of the first network device is encapsulated in the data portion of the probe packet in a type-length-value TLV format; Or, the identifier of the first network device is encapsulated in the source IP address of the IP header of the probe packet.
  • the detection packet further includes an addition instruction
  • the apparatus further includes: an adding unit configured to add an instruction according to the addition The indication and the identifier of the first network device, and the identifier of the first network device is added to the destination address of the response message.
  • the processing unit is specifically configured to: add the first network to the destination IP address of the response packet The IP address of the device; or, adding the MAC address of the first network device to the destination MAC address of the response packet.
  • the sending unit is specifically configured to: send a message to the first network device or the third network device according to a load sharing algorithm The network device sends the response message.
  • the first network device, the second network device, and the third network device are operator edge devices PE, the user side network device is a user edge device CE.
  • the detection packet is a detection packet of an Ethernet virtual private local area network EVPN virtual private wireless service VPWS scenario
  • the response The message is the response message of the EVPN VPWS scenario.
  • the message transmission device provided in the fourth aspect is configured to execute the message transmission method provided in the second aspect.
  • the message transmission device provided in the fourth aspect is configured to execute the message transmission method provided in the second aspect.
  • an embodiment of the present application provides a first network device, where the device may include a processor, configured to implement the packet transmission method described in the foregoing first aspect.
  • the device may further include a memory, the memory is coupled to the processor, and when the processor executes the instructions stored in the memory, the message transmission method described in the first aspect or any possible implementation manner of the first aspect can be implemented.
  • the device may also include a communication interface for the apparatus to communicate with other devices, for example, the communication interface may be a transceiver, circuit, bus, module or other type of communication interface.
  • the device may include:
  • the processor is configured to send a detection packet to the second network device, where the detection packet may include an identifier of the first network device, and the identifier of the first network device is used to indicate that the second network device is responding to the detection packet for the purpose of Add the identifier of the first network device to the address; receive a response message from the second network device, and the destination address of the response message is the identifier of the first network device; or receive the updated response message from the third network device, update the The destination address of the latter response message is the identifier of the first network device, and both the third network device and the first network device are connected to the same user-side network device.
  • the instructions in the memory in this application can be pre-stored or downloaded from the Internet when the device is used and stored, and this application does not specifically limit the source of the instructions in the memory.
  • the coupling in the embodiments of the present application is an indirect coupling or connection between devices, units or modules, which may be in electrical, mechanical or other forms, and is used for information exchange between devices, units or modules.
  • an embodiment of the present application provides a second network device, where the device may include a processor for implementing the packet transmission method described in the second aspect or any possible implementation manner of the second aspect.
  • the device may further include a memory, the memory is coupled to the processor, and when the processor executes the instructions stored in the memory, the message transmission method described in the second aspect above can be implemented.
  • the device may also include a communication interface for the apparatus to communicate with other devices, for example, the communication interface may be a transceiver, circuit, bus, module or other type of communication interface.
  • the device includes:
  • a processor configured to receive a detection packet sent by the first network device, where the detection packet includes the identifier of the first network device; generate a response packet of the detection packet, and the destination address of the response packet includes the identifier of the first network device; A response message is sent to the first network device or the third network device, where both the third network device and the first network device are connected to the same user-side network device.
  • the instructions in the memory in this application can be pre-stored or downloaded from the Internet when the device is used and stored, and this application does not specifically limit the source of the instructions in the memory.
  • the coupling in the embodiments of the present application is an indirect coupling or connection between devices, units or modules, which may be in electrical, mechanical or other forms, and is used for information exchange between devices, units or modules.
  • a seventh aspect provides a message transmission system
  • the communication system may include a first device for message transmission, and a second device for message transmission, where the first device for message transmission may be the third aspect or
  • the second apparatus for transmitting the message may be the apparatus in the fourth aspect or any possible implementation manner of the fourth aspect.
  • a message transmission system may include a first network device and a second network device, and the first network device may be the fifth aspect or any possible implementation of the fifth aspect.
  • the apparatus in the manner, the second network device may be the apparatus in the sixth aspect or any possible implementation manner of the sixth aspect.
  • the embodiments of the present application further provide a computer-readable storage medium, including instructions, when running on a computer, causing the computer to execute the message described in any one of the above aspects or any possible implementation manner transfer method.
  • the embodiments of the present application further provide a computer program product, which, when running on a computer, enables the computer to execute the message transmission method described in any one of the foregoing aspects or any possible implementation manner.
  • an embodiment of the present application provides a chip system, where the chip system includes a processor and may further include a memory, for implementing the functions performed by the first network device in the foregoing method.
  • the chip system can be composed of chips, and can also include chips and other discrete devices.
  • an embodiment of the present application provides a chip system, where the chip system includes a processor, and may further include a memory, for implementing the functions performed by the second network device in the foregoing method.
  • the chip system can be composed of chips, and can also include chips and other discrete devices.
  • FIG. 1 is a schematic structural diagram of a message transmission system in an EVPN VPWS dual-homing dual-active scenario provided by an embodiment of the present application;
  • FIG. 2 is a schematic structural diagram of a message transmission system according to an embodiment of the present application.
  • FIG. 3 is a schematic structural diagram of a message transmission system in another EVPN VPWS dual-homing dual-active scenario provided by an embodiment of the present application;
  • FIG. 4 is a schematic structural diagram of a network device according to an embodiment of the present application.
  • FIG. 5 is a schematic flowchart of a message transmission method provided by an embodiment of the present application.
  • FIG. 6 is a schematic structural diagram of a detection packet provided by an embodiment of the present application.
  • FIG. 7 is a schematic structural diagram of a response message provided by an embodiment of the present application.
  • FIG. 8 is a schematic structural diagram of another response message provided by an embodiment of the present application.
  • FIG. 9 is a schematic flowchart of another message transmission method provided by an embodiment of the present application.
  • FIG. 10 is a schematic structural diagram of a message transmission apparatus provided by an embodiment of the present application.
  • FIG. 11 is a schematic structural diagram of another message transmission apparatus provided by an embodiment of the present application.
  • FIG. 12 is a schematic structural diagram of a first network device according to an embodiment of the present application.
  • FIG. 13 is a schematic structural diagram of another message transmission apparatus provided by an embodiment of the present application.
  • FIG. 14 is a schematic structural diagram of still another message transmission apparatus provided by an embodiment of the present application.
  • FIG. 15 is a schematic structural diagram of a second network device according to an embodiment of the present application.
  • words such as “exemplary” or “for example” are used to represent examples, illustrations or illustrations. Any embodiments or designs described in the embodiments of the present application as “exemplary” or “such as” should not be construed as preferred or advantageous over other embodiments or designs. Rather, the use of words such as “exemplary” or “such as” is intended to present the related concepts in a specific manner to facilitate understanding.
  • At least one may also be described as one or more, and the multiple may be two, three, four or more, which is not limited in this application.
  • an embodiment of the present application provides a packet transmission method.
  • the receiver device of the probe packet adds the identifier as the destination address of a response packet of the probe packet. In this way, even if the non-initiator device receives the response packet, it can forward the response packet to the initiator device of the probe packet according to the destination address of the response packet, and ensure that the initiator device of the probe packet can receive the sent Response message to the probe message.
  • the probe packet When the probe packet is used to detect the tunnel status, the detection error caused by the initiating device of the probe packet being unable to receive the response packet of the probe packet is avoided, and the accuracy of tunnel detection is improved.
  • the identifier of the initiator device is added to the destination address part of the response packet, when the non-initiator device receives the response packet, it can directly forward the response packet to the initiator device according to the traditional routing and forwarding mechanism. This ensures the compatibility and friendliness of network operation.
  • the message transmission system 20 may include multiple user-side network devices 201 and multiple operator-side network devices 202 .
  • One user-side network device 201 may be connected to one or more operator-side network devices 202 .
  • the user-side network device 201 and the operator-side network device 202 may communicate through IP routing; the operator-side network device 202 and the operator-side network device 202 may communicate through tunnels, or IP routing communication, or communicate in other ways.
  • the user side network device 201 may be CE or others. Exemplarily, the user-side network device 201 may be a router or a switch. The user-side network device 201 may communicate with another user-side network device 201 accessed through other operator-side network devices 202 through one or more operator-side network devices 202 .
  • the direct connection between the user-side network device 201 and the operator-side network device 202 shown in FIG. 2 is only a possible example, and the user-side network device 201 can also be connected to the operator-side network device through one or more other network devices. 202 Connection.
  • the operator-side network device 202 may be PE or others.
  • the carrier-side network device 202 may be a router or a switch, or other product forms.
  • the network device 202 on the operator side may send a detection message and/or receive a response message according to the solution provided in this application; or, the network device 202 on the operator side may follow the solution provided in this application.
  • the specific processing process of receiving a detection packet and sending a response packet of the received detection packet is described in the following method embodiments.
  • the tunnel can be iterative multi-protocol label switching (MPLS), segment routing (SR), SRv6 and other tunnel types.
  • MPLS multi-protocol label switching
  • SR segment routing
  • SRv6 tunnel types
  • the message transmission system 20 may be used for message transmission in different scenarios, which is not uniquely limited in this embodiment of the present application.
  • the message transmission system 20 can be applied to the message transmission of the EVPN VPWS multi-homing multi-active scenario.
  • the EVPN VPWS multi-homing scenario there is one user-side network device 201 connected to multiple operator-side network devices 202; and the operator-side network device 202 is set to a multi-active mode.
  • FIG. 3 illustrates a structure in which the message transmission system 20 is applied to an EVPN VPWS dual-homing dual-active scenario.
  • the message transmission system 20 may include a first PE301, a second PE302, a third PE303, a first CE304, and a second CE305.
  • the first CE304 is dual-homed to the first PE301 and the third PE303; the second CE305 is single-homed to the second PE302; the first PE301 communicates with the second PE302 through the EVPN VPWS tunnel, and the second PE302 and the third PE303 communicate through the EVPN VPWS tunnel communication, the first PE301 communicates with the third PE303 through IP routing or tunneling or other methods.
  • PEs can communicate directly, or, other PEs can also communicate through other nodes.
  • the second CE305 is single-homed to the second PE302.
  • the second CE305 may also be dual-homed to two PEs; more CEs may also be connected to the third PE303.
  • the embodiments of the present application do not specifically limit the number of CEs and PEs included in the scenario, and the connection modes between CEs and PEs and between PEs and PEs.
  • the first PE301 may be used to send a detection packet, and receive a response packet of the detection packet sent by the second PE302 or the third PE303;
  • the second PE302 may be used to receive the detection packet sent by the first PE301, and send the response packet of the detection packet to the first PE301 or the third PE303;
  • the third PE303 can be used to receive the response packet of the detection packet sent by the second PE302, and forward the response packet of the detection packet to The first PE301.
  • the embodiment of the present application provides a network device 40 for executing the packet transmission method provided by the present application.
  • the network device 40 may be the operator-side network device 202 shown in FIG. 2 .
  • FIG. 4 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 , and a transceiver 403 .
  • the memory 402 may be a volatile memory (volatile memory), such as random-access memory (RAM); or a 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 (solid-state drive, SSD); or a combination of the above-mentioned types of memories, for storing application programs that can implement the method of the present application code, configuration files, data information, or other content.
  • volatile memory such as random-access memory (RAM)
  • non-volatile memory such as read-only memory (read-only memory, ROM), flash memory (flash memory), hard disk drive (HDD) or solid-state drive (solid-state drive, SSD)
  • HDD hard disk drive
  • SSD solid-state drive
  • the transceiver 403 is used for information exchange between the network device 40 and other devices.
  • the transceiver 403 may be used to exchange information with other network devices.
  • the processor 401 may be the control center of the network device 40 .
  • the processor 401 may be a central processing unit (CPU), an application specific integrated circuit (ASIC), or an integrated circuit configured to implement one or more of the embodiments of the present application.
  • Circuits such as: one or more microprocessors (digital singnal processor, DSP), or, one or more field programmable gate array (field programmable gate array, FPGA).
  • the network device 40 is the initiating end device of the detection message, and the processor 401 makes the network device 40 execute as the first network device by running or executing the software programs and/or modules stored in the memory 402.
  • the probe packet includes the identifier of the first network device, and the identifier of the first network device is used to instruct the second network device to add the first network device to the destination address of the response packet of the probe packet identification of the device; receive a response message from the second network device, and the destination address of the response message is the identification of the first network device; or, receive an updated response message from a third network device, the updated response message is The destination address is the identifier of the first network device, and both the third network device and the first network device are connected to the same user-side network device.
  • the network device 40 may be, for example, the first PE 301 shown in FIG. 3 .
  • the network device 40 is the receiving end device of the detection packet, and the processor 401 runs or executes the software programs and/or modules stored in the memory 402 so that the network device 40 acts as the second network device Execute the following functions:
  • the network device 40 may be, for example, the second PE 302 shown in FIG. 3 .
  • the processor 401 can execute all the described functions by running or executing the software programs and/or modules stored in the memory 402;
  • the software program and/or module cooperates with other components or modules in the network device 40 to jointly perform all the described functions, for example, the processor 401 performs the function of generating a probe message or a response message, and sends and receives corresponding messages through the transceiver 403. Probe packets or response packets.
  • an embodiment of the present application provides a packet transmission method, which can be applied to an interaction process between a first network device and a second network device.
  • the first network device and the second network device may be carrier-side network devices in the message transmission system shown in FIG. 2 .
  • the first network device and the third network device are both connected to the first user-side network device, and the second network device is connected to the second user-side network device.
  • the first network device may be the first PE 301 illustrated in FIG. 3
  • the second network device may be the second PE 302 illustrated in FIG. 3
  • the third network device may be the third PE 303 illustrated in FIG. 3 .
  • the packet transmission method provided in this embodiment of the present application may be used in a tunnel detection process between network devices on the operator side, or in other network processing processes in which a response packet is received by sending out a probe packet, which is not covered by this application. be specifically limited.
  • the use of probe packets for tunnel detection is taken as an example, and the packet transmission method provided by the present application is described in detail, and the scenarios in which probe packets are used for other purposes are not repeated.
  • the packet transmission method provided by the embodiment of the present application may include:
  • the first network device generates a detection packet.
  • the first network device performs the operation of S501 to generate a detection packet when it needs to perform network processing for sending a detection packet to receive a response packet.
  • the timing may be user indication or periodic timing or others, and the network processing may be tunnel detection or others.
  • the detection packet is a packet sent by the initiator device in the network processing process of receiving the response packet by sending the detection packet.
  • the probe packet may be used to detect whether the tunnel connected to the first network device is normal.
  • the application scenarios and functions of the detection packets may be configured according to actual conditions, and the embodiments of the present application do not uniquely limit the application scenarios and specific functions of the detection packets.
  • the detection packet may be a packet used to detect whether the tunnel connected to the first network device is normal in the EVPN VPWS scenario.
  • the detection packet may include the identifier of the first network device.
  • the identifier of the first network device included in the probe packet may be used to instruct the network device (for example, the second network device) that receives the probe packet to add the first network device's identifier to the destination address of the response packet of the probe packet. identifier to ensure that the first network device can receive the response message corresponding to the sent probe message.
  • the first network device may be an end device on one side of the tunnel, and the device receiving the probe packet may be, for example, an end device on the other side of the tunnel.
  • the tunnel can be a segmented tunnel or a segmented tunnel.
  • the identifier of the first network may be used to uniquely indicate the first network device, and this application does not limit the type of the identifier of the first network device.
  • the identifier of the first network device may include the IP address of the first network device.
  • the IP address of the first network device may be an interface IP address of the first network device; or, an IP address of a loopback interface of the first network device, or a SID in the form of an IP address of the first network device.
  • the IP address may be an IPv4 address, an IPv6 address, or others.
  • the identifier of the first network device may include: the MAC address of the first network device.
  • the encapsulation location of the identifier of the first network device in the probe packet may include, but is not limited to, the following implementation A or implementation B.
  • Implementation A The identifier of the first network device is encapsulated in the data part of the probe packet in TLV format.
  • FIG. 6 illustrates the structure of a probe packet.
  • the structure of the probe packet includes a data part and a header.
  • the header may include: a user datagram protocol (UDP) header, an IP header, a label stack, and a link header.
  • UDP user datagram protocol
  • the UDP header may include source port and destination port;
  • the IP header may include source IP address, destination IP address and reserved bits;
  • the label stack may include public network path label and tunnel label.
  • the identifier of the first network device may be encapsulated in the data part of the probe packet with the structure shown in FIG. 6 in TLV format.
  • the TLV includes the TLV type, the length of the identifier of the first network device, and the identifier of the first network device.
  • TLV may be configured according to actual requirements, which is not specifically limited in this embodiment of the present application.
  • the TLV type (tag, T) may be configured as 26, and the length (length, L) of the TLV may be configured as the length of the IPv4 address of the first network device , the value (value, V) of the TLV may be configured as the IPv4 address of the first network device.
  • the type T occupies 1 byte
  • the length L occupies 1 byte
  • the value V occupies 4 bytes.
  • the T of the TLV can be configured to be 26
  • the L of the TLV can be configured to be the length of the IPv6 address of the first network device
  • the V of the TLV can be configured as the length of the IPv6 address of the first network device. Configured as the IPv6 address of the first network device. Among them, T occupies 1 byte, L occupies 1 byte, and V occupies 16 bytes.
  • the T of the TLV can be configured to be 26
  • the L of the TLV can be configured to be the length of the MAC address of the first network device
  • the V of the TLV can be configured as the length of the MAC address of the first network device. Configured as the MAC address of the first network device. Among them, T occupies 1 byte, L occupies 1 byte, and V occupies 6 bytes.
  • Implementation B The identifier of the first network device is encapsulated in the source IP address of the IP header of the probe packet.
  • the identifier of the first network device is the IP address of the first network device.
  • the IP address of the first network device may be encapsulated in the source IP address of the IP header of the probe packet with the structure shown in FIG. 6 .
  • the identifier of the first network device can be encapsulated in other positions of the detection packet according to actual requirements, and the above implementation A or implementation B does not constitute a unique limitation.
  • the detection packet may further include a type indication of the identifier of the first network device.
  • the identifier type indication of the first network device is used to indicate the type of the identifier of the first network device carried in the probe packet.
  • the identification type of the first network device may include but is not limited to any of the following: IPv4, IPv6, and MAC.
  • the second network device may determine a network application environment matching the type according to the indication of the identification type.
  • the probe packet may further include an addition indication, and the identifier of the first network device and the addition indicator are used to jointly instruct the second network device to add the identifier of the first network device to the destination address of the response packet of the probe packet.
  • the user can configure the form of the addition indication and its position in the probe message according to the actual situation, which is not uniquely limited in this application.
  • the addition indication may be in the form of one or more bit values.
  • the addition indicates that one or more reserved bits may be the header of the probe packet.
  • the addition indication may be a certain reserved bit or certain reserved bits in the IP header of the probe packet with the structure as shown in FIG. 6 .
  • the addition indication may be 3 reserved bits in the IP header of the probe packet, the value of which is 001.
  • the implementation of S501 may be: the first network device obtains the identification information of the tunnel to be detected, takes the identification information of the tunnel to be detected as the data part of the probe packet, and then By adding the identifier of the first network device, or adding the identifier of the first network device and adding the instruction by the method in the above-mentioned implementation A or implementation B, the packet is encapsulated with the UDP header, IP header, label stack and link header to generate Probe packets of the structure shown in Figure 6.
  • the first network device may configure the source port in the UDP header of the detection packet as a random port number, and configure the destination port in the UDP header as 3503; configure the source IP address in the IP header of the detection packet Configure the IP address and destination IP address of the first network device as the IP address of the second network device, or configure the IP header and destination IP address as 127/8 according to RFC8029, for example, 127.0.0.1;
  • the public network label is configured as the path label of the tunnel detected by the first network device, and the tunnel label is configured as the tunnel entry label and the tunnel exit label.
  • the first network device sends a detection packet to the second network device.
  • the second network device is a network device that receives the detection packet.
  • the second network device may be the destination end device when the first network device sends the probe packet.
  • the second network device determines that the destination IP address in the probe packet is the same as its own IP address when receiving the probe packet, then the second network device determines that the destination IP address in the probe packet is the same as its own IP address.
  • the second network device determines that the destination IP address in the probe packet is the same as its own IP address.
  • the tunnel identifier to be detected is used as the destination tunnel identifier of the probe packet, and the probe packet is sent on the tunnel connected to it. Any one of the multiple network devices at the other end of the tunnel may receive the detection packet, and the peer network device that receives the detection packet is the second network device.
  • the indicating IP address is used to instruct the network device that has received the detection packet to no longer forward the detection packet and process the detection packet by itself.
  • the indicated IP address may be 127/8, for example, 127.0.0.1.
  • the other end of the tunnel connected to the first network device is a multi-homing scenario, and the destination IP address in the detection packet is configured as 127/8, for example, 127.0.0.1; the tunnel identifier to be detected is used as the detection packet. the destination tunnel identifier, and sends the detection packet on the tunnel to which it is connected. Any network device at the other end of the tunnel may receive the detection packet, and the peer network device that receives the detection packet may receive the detection packet. If it is determined that the destination IP address in the probe packet is configured as 127/8, it considers itself (the second network device) as the peer network device that receives the probe packet.
  • S502 may be implemented as: the first network device sends the detection packet generated in S501 through the tunnel to which it is connected.
  • the first network device may send the detection packet generated by S501 through the EVPN VPWS tunnel.
  • the first network device directly sends the probe packet generated in S501 to the second network device through the tunnel.
  • the first network device and the second network device are two end devices of the tunnel, or the first network device and the second network device include multiple segments of tunnels, the first network device is the end device of the first segment of the tunnel, and The second network device is the end device of the last segment of the tunnel.
  • the first network device sends the detection packet generated in S501 through the tunnel, and then reaches the second network device after being forwarded by one or more network devices.
  • the first network device forwards the probe packet generated in S501 to the second network device via network device 1 and network device 2 through the iterative MPLS or EVPN VPWS tunnel of the SR public network.
  • the second network device receives the detection packet sent by the first network device.
  • the network device can identify the purpose of the packet by receiving the port number of the packet. For example, a packet received by a certain port may be configured as a probe packet, and the second network device identifies the receiving port when receiving the packet to determine whether the received packet is a probe packet.
  • the protocol specifies that port 3503 receives a probe packet for detecting whether the tunnel is normal
  • the second network device receives the packet in S503
  • it identifies that the port number receiving the packet is 3503, and the packet can be determined. It is a probe packet used to detect whether the tunnel is normal.
  • the second network device identifies the destination IP address of the probe packet, and if the IP address is its own IP address or the destination IP is 127/8, upload it to the local machine for processing; the second network device decodes the probe packet. encapsulate, and obtain the data information in the detection packet, so as to execute S504. If the destination address of the detection packet is not its own address, the second network device may forward the packet according to the destination IP address, so as to forward the packet to the network device capable of executing S504.
  • the second network device generates a response message of the detection message.
  • the second network device performs corresponding processing according to the purpose of the received detection packet. For example, when the detection packet is used to detect whether the tunnel is normal, the second network device in S504 detects whether the tunnel is normal, and obtains the detection result. In S504, the second network device takes the result obtained by the executed processing as the data part, and generates a response message.
  • the second network device obtains the identifier of the first network device at the location where the identifier of the first network device is encapsulated in the detection message, and according to the indication of the identifier of the first network device, converts the identifier of the first network device. Identifies the destination address of the response message to generate the response message.
  • the packaging location of the identifier of the first network device is known to the second network device, and the known manner may be that the second network device directly knows the packaging location where the identifier of the first network device is located, or the second network device passes the identifier
  • the indication information determines an encapsulation location where the identifier of the first network device is located.
  • the second network device obtains the first network device by encapsulating the location of the identifier of the first network device in the probe packet (the location of the encapsulation of the identifier of the first network device is known to the second network device) , add the indicated position in the detection message (the position of adding the instruction is known to the second network device) to obtain the addition instruction, and according to the acquired identification of the first network device and the common indication of the addition instruction, the first network device
  • the ID of the response message is used as the destination address of the response message to generate a response message.
  • the addition indication may be used to indicate whether the second network device needs to add the identifier of the first network device in the response packet.
  • the location where the second network device encapsulates the identification of the first network device in the probe packet does not obtain the first network device.
  • the identifier of the network device is not obtained at the location where the indication is added in the detection packet, and the response packet generated by the second network device in S504 may not carry the identifier of the first network device.
  • the processing result may be used as the data part of the response message
  • the identifier of the first network device may be used as the destination address of the response message
  • the The data part of the response packet is encapsulated by UDP, IP, Ethernet, label stack and link layer, and a response packet of the detection packet is generated.
  • the packet structure of the response packet may be as shown in FIG. 7 .
  • the response message may include a data part and a header, and the header may include a UDP header, an IP header, an Ethernet header, a label stack, and a link header.
  • the UDP header may include source port and destination port;
  • the IP header may include source IP address, destination IP address and reserved bits;
  • the Ethernet header may include source MAC address and destination MAC address;
  • the label stack may include public network path label and tunnel label.
  • the detection packet may be a detection packet of the EVPN VPWS scenario
  • the response packet of the detection packet may be a response packet of the detection packet of the EVPN VPWS scenario.
  • the tunnel label of the response packet of the structure shown in FIG. 7 is the EVPN VPWS tunnel label.
  • the second network device uses the IP address of the first network device as the destination IP address of the response packet.
  • the second network device uses the MAC address of the first network device as the destination MAC address of the response packet.
  • S504 may be implemented as: the exit identifier of the tunnel to be detected obtained by the second network device in the data part of the probe packet, if the identifier is the same as its own tunnel identifier If the same, it is determined that the tunnel to be detected is normal, and if the identifier is different from the identifier of the own tunnel, it is determined that the tunnel to be detected is abnormal.
  • the second network device takes the detection result of the normality or abnormality of the tunnel as the data part of the response packet of the detection packet, or the second network device converts the detection result of the normality or abnormality of the tunnel into a corresponding code, which is used as the detection packet The data part of the response message.
  • the second network device obtains the identification of the first network device carried in the detection packet, and uses the identification of the first network device as the destination address of the response packet of the detection packet; and performs UDP on the data part of the response packet. , IP, Ethernet, label stack, and link layer encapsulation to generate response packets for detection packets.
  • the second network device may further determine packet loss and delay on the basis of determining whether the exit identifier of the tunnel to be detected is the same as its own tunnel identifier. Specifically, if the second network device determines that the exit identifier of the tunnel to be detected is the same as its own tunnel identifier, and the received probe packet has no packet loss, and the delay is less than the preset threshold, and the tunnel to be detected in the probe packet is detected The egress identifier of the device is the same as its own tunnel identifier, and it is determined that the tunnel to be detected is normal; otherwise, it is determined that the tunnel to be detected is abnormal.
  • S504 may be implemented as: the second network device obtains the to-be-detected data in the probe packet.
  • the exit identifier of the tunnel judge that the identifier is the same as the tunnel identifier, and then count the delay and packet number of the received probe packets. If there is no packet loss and the delay is less than the preset threshold, the communication of the EVPN VPWS tunnel is considered to be normal.
  • the second network device converts the normal or abnormal detection result of the tunnel into a code corresponding to the detection result, as the data part of the response message of the detection message. Then, the second network device fills the source port in the UDP header of the response packet of the detection packet with 3503 and the destination port number with 65004; fills the source IP address in the IP header of the response packet with the detection packet as The IP address of the second network device, after obtaining the IP address of the first network device carried in the probe packet, fills the destination IP address in the IP header of the response packet of the probe packet with the IP address of the first network device address; fill the source MAC address in the Ethernet header of the response packet of the detection packet with the MAC address of the second network device, obtain the MAC address of the first network device by searching for a route, and then use the response packet of the detection packet to obtain the MAC address of the first network device.
  • the destination MAC address in the Ethernet header is filled with the MAC address of the Ethernet header of the
  • the second network device can ensure that the response packet can be successfully forwarded to the first network device that is the initiator of the probe packet, without the traditional
  • the response packet may fail to reach the originating end of the probe packet smoothly.
  • the IP address of the first network device is added to the destination IP address field of the response message, it is also possible for the device that is the non-initiator to continue to forward the response message according to the traditional forwarding rules after receiving the response message. The compatibility of network operation has been improved.
  • the second network device sends the response message to the first network device or the third network device.
  • the third network device and the first network device are both connected to the same first user-side network device.
  • the third network device is any network device other than the first network device connected to the same user-side network device.
  • the first network device may be the first PE301
  • the second network device may be the second PE302
  • the third network device may be the third PE303.
  • the second network device may select one network device from multiple network devices connected to the first user-side network device according to the load sharing algorithm, and send a response packet of the probe packet generated in S504 to the selected network device through the tunnel.
  • the second PE302 may send a response packet to one of the first PE301 or the second PE303 according to the load sharing algorithm.
  • the user can configure the load sharing algorithm according to actual needs. For example, in a possible implementation manner, a network device with the smallest load is selected according to a load sharing algorithm, or any network device whose load is less than the first threshold is selected according to the load sharing algorithm.
  • the user may configure the first threshold according to actual needs, which is not limited in this embodiment of the present application.
  • the second network device may also send a response packet to the first network device or the third network device according to other preset mechanisms.
  • the second network device sends the response packet of the probe packet generated in S504 to the first network device or the third network device through the tunnel of the iterative MPLS or SR public network.
  • the first network device receives a response packet from the second network device; or, receives an updated response packet from the third network device.
  • the destination addresses of the response message and the updated response message are the identifiers of the first network device.
  • S506 may be implemented as: the first network device receives the response message of the detection message sent by the second network device in S505, and the first network device obtains the destination address in the response message of the detection message. , determine that the destination address is the identifier of the first network device, and then decapsulate the response packet to obtain data information in the response packet.
  • the third network device receives the response message of the detection message sent by the second network device in S505, the third network device obtains the destination address in the response message, and determines that the destination address is the first The identification of the network device is different from its own network device identification, and then the response packet is updated, and the updated response packet of the probe packet is forwarded to the first network device indicated by the destination address through IP routing or tunneling or other methods.
  • the first network device receives the response packet of the updated probe packet forwarded by the third network device, obtains the destination address in the response packet of the updated probe packet, and determines that the destination address is the identifier of the first network device , and then decapsulate the response packet of the updated detection packet to obtain data information in the response packet of the updated detection packet.
  • the specific implementation may be to modify the received message in some way, such as removing the label stack and link layer encapsulation in the response message of the probe message, or further Add other necessary information to the message.
  • the update can also be understood as that the third network device does not need to make any substantial changes to the message, but directly transparently transmits the message to the first network device through the third network device Arts.
  • the second network device sends a response message with the structure shown in FIG. 7 to the third network device in S505
  • the destination address of the response message is the identifier of the first network device
  • the third network device sends the response message to the first network device.
  • the updated response message sent by the network device may be as shown in FIG. 8 .
  • the first network device determines whether the tunnel to be detected is normal according to the acquired data information in the response packet.
  • An embodiment of the present application provides a message transmission method.
  • the receiver device of the probe packet adds the identifier as the destination address of a response packet of the probe packet.
  • the non-initiator device receives the response packet, it can forward the response packet to the initiator device of the probe packet according to the destination address of the response packet, so as to ensure that the initiator device of the probe packet can receive the sent probe packet. response message.
  • the probe packet is used to detect the tunnel status, the detection error caused by the initiating end device of the probe packet being unable to receive the response packet of the probe packet is avoided, and the accuracy of tunnel detection is improved.
  • the first network device may also receive response packets of detection packets sent by other network devices.
  • the packet transmission method provided by the embodiment of the present application may also include the following: Describe S507 and S508.
  • the first network device receives other response packets.
  • the initiating end device of the detection packet can also be other network devices except the first network device.
  • the first network device may also receive other response packets sent by the remote network device (eg, the second network device) through the tunnel.
  • the first network device forwards the other response packets to the network device indicated by the destination addresses of the other response packets according to the destination addresses of the other response packets being addresses other than the identifier of the first network device.
  • the other network devices indicated by the destination addresses of the response packets are connected to the first user-side network device.
  • S508 may be implemented as: the first network device obtains the destination addresses of the other response packets received in S507, determines that the destination addresses of the other response packets are different from its own destination address, and the first network device obtains the destination addresses of the other response packets. After the update, it is forwarded to other network devices indicated by the destination address of the response packet through IP routing or tunneling.
  • the other network device may further obtain the updated data information of the other response message.
  • the message transmission process provided by the embodiment of the present application is described below by taking the message transmission system of the EVPN VPWS dual-homing dual-active scenario shown in FIG. 1 as an example.
  • PE1 initiates tunnel detection, it is used to detect whether the EVPN tunnels with tunnel IDs 100 to 200 are normal; this process may include:
  • PE1 obtains the IP address of PE1 and the egress identifier of the tunnel to be detected, and uses the IP address of PE1 and the egress identifier of the tunnel to be detected stored in TLV format as the data part of the detection packet, and then uses the data part to Encapsulate and generate a detection packet, PE1 sends the detection packet to the egress device of the tunnel through the EVPN VPWS tunnel of 100 to 200; PE3 receives the detection packet, decapsulates the detection packet, and sends the detection packet in the detection packet.
  • the data part obtains the identification of the tunnel to be detected, obtains the detection result of the current tunnel according to the identification, and uses the detection result of this tunnel as the data part of the response packet of the detection packet; PE3 obtains the detection result in the data part of the detection packet
  • the IP address of PE1 in the packet, the destination IP address of the response packet of the detection packet is added as the IP address of PE1, and the response packet of the detection packet is encapsulated and sent to the tunnel egress device through the EVPN VPWS tunnel.
  • PE1 receives the response packet, it obtains the current tunnel detection result according to the response packet; if PE2 receives the response packet, PE2 updates the response packet and forwards it to PE1 through IP routing, and PE1 receives the response packet forwarded by PE2.
  • the response message and the current tunnel detection result are obtained.
  • PE1 obtains the egress identifier of the tunnel to be detected, takes the egress identifier of the tunnel to be detected as the data part of the packet, obtains the IP address of PE1, and configures the source IP address of the IP header of the packet as PE1 The source IP address of the source IP address, set some 3 reserved bits in the packet to 001 as an addition instruction, and then encapsulate the packet to generate a probe packet; PE1 sends the probe packet to the EVPN VPWS tunnel from 100 to 200 to The device at the exit end of the tunnel; PE3 receives the probe packet, decapsulates the probe packet, and obtains the end ID of the tunnel to be detected in the probe packet in the data part of the probe packet, and obtains the current tunnel ID according to the ID.
  • the detection result is used as the data part of the response packet of the detection packet; PE1 finds that there is an addition indication 001 in the detection packet, obtains the IP address of PE1 from the source IP address in the IP header of the detection packet, and uses the detection packet to obtain the IP address of PE1.
  • the destination IP address of the response packet is added as the IP address of PE1, and the response packet of the detection packet is encapsulated and sent to the tunnel egress device through the EVPN VPWS tunnel. If PE2 receives the response packet, PE2 updates the response packet and forwards it to PE1, and PE1 receives the response packet forwarded by PE2 and obtains the current tunnel detection result.
  • PE1 obtains the MAC address of PE1 and the egress identifier of the tunnel to be detected, uses the MAC address of PE1 and the egress identifier of the tunnel to be detected stored in TLV format as the data part of the packet, and uses the packet in the packet.
  • a certain 3 reserved bits are set to 001 as an addition instruction, and then the packet is encapsulated to generate a probe packet; PE1 sends the probe packet to the egress device of the tunnel through the EVPN VPWS tunnel of 100 to 200; PE3 receives the Probe packet, after decapsulating the probe packet, obtain the end identifier of the tunnel to be detected in the probe packet in the data part of the probe packet, and obtain the tunnel detection result according to the identifier, as the response of the probe packet The data part of the message; PE1 finds that the addition indication 001 exists in the detection message, searches the data part of the detection message for the MAC address of PE1 stored in TLV format, and adds the destination MAC address of the response message of the detection message It is the MAC address of PE1.
  • PE1 After encapsulating the response packet of the detection packet, it is sent to the tunnel egress device through the EVPN VPWS tunnel. If PE1 receives the response packet, it will obtain the tunnel detection result according to the response packet. PE2 receives the response packet, and PE2 updates the response packet and forwards it to PE1, and PE1 receives the response packet forwarded by PE2 and obtains the current tunnel detection result.
  • each message transmission apparatus such as the first network device and the second network device, includes corresponding hardware structures and/or software modules for performing each function.
  • the present invention can be implemented in hardware or a combination of hardware and computer software in conjunction with the units and algorithm steps of each example described in the embodiments disclosed herein. Whether a function is performed by hardware or computer software driving hardware depends on the specific application and design constraints of the technical solution. Skilled artisans may implement the described functionality using different methods for each particular application, but such implementations should not be considered beyond the scope of the present invention.
  • the message transmission apparatus and the like can be divided into functional modules according to the above method examples.
  • each functional module can be divided corresponding to each function, or two or more functions can be integrated into one processing module.
  • the above-mentioned integrated modules can be implemented in the form of hardware, and can also be implemented in the form of software function modules. It should be noted that, the division of modules in the embodiment of the present invention is schematic, and is only a logical function division, and there may be other division manners in actual implementation.
  • FIG. 10 shows a message transmission apparatus 100 provided by an embodiment of the present application, which is used to implement the function of the first network device in the above-mentioned embodiment.
  • the message transmission apparatus 100 may be a first network device or the message transmission apparatus 100 may be deployed in the first network device.
  • the message transmission apparatus 100 may include: a first sending unit 1001 and a first receiving unit 1002 .
  • the first sending unit 1001 is configured to perform S502 in FIG. 5 or FIG. 9 ; the first receiving unit 1002 is configured to perform S506 in FIG. 5 or FIG. 9 .
  • all relevant contents of the steps involved in the above method embodiments can be cited in the functional descriptions of the corresponding functional modules, which will not be repeated here.
  • the message transmission apparatus 100 may further include: a processing unit 1003 , a second receiving unit 1004 and a second sending unit 1005 .
  • the processing unit 1003 is configured to execute S501 in FIG. 5 or FIG. 9 ;
  • the second receiving unit 1004 is configured to execute S507 in FIG. 9 ;
  • the second sending unit 1005 is configured to execute S508 in FIG. 9 .
  • the first network device 120 provided in this embodiment of the present application is used to implement the function of the first network device in the above method.
  • the first network device 120 includes at least one processing module 1201, which is configured to implement the function of the first network device in the embodiment of the present application.
  • the processing module 1201 may be configured to execute the process S501 in FIG. 5 , for details, please refer to the detailed description in the method example, which will not be repeated here.
  • the first network device 120 may also include at least one storage module 1202 for storing program instructions and/or data.
  • the storage module 1202 and the processing module 1201 are coupled.
  • the coupling in the embodiments of the present application is an indirect coupling or communication connection between devices, units or modules, which may be in electrical, mechanical or other forms, and is used for information exchange between devices, units or modules.
  • the processing module 1201 may cooperate with the storage module 1202 .
  • the processing module 1201 may execute program instructions stored in the storage module 1202 . At least one of the at least one storage module may be included in the processing module.
  • the first network device 120 may further include a communication module 1203 for communicating with other devices through a transmission medium, so as to determine that the first network device 120 can communicate with other devices.
  • the communication module 1203 is used for the device to communicate with other devices.
  • the processor 1201 may use the communication module 1203 to perform the processes S502, S506, S507, and S508 in FIG. 5 or FIG. 9 .
  • the processing module 1201 is a processor
  • the storage module 1202 is a memory
  • the communication module 1203 is a transceiver
  • the first network device 120 involved in FIG. 12 in the embodiment of the present application may be the network device 40 shown in FIG. 4 .
  • the message transmission apparatus 100 or the first network device 120 provided by the embodiments of the present application may be used to implement the functions of the first network device in the methods implemented by the above embodiments of the present application.
  • the specific technical details are not disclosed, please refer to the embodiments of the present application.
  • the message transmission apparatus 130 provided in the embodiment of the present application is used to realize the function of the second network device in the above-mentioned embodiment.
  • the message transmission apparatus 130 may be a second network device or the message transmission apparatus 130 may be deployed in the second network device.
  • the message transmission apparatus 130 may include: a receiving unit 1301 , a processing unit 1302 and a sending unit 1303 .
  • the receiving unit 1301 is configured to execute S503 in FIG. 5 or FIG. 9 ;
  • the processing unit 1302 is configured to execute S504 in FIG. 5 or FIG. 9 ;
  • the sending unit 1303 is configured to execute S505 in FIG. 5 or FIG. 9 .
  • the message transmission apparatus 130 may further include: an adding unit 1304 .
  • the adding unit 1304 is configured to execute S504 in FIG. 5 or FIG. 9 .
  • S504 in FIG. 5 or FIG. 9 .
  • the second network device 150 provided in this embodiment of the present application is used to implement the functions of the second network device in the foregoing embodiments.
  • the second network device 150 may include at least one processing module 1501 for implementing the functions of the second network device in this embodiment of the present application. For details, refer to the detailed description in the method example, which will not be repeated here.
  • the second network device 150 may also include at least one storage module 1502 for storing program instructions and/or data.
  • the storage module 1502 and the processing module 1501 are coupled.
  • the coupling in the embodiments of the present application is an indirect coupling or communication connection between devices, units or modules, which may be in electrical, mechanical or other forms, and is used for information exchange between devices, units or modules.
  • the processing module 1501 may cooperate with the storage module 1502 .
  • the processing module 1501 may execute program instructions stored in the storage module 1502 . At least one of the at least one storage module may be included in the processing module.
  • the second network device 150 may further include a communication module 1503 for communicating with other devices through a transmission medium, so as to determine that the second network device 150 can communicate with other devices.
  • the communication module 1503 is used for the device to communicate with other devices.
  • the processing module 1501 uses the communication module 1503 to perform S503 and S505 in the process of FIG. 5 or FIG. 9 .
  • the processing module 1501 is a processor
  • the storage module 1502 is a memory
  • the communication module 1503 is a transceiver
  • the second network device 150 involved in FIG. 15 in the embodiment of the present application may be the network device 40 shown in FIG. 4 .
  • the message transmission apparatus 130 or the second network device 150 provided in the embodiments of the present application may be used to implement the functions of the second network device in the above-mentioned embodiments of the present application.
  • the specific technical details are not disclosed, please refer to each embodiment of the present application.
  • the message transmission system may include a first device for message transmission and a second device for message transmission, and the first device for message transmission may implement the above implementation.
  • the second device for transmitting the message may implement the function of the second network device.
  • the first device for packet transmission may be the first network device described in the embodiment of the application
  • the second device for packet transmission may be the second network device described in the embodiment of the application.
  • chip system includes a processor, and may further include a memory, for implementing the function of the first network device in the embodiment shown in FIG. 5 or FIG. 9 .
  • the chip system can be composed of chips, and can also include chips and other discrete devices.
  • chip system includes a processor and may further include a memory, for implementing the function of the second network device in the embodiment shown in FIG. 5 or FIG. 9 .
  • the chip system can be composed of chips, and can also include chips and other discrete devices.
  • FIG. 5 or FIG. 9 above. the steps in the example.
  • inventions of the present application further provide a computer program product, the computer product includes a computer program, when the computer program product runs on a computer, the computer causes the computer to execute each step in the embodiment shown in FIG. 5 or FIG. 9 .
  • the disclosed apparatus and method may be implemented in other manners.
  • the device embodiments described above are only illustrative.
  • the division of the modules or units is only a logical function division. In actual implementation, there may be other division methods.
  • multiple units or components may be Incorporation may either be integrated into another device, or some features may be omitted, or not implemented.
  • the shown or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, indirect coupling or communication connection of devices or units, and may be in electrical, mechanical or other forms.
  • the units described as separate components may or may not be physically separated, and components shown as units may be one physical unit or multiple physical units, that is, they may be located in one place, or may be distributed to multiple different places . Some or all of the units may be selected according to actual needs to achieve the purpose of the solution in this embodiment.
  • each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically alone, or two or more units may be integrated into one unit.
  • the above-mentioned integrated units may be implemented in the form of hardware, or may be implemented in the form of software functional units.
  • the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it may be stored in a readable storage medium.
  • the technical solutions of the embodiments of the present application can be embodied in the form of software products in essence, or the parts that contribute to the prior art, or all or part of the technical solutions, which are stored in a storage medium , including several instructions to make a device (which may be a single-chip microcomputer, a chip, etc.) or a processor (processor) to execute all or part of the steps of the methods described in the various embodiments of the present application.
  • the aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), magnetic disk or optical disk and other media that can store program codes .

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Hardware Design (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

本申请实施例公开了一种报文传输方法、装置及系统,涉及计算机领域,提高了探测报文的发起端设备接收到探测报文的响应报文的概率,在该探测报文用于检测隧道状态时,提高了隧道检测的准确度。具体方案为:第一网络设备向第二网络设备发送探测报文,探测报文包括第一网络设备的标识,第一网络设备的标识用于指示第二网络设备在探测报文的响应报文的目的地址中添加第一网络设备的标识;从第二网络设备接收响应报文,响应报文的目的地址为第一网络设备的标识;或者,从第三网络设备接收更新后的响应报文,更新后的响应报文的目的地址为第一网络设备的标识,第三网络设备和第一网络设备均与同一用户侧网络设备连接。

Description

一种报文传输方法、装置及系统
本申请要求于2020年08月28日提交国家知识产权局、申请号为202010890127.0、发明名称为“一种报文传输方法、装置及系统”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请实施例涉及计算机领域,尤其涉及一种报文传输方法、装置及系统。
背景技术
在以太虚拟私有局域网(ethernet virtual private network,EVPN)虚拟私有无线服务(virtual private wire service,VPWS)系统中,如果EVPN VPWS隧道异常,例如,标签交换路径(Label Switched Path,LSP)转发数据失败,EVPN VPWS控制平面无法检测到这种错误,导致网络维护困难。
EVPN VPWS因特网包探索器(packet internet groper,Ping)提供了一种EVPN VPWS场景的EVPN VPWS隧道检测方案,用于检测发起端设备到接收端设备的EVPN隧道是否正常。该过程包括:发起端设备生成探测(echo request)报文,探测报文中携带了待检测隧道的标识(identifiers,ID)信息,将探测报文通过EVPN VPWS隧道发送给接收端设备。接收端设备接收探测报文,根据探测报文中的待检测隧道的标识信息进行检测校验,判断待检测隧道正常或者异常;并将本次的检测校验结果封装在响应(echo reply)报文中,然后将响应报文通过EVPN VPWS隧道发送给发起端设备。发起端设备接收响应报文,获取响应报文中的本次的检测校验结果。发起端设备多次发送探测报文并接收响应报文,根据多次响应报文中的检测校验结果判断发起端设备到接收端设备的EVPN VPWS隧道是否正常。
在EVPN VPWS双归双活场景的报文传输系统中,如图1所示,用户边缘设备(customer edge device,CE)1双归接入运营商边缘设备(provider edge device,PE)1和PE2,CE2单归接入PE3,PE1和PE2设置为双活模式;PE1可以通过EVPN VPWS隧道与PE3通信,PE2也可以通过EVPN VPWS隧道与PE3通信;PE1和PE2侧的EVPN VPWS隧道标识(本地EVPN VPWS ID)为100,PE3侧的EVPN VPWS隧道标识(远端EVPN VPWS ID)为200。在此场景中,若PE1发起隧道检测,用于检测隧道标识为100至200的EVPN VPWS隧道是否正常。PE1将探测报文通过EVPN VPWS隧道发送给PE3,PE3接收探测报文,根据探测报文获取检测结果,然后将包括检测结果的响应报文通过EVPN VPWS隧道发送至隧道出口设备。由于该场景中的PE1和PE2的隧道标识相同,所以PE1可能正常接收到响应报文,也可能无法接收到响应报文,即响应报文由PE2接收。
上述隧道检测方案中,无法保证探测报文的发起端设备PE1可以接收到发出的探测报文的响应报文,若PE1无法正常接收到响应报文,则判定100至200的EVPN VPWS隧道异常,这种情况下100至200的隧道可能正常,只是由于响应报文被PE2接收,无法到达PE1,导致PE1检测错误,使隧道检测的准确度较低。
发明内容
本申请提供一种报文传输方法、装置及系统,提高了探测报文的发起端设备接收到发出的探测报文的响应报文的概率,在该探测报文用于检测隧道状态时,提高了隧道检测的准确度。
本申请采用如下技术方案:
第一方面,本申请提供一种报文传输方法,该方法由第一网络设备执行,该方法可以包括:向第二网络设备发送探测报文,探测报文可以包括第一网络设备的标识,第一网络设备的标识用于指示第二网络设备在探测报文的响应报文的目的地址中添加第一网络设备的标识;从第二网络设备接收响应报文,响应报文的目的地址为第一网络设备的标识;或者,从第三网络设备接收更新后的响应报文,更新后的响应报文的目的地址为第一网络设备的标识,第三网络设备和第一网络设备均与同一用户侧网络设备连接。
本申请实施例提供的报文传输方法,通过在探测报文中加入发起端设备的标识,探测报文的接收端设备将该标识添加为探测报文的响应报文的目的地址,这样,即使非发起端设备接收到响应报文,可以按照响应报文目的地址,将响应报文转发给探测报文的发起端设备,而保证探测报文的发起端设备可以接收到发出的探测报文的响应报文。在探测报文用于检测隧道状态时,避免了探测报文的发起端设备由于无法接收到探测报文的响应报文而引起的检测错误,提高了隧道检测的准确度。此外,由于标识的添加位置为响应报文的目的地址字段,非发起端设备在接收到响应报文时能够直接根据传统的路由转发机制,将该响应报文转发至探测报文的发起端设备,而无需过多改动非发起端设备的报文转发行为,有利于提高网络的运行兼容性和友好性。
结合第一方面,在一种可能的实现方式中,第一网络设备的标识可以包括:第一网络设备的网际协议(internet protocol,IP)地址;或者,第一网络设备的媒体访问控制(media access control,MAC)地址。在该可能的实现方式中,可以通过IP地址或者MAC地址作为第一网络设备的标识,实现的灵活性较高。
结合第一方面或上述一种可能的实现方式中,在另一种可能的实现方式中,第一网络设备的IP地址可以包括:第一网络设备的接口IP地址;或者,第一网络设备的环回loopback接口IP地址;或者,第一网络设备的IP地址形式的段标识符(segment identifiers,SID)。在该可能的实现方式中,可以根据实际需求配置不同形式的IP地址,以适应不同的应用场景。
结合第一方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,在向第二网络设备发送探测报文之前,该方法还可以包括:生成探测报文;其中,第一网络设备的标识可以以类型长度值TLV格式封装于探测报文的数据部分;或者,第一网络设备的标识可以封装于探测报文IP头的源IP地址中。在该可能的实现方式中,可以根据实际需求将第一网络设备的标识保存于探测报文的不同位置,应用范围广泛。
结合第一方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,探测报文还可以包括添加指示,第一网络设备的标识可以用于指示第二网络设备在探测报文的响应报文的目的地址中添加第一网络设备的标识,可以包括:第一网络设备的标识和添加指示可以用于共同指示第二网络设备在响应报文的目的地址中添加第一网 络设备的标识。在该可能的实现方式中,可以通过添加指示的方式使第二网络设备在响应报文的目的地址中添加第一网络设备的标识,实现简单。
结合第一方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,该方法还可以包括:接收其他响应报文;根据其他响应报文的目的地址为第一网络设备的标识之外的地址,将其他响应报文转发给其他响应报文的目的地址指示的网络设备,其他响应报文的目的地址指示的网络设备与用户侧网络设备连接。该其他响应报文的目的地址指示的网络设备例如可以是在多归多活场景下的该第三网络设备,或者与该第一网络设备存在多归关系的其他一个或多个网络设备。
结合第一方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,第一网络设备、第二网络设备和第三网络设备可以为运营商边缘设备PE,用户侧网络设备可以为用户边缘设备CE。
结合第一方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,探测报文可以为以太虚拟私有局域网EVPN虚拟私有无线服务VPWS场景的探测报文,响应报文可以为EVPN VPWS场景的响应报文。
第二方面,本申请提供另一种报文传输方法,该方法可以由第二网络设备执行,该方法可以包括:接收第一网络设备发送的探测报文,探测报文包括第一网络设备的标识;生成探测报文的响应报文,响应报文的目的地址包括第一网络设备的标识;向第一网络设备或者第三网络设备发送响应报文,第三网络设备和第一网络设备均与同一用户侧网络设备连接。
本申请实施例提供的报文传输方法,通过在探测报文中加入发起端设备的标识,探测报文的接收端设备将该标识添加为探测报文的响应报文的目的地址,这样,即使非发起端设备接收到响应报文,可以按照响应报文目的地址,将响应报文转发给探测报文的发起端设备,而保证探测报文的发起端设备可以接收到发出的探测报文的响应报文。在探测报文用于检测隧道状态时,避免了探测报文的发起端设备由于无法接收到探测报文的响应报文而引起的检测错误,提高了隧道检测的准确度。此外,通过将标识添加到响应报文的目的地址字段,也可以保证在非发起端设备接收到响应报文时,能够直接根据传统的路由转发机制将该响应报文转发至探测报文的发起端设备,有利于提高网络的运行兼容性和友好性。
结合第二方面,在一种可能的实现方式中,第一网络设备的标识可以包括:第一网络设备的网际协议IP地址;或者,第一网络设备的媒体访问控制MAC地址。在该可能的实现方式中,可以通过IP地址或者MAC地址作为第一网络设备的标识,实现的灵活性较高。
结合第二方面或上述一种可能的实现方式中,在另一种可能的实现方式中,第一网络设备的IP地址可以包括:第一网络设备的接口IP地址;或者,第一网络设备的环回loopback接口IP地址;或者,第一网络设备的IP地址形式的段标识符SID。在该可能的实现方式中,可以根据实际需求配置不同形式的IP地址,以适应不同的应用场景。
结合第二方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,第一网络设备的标识可以以类型长度值TLV格式封装于探测报文的数据部分;或者,第 一网络设备的标识可以封装于探测报文IP头的源IP地址中。在该可能的实现方式中,在该可能的实现方式中,可以根据实际需求将第一网络设备的标识保存于探测报文的不同位置,应用范围广泛。
结合第二方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,探测报文还可以包括添加指示,该方法还可以包括:根据添加指示及第一网络设备的标识,在响应报文的目的地址中添加第一网络设备的标识。在该可能的实现方式中,在该可能的实现方式中,可以通过添加指示的方式使第二网络设备在响应报文的目的地址中添加第一网络设备的标识,实现简单。
结合第二方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,生成探测报文的响应报文,可以包括:在响应报文的目的IP地址中添加第一网络设备的IP地址;或者,在响应报文的目的MAC地址添加第一网络设备的MAC地址。
结合第二方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,向第一网络设备或者第三网络设备发送响应报文,可以包括:根据负载分担算法,向第一网络设备或者第三网络设备发送响应报文。
结合第二方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,第一网络设备、第二网络设备和第三网络设备可以为运营商边缘设备PE,用户侧网络设备可以为用户边缘设备CE。
结合第二方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,探测报文可以为以太虚拟私有局域网EVPN虚拟私有无线服务VPWS场景的探测报文,响应报文可以为EVPN VPWS场景的响应报文。
第三方面,本申请还提供了一种报文传输装置,该装置可以为上述第一方面或第一方面任一种可能的实现方式中的第一网络设备,或者该装置可以部署于该第一网络设备。该装置可以包括第一发送单元、第一接收单元。其中:
第一发送单元,用于向第二网络设备发送探测报文,探测报文包括第一网络设备的标识,第一网络设备的标识用于指示第二网络设备在探测报文的响应报文的目的地址中添加第一网络设备的标识。
第一接收单元,用于从第二网络设备接收响应报文,响应报文的目的地址为第一网络设备的标识;或者,从第三网络设备接收更新后的响应报文,更新后的响应报文的目的地址为第一网络设备的标识,第三网络设备和第一网络设备均与同一用户侧网络设备连接。
结合第三方面,在一种可能的实现方式中,所述第一网络设备的标识包括:
所述第一网络设备的网际协议IP地址;或者,所述第一网络设备的媒体访问控制MAC地址。
结合第三方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,所述第一网络设备的IP地址包括:所述第一网络设备的接口IP地址;或者,所述第一网络设备的环回loopback接口IP地址;或者,所述第一网络设备的IP地址形式的段标识符SID。
结合第三方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,在所述第一发送单元向第二网络设备发送探测报文之前,所述装置还包括:
处理单元,用于生成所述探测报文;其中,所述第一网络设备的标识以类型长度值TLV格式封装于所述探测报文的数据部分;或者,所述第一网络设备的标识封装于所述探测报文IP头的源IP地址中。
结合第三方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,所述探测报文还包括添加指示,所述第一网络设备的标识用于指示所述第二网络设备在所述探测报文的响应报文的目的地址中添加所述第一网络设备的标识,包括:所述第一网络设备的标识和所述添加指示用于共同指示所述第二网络设备在所述响应报文的目的地址中添加所述第一网络设备的标识。
结合第三方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,所述装置还包括:第二接收单元,用于接收其他响应报文;第二发送单元,用于根据所述其他响应报文的目的地址为所述第一网络设备的标识之外的地址,将所述其他响应报文转发给所述其他响应报文的目的地址指示的网络设备,所述其他响应报文的目的地址指示的网络设备与所述用户侧网络设备连接。
结合第三方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,所述第一网络设备、所述第二网络设备和所述第三网络设备为运营商边缘设备PE,所述用户侧网络设备为用户边缘设备CE。
结合第三方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,所述探测报文为以太虚拟私有局域网EVPN虚拟私有无线服务VPWS场景的探测报文,所述响应报文为所述EVPN VPWS场景的响应报文。
需要说明的是,第三方面提供的报文传输装置,用于执行上述第一方面提供的报文传输方法,具体实现可以参考上述第一方面的具体实现。
第四方面,本申请提供了一种报文传输装置,该装置可以为上述第二方面或第二方面任一种可能的实现方式中的第二网络设备,或者该装置可以部署于第二网络设备。该装置可以包括:接收单元、处理单元和发送单元。其中:
接收单元,用于接收第一网络设备发送的探测报文,探测报文包括第一网络设备的标识。
处理单元,用于生成探测报文的响应报文,响应报文的目的地址包括第一网络设备的标识。
发送单元,用于向第一网络设备或者第三网络设备发送响应报文,第三网络设备和第一网络设备均与同一用户侧网络设备连接。
结合第四方面,在一种可能的实现方式中,所述第一网络设备的标识包括:所述第一网络设备的网际协议IP地址;或者,所述第一网络设备的媒体访问控制MAC地址。
结合第四方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,所述第一网络设备的IP地址包括:所述第一网络设备的接口IP地址;或者,所述第一网络设备的环回loopback接口IP地址;或者,所述第一网络设备的IP地址形式的段标识符SID。
结合第四方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,所述第一网络设备的标识以类型长度值TLV格式封装于所述探测报文的数据部分;或 者,所述第一网络设备的标识封装于所述探测报文IP头的源IP地址中。
结合第四方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,所述探测报文还包括添加指示,所述装置还包括:添加单元,用于根据所述添加指示及所述第一网络设备的标识,在所述响应报文的目的地址中添加所述第一网络设备的标识。
结合第四方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,所述处理单元具体用于:在所述响应报文的目的IP地址中添加所述第一网络设备的IP地址;或者,在所述响应报文的目的MAC地址添加所述第一网络设备的MAC地址。
结合第四方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,所述发送单元具体用于:根据负载分担算法,向所述第一网络设备或者所述第三网络设备发送所述响应报文。
结合第四方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,所述第一网络设备、所述第二网络设备和所述第三网络设备为运营商边缘设备PE,所述用户侧网络设备为用户边缘设备CE。
结合第四方面或上述任一种可能的实现方式中,在另一种可能的实现方式中,所述探测报文为以太虚拟私有局域网EVPN虚拟私有无线服务VPWS场景的探测报文,所述响应报文为所述EVPN VPWS场景的响应报文。
需要说明的是,第四方面提供的报文传输装置,用于执行上述第二方面提供的报文传输方法,具体实现可以参考上述第二方面的具体实现。
第五方面,本申请实施例提供一种第一网络设备,该设备可以包括处理器,用于实现上述第一方面描述的报文传输方法。该设备还可以包括存储器,存储器与处理器耦合,处理器执行存储器中存储的指令时,可以实现上述第一方面或第一方面任一种可能的实现方式描述的报文传输方法。该设备还可以包括通信接口,通信接口用于该装置与其它设备进行通信,示例性的,通信接口可以是收发器、电路、总线、模块或其它类型的通信接口。在一种可能的实现中,该设备可以包括:
存储器,用于存储指令;
处理器,用于向第二网络设备发送探测报文,探测报文可以包括第一网络设备的标识,第一网络设备的标识用于指示第二网络设备在探测报文的响应报文的目的地址中添加第一网络设备的标识;从第二网络设备接收响应报文,响应报文的目的地址为第一网络设备的标识;或者,从第三网络设备接收更新后的响应报文,更新后的响应报文的目的地址为第一网络设备的标识,第三网络设备和第一网络设备均与同一用户侧网络设备连接。
需要说明的是,本申请中存储器中的指令可以预先存储也可以使用该装置时从互联网下载后存储,本申请对于存储器中指令的来源不进行具体限定。本申请实施例中的耦合是装置、单元或模块之间的间接耦合或连接,其可以是电性,机械或其它的形式,用于装置、单元或模块之间的信息交互。
第六方面,本申请实施例提供一种第二网络设备,该设备可以包括处理器,用于实现上述第二方面或第二方面任一种可能的实现方式描述的报文传输方法。该设备还可以包括存储器,存储器与处理器耦合,处理器执行存储器中存储的指令时,可以实 现上述第二方面描述的报文传输方法。该设备还可以包括通信接口,通信接口用于该装置与其它设备进行通信,示例性的,通信接口可以是收发器、电路、总线、模块或其它类型的通信接口。在一种可能的实现中,该设备包括:
存储器,用于存储指令;
处理器,用于接收第一网络设备发送的探测报文,探测报文包括第一网络设备的标识;生成探测报文的响应报文,响应报文的目的地址包括第一网络设备的标识;向第一网络设备或者第三网络设备发送响应报文,第三网络设备和第一网络设备均与同一用户侧网络设备连接。
需要说明的是,本申请中存储器中的指令可以预先存储也可以使用该装置时从互联网下载后存储,本申请对于存储器中指令的来源不进行具体限定。本申请实施例中的耦合是装置、单元或模块之间的间接耦合或连接,其可以是电性,机械或其它的形式,用于装置、单元或模块之间的信息交互。
第七方面,提供了一种报文传输系统,该通信系统中可以包括报文传输的第一装置,以及报文传输的第二装置,该报文传输的第一装置可以是第三方面或第三方面任一种可能的实现方式中的装置,该报文传输的第二装置可以是第四方面或第四方面任一种可能的实现方式中的装置。
第八方面,提供了一种报文传输系统,该通信系统中可以包括第一网络设备,以及第二网络设备,该第一网络设备可以是第五方面或第五方面任一种可能的实现方式中的装置,该第二网络设备可以是第六方面或第六方面任一种可能的实现方式中的装置。
第九方面,本申请实施例中还提供一种计算机可读存储介质,包括指令,当其在计算机上运行时,使得计算机执行上述任一方面或任意一种可能的实现方式所述的报文传输方法。
第十方面,本申请实施例中还提供一种计算机程序产品,当其在计算机上运行时,使得计算机执行上述任一方面或任意一种可能的实现方式所述的报文传输方法。
第十一方面,本申请实施例提供了一种芯片系统,该芯片系统包括处理器,还可以包括存储器,用于实现上述方法中第一网络设备执行的功能。该芯片系统可以由芯片构成,也可以包含芯片和其他分立器件。
第十二方面,本申请实施例提供了一种芯片系统,该芯片系统包括处理器,还可以包括存储器,用于实现上述方法中第二网络设备执行的功能。该芯片系统可以由芯片构成,也可以包含芯片和其他分立器件。
上述第三方面至第十二方面提供的方案,用于实现上述第一方面至第二方面提供的报文传输方法,因此可以与第一方面至第二方面达到相同的有益效果,此处不再进行赘述。
需要说明的是,上述各个方面中的任意一个方面的各种可能的实现方式,在方案不矛盾的前提下,均可以进行组合。
附图说明
图1为本申请实施例提供的一种EVPN VPWS双归双活场景的报文传输系统的结构示意图;
图2为本申请实施例提供的一种报文传输系统的结构示意图;
图3为本申请实施例提供的另一种EVPN VPWS双归双活场景的报文传输系统的结构示意图;
图4为本申请实施例提供的一种网络设备的结构示意图;
图5为本申请实施例提供的一种报文传输方法的流程示意图;
图6为本申请实施例提供的一种探测报文结构示意图;
图7为本申请实施例提供的一种响应报文结构示意图;
图8为本申请实施例提供的另一种响应报文结构示意图;
图9为本申请实施例提供的另一种报文传输方法的流程示意图;
图10为本申请实施例提供的一种报文传输装置结构示意图;
图11为本申请实施例提供的另一种报文传输装置结构示意图;
图12为本申请实施例提供的一种第一网络设备结构示意图;
图13为本申请实施例提供的另一种报文传输装置结构示意图;
图14为本申请实施例提供的再一种报文传输装置结构示意图;
图15为本申请实施例提供的一种第二网络设备结构示意图。
具体实施方式
本申请说明书和权利要求书及上述附图中的术语“第一”、“第二”和“第三”等是用于区别不同对象,而不是用于限定特定顺序。
在本申请实施例中,“示例性的”或者“例如”等词用于表示作例子、例证或说明。本申请实施例中被描述为“示例性的”或者“例如”的任何实施例或设计方案不应被解释为比其它实施例或设计方案更优选或更具优势。确切而言,使用“示例性的”或者“例如”等词旨在以具体方式呈现相关概念,便于理解。
在本申请的描述中,除非另有说明,“/”表示前后关联的对象是一种“或”的关系,例如,A/B可以表示A或B;本申请中的“和/或”仅仅是一种描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况,其中A,B可以是单数或者复数。并且,在本申请的描述中,除非另有说明,“多个”是指两个或多于两个。“以下至少一项(个)”或其类似表达,是指的这些项中的任意组合,包括单项(个)或复数项(个)的任意组合。例如,a,b,或c中的至少一项(个),可以表示:a,b,c,a-b,a-c,b-c,或a-b-c,其中a,b,c可以是单个,也可以是多个。
在本申请实施例中,至少一个还可以描述为一个或多个,多个可以是两个、三个、四个或者更多个,本申请不做限制。
如前所述,现有的隧道检测方案无法保证探测报文的发起端设备可以接收到发出的探测报文的响应报文,使隧道检测的准确度较低。基于此,本申请实施例提供一种报文传输方法,通过在探测报文中加入发起端设备的标识,探测报文的接收端设备将该标识添加为探测报文的响应报文的目的地址,这样,即使非发起端设备接收到响应报文,可以按照响应报文目的地址,将响应报文转发给探测报文的发起端设备,而保证探测报文的发起端设备可以接收到发出的探测报文的响应报文。在探测报文用于检测隧道状态时,避免了探测报文的发起端设备由于无法接收到探测报文的响应报文而 引起的检测错误,提高了隧道检测的准确度。此外,由于发起端设备的标识添加在响应报文的目的地址部分,可以使得非发起端设备在接收到响应报文时,直接根据传统的路由转发机制将该响应报文转发至发起端设备,由此保证了网络运行的兼容性和友好性。
下面将结合附图对本申请实施例的实施方式进行详细描述。
本申请实施例提供的方案可以应用于图2所示的报文传输系统20中。如图2所示,该报文传输系统20可以包括多个用户侧网络设备201、多个运营商侧网络设备202。一个用户侧网络设备201可以与一个或多个运营商侧网络设备202连接。其中,用户侧网络设备201与运营商侧网络设备202可以通过IP路由通信;运营商侧网络设备202与运营商侧网络设备202间可以通过隧道通信,或者IP路由通信,或者其他方式通信。
用户侧网络设备201可以为CE或者其他。示例性的,用户侧网络设备201可以为路由器或交换机。用户侧网络设备201可以通过一个或多个运营商侧网络设备202,与通过其他运营商侧网络设备202接入的另一个用户侧网络设备201通信。图2所示的用户侧网络设备201与运营商侧网络设备202直接连接的方式仅作为一种可能的示例,用户侧网络设备201也可以通过一个或多个其他网络设备与运营商侧网络设备202连接。
运营商侧网络设备202可以为PE或者其他。示例性的,运营商侧网络设备202可以为路由器或交换机,或其他产品形态。
一种可能的实现方式中,运营商侧网络设备202可以按照本申请提供的方案发送探测报文,和/或,接收响应报文;或者,运营商侧网络设备202可以按照本申请提供的方案接收探测报文,以及发送接收的探测报文的响应报文,其具体处理过程详见下述方法实施例描述。
隧道可以为迭代多协议标签交换(multi-protocol label switching,MPLS)、分段路由(segment routing,SR)、SRv6等隧道类型。
需要说明的是,报文传输系统20可以用于不同场景的报文传输,本申请实施例对此不予唯一限定。
例如,报文传输系统20可以应用于EVPN VPWS多归多活场景的报文传输。其中,在EVPN VPWS多归场景中,存在一个用户侧网络设备201与多个运营商侧网络设备202连接;且运营商侧网络设备202设置为多活模式。
示例性的,图3示意了报文传输系统20应用于EVPN VPWS双归双活场景下的结构。如图3所示,该报文传输系统20可以包括第一PE301、第二PE302、第三PE303、第一CE304、第二CE305。
其中,第一CE304双归接入第一PE301和第三PE303;第二CE305单归接入第二PE302;第一PE301与第二PE302通过EVPN VPWS隧道通信,第二PE302与第三PE303通过EVPN VPWS隧道通信,第一PE301与第三PE303通过IP路由或者隧道或者其他方式通信。
同样的,其他PE间可以直接通信,或者,其他PE间也可以通过其他节点通信。
可以理解的,第二CE305单归接入第二PE302,在实际应用中,第二CE305也可 以双归接入两个PE;还可以有更多的CE接入第三PE303。本申请实施例对于场景中包括的CE、PE数量,以及CE与PE间、PE与PE间的连接方式不作具体限定。
示例性的,第一PE301可以用于发送探测报文,以及接收第二PE302或者第三PE303发送的探测报文的响应报文;第二PE302可以用于接收第一PE301发送的探测报文,并将探测报文的响应报文发送给第一PE301或者第三PE303;第三PE303可以用于接收第二PE302发送的探测报文的响应报文,并将探测报文的响应报文转发给第一PE301。
下面结合附图,对本申请的实施例提供的方案进行具体阐述。
一方面,本申请实施例提供一种网络设备40,用于执行本申请提供的报文传输方法。该网络设备40可以为图2所示的运营商侧网络设备202。
图4示意了本申请实施例提供的网络设备40的结构图。如图4所示,网络设备40可以包括处理器401、存储器402、收发器403。
下面结合图4对网络设备40的各个构成部件进行具体的介绍:
存储器402可以是易失性存储器(volatile memory),例如随机存取存储器(random-access memory,RAM);或者非易失性存储器(non-volatile memory),例如只读存储器(read-only memory,ROM),快闪存储器(flash memory),硬盘(hard disk drive,HDD)或固态硬盘(solid-state drive,SSD);或者上述种类的存储器的组合,用于存储可实现本申请方法的应用程序代码、配置文件、数据信息或者其他内容。
收发器403用于网络设备40与其他设备的信息交互。例如,收发器403可以用于与其他网络类设备交互信息。
处理器401可以是网络设备40的控制中心。例如,处理器401可以是一个中央处理器(central processing unit,CPU),也可以是特定集成电路(application specific integrated circuit,ASIC),或者是被配置成实施本申请实施例的一个或多个集成电路,例如:一个或多个微处理器(digital singnal processor,DSP),或,一个或者多个现场可编程门阵列(field programmable gate array,FPGA)。
一种可能的实现方式中,网络设备40为探测报文的发起端设备,处理器401通过运行或执行存储在存储器402内的软件程序和/或模块,使得网络设备40作为第一网络设备执行如下功能:
向第二网络设备发送探测报文,探测报文包括第一网络设备的标识,第一网络设备的标识用于指示第二网络设备在探测报文的响应报文的目的地址中添加第一网络设备的标识;从第二网络设备接收响应报文,响应报文的目的地址为第一网络设备的标识;或者,从第三网络设备接收更新后的响应报文,更新后的响应报文的目的地址为第一网络设备的标识,第三网络设备和第一网络设备均与同一用户侧网络设备连接。
该实现方式中,网络设备40例如可以是图3示出的第一PE301。
另一种可能的实现方式中,网络设备40为探测报文的接收端设备,处理器401通过运行或执行存储在存储器402内的软件程序和/或模块,使得网络设备40作为第二网络设备执行如下功能:
接收第一网络设备发送的探测报文,探测报文包括第一网络设备的标识;生成探测报文的响应报文,响应报文的目的地址包括第一网络设备的标识;向第一网络设备 或者第三网络设备发送响应报文,第三网络设备和第一网络设备均与同一用户侧网络设备连接。
该实现方式中,网络设备40例如可以是图3示出的第二PE302。
上述两种可能的实现方式中,处理器401可以通过运行或执行存储在存储器402内的软件程序和/或模块,执行所描述的全部功能;也可以是可以通过运行或执行存储在存储器402内的软件程序和/或模块,配合网络设备40中的其他部件或模块共同执行所描述的全部功能,例如,处理器401执行生成探测报文或响应报文的功能,并通过收发器403收发相应的探测报文或响应报文。
另一方面,本申请实施例提供一种报文传输方法,可以应用于第一网络设备与第二网络设备的交互过程。其中,第一网络设备、第二网络设备可以为图2所示的报文传输系统中的运营商侧网络设备。第一网络设备、第三网络设备均与第一用户侧网络设备连接,第二网络设备与第二用户侧网络设备连接。示例性的,第一网络设备可以为图3中示意的第一PE301,第二网络设备可以为图3中示意的第二PE302,第三网络设备可以为图3中示意的第三PE303。
需要说明的是,本申请实施例提供的报文传输方法可以用于运营商侧网络设备间的隧道检测过程,或者其他通过发出探测报文接收响应报文的网络处理过程,本申请对此不予具体限定。其中,本申请实施例中以探测报文用于隧道检测为例,对本申请提供的报文传输方法进行详细描述,对于探测报文做其他用途的场景,不再一一赘述。
如图5所示,本申请实施例提供的报文传输方法可以包括:
S501、第一网络设备生成探测报文。
具体的,第一网络设备在需要进行发出探测报文以接收响应报文的进行网络处理的时机时,执行S501的操作生成探测报文。该时机可以为用户指示或者周期性时刻或者其他,该网络处理可以为隧道检测或者其他。
其中,探测报文为通过发出探测报文接收响应报文的网络处理过程中,发起端设备发出的报文。示例性的,探测报文可以用于检测第一网络设备连接的隧道是否正常。
其中,可以根据实际情况配置探测报文的应用场景及其功能,本申请实施例对于探测报文的应用场景及其具体功能不予唯一限定。
一种可能的实现方式中,探测报文可以为EVPN VPWS场景中用于检测第一网络设备连接的隧道是否正常的报文。
其中,探测报文可以包括第一网络设备的标识。探测报文中包括的第一网络设备的标识可以用于指示接收该探测报文的网络设备(例如第二网络设备)在探测报文的响应报文的目的地址中添加该第一网络设备的标识,以保证第一网络设备可以接收到发出的探测报文对应的响应报文。在EVPN VPWS场景中,第一网络设备可以是隧道一侧的端设备,而接收该探测报文的设备例如可以是该隧道另一侧的端设备。该隧道可以是一段隧道,也可以是分段隧道。
具体的,第一网络的标识可以用于唯一指示该第一网络设备,对于第一网络设备的标识的类型,本申请不予限定。
一种可能的实现方式中,第一网络设备的标识可以包括第一网络设备的IP地址。
示例性的,第一网络设备的IP地址可以为第一网络设备的接口IP地址;或者, 第一网络设备的loopback接口IP地址,或者,第一网络设备的IP地址形式的SID。
其中,IP地址可以为IPv4地址,或者IPv6地址,或者其他。
另一种可能的实现方式中,第一网络设备的标识可以包括:第一网络设备的MAC地址。
可选的,第一网络设备的标识在探测报文中的封装位置可以包括但不限于下述实现A或实现B。
实现A、将第一网络设备的标识以TLV格式封装于探测报文的数据部分。
示例性的,图6示意了一种探测报文的结构。如图6所示,该探测报文结构包括数据部分和头部。头部可以包括:用户数据报协议(user datagram protocol,UDP)头、IP头、标签栈以及链路头。如图6所示,UDP头可以包括源端口、目的端口;IP头可以包括源IP地址、目的IP地址以及保留位;标签栈可以包括公网路径标签以及隧道标签。
例如,第一网络设备的标识可以以TLV格式封装于如图6所示结构的探测报文的数据部分。其中,该TLV包括TLV类型、第一网络设备的标识的长度以及第一网络设备的标识。
需要说明的是,可以根据实际需求配置TLV的结构,本申请实施例对此不予具体限定。
例如,当第一网络设备的标识为IPv4地址时,可以将该TLV类型(tag,T)配置为26,可以将该TLV的长度(length,L)配置为第一网络设备的IPv4地址的长度,可以将该TLV的值(value,V)的配置为第一网络设备的IPv4地址。其中,类型T占用1个字节,长度L占用1个字节,值V占用4个字节。
再例如,当第一网络设备的标识为IPv6地址时,可以将该TLV的T配置为26,可以将该TLV的L配置为第一网络设备的IPv6地址的长度,可以将该TLV的V的配置为第一网络设备的IPv6地址。其中,T占用1个字节,L占用1个字节,V占用16个字节。
再例如,当第一网络设备的标识为MAC地址时,可以将该TLV的T配置为26,可以将该TLV的L配置为第一网络设备的MAC地址的长度,可以将该TLV的V的配置为第一网络设备的MAC地址。其中,T占用1个字节,L占用1个字节,V占用6个字节。
实现B、将第一网络设备的标识封装于探测报文IP头的源IP地址中。
具体的,在实现B中,第一网络设备的标识为第一网络设备的IP地址。
示例性的,在实现B中,可以将第一网络设备的IP地址封装于如图6所示结构的探测报文IP头的源IP地址中。
可以理解的,可以根据实际需求将第一网络设备的标识封装于探测报文的其他位置,上述实现A或实现B并不构成唯一限定。
可选的,探测报文还可以包括第一网络设备的标识的类型指示。第一网络设备的标识类型指示,用于指示携带于探测报文中的第一网络设备的标识的类型。例如,第一网络设备的标识类型可以包括但不限于下述任一项:IPv4,IPv6,MAC。在某些可能的应用中,第二网络设备可以根据该标识类型的指示,确定与该类型匹配的网络应 用环境。
可选的,探测报文还可以包括添加指示,第一网络设备的标识和添加指示用于共同指示第二网络设备在探测报文的响应报文的目的地址中添加第一网络设备的标识。
需要说明的是,用户可以根据实际情况配置添加指示的形式及其在探测报文中的位置,本申请对此不予唯一限定。
示例性的,添加指示的形式可以为一个或多个比特位的值。
一种可能的实现方式中,添加指示可以为探测报文的头部的一个或多个保留位。
例如,添加指示可以为如图6所示结构的探测报文的IP头中的某一个保留位,或者某多个保留位。
示例性的,添加指示可以为探测报文IP头中3个保留位,其值为001。
示例的,在探测报文用于检测隧道状态的场景中,S501的实现可以为:第一网络设备获取待检测隧道的标识信息、将待检测隧道的标识信息作为探测报文的数据部分,然后通过上述实现A或实现B中的方法添加第一网络设备的标识、或者添加第一网络设备的标识及添加指示,将报文进行UDP头、IP头、标签栈及链路头封装后,生成图6所示结构的探测报文。
其中,第一网络设备可以将探测报文的UDP头中的源端口配置为一个随机的端口号,将UDP头中的目的端口配置为3503;将探测报文的IP头中的源IP地址配置为第一网络设备的IP地址、目的IP地址配置为第二网络设备的IP地址,或者根据RFC8029的规定,将IP头目的IP地址配置为127/8,例如,127.0.0.1;将标签栈中的公网标签配置为第一网络设备检测的隧道的路径标签,隧道标签配置为隧道入口标签和隧道出口标签。
S502、第一网络设备向第二网络设备发送探测报文。
其中,第二网络设备为接收探测报文的网络设备。
一种可能的实现方式中,当探测报文中目的IP地址配置为目的端设备的IP地址时,第二网络设备可以为第一网络设备发送探测报文时的目的端设备。
例如,当探测报文中的目的IP地址填充为第二网络设备的IP地址时,第二网络设备在接收到探测报文时,确定探测报文中的目的IP地址与自身IP地址相同,则认为自身(第二网络设备)为目的端设备。
另一种可能的实现方式中,当探测报文中目的IP地址配置为指示IP地址时,将要检测的隧道标识作为探测报文的目的隧道标识,在其连接的隧道上发出该探测报文,隧道另一端的多个网络设备中任一个网络设备均可能接收到该探测报文,接收到该探测报文的对端网络设备为第二网络设备。
其中,指示IP地址用于指示接收到探测报文的网络设备不再转发该探测报文,并自身处理该探测报文。
一种可能的实现方式中,根据RFC8029的规定,指示IP地址可以为127/8,例如,127.0.0.1。
例如,在隧道检测场景中,第一网络设备接的隧道另一端为多归场景,探测报文中目的IP地址配置为127/8,例如,127.0.0.1;将要检测的隧道标识作为探测报文的目的隧道标识,在其连接的隧道上发出该探测报文,隧道另一端的多个网络设备中任一 个网络设备均可能接收到该探测报文,接收到该探测报文的对端网络设备确定探测报文中目的IP地址配置为127/8,则认为自身(第二网络设备)为接收该探测报文的对端网络设备。
具体的,S502可以实现为:第一网络设备通过其连接的隧道发送S501生成的探测报文。
一种可能的实现方式中,在探测报文为EVPN VPWS场景的探测报文时,第一网络设备可以将S501生成的探测报文通过EVPN VPWS隧道发出。
例如,第一网络设备将S501生成的探测报文通过隧道直接发送至第二网络设备。其中,第一网络设备和第二网络设备为该隧道的两个端设备,或者第一网络设备和第二网络设备之间包括多段隧道,第一网络设备为第一段隧道的端设备,而第二网络设备为最后一段隧道的端设备。
再例如,第一网络设备将S501生成的探测报文通过隧道发送,经一个或多个网络设备的转发后到达第二网络设备。
示例性的,第一网络设备将S501生成的探测报文通过迭代MPLS或者SR公网的EVPN VPWS隧道,之后经网络设备1和网络设备2转发给第二网络设备。
S503、第二网络设备接收第一网络设备发送的探测报文。
具体的,网络设备可以通过接收报文的端口号,来识别报文的用途。例如,可以配置某一端口接收的报文为探测报文,第二网络设备在收到报文时识别接收端口,来确定接收的报文是否为探测报文。
示例性的,假设协议规定3503端口接收用于检测隧道是否正常的探测报文,S503中第二网络设备接收到报文时,识别接收该报文的端口号为3503,就可以确定该报文为用于检测隧道是否正常的探测报文。然后,第二网络设备识别出探测报文的目的IP地址,若该IP地址为自己的IP地址或者目的IP为127/8,则上传本机处理;第二网络设备对该探测报文进行解封装,获取探测报文中的数据信息,以执行S504。若探测报文的目的地址不是自己的地址,第二网络设备可以按照目的IP地址转发该报文,以将该报文转发至能够执行S504的网络设备。
S504、第二网络设备生成探测报文的响应报文。
具体的,S504中第二网络设备根据接收的探测报文的用途,执行对应的处理。例如,当探测报文用于检测隧道是否正常,S504中第二网络设备则检测隧道是否正常,得到检测结果。第二网络设备在S504中将该执行的处理得到的结果作为数据部分,生成响应报文。
一种可能的实现方式中,第二网络设备在探测报文中封装第一网络设备的标识的位置获取第一网络设备的标识,根据第一网络设备的标识的指示,将第一网络设备的标识作为响应报文的目的地址,生成响应报文。其中,第一网络设备的标识的封装位置对于第二网络设备已知,该已知的方式可以是第二网络设备直接知晓第一网络设备的标识所在的封装位置,或者第二网络设备通过标识指示信息确定第一网络设备的标识所在的封装位置。
另一种可能的实现方式中,第二网络设备在探测报文中封装第一网络设备的标识的位置(第一网络设备的标识的封装位置对于第二网络设备已知)获取第一网络设备 的标识,在探测报文中添加指示的位置(添加指示的位置对于第二网络设备已知)获取添加指示,根据获取的第一网络设备的标识及添加指示的共同指示,将第一网络设备的标识作为响应报文的目的地址,生成响应报文。该添加指示可以用于指示第二网络设备是否需要在响应报文中添加第一网络设备的标识。
应理解,若第二网络设备在探测报文中封装第一网络设备的标识的位置未获取到第一网络设备的标识,或者,第二网络设备在探测报文中封装第一网络设备的标识的位置获取第一网络设备的标识,但在探测报文中添加指示的位置未获取到添加指示,或者,第二网络设备在探测报文中封装第一网络设备的标识的位置未获取第一网络设备的标识,且在探测报文中添加指示的位置未获取到添加指示,第二网络设备在S504中生成的响应报文则可以不携带第一网络设备的标识。
示例性的,在S504中,第二网络设备生成探测报文的响应报文时,可以将处理结果作为响应报文的数据部分,将第一网络设备的标识作为响应报文的目的地址,对该响应报文的数据部分进行UDP、IP、以太网、标签栈以及链路层的封装,生成探测报文的响应报文。例如,响应报文的报文结构可以如图7示意。其中,响应报文可以包括数据部分和头部,头部可以包括UDP头、IP头、以太网头、标签栈以及链路头。UDP头可以包括源端口、目的端口;IP头可以包括源IP地址、目的IP地址以及保留位;以太网头可以包括源MAC地址、目的MAC地址;标签栈可以包括公网路径标签以及隧道标签。
一种可能的实现方式中,探测报文可以为EVPN VPWS场景的探测报文,对应的,S504中,探测报文的响应报文可以为EVPN VPWS场景的探测报文的响应报文。在该可能的实现方式中,图7所示结构的响应报文的隧道标签为EVPN VPWS隧道标签。
一种可能的实现方式中,当第一网络设备的标识为第一网络设备的IP地址时,第二网络设备将第一网络设备的IP地址作为响应报文的目的IP地址。
另一种可能的实现方式中,当第一网络设备的标识为第一网络设备的MAC地址时,第二网络设备将第一网络设备的MAC地址作为响应报文的目的MAC地址。
例如,在探测报文用于检测隧道是否正常的场景中,S504可以实现为:第二网络设备在探测报文中的数据部分获取的待检测隧道的出口标识,若该标识与自己的隧道标识相同,确定待检测隧道正常,若该标识与自己的隧道标识不同,确定待检测隧道异常。第二网络设备将该隧道正常或异常的检测结果作为探测报文的响应报文的数据部分,或者,第二网络设备将该隧道正常或异常的检测结果转换为对应的编码,作为探测报文的响应报文的数据部分。然后,第二网络设备获取探测报文中携带的第一网络设备的标识,将第一网络设备的标识作为探测报文的响应报文的目的地址;并对该响应报文的数据部分进行UDP、IP、以太网、标签栈以及链路层的封装,生成探测报文的响应报文。
进一步可选的,第二网络设备确定待检测隧道是否正常时,在判断待检测隧道的出口标识与自己的隧道标识是否相同的基础上,还可以增加丢包以及时延的判断。具体的,若第二网络设备判断待检测隧道的出口标识与自己的隧道标识相同,且接收到的探测报文无丢包,且时延小于预设阈值,且探测报文中的待检测隧道的出口标识与自己的隧道标识相同,确定待检测隧道正常,否则,确定待检测隧道异常。
需要说明的是,上述确定待检测隧道是否正常的过程为示例说明,并不构成唯一限定。
示例性的,假设探测报文中携带了第一网络设备的IP地址,在探测报文用于检测隧道是否正常的场景中,S504可以实现为:第二网络设备获取探测报文中的待检测隧道的出口标识,判断该标识与自己的隧道标识相同,然后统计接收到的探测报文的时延与包数,若无丢包且时延小于预设阈值,则认为该EVPN VPWS隧道通信正常;否则,认为该EVPN VPWS隧道通信异常;第二网络设备将该隧道正常或异常的检测结果转换为检测结果对应的编码,作为探测报文的响应报文的数据部分。然后,第二网络设备将探测报文的响应报文的UDP头中的源端口填充为3503、目的端口号填充为65004;将探测报文的响应报文的IP头中的源IP地址填充为第二网络设备的IP地址,通过获取探测报文中携带的第一网络设备的IP地址后,将探测报文的响应报文的IP头中的目的IP地址填充为该第一网络设备的IP地址;将探测报文的响应报文的以太网头中的源MAC地址填充为第二网络设备的MAC地址,通过查找路由获取第一网络设备的MAC地址后,将探测报文的响应报文的以太网头中的目的MAC地址填充为第一网络设备的MAC地址;然后对该探测报文的响应报文添加MPLS标签或者SR标签,以及EVPN VPWS隧道标签等信息,生成探测报文的响应报文。
第二网络设备通过在响应报文的目的IP地址中添加第一网络设备的IP地址,可以保证该响应报文最终能够顺利转发至作为探测报文发起端的第一网络设备,而不会出现传统实现方式中由于目的IP地址填充的为第一网络设备和第三网络设备共用的默认值,而导致响应报文可能无法顺利到达探测报文发起端的问题。此外,由于第一网络设备的IP地址添加在响应报文的目的IP地址字段,也可以使得作为非发起端的设备在接收到该响应报文后,根据传统转发规则继续进行响应报文的转发,提高了网络运行的兼容性。
S505、第二网络设备向第一网络设备或者第三网络设备发送该响应报文。
其中,第三网络设备和第一网络设备均与同一个第一用户侧网络设备连接。第三网络设备为该同一个用户侧网络设备连接的除第一网络设备之外的任一个网络设备。在EVPN VPWS多归多活场景中,如图3所示,该第一网络设备可以为第一PE301,该第二网络设备可以为第二PE302,该第三网络设备可以为第三PE303。
例如,第二网络设备可以根据负载分担算法从与第一用户侧网络设备连接的多个网络设备中选择一个网络设备,通过隧道向选择的网络设备发送S504生成的探测报文的响应报文。仍以图3为例,第二PE302可以根据负载分担算法向第一PE301或第二PE303中的一个发送响应报文。
需要说明的是,用户可以根据实际需求配置负载分担算法。例如,一种可能的实现方式中,根据负载分担算法选择负载最小的网络设备,或者,根据负载分担算法选择负载小于第一阈值的任一个网络设备。
需要说明的是,用户可以根据实际需求配置第一阈值,本申请实施例对此不予限定。
第二网络设备也可以根据其他预设机制向第一网络设备或第三网络设备发送响应报文。
示例性的,第二网络设备将S504生成的探测报文的响应报文通过经迭代MPLS或者SR公网的隧道发送至第一网络设备或者第三网络设备。
S506、第一网络设备从第二网络设备接收响应报文;或者,从第三网络设备接收更新后的响应报文。
其中,该响应报文和该更新后的响应报文的目的地址为第一网络设备的标识。
一种可能的实现方式中,S506可以实现为:第一网络设备接收S505中第二网络设备发送的探测报文的响应报文,第一网络设备获取探测报文的响应报文中的目的地址,确定该目的地址为第一网络设备的标识,然后对该响应报文解封装,获取响应报文中的数据信息。
另一种可能的实现方式中,第三网络设备接收S505中第二网络设备发送的探测报文的响应报文,第三网络设备获取响应报文中的目的地址,确定该目的地址为第一网络设备的标识,与自己的网络设备标识不同,然后更新响应报文,将更新后的探测报文的响应报文通过IP路由或者隧道等其他方式转发给目的地址指示的第一网络设备。第一网络设备接收到第三网络设备转发的更新后的探测报文的响应报文,获取更新后的探测报文的响应报文中的目的地址,确定该目的地址为第一网络设备的标识,然后对更新后的探测报文的响应报文解封装,获取更新后的探测报文的响应报文中的数据信息。对于更新响应报文的操作,其具体实现可以是对接收到的报文进行某种方式的修改,如去掉探测报文的响应报文中的标签栈以及链路层的封装,或者进一步地在报文中添加其他必要的信息等。或者,在另一种可能的情形下,该更新也可以理解为无需第三网络设备对报文进行任何实质性的改变,而是通过该第三网络设备直接向第一网络设备透传该报文。
示例性的,若S505中第二网络设备向第三网络设备发送如图7所示结构的响应报文,该响应报文的目的地址为第一网络设备的标识,第三网络设备向第一网络设备发送的更新后的响应报文可以如图8所示。
可选的,在探测报文用于检测隧道是否正常的场景中,第一网络设备根据获取的响应报文中的数据信息确定待检测隧道是否正常。
本申请实施例提供一种报文传输方法,通过在探测报文中加入发起端设备的标识,探测报文的接收端设备将该标识添加为探测报文的响应报文的目的地址,这样,即使非发起端设备接收到响应报文,可以按照响应报文目的地址,将响应报文转发给探测报文的发起端设备,而保证探测报文的发起端设备可以接收到发出的探测报文的响应报文。在探测报文用于检测隧道状态时,避免了探测报文的发起端设备由于无法接收到探测报文的响应报文而引起的检测错误,提高了隧道检测的准确度。
进一步的,在实际应用中,第一网络设备也可以收到其他网络设备发出的探测报文的响应报文,如图9所示,本申请实施例提供的报文传输方法,还可以包括下述S507和S508。
S507、第一网络设备接收其他响应报文。
可以理解的,探测报文的发起端设备还可以为除第一网络设备之外的其他网络设备,当探测报文的发起端设备为与第一用户侧网络设备连接的,除第一网络设备之外的其他网络设备时,第一网络设备也可能接收到远端网络设备(如第二网络设备)通 过隧道发送的其他响应报文。
其中,其他响应报文的格式以及内容,可以参照前述响应报文的描述,此处不再赘述。
S508、第一网络设备根据其他响应报文的目的地址为第一网络设备的标识之外的地址,将其他响应报文转发给其他响应报文的目的地址指示的网络设备。
其中,其他响应报文的目的地址指示的网络设备与第一用户侧网络设备连接。
具体的,S508可以实现为:第一网络设备获取S507中接收的其他响应报文的目的地址,确定其他响应报文的目的地址与自己的目的地址不同,第一网络设备将该其他响应报文更新后,通过IP路由或者隧道转发给其他响应报文的目的地址指示的网络设备。
可选的,其他网络设备接收该更新后的其他响应报文之后,可以进一步获取该更新后的其他响应报文数据信息。
下面以图1所示的EVPN VPWS双归双活场景的报文传输系统为例,对本申请实施例提供的报文传输过程进行说明。
如图1所示,若PE1发起隧道检测,用于检测隧道标识为100至200的EVPN隧道是否正常;该过程可以包括:
一种情况下,PE1获取PE1的IP地址以及待检测隧道的出口端标识,将以TLV格式存储的PE1的IP地址以及待检测隧道的出口端标识作为探测报文的数据部分,然后对数据部分进行封装,生成探测报文,PE1将该探测报文通过100至200的EVPN VPWS隧道发送给隧道的出口端设备;PE3接收该探测报文,对该探测报文解封装后在探测报文的数据部分获取待检测隧道的标识,根据该标识得到本次隧道的检测结果,并将本次隧道的检测结果作为探测报文的响应报文的数据部分;PE3在探测报文的数据部分获取探测报文中PE1的IP地址,将该探测报文的响应报文的目的IP地址添加为PE1的IP地址,对探测报文的响应报文进行封装后通过EVPN VPWS隧道发送至隧道出口设备,若PE1接收到该响应报文,则根据响应报文获取本次的隧道检测结果;若PE2接收到该响应报文,PE2将响应报文更新后,通过IP路由转发给PE1,PE1接收PE2转发的该响应报文并获取本次的隧道检测结果。
另一种情况下,PE1获取待检测隧道的出口端标识,将待检测隧道的出口端标识作为报文的数据部分,获取PE1的IP地址,将报文的IP头的源IP地址配置为PE1的源IP地址,将报文中的某3个保留位配置为001,作为添加指示,然后封装该报文,生成探测报文;PE1将该探测报文通过100至200的EVPN VPWS隧道发送给隧道的出口端设备;PE3接收该探测报文,对该探测报文解封装后在探测报文的数据部分获取该探测报文中的待检测隧道的端标识,根据该标识得到本次隧道的检测结果,作为探测报文的响应报文的数据部分;PE1查找到探测报文中存在添加指示001,在探测报文的IP头中的源IP地址中获取PE1的IP地址,将该探测报文的响应报文的目的IP地址添加为PE1的IP地址,对探测报文的响应报文进行封装后通过EVPN VPWS隧道发送至隧道出口设备,若PE1接收到该响应报文,则根据响应报文获取本次的隧道检测结果;若PE2接收到该响应报文,PE2将响应报文更新后转发给PE1,PE1接收PE2转发的该响应报文并获取本次的隧道检测结果。
再一种情况下,PE1获取PE1的MAC地址以及待检测隧道的出口端标识,将以TLV格式存储的PE1的MAC地址以及待检测隧道的出口端标识作为报文的数据部分,将报文中的某3个保留位配置为001,作为添加指示,然后封装该报文,生成探测报文;PE1将该探测报文通过100至200的EVPN VPWS隧道发送给隧道的出口端设备;PE3接收该探测报文,对该探测报文解封装后在探测报文的数据部分获取该探测报文中的待检测隧道的端标识,根据该标识得到本次隧道的检测结果,作为探测报文的响应报文的数据部分;PE1查找到探测报文中存在添加指示001,在探测报文的数据部分查找以TLV格式存储的PE1的MAC地址,将该探测报文的响应报文的目的MAC地址添加为PE1的MAC地址,对探测报文的响应报文进行封装后通过EVPN VPWS隧道发送至隧道出口设备,若PE1接收到该响应报文,则根据响应报文获取本次的隧道检测结果;若PE2接收到该响应报文,PE2将响应报文更新后转发给PE1,PE1接收PE2转发的该响应报文并获取本次的隧道检测结果。
上述主要从报文传输系统中第一网络设备与第二网络设备之间交互的角度对本发明实施例提供的方案进行了介绍。可以理解的是,各报文传输装置,例如第一网络设备、第二网络设备等为了实现上述功能,其包含了执行各个功能相应的硬件结构和/或软件模块。本领域技术人员应该很容易意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,本发明能够以硬件或硬件和计算机软件的结合形式来实现。某个功能究竟以硬件还是计算机软件驱动硬件的方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本发明的范围。
本发明实施例可以根据上述方法示例对报文传输装置等进行功能模块的划分,例如,可以对应各个功能划分各个功能模块,也可以将两个或两个以上的功能集成在一个处理模块中。上述集成的模块既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。需要说明的是,本发明实施例中对模块的划分是示意性的,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式。
在采用对应各个功能划分各个功能模块的情况下,图10示为本申请实施例提供的一种报文传输装置100,用于实现上述实施例中第一网络设备的功能。该报文传输装置100可以是第一网络设备或者该报文传输装置100可以部署于第一网络设备。如图10所示,报文传输装置100可以包括:第一发送单元1001和第一接收单元1002。第一发送单元1001用于执行图5或图9中的S502;第一接收单元1002用于执行图5或图9中的S506。其中,上述方法实施例涉及的各步骤的所有相关内容均可以援引到对应功能模块的功能描述,在此不再赘述。
进一步的,如图11所示,报文传输装置100还可以包括:处理单元1003、第二接收单元1004和第二发送单元1005。其中,处理单元1003用于执行图5或图9中S501;第二接收单元1004用于执行图9中S507;第二发送单元1005用于执行图9中S508。其中,上述方法实施例涉及的各步骤的所有相关内容均可以援引到对应功能模块的功能描述,在此不再赘述。
在采用集成的单元的情况下,如图12所示为本申请实施例提供的第一网络设备120,用于实现上述方法中第一网络设备的功能。第一网络设备120包括至少一个处理 模块1201,用于实现本申请实施例中第一网络设备的功能。示例性地,处理模块1201可以用于执行图5中的过程S501,具体参见方法示例中的详细描述,此处不做赘述。
第一网络设备120还可以包括至少一个存储模块1202,用于存储程序指令和/或数据。存储模块1202和处理模块1201耦合。本申请实施例中的耦合是装置、单元或模块之间的间接耦合或通信连接,可以是电性,机械或其它的形式,用于装置、单元或模块之间的信息交互。处理模块1201可能和存储模块1202协同操作。处理模块1201可以执行存储模块1202中存储的程序指令。所述至少一个存储模块中的至少一个可以包括于处理模块中。
第一网络设备120还可以包括通信模块1203,用于通过传输介质和其它设备进行通信,从而用于确定第一网络设备120可以和其它设备进行通信。所述通信模块1203用于该设备与其它设备进行通信。示例性的,处理器1201可以利用通信模块1203执行图5或图9中的过程S502、S506、S507、S508。
当处理模块1201为处理器,存储模块1202为存储器,通信模块1203为收发器时,本申请实施例图12所涉及的第一网络设备120可以为图4所示的网络设备40。
如前述,本申请实施例提供的报文传输装置100或第一网络设备120可以用于实施上述本申请各实施例实现的方法中第一网络设备的功能,为了便于说明,仅示出了与本申请实施例相关的部分,具体技术细节未揭示的,请参照本申请各实施例。
在采用对应各个功能划分各个功能模块的情况下,如图13所示为本申请实施例提供的报文传输装置130,用于实现上述实施例中第二网络设备的功能。该报文传输装置130可以是第二网络设备或者该报文传输装置130可以部署于第二网络设备。如图13所示,报文传输装置130可以包括:接收单元1301、处理单元1302和发送单元1303。接收单元1301用于执行图5或图9中S503;处理单元1302用于执行图5或图9中S504;发送单元1303用于执行图5或图9中S505。其中,上述方法实施例涉及的各步骤的所有相关内容均可以援引到对应功能模块的功能描述,在此不再赘述。
进一步的,如图14所示,报文传输装置130还可以包括:添加单元1304。其中,添加单元1304用于执行图5或图9中S504。其中,上述方法实施例涉及的各步骤的所有相关内容均可以援引到对应功能模块的功能描述,在此不再赘述。
在采用集成的单元的情况下,如图15所示为本申请实施例提供的第二网络设备150,用于实现上述实施例中第二网络设备的功能。该第二网络设备150可以包括至少一个处理模块1501,用于实现本申请实施例中第二网络设备的功能,具体参见方法示例中的详细描述,此处不做赘述。
第二网络设备150还可以包括至少一个存储模块1502,用于存储程序指令和/或数据。存储模块1502和处理模块1501耦合。本申请实施例中的耦合是装置、单元或模块之间的间接耦合或通信连接,可以是电性,机械或其它的形式,用于装置、单元或模块之间的信息交互。处理模块1501可能和存储模块1502协同操作。处理模块1501可能执行存储模块1502中存储的程序指令。所述至少一个存储模块中的至少一个可以包括于处理模块中。
第二网络设备150还可以包括通信模块1503,用于通过传输介质和其它设备进行通信,从而用于确定第二网络设备150可以和其它设备进行通信。所述通信模块1503 用于该设备与其它设备进行通信。示例性的,处理模块1501利用通信模块1503执行图5或图9过程中的S503、S505。
当处理模块1501为处理器,存储模块1502为存储器,通信模块1503为收发器时,本申请实施例图15所涉及的第二网络设备150可以为图4所示的网络设备40。
如前述,本申请实施例提供的报文传输装置130或第二网络设备150可以用于实施上述本申请上述实施例中第二网络设备的功能,为了便于说明,仅示出了与本申请实施例相关的部分,具体技术细节未揭示的,请参照本申请各实施例。
本申请另一些实施例提供一种报文传输系统,该报文传输系统中可以包括报文传输的第一装置和报文传输的第二装置,该报文传输的第一装置可以实现上述实施例中第一网络设备的功能,该报文传输的第二装置可以实现第二网络设备的功能。例如,报文传输的第一装置可以为本申请实施例描述的第一网络设备,报文传输的第二装置可以为本申请实施例描述的第二网络设备。
本申请另一些实施例提供了一种芯片系统,该芯片系统包括处理器,还可以包括存储器,用于实现上述图5或图9所示实施例中第一网络设备的功能。该芯片系统可以由芯片构成,也可以包含芯片和其他分立器件。
本申请另一些实施例提供了一种芯片系统,该芯片系统包括处理器,还可以包括存储器,用于实现上述图5或图9所示实施例中第二网络设备的功能。该芯片系统可以由芯片构成,也可以包含芯片和其他分立器件。
本申请另一些实施例还提供一种计算机可读存储介质,该计算机可读存储介质可包括计算机程序,当该计算机程序在计算机上运行时,使得该计算机执行上述图5或图9所示实施例中各个步骤。
本申请另一些实施例还提供一种计算机程序产品,该计算机产品包含计算机程序,当该计算机程序产品在计算机上运行时,使得该计算机执行上述图5或图9所示实施例中各个步骤。
通过以上的实施方式的描述,所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,仅以上述各功能模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能模块完成,即将装置的内部结构划分成不同的功能模块,以完成以上描述的全部或者部分功能。
在本申请所提供的几个实施例中,应该理解到,所揭露的装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,所述模块或单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个装置,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是一个物理单元或多个物理单元,即可以位于一个地方,或者也可以分布到多个不同地方。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。
另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以 是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。
所述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个可读取存储介质中。基于这样的理解,本申请实施例的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该软件产品存储在一个存储介质中,包括若干指令用以使得一个设备(可以是单片机,芯片等)或处理器(processor)执行本申请各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(Read-Only Memory,ROM)、随机存取存储器(Random Access Memory,RAM)、磁碟或者光盘等各种可以存储程序代码的介质。
以上所述,仅为本申请的具体实施方式,但本申请的保护范围并不局限于此,任何在本申请揭露的技术范围内的变化或替换,都应涵盖在本申请的保护范围之内。因此,本申请的保护范围应以所述权利要求的保护范围为准。

Claims (21)

  1. 一种报文传输方法,其特征在于,所述方法由第一网络设备执行,所述方法包括:
    向第二网络设备发送探测报文,所述探测报文包括所述第一网络设备的标识,所述第一网络设备的标识用于指示所述第二网络设备在所述探测报文的响应报文的目的地址中添加所述第一网络设备的标识;
    从所述第二网络设备接收所述响应报文,所述响应报文的目的地址为所述第一网络设备的标识;或者,从第三网络设备接收更新后的所述响应报文,所述更新后的所述响应报文的目的地址为所述第一网络设备的标识,所述第三网络设备和所述第一网络设备均与同一用户侧网络设备连接。
  2. 根据权利要求1所述的方法,其特征在于,所述第一网络设备的标识包括:
    所述第一网络设备的网际协议IP地址;
    或者,
    所述第一网络设备的媒体访问控制MAC地址。
  3. 根据权利要求2所述的方法,其特征在于,所述第一网络设备的IP地址包括:
    所述第一网络设备的接口IP地址;
    或者,
    所述第一网络设备的环回loopback接口IP地址;
    或者,
    所述第一网络设备的IP地址形式的段标识符SID。
  4. 根据权利要求1-3任一项所述的方法,其特征在于,在所述向第二网络设备发送探测报文之前,所述方法还包括:
    生成所述探测报文;其中,
    所述第一网络设备的标识以类型长度值TLV格式封装于所述探测报文的数据部分;
    或者,
    所述第一网络设备的标识封装于所述探测报文IP头的源IP地址中。
  5. 根据权利要求1-4任一项所述的方法,其特征在于,所述探测报文还包括添加指示,所述第一网络设备的标识用于指示所述第二网络设备在所述探测报文的响应报文的目的地址中添加所述第一网络设备的标识,包括:
    所述第一网络设备的标识和所述添加指示用于共同指示所述第二网络设备在所述响应报文的目的地址中添加所述第一网络设备的标识。
  6. 根据权利要求1-5任一项所述的方法,其特征在于,所述方法还包括:
    接收其他响应报文;
    根据所述其他响应报文的目的地址为所述第一网络设备的标识之外的地址,将所述其他响应报文转发给所述其他响应报文的目的地址指示的网络设备,所述其他响应报文的目的地址指示的网络设备与所述用户侧网络设备连接。
  7. 根据权利要求1-6任一项所述的方法,其特征在于,所述第一网络设备、所述第二网络设备和所述第三网络设备为运营商边缘设备PE,所述用户侧网络设备为用户边缘设备CE。
  8. 根据权利要求1-7任一项所述的方法,其特征在于,所述探测报文为以太虚拟私有局域网EVPN虚拟私有无线服务VPWS场景的探测报文,所述响应报文为所述EVPN VPWS场景的响应报文。
  9. 一种报文传输方法,其特征在于,所述方法由第二网络设备执行,所述方法包括:
    接收第一网络设备发送的探测报文,所述探测报文包括所述第一网络设备的标识;
    生成所述探测报文的响应报文,所述响应报文的目的地址包括所述第一网络设备的标识;
    向所述第一网络设备或者第三网络设备发送所述响应报文,所述第三网络设备和所述第一网络设备均与同一用户侧网络设备连接。
  10. 根据权利要求9所述的方法,其特征在于,所述第一网络设备的标识包括:
    所述第一网络设备的网际协议IP地址;
    或者,
    所述第一网络设备的媒体访问控制MAC地址。
  11. 根据权利要求10所述的方法,其特征在于,所述第一网络设备的IP地址包括:
    所述第一网络设备的接口IP地址;
    或者,所述第一网络设备的环回loopback接口IP地址;
    或者,所述第一网络设备的IP地址形式的段标识符SID。
  12. 根据权利要求9-11任一项所述的方法,其特征在于,所述第一网络设备的标识以类型长度值TLV格式封装于所述探测报文的数据部分;
    或者,
    所述第一网络设备的标识封装于所述探测报文IP头的源IP地址中。
  13. 根据权利要求9-12任一项所述的方法,其特征在于,所述探测报文还包括添加指示,所述方法还包括:
    根据所述添加指示及所述第一网络设备的标识,在所述响应报文的目的地址中添加所述第一网络设备的标识。
  14. 根据权利要求10所述的方法,其特征在于,生成所述探测报文的响应报文,包括:
    在所述响应报文的目的IP地址中添加所述第一网络设备的IP地址;
    或者,
    在所述响应报文的目的MAC地址添加所述第一网络设备的MAC地址。
  15. 根据权利要求9-14任一项所述的方法,其特征在于,所述向所述第一网络设备或者所述第三网络设备发送所述响应报文,包括:
    根据负载分担算法,向所述第一网络设备或者所述第三网络设备发送所述响应报文。
  16. 根据权利要求9-15任一项所述的方法,其特征在于,所述第一网络设备、所述第二网络设备和所述第三网络设备为运营商边缘设备PE,所述用户侧网络设备为用户边缘设备CE。
  17. 根据权利要求9-16任一项所述的方法,其特征在于,所述探测报文为以太虚拟私有局域网EVPN虚拟私有无线服务VPWS场景的探测报文,所述响应报文为所述EVPN VPWS场景的响应报文。
  18. 一种第一网络设备,其特征在于,所述设备包括:处理器和存储器;
    所述存储器与所述处理器连接;所述存储器用于存储计算机指令,当所述处理器执行所述计算机指令时,所述设备执行如权利要求1至8中任一项所述的报文传输方法。
  19. 一种第二网络设备,其特征在于,所述设备包括:处理器和存储器;
    所述存储器与所述处理器连接;所述存储器用于存储计算机指令,当所述处理器执行所述计算机指令时,所述设备执行如权利要求9至17中任一项所述的报文传输方法。
  20. 一种报文传输系统,其特征在于,包括如权利要求18所述的第一网络设备,以及如权利要求19所述的第二网络设备。
  21. 一种计算机可读存储介质,包括指令,当其在计算机上运行时,使得计算机执行权利要求1至17中任一项所述的报文传输方法。
PCT/CN2021/114150 2020-08-28 2021-08-23 一种报文传输方法、装置及系统 WO2022042503A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
EP21860338.9A EP4195541A4 (en) 2020-08-28 2021-08-23 MESSAGE TRANSMISSION METHOD, APPARATUS AND SYSTEM
US18/175,431 US20230208757A1 (en) 2020-08-28 2023-02-27 Packet Transmission Method, Apparatus, and System

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202010890127.0 2020-08-28
CN202010890127.0A CN114189564A (zh) 2020-08-28 2020-08-28 一种报文传输方法、装置及系统

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US18/175,431 Continuation US20230208757A1 (en) 2020-08-28 2023-02-27 Packet Transmission Method, Apparatus, and System

Publications (1)

Publication Number Publication Date
WO2022042503A1 true WO2022042503A1 (zh) 2022-03-03

Family

ID=80352660

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/114150 WO2022042503A1 (zh) 2020-08-28 2021-08-23 一种报文传输方法、装置及系统

Country Status (4)

Country Link
US (1) US20230208757A1 (zh)
EP (1) EP4195541A4 (zh)
CN (1) CN114189564A (zh)
WO (1) WO2022042503A1 (zh)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114866466A (zh) * 2022-03-29 2022-08-05 深圳会当科技有限公司 设备通信方法、装置、电子设备及可读存储介质
CN115426398A (zh) * 2022-10-27 2022-12-02 杭州海康威视数字技术股份有限公司 基于多层协同的视频物联网设备安全发现方法及装置

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115378816B (zh) * 2022-08-02 2024-02-23 深信服科技股份有限公司 网络配置检测方法、装置及存储介质

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7336615B1 (en) * 2001-06-25 2008-02-26 Juniper Networks, Inc. Detecting data plane livelines in connections such as label-switched paths
CN101447900A (zh) * 2008-12-15 2009-06-03 华为技术有限公司 一种建立双向转发检测的方法、系统及设备
CN101505250A (zh) * 2009-04-10 2009-08-12 杭州华三通信技术有限公司 公网lsp的探测方法和探测系统及vpn
CN105337785A (zh) * 2014-07-18 2016-02-17 华为技术有限公司 一种路径连通性检测方法及装置
US9497107B1 (en) * 2013-06-06 2016-11-15 Cisco Technology, Inc. Seamless path monitoring and rapid fault isolation using bidirectional forwarding detection in a network environment
CN107040443A (zh) * 2015-10-01 2017-08-11 丛林网络公司 多宿主拓扑的evpn网络的快速收敛

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7920477B2 (en) * 2007-01-24 2011-04-05 Viasat, Inc. Network layer error control systems and methods
US7844719B2 (en) * 2007-02-13 2010-11-30 Cisco Technology, Inc. Tunnel availability detection with reduced control plane overhead
CN109218178B (zh) * 2017-07-05 2021-06-22 华为技术有限公司 一种报文处理方法及网络设备
US11349749B2 (en) * 2018-10-17 2022-05-31 Juniper Networks, Inc. Node protection for bum traffic for multi-homed node failure
CN110635968A (zh) * 2019-09-27 2019-12-31 深信服科技股份有限公司 堆叠双活检测通道的监控方法、装置、设备及存储介质
US11121954B2 (en) * 2020-01-15 2021-09-14 Cisco Technology, Inc. Telemetry collection and analysis for SD-WAN tunnels

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7336615B1 (en) * 2001-06-25 2008-02-26 Juniper Networks, Inc. Detecting data plane livelines in connections such as label-switched paths
CN101447900A (zh) * 2008-12-15 2009-06-03 华为技术有限公司 一种建立双向转发检测的方法、系统及设备
CN101505250A (zh) * 2009-04-10 2009-08-12 杭州华三通信技术有限公司 公网lsp的探测方法和探测系统及vpn
US9497107B1 (en) * 2013-06-06 2016-11-15 Cisco Technology, Inc. Seamless path monitoring and rapid fault isolation using bidirectional forwarding detection in a network environment
CN105337785A (zh) * 2014-07-18 2016-02-17 华为技术有限公司 一种路径连通性检测方法及装置
CN107040443A (zh) * 2015-10-01 2017-08-11 丛林网络公司 多宿主拓扑的evpn网络的快速收敛

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP4195541A4

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114866466A (zh) * 2022-03-29 2022-08-05 深圳会当科技有限公司 设备通信方法、装置、电子设备及可读存储介质
CN115426398A (zh) * 2022-10-27 2022-12-02 杭州海康威视数字技术股份有限公司 基于多层协同的视频物联网设备安全发现方法及装置

Also Published As

Publication number Publication date
US20230208757A1 (en) 2023-06-29
EP4195541A4 (en) 2024-01-17
CN114189564A (zh) 2022-03-15
EP4195541A1 (en) 2023-06-14

Similar Documents

Publication Publication Date Title
US11533249B2 (en) Route processing method and apparatus, and data transmission method and apparatus
US11265241B2 (en) Path detection method and apparatus
US11075774B2 (en) VXLAN packet processing method, device, and system
US11979322B2 (en) Method and apparatus for providing service for traffic flow
WO2022042503A1 (zh) 一种报文传输方法、装置及系统
WO2016192686A1 (zh) 数据报文转发
US10284461B2 (en) Method and related apparatus for probing packet forwarding path
US11165693B2 (en) Packet forwarding
EP3767898A1 (en) Packet forwarding method and apparatus
JP2022500915A (ja) 通信方法、デバイス、及びシステム
WO2017000802A1 (zh) 一种业务故障定位方法及装置
US7782790B1 (en) Extensions to the path verification protocol to support link bundling constructs
US11522792B2 (en) Method for discovering forwarding path and related device thereof
WO2022083563A1 (zh) 链路检测方法、链路检测装置、终端设备和存储介质
CN108667709B (zh) 一种报文转发方法及装置
WO2020173424A1 (zh) 报文处理的方法和网关设备
US20220247598A1 (en) Packet Detection Method, Connectivity Negotiation Relationship Establishment Method, and Related Device
CN114520762B (zh) BIERv6报文的发送方法以及第一网络设备
KR20230022251A (ko) Bier oam 검출 방법, 디바이스, 및 시스템
WO2022135321A1 (zh) 报文传输方法、设备及系统
WO2023078144A1 (zh) 报文处理方法、装置及系统
EP4319096A1 (en) Packet transmission method and related device
US20240056389A1 (en) Information processing method, and device and storage medium

Legal Events

Date Code Title Description
ENP Entry into the national phase

Ref document number: 2021860338

Country of ref document: EP

Effective date: 20230310

NENP Non-entry into the national phase

Ref country code: DE