CN115695246A - Tunnel quality detection method based on SRv and related device - Google Patents

Tunnel quality detection method based on SRv and related device Download PDF

Info

Publication number
CN115695246A
CN115695246A CN202110864909.1A CN202110864909A CN115695246A CN 115695246 A CN115695246 A CN 115695246A CN 202110864909 A CN202110864909 A CN 202110864909A CN 115695246 A CN115695246 A CN 115695246A
Authority
CN
China
Prior art keywords
network device
detection
tunnel
list path
packet
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202110864909.1A
Other languages
Chinese (zh)
Inventor
辛方
范汇华
李基亮
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN202110864909.1A priority Critical patent/CN115695246A/en
Priority to PCT/CN2022/107929 priority patent/WO2023005927A1/en
Publication of CN115695246A publication Critical patent/CN115695246A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • 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
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/08Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
    • H04L43/0805Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters by checking availability
    • H04L43/0811Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters by checking availability by checking connectivity
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/08Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
    • H04L43/0823Errors, e.g. transmission errors
    • H04L43/0829Packet loss
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/08Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
    • H04L43/0852Delays
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/08Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
    • H04L43/0852Delays
    • H04L43/087Jitter
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Environmental & Geological Engineering (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The embodiment of the application discloses a tunnel quality detection method and a related device based on SRv, which are used for detecting the SLA quality of a tunnel. In the application, a first network device generates a first detection message, where the first detection message carries a first segment list path and a second segment list path, the first segment list path is used to represent a first tunnel, the second segment list path is used to represent a second tunnel, the first tunnel is a tunnel from the first network device to a second network device, and the second tunnel is a tunnel from the second network device to the first network device. Then, after the first network device sends the first detection packet, the first detection packet is sent to the second network device according to the first segment list path, and then returns to the first network device according to the second segment list path. Because the first network device monitors the first detection message after sending the first detection message, when the first network device receives the first detection message, the SLA quality of the first tunnel and the SLA quality of the second tunnel can be detected.

Description

Tunnel quality detection method based on SRv and related device
Technical Field
The application relates to the field of communication, in particular to a tunnel quality detection method and a related device based on an internet protocol version 6 segmented route SRv.
Background
SRv6 is a Segment Routing (SR) technology implemented based on internet protocol version 6 (IPv 6) technology, and specifically, a segment list (or multiple segment lists) based on IPv6 is added to a data packet to implement routing of the data packet. After the tunnel based on SRv is created, the quality of the service-level agreement (SLA) of the tunnel needs to be detected, but currently, an effective means for detecting the quality of the SLA of the tunnel is lacking.
Disclosure of Invention
The embodiment of the application provides a tunnel quality detection method based on SRv and a related device, which are used for detecting the SLA quality of a tunnel.
In the present application, a first network device generates a first detection packet, where the first detection packet carries a first segment list path and a second segment list path, the first segment list path is used to characterize a first tunnel, the second segment list path is used to characterize a second tunnel, the first tunnel is a tunnel from the first network device to a second network device, and the second tunnel is a tunnel from the second network device to the first network device. Then, after the first network device sends the first detection packet, the first detection packet is sent to the second network device according to the first segment list path, and then returns to the first network device according to the second segment list path. Because the first network equipment monitors the first detection message after sending the first detection message, when the first network equipment receives the first detection message, the SLA quality of the first tunnel and the SLA quality of the second tunnel can be detected.
In some possible implementations, SLA quality includes packet loss rate, latency, and jitter.
In some possible implementations, the first network device may send multiple detection packets, where the detection packets have the same five-tuple (or the same five-tuple and the same session identifier), and the first detection packet includes the multiple detection packets. After receiving the first detection message, the first network device checks the number of the received first detection messages to determine the packet loss rate.
In some possible implementation manners, the first network device sends the first detection packet through a tunnel interface of a first tunnel, where the first tunnel is a tunnel created according to the first segment list path, so as to ensure that the SLA quality of the first tunnel can be detected.
In some possible implementation manners, the first section list path and the second section list path are in a forward and reverse common path, so that the SLA quality of the specified tunnel can be detected more accurately.
In some possible implementation manners, the first network device receives the first detection packet, and the first network device determines the two-way delay of the first detection packet according to a receiving time point of the first detection packet and a sending timestamp of the first detection packet, so that the delay in the SLA quality can be calculated.
Illustratively, the two-way delay of the first detection packet = the receiving time point of the first detection packet — the transmission timestamp of the first detection packet. Jitter is delay jitter and is used for representing the change of the delay.
In some possible implementations, the first network device may determine the jitter of the first tunnel or the second tunnel from a latency (or a bidirectional latency).
In some possible implementation manners, the first network device receives the second detection packet, obtains the session identifier and the five-tuple of the second detection packet, and determines that the second detection packet is the first detection packet if the session identifier and the five-tuple of the second detection packet are the same as the session identifier and the five-tuple of the first detection packet, so as to determine whether the first detection packet is received.
When the five tuples of the two detection messages are different and the session identifiers are the same, or the five tuples of the two detection messages based on the two-way active measurement protocol (TWAMP) are the same and the session identifiers are different, the two detection messages are also considered to belong to two different TWAMP instances. Then, by setting the session identification, all TWAMP instances are made to use the same source port number or the same destination port number, thereby saving the use of port numbers.
In some possible implementation manners, the first detection packet is a TWAMP packet and takes effect, the TWAMP is configured and takes effect in the first network device, the TWAMP is not configured or does not take effect in the second network device, that is, the TWAMP is a single-arm TWAMP, the first segment list path and the second segment list path are successively pushed in the header of the first detection packet, and the destination address of the first detection packet is the local address of the first network device.
In some possible implementation manners, the second segment list path is compressed in a Binding Segment Identifier (BSID), so that the forwarded first detection packet is smaller, and the requirement on the bandwidth is reduced.
In some possible implementations, the expansion manner of the BSID is an encapsulation (encaps) manner or an insertion (insert) manner, so that the second network device can obtain the information of the second segment list path in the BSID.
It should be noted that encaps uses the current first detection packet as a load, so as to perform encapsulation to obtain a new first detection packet, and then pushes the second segment of list path in the BSID in the new first detection packet.
It should be noted that the insert method is to directly expand the current first detection packet at the BSID position to obtain a new first detection packet, and then directly insert the second segment list path into the first segment list path in the new first detection packet.
In some possible implementation manners, the first detection packet is a TWAMP packet, the first network device and the first network device configure and validate the TWAMP, the header of the first detection packet pushes the first segment of the list path, and the payload of the first detection packet carries the second segment of the list path, so that the second network device can obtain information of the second segment of the list path from the payload and return the first detection packet according to the second segment of the list path, thereby achieving detection of SLA quality of the first tunnel and the second tunnel.
In a second aspect, the present application provides a network device, which is specifically a first network device, and the first network device is configured to execute the method described in any one of the foregoing possible implementation manners of the first aspect.
In a third aspect, the present application provides a computer-readable storage medium, which stores instructions that, when executed on a computer, cause the computer to perform the method according to any one of the possible implementation manners of the first aspect.
A fourth aspect of the present application provides a computer program product comprising computer executable instructions stored in a computer readable storage medium; the computer executable instructions may be read by at least one processor of the device from a computer readable storage medium, the execution of which by the at least one processor causes the device to carry out the method provided by the first aspect or any one of the possible implementations of the first aspect described above.
A fifth aspect of the present application provides a network device that may include at least one processor, a memory, and a communication interface. At least one processor is coupled with the memory and the communication interface. The memory is configured to store instructions, the at least one processor is configured to execute the instructions, and the communication interface is configured to communicate with other network devices under control of the at least one processor. The instructions, when executed by at least one processor, cause the at least one processor to perform the method of the first aspect or any possible implementation of the first aspect.
A sixth aspect of the present application provides a chip system, where the chip system includes a processor, configured to support a first network terminal to implement the functions in the first aspect or any one of the possible implementation manners of the first aspect.
In one possible design, the system-on-chip may further include a memory for storing program instructions and data necessary for the first network terminal. The chip system may be constituted by a chip, or may include a chip and other discrete devices.
For technical effects brought by any one of the possible implementation manners of the second aspect to the sixth aspect, reference may be made to technical effects brought by different possible implementation manners of the first aspect or the first aspect, and details are not described here.
Drawings
FIG. 1 is a diagram illustrating a system architecture according to an embodiment of the present application;
fig. 2-1 the present application proposes a tunnel quality detection method based on SRv;
fig. 2-2 is a schematic diagram of a forwarding process of the first detection packet among the ACC, MC1, P1 and PE 3;
fig. 2-3 are another schematic diagrams of the forwarding process of the first detection packet among the ACC, MC1, P1, and PE 3;
fig. 2-4 are another schematic diagrams of the forwarding process of the first detection packet among the ACC, MC1, P1, and PE 3;
fig. 2-5 are another schematic diagrams of the forwarding process of the first detection packet among the ACC, MC1, P1, and PE 3;
fig. 2 to 6 are another schematic diagrams of the forwarding process of the first detection packet among the ACC, MC1, P1, and PE 3;
fig. 2 to 7 are another schematic diagrams of the forwarding process of the first detection packet among the ACC, MC1, P1, and PE 3;
fig. 3 is a schematic structural diagram of a network device according to 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.
Detailed Description
The embodiment of the application provides a tunnel quality detection method based on SRv and a related device, which are used for detecting the SLA quality of a tunnel.
Embodiments of the present application are described below with reference to the accompanying drawings.
The terms "first," "second," and the like in the description and in the claims of the present application and in the above-described drawings are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the terms so used are interchangeable under appropriate circumstances and are merely descriptive of the various embodiments of the application and how objects of the same nature can be distinguished. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of elements is not necessarily limited to those elements, but may include other elements not expressly listed or inherent to such process, method, article, or apparatus.
Referring to fig. 1, a schematic diagram of a system architecture according to an embodiment of the present application is shown. Referring to fig. 1, the system architecture includes a communication network 100, and at least two user equipments communicatively connected to the communication network 100, where any two user equipments may transmit a service packet through the communication network 100. For example, in the embodiment of the present application, the at least two pieces of user equipment include user equipment 200 to 500 (that is, user equipment 200, user equipment 300, user equipment 400, and user equipment 500), and the user equipment 200 transmits a service packet to the user equipment 300 through the communication network 100 as an example, that is, the user equipment 200 is taken as a sending device and the user equipment 300 is taken as a receiving device as an example.
As shown in fig. 1, the communication network 100 includes a controller 101 and a plurality of network devices communicatively connected to the controller 101, and the network devices are configured to forward traffic packets under the control of the controller 101. And, according to the flow direction and the transmission path of the traffic packet, the plurality of network devices may include an ingress (ingress) device, an egress (egress) device, and at least one transit (transit) device located between the ingress device and the egress device.
For example, in the embodiment of the present application, the plurality of network devices include network devices 102 to 114 (that is, network device 102, network device 103, network device 104, network device 105, network device 106, network device 107, network device 108, network device 109, network device 110, network device 111, network device 112, network device 113, and network device 114), the user device 200 and the user device 300 are communicatively connected to the network device 102 in the communication network 100, and the user device 400 and the user device 500 are communicatively connected to the network device 113 in the communication network 100 as an example. It is to be understood that, in an example where the user equipment 200 transmits the service packet to the user equipment 300 through the communication network 100, the network equipment 102 may be an ingress device, the network equipment 113 may be an egress device, and the network equipment 103 to 113 may be transit devices. The network device is also called a network node, a gateway device, a routing node or a routing device, the ingress device is also called a head node, the egress device is also called a tail node, and the transit device is also called a transit node or an intermediate node.
Illustratively, network device 102 and network device 114 may be customer edge routers (CEs), where network device 102 is CE1 and network device 114 is CE2. Illustratively, the network device 103 may be an access router (ACC); the network device 103 and the network device 104 may be aggregation routers (AGGs), wherein the network device 103 is an AGG1 and the network device 104 is an AGG2; network device 105 and network device 106 may be metro core routers (MC), where network device 105 is MC1 and network device 106 is MC2; the network device 107 and the network device 108 may be provider edge routers (PEs), where the network device 107 is PE1 and the network device 108 is PE2; network device 109 and network device 110 may be a provider router (P), where network device 109 is P1 and network device 110 is P2; network device 111 and network device 112 may be PEs, where network device 111 is PE3 and network device 112 is PE4.
The controller 101 is a brain of a future cloud network, integrates functions of network management, service control, network analysis and the like, and is a core enabling system for realizing network resource pooling, network connection automation, self-optimization and operation and maintenance automation. The controller 101 may be a functional module deployed in a server, or a server cluster composed of a plurality of servers, or a cloud computing service center, which is not limited in this embodiment of the present application. A server is also called a server, and is a device that provides computing services. Since a server needs to respond to and process a service request to provide a reliable service, the server generally has the capability of undertaking and guaranteeing the service, and the server needs to have strong processing capability, high stability, high reliability, high security, expandability, and manageability. In the embodiment of the present application, the server may be an x86 server, which is also called a Complex Instruction Set (CISC) architecture server, that is, a Personal Computer (PC) server in general, and is a server based on a PC architecture and using an intel or other x86 instruction set compatible processor chip and a windows operating system.
Each of the network devices 102 to 114 may be a device such as a switch or a router (router) used for forwarding a service packet in a communication network, and the network devices 102 to 114 may be the same network device, for example, the network devices 102 to 114 may all be routers, or the network devices 102 to 114 may be different network devices, for example, one part of the network devices 102 to 114 is a router and the other part is a switch. The router is a special intelligent network device which can read a destination address in a service message and determine how to transmit the service message according to the destination address; the router can understand different protocols, such as an ethernet protocol used by a certain local area network, a transmission control protocol/internet protocol (TCP/IP) protocol used by the internet, and the like, so that the router can analyze destination addresses of service messages transmitted by various different types of networks and convert non-TCP/IP addresses into TCP/IP addresses, or vice versa; and then, according to the selected routing algorithm, each service message is transmitted to the destination address according to the optimal transmission path, so that the router can connect the non-TCP/IP network to the Internet. It should be noted that, in order to distinguish from a transmission path of a traffic packet, a communication connection between the controller 101 and each network device is shown in a form of a dashed double arrow in fig. 1, and in some scenarios, the transmission path described in this embodiment may also be referred to as a communication link, a communication path, a communication tunnel, a tunnel path, or the like.
Each of the user devices 200 to 500 may be a communication device with a wireless communication function, for example, each of the user devices 200 to 500 may be a desktop computer, an internet of things (IoT) device, and the like, and the user devices 200 to 500 may be the same communication device, for example, each of the user devices 200 to 500 may be a desktop computer, or the user devices 200 to 500 may be different communication devices, for example, a part of the user devices 200 to 500 is a desktop computer and another part is an IoT device.
It should be noted that the communication network 100 in the system architecture shown in fig. 1 is only used for example, and is not used to limit the technical solution of the embodiment of the present application, and in the specific implementation process, the communication network may also include other devices, and the number of network devices may be configured according to needs.
SRv6 is a Segment Routing (SR) technology implemented based on internet protocol version 6 (IPv 6) technology, and specifically, routing of a data packet is implemented by adding one or more segment lists (segment lists) based on IPv6 to the data packet. Specifically, the routing manner of the data packet based on SRv is described in detail in the following steps 201 to 208, which is not described herein again.
Each network device in the communication network shown in fig. 1 is configured with SRv, and a tunnel can be created based on SRv. For example, as shown in fig. 1, there may be multiple tunnels between the ACC and PE 3: ACC- > AGG1- > MC1- > PE1- > P1- > PE3, ACC- > AGG2- > MC2- > PE2- > PE1- > P1- > PE3. The two tunnels can be mutually used as main tunnels and standby tunnels, so that load sharing is realized. After a tunnel is created, service-level agreement (SLA) quality of the tunnel needs to be detected. It should be noted that the SLA quality may include packet loss rate, delay and jitter.
Currently, detection means for SLA quality include Bidirectional Forwarding Detection (BFD), in-band flow information measurement (IFIT), two-way active measurement protocol (TWAMP), and the like. The current BFD can only detect the connection and disconnection of the tunnel, and the SLA quality of the tunnel cannot be measured. The current IFIT and TWAMP can only detect the SLA quality based on the traffic, and cannot detect the SLA quality of the tunnel. For example, if a certain network device in a tunnel fails, if the current IFIT and TWAMP are used, the data packet selects another tunnel to send the data packet to the destination network device. In summary, there is currently no corresponding technical solution for detecting the SLA quality of the tunnel.
Therefore, the application provides a tunnel quality detection method based on SRv.
In this embodiment of the present application, a first network device generates a first detection packet, where the first detection packet carries a first segment list path and a second segment list path, the first segment list path is used to characterize a first tunnel, the second segment list path is used to characterize a second tunnel, the first tunnel is a tunnel from the first network device to a second network device, and the second tunnel is a tunnel from the second network device to the first network device. Then, after the first network device sends the first detection packet, the first detection packet is sent to the second network device according to the first segment list path, and then returns to the first network device according to the second segment list path. Because the first network device monitors the first detection message after sending the first detection message, when the first network device receives the first detection message, the SLA quality of the first tunnel and the SLA quality of the second tunnel can be detected.
In some possible implementations, the first detection packet may be a TWAMP-based detection packet, or may be an IFIT-based detection packet, which is not limited herein. In the embodiment of the present application, the first detection packet is taken as a detection packet based on TWAMP as an example for description. For example, please refer to fig. 2-1, which is a detailed implementation step of a tunnel quality detection method based on SRv proposed by the present application, the method may be applied to a communication network 100 as shown in fig. 1, where a plurality of network devices in the communication network 100 include a first network device and a second network device, and at least one relay device located between the first network device and the second network device.
In this embodiment of the application, the first network device and the second network device may be any two non-adjacent network devices in the communication network 100, and an ACC shown in fig. 1 is taken as the first network device, and a PE3 is taken as the second network device for example.
Referring to fig. 2-1, the method may include the steps of:
201. the first network device configures the TWAMP.
In some possible implementations, TWAMP, hereinafter referred to as bilateral TWAMP, may be configured for both the first network device and the second network device. In some possible implementations, TWAMP may also be configured and validated only for the first network device, and not for the second network device, or the second network device may also be configured with TWAMP but not validated, referred to below as a one-arm TWAMP. In some possible implementations, a TWAMP module (physical or virtual) is built into the first network device (or the first network device and/or the second network device), and a TWAMP instance may be created by the TWAMP module.
202. The first network device generates a first detection message.
In this embodiment of the present application, the first detection message includes a load (payload), a Source Address (SA), a Destination Address (DA), and a Segment Routing Header (SRH) based on SRv, which are described below.
1. And (4) loading.
In some possible implementation manners, if the first network device configures and validates the TWAMP, and the second network device does not configure or validate the TWAMP, the payload in the first detection packet may not carry any valid information, or may carry other necessary information, which is not limited herein. For example, the information carried in the load of the first detection packet is "00000000". In some possible implementation manners, if both the first network device and the second network device configure and generate TWAMP, the load of the first detection packet may carry information of the second segment list path.
2. SA and DA.
When the first detection message is generated, the SA and the DA of the first detection message are both set as the local address of the first network device. It should be noted that, in the embodiment of the present application, the values of SA and DA are both IPv6 addresses. For example, if the native address of the first network device is 1::1, then SA and DA can both be set to 1::1, then before the push segment list, the first detection packet can be as shown in Table 1 below:
TABLE 1
DA=1::1
SA=1::1
Load(s)
It should be noted that 1: 1 is an IPv6 address used by the first network device issuing route.
3. SRH SRv.
It should be noted that the SRH based on SRv includes Segment Left (SL) and a plurality of segment lists (segment list), and the value of the segment list may be IPv6 address of the network device or link.
In the embodiment of the present application, in the scenario of the one-arm TWAMP, the segment list includes a first segment list path and a second segment list path. In the scenario of two-way TWAMP, the segment list only includes the first segment list path, and the load of the first detection packet carries information of the second segment list path. SRH in the scenarios of one-arm TWAMP and two-sided TWAMP are described below, respectively.
One-arm TWAMP scenarios.
In this embodiment, in the context of one-arm TWAMP, the plurality of segment lists may include a first segment list path and a second segment list path, where the first segment list path is a path from the first network device to the second network device, and the second segment list path is a path from the second network device to the first network device, where the first segment list path is used to characterize the first tunnel and the second segment list path is used to characterize the second tunnel.
For example, as shown in fig. 1, the first segment of the list path is "MC1- > P1- > PE3" or "MC2- > P1- > PE3", and the first tunnel characterized is "ACC- > MC1- > P1- > PE3" or "ACC- > MC2- > P1- > PE3"; the second segment list path is "MC1- > P1- > ACC" or "MC2- > P1- > ACC", and the second tunnel characterized is "PE3- > P1- > MC1- > ACC" or "PE3- > P1- > MC2- > ACC".
In some possible implementations, the first segment list path and the second segment list path may be forward and backward common. For example, the first segment of the list path is "MC1- > P1- > PE3", the first tunnel characterized is "ACC- > MC1- > P1- > PE3", and the second segment of the list path is "MC1- > P1- > ACC", and the second tunnel characterized is "PE3- > MC1- > P1- > ACC". Alternatively, the first-segment list path is "MC2- > P1- > PE3", the first tunnel characterized is "ACC- > MC2- > P1- > PE3", and the second-segment list path is "MC2- > P1- > ACC", and the second tunnel characterized is "PE3- > MC2- > P1- > ACC".
It should be noted that the first tunnel represented by the first segment list path and the second tunnel represented by the second segment list path may be created in advance. In some possible implementations, the first segment list path or the second segment list path may be a strict path, a loose path, or a strictly and loosely mixed path, which is not limited herein. The forwarding between two adjacent network devices in the first segment list path or the second segment list path may BE implemented through policy, or may BE implemented through Best Effort (BE), which is not limited herein.
In this embodiment, when the first network device generates the first detection packet, the first segment list path and the second segment list path may be pushed in sequence in a header of the first detection packet. It should be noted that in the SRH of SRv, the IPv6 address of the first push is read first, and the IPv6 address of the second push is read later. For example, in the first detection packet shown in table 1, the first section list path and the second section list path are pushed in sequence, and the first detection packet may be as shown in table 2 below:
TABLE 2
Figure BDA0003186924000000081
As shown in table 2, the first segment list path includes a plurality of segment list segments, mc1.End, p1.End, and pe3.End. The second segment list path includes a plurality of segment list: PE3.END, P1.END, MC1.END and 1: 1. In addition, SL is used to indicate which segment list is currently pointed to.
Exemplarily, in the first detection message as shown in table 2, let SA = ACC::1, where ACC::1 denotes the IPv6 address that needs to be filled in on the SA when encapsulating the first detection message based on SRv. In some possible implementations, ACC::1 can take the value 1::1.
Exemplarily, when SL =5, the mc1.End is pointed; when SL =4, P1 is pointed; when SL =3, point to pe3.End; when SL =2, p1.End is pointed; when SL =1, point to mc1.End; when SL =0, 1::1, i.e. the IPv6 address of the first network device (ACC). Where SL =5 directed mc1.End, SL =4 directed p1.End, and SL =3 directed pe3.End make up a first-segment list path, SL =3 directed pe3.End, SL =2 directed p1.End, SL =1 directed pe3.End, and SL =0 directed 1::1 (i.e., the IPv6 address of the ACC) make up a second-segment list path.
Note that as shown in table 1, DA is set to 1::1, and after the first-stage list path and the second-stage list path are pushed in sequence, table 2 is obtained, DA is set to the position pointed by SL =5, i.e., mc1.End, and the position pointed by SL =0 is set to the original value 1::1 of DA, as the final destination address. It should be noted that, in the forwarding process of the first detection packet, the value of DA changes with the change of the value of SL, that is, points to different segment lists, so as to instruct the forwarding of the first detection packet.
Note that ". END" indicates a type of Segment Identifier (SID), and indicates an IPv6 address of a network device. For example, mc1.End indicates the IPv6 address of MC1, and pe3.End indicates the IPv6 address of PE3. Wherein a segment list includes a SID.
In some possible implementations, the second segment list path is compressed onto a Binding Segment Identifier (BSID). ". BSID" represents a type of Segment Identifier (SID) indicating a SID in which specific information is embedded. In some possible implementations, the BSID may be an index, and the network device may query corresponding information (e.g., information of the second-segment list path corresponding to the BSID) according to the index. For example, if information corresponding to one BSID is published on the network in a flooding manner in advance, the network device may store the information of the BSID, and when receiving the BSID, may query the stored information. In some possible implementations, when the network device receives the BSID, the network device may also query the network controller for information corresponding to the BSID, which is not limited herein.
For example, in the first detection message shown in table 2, the p1.End indicating that SL =2 points and the mc1.End indicating that SL =1 points in the second segment list are compressed in the BSID, and then the point of the value of SL is updated, so as to obtain the first detection message shown in table 3:
TABLE 3
Figure BDA0003186924000000091
Then, when the PE3 receives the first detection packet, changing SL =2 to SL =1, the PE3.Bsid is pointed, the values of p1.End and mc1.End are obtained by reading the value of the PE3.Bsid, and then the PE3.Bsid can be pushed in the first detection packet by means of encaps or insert to indicate the backhaul of the first detection packet. Specifically, the ways of encaps or insert and the forwarding process of the first detection packet will be described in detail in the following steps 205 to 207, which are not described herein again.
In some possible implementations, the IPv6 addresses of any consecutive plurality of network devices as shown in table 2 may be compressed in one BSID, which is not limited herein. For example, in the first detection message shown in table 2, pe3.End indicating that SL =3 points to, p1.End indicating that SL =2 points to, and mc1.End indicating that SL =1 points to in the second segment list are compressed in BSID, and then the point of the value of SL is updated, the first detection message shown in table 4 is obtained:
TABLE 4
Figure BDA0003186924000000092
Then, when P1 receives the first detection packet and prepares to forward, SL =2 is changed to SL =1 to point to pe3.Bsid, and the values of pe3.End, P1.End, and mc1.End are obtained by reading pe3.Bsid, where the expansion mode of pe3.Bsid may be encaps or insert, which is described in step 206 below.
For another example, in the first detection message shown in table 2, pe3.End indicating that SL =3 points and p1.End indicating that SL =2 points in the second segment list are compressed in BSID, and then the point of the value of SL is updated, so as to obtain the first detection message shown in table 5:
TABLE 5
Figure BDA0003186924000000101
Then, when P1 receives the first detection packet and prepares for forwarding, the value of SL changes from 3 to 2, which points to P1.Bsid, and by reading P1.Bsid, it expands in encaps or insert manner to obtain the values of pe3.End and P1.End, and then pushes in the first detection packet to indicate that the first detection packet continues to be forwarded.
(II) scenarios of bilateral TWAMP.
In this embodiment of the present application, for a bilateral TWAMP scenario, the SRH may include a first segment list path, and carry information of a second segment list path through a payload. Illustratively, when the first network device generates the first detection packet, it only needs to push the first segment of the list path in the first detection packet, and then carries the information of the second segment of the list path in the load. Then, after the first detection message received by the second network device, the information of the second segment list path is obtained from the load, and then the second segment list path is pushed to the first detection message and forwarded to the first detection message.
For example, if the first network device sets the DA of the first detection packet to the IPv6 address of the second network device, for example, 1::2, then before the push segment list, the first detection packet may be as shown in table 6 below:
TABLE 6
DA=1::2
SA=1::1
Load(s)
Then, when the first network device generates the first detection packet, the first segment list path is pushed in the header of the first detection packet. For example, in the first detection message shown in table 6, the first segment list path is pushed, and the first detection message may be as shown in table 7 below:
TABLE 7
Figure BDA0003186924000000102
As shown in table 7, in the case of the first detection packet, when SL =2, the pointed IPv6 address is the IPv6 address of MC 1; when SL =1, p1.End is pointed; when SL =0, 1::2 (i.e. IPv6 address of PE 3) is pointed to. Wherein the SL =2 directed mc1.End, SL =1 directed p1.End, and SL =0 directed pe3.End represent the first-segment list path. In this embodiment, the second segment list path may be carried in the payload, and includes the IPv6 addresses of PE3, P1, and ACC.
Note that as shown in table 6, DA is set to 1::2, and after the first segment of the list path is pushed, table 7 is obtained, DA is set to the position to which SL =0 points, i.e., mc1.End, and SL =0 points is set to 1::2. When the second network device (PE 3) generates the first detection packet as shown in table 7, since SL =5 currently, the DA is changed to the IPv6 address of MC1, which is denoted by mc1. End.
In some possible implementations, as shown in table 7, IPv6 addresses of any consecutive multiple network devices may be compressed in one BSID, and for a specific implementation, please refer to the description in the foregoing scenario of one-arm TWAMP, which is not described herein again.
4. And (5) quintuple.
In this embodiment, the first detection packet may further carry a five-tuple (a source network protocol (IP) address, a source port, a destination IP address, a destination port, and a transport layer protocol). In some possible implementations, if the quintuple of the two detection packets is the same, the two detection packets may be regarded as belonging to the same TWAMP instance.
5. Session identification (session id).
In some feasible implementation manners, the first detection packet may further carry a session identifier (session id), and when the five-tuple and the session identifier of the two detection packets are the same, the two detection packets may be regarded as belonging to the same TWAMP instance. Then, when the five tuples of the two detection messages are different and the session identifiers are the same, or the five tuples of the two detection messages based on TWAMP are the same and the session identifiers are different, the two detection messages are also considered as belonging to two different TWAMP instances. Then, by setting the session identification, all TWAMP instances are made to use the same source port number or the same destination port number, thereby saving the use of port numbers.
203. The first network equipment sends a first detection message.
In some possible implementations, the first detection packet may include multiple detection packets having the same five-tuple (or the same five-tuple and the session identifier).
It should be noted that, when the first detection packet is sent, a sending timestamp may be added to the first detection packet. In some possible implementations, the first network device may continuously send the multiple detection packets in the first detection packet in a short time, for example, 10 detection packets are sent within 1 second, or may send the multiple detection packets in the first detection packet in a timed manner, for example, one detection packet is sent every 0.1 second. It should be noted that the sending timestamp is used for calculating the time delay, and when the first network device receives the first detection packet, the time delay of the first detection packet may be calculated by receiving the receiving time point of the first detection packet and the sending timestamp in the first detection packet.
In some possible implementations, after the first tunnel is created, a tunnel identifier may be obtained, and a tunnel interface may be allocated to the first tunnel in the first network device. And corresponding the tunnel identifier with a tunnel interface, and in order to ensure that the data message is sent through the first tunnel, sending a first detection message through the tunnel interface of the first tunnel by the first network equipment.
204. The first network device monitors the first detection message.
In this embodiment of the present application, after the first network device sends the first detection packet, the first detection packet may be monitored. In some possible implementations, two detection packets belonging to the same TWAMP instance are considered as the same detection packet. For example, if the five tuples of the two detection packets are the same, the two detection packets are regarded as belonging to the same TWAMP instance, i.e. as the same detection packet. Or, if the five tuples and the session identifiers of the two detection packets are the same, the two detection packets are regarded as belonging to the same TWAMP instance, that is, as the same detection packet.
For example, when the first network device receives the second detection packet, if the DA of the second detection packet is the local address of the first network device, the quintuple of the second detection packet is further obtained, and the table is queried and calculated according to the quintuple, so as to determine whether the second detection packet is the TWAMP packet. And if the second detection message hits in the computation table, determining that the second detection message is the TWAMP message. And then the first network equipment acquires the session identifier of the second detection message, and then queries a corresponding session table of the TWAMP according to the session identifier. If a specific TWAMP instance is hit and the first detection message belongs to the TWAMP instance, the second detection message is determined to be the first detection message.
205. And the second network equipment receives the first detection message.
For example, as shown in fig. 2-2, a schematic diagram of a forwarding process of a first detection packet between a first network device (ACC), an MC1, a P1, and a second network device (PE 3) is shown. When the first network device is ready to send the first detection packet as shown in table 2, if the segment list in the SRH and SL =5 point to the mc1.End, the DA is set to "DA = mc1.End", that is, MC1 is the next destination network device. As can be seen from fig. 1, there may be two paths from the first network device (ACC) to MC1, one is ACC- > AGG1- > MC1 and one is ACC- > AGG2- > MC1. By means of a preset policy or BE, the first network device (ACC) may select one of the paths, for example, ACC- > AGG1- > MC1 is selected.
After MC1 receives the first detection packet, if SL =4, the packet is directed to P1.End, and DA is set to "DA = P1.End", that is, P1 is the next destination network device. Then, MC1 forwards the first detection packet to P1. As can be seen from FIG. 1, there can be two paths from MC1 to P1, one is MC1- > PE1- > P1, and the other is MC1- > MC2- > PE2- > PE1- > P1. By means of a preset policy or BE, MC1 may select one of the paths, for example, MC1- > PE1- > P1 is selected.
After the P1 receives the first detection packet, if SL =3, the packet is directed to pe3.End, and the DA is set to "DA = pe3.End", that is, the PE3 is the next destination network device. Then, P1 forwards the first detection packet to PE3. As shown in fig. 1, PE3 is a network device adjacent to P1, and P1 directly forwards the first detection packet to PE3 through a corresponding interface. In some possible implementation manners, if a link between PE3 and P1 fails, PE3 may also forward the first detection packet to P1 through the standby link.
Through the forwarding process, the second network device (PE 3) receives the first detection message. It should be noted that if the SLA quality of the tunnel is poor, there is an opportunity for packet loss at each step of the above process. If packet loss occurs, the first detection message cannot be sent to the second network device (PE 3). In some possible implementations, since the first detection packet is a UDP packet, if a packet loss occurs, retransmission is not performed.
Similarly, the forwarding process of the first detection packet in table 3 is shown in fig. 2-3, and is similar to the forwarding process described above, and is not described herein again. The forwarding process of the first detection packet in table 4 or 5 is similar to the forwarding process of the first detection packet in table 2 or 3, and is not described herein again. For the method for processing BSID in the first detection message with BSID as shown in table 4 or 5, please refer to step 206 below, which is not described herein again.
206. And the second network equipment forwards the first detection message according to the second section list path.
In this embodiment of the present application, after receiving the first detection packet, the second network device forwards the first detection packet according to the second segment list path. The following describes the forwarding method of the first detection packet by the second network device in the scenarios of the one-arm TWAMP and the two-side TWAMP, respectively.
One scenario for one-arm TWAMP.
For example, as shown in fig. 2 to 4, schematic diagrams of a forwarding process of a first detection packet between a second network device (PE 3), a P1, an MC1, and a first network device (ACC) are shown.
If the first detection message is shown in table 2, after the second network device (PE 3) receives the first detection message, if SL =2, the second network device points to P1.End, and DA is set to "DA = P1.End", that is, P1 is the next destination network device. Then, the second network device (PE 3) forwards the first detection message to P1. As shown in fig. 1, P1 is a network device adjacent to PE3, and PE3 directly forwards the first detection packet to P1 through a corresponding interface. In some possible implementation manners, if a link between P1 and PE3 fails, P1 may also forward the first detection packet to PE3 through the standby link.
After P1 receives the first detection message, if SL =1, it points to mc1.End, and DA is set to "DA = mc1.End", that is, MC1 is the next destination network device. Then, P1 forwards the first detection packet to MC1. As can be seen from FIG. 1, there can be two paths from P1 to MC1, one is P1- > PE1- > MC1, and the other is P1- > PE1- > PE2- > MC2- > MC1. By means of a preset policy or BE, P1 may select one of the paths, for example, P1- > PE1- > MC1 is selected.
When MC1 receives the first detection message, let SL =0 point to 1::1, and set DA to "DA =1::1", that is, the network device (i.e., ACC, first network device) whose IPv6 address is 1::1 is the next destination network device. Then, MC1 forwards the first detection packet to the first network device (ACC). As can be seen from FIG. 1, there are two routes from MC1 to ACC, one is MC1- > AGG1- > ACC and one is MC1- > MC2- > AGG2- > AGG1- > ACC. By means of a preset policy or BE, MC1 may select one of the paths, for example, MC1- > AGG1- > ACC is selected.
Through the forwarding process, the first network device (ACC) receives the first detection packet. It should be noted that, if the SLA quality of the tunnel is poor, there is an opportunity for packet loss at each step of the above process. If the packet loss occurs, the first detection message cannot be sent to the first network equipment (ACC).
Similarly, for the first detection packet in table 7, the forwarding process is similar to the forwarding process described above, and details are not described here.
For another example, if the first detection message is shown in table 3, when the second network device (PE 3) receives the first detection message, if SL =1 indicates pe3.Bsid, then the second network device (PE 3) acquires the segment list path indicated in pe3. Bsid. In the example shown in table 3, the pe3.Bsid indicates the second segment list path, and the second network device (PE 3) may expand the pe3.Bsid to obtain information of the second segment list path. In some possible implementations, the second network device (PE 3) may be deployed by means of encapsulation (encaps) or insertion (insert). The manner of encaps or insert, respectively, is described below.
(1) encaps.
It should be noted that encaps uses the current first detection packet as a load, so as to perform encapsulation to obtain a new first detection packet, and then pushes the second segment of list path in the BSID in the new first detection packet. Exemplarily, as shown in fig. 2 to 5, it is a schematic diagram of a forwarding process of a first detection packet between a second network device (PE 3), a P1, an MC1 and a first network device (ACC).
For the first detection packet shown in table 3, let SL =0, that is, point to 1::1, then set DA to "DA =1::1", that is, the network device (that is, ACC, first network device) whose IPv6 address is 1::1 is the next destination network device, and obtain the first detection packet shown in table 8:
TABLE 8
Figure BDA0003186924000000141
Then, the BSID is expanded by encaps to obtain a first detection packet as shown in table 9:
TABLE 9
Figure BDA0003186924000000142
If the load in the first detection message shown in table 9 is the first detection message shown in table 8, the first detection message shown in table 10 is obtained:
watch 10
Figure BDA0003186924000000143
Then, as shown in table 9 (or table 10), since SL =2, P1.End is pointed, DA is set to "DA = P1.End", that is, P1 is the next destination network device. Then, the second network device (PE 3) forwards the first detection message to the P1. As shown in fig. 1, P1 is a network device adjacent to PE3, and PE3 directly forwards the first detection packet to P1 through a corresponding interface. In some possible implementation manners, if a link between PE3 and P1 fails, PE3 may also forward the first detection packet to P1 through the standby link.
After P1 receives the first detection packet, if SL =1, it points to mc1.End, and then sets DA to "DA = mc1.End", that is, MC1 is the next destination network device. Then, P1 forwards the first detection packet to MC1. As can be seen from FIG. 1, there can be two paths from P1 to MC1, one being P1- > PE1- > MC1 and one being P1- > PE1- > PE2- > MC2- > MC1. By means of a preset policy or BE, P1 may select one of the paths, for example, P1- > PE1- > MC1 is selected.
When MC1 receives the first detection message, let SL =0 point to 1::1, and set DA to "DA =1::1", that is, the network device (i.e., ACC, first network device) whose IPv6 address is 1::1 is the next destination network device. Then, MC1 forwards the first detection packet to the first network device (ACC). As can be seen from FIG. 1, there are two routes from MC1 to ACC, one is MC1- > AGG1- > ACC and one is MC1- > MC2- > AGG2- > AGG1- > ACC. By means of a preset policy or BE, MC1 may select one of the paths, for example, MC1- > AGG1- > ACC.
It should be noted that, when the MC1 sends the first detection packet to the first network device (ACC), the MC1 executes the last-hop SRH segment information pop-Up (USP), so as to obtain the first detection packet shown in table 11:
TABLE 11
Figure BDA0003186924000000151
If mc1.End is a Penultimate Segment Pop (PSP) mode, then MC1 strips the SRH of the first detection packet to obtain the first detection packet as shown in table 12:
TABLE 12
Figure BDA0003186924000000152
In fig. 2-5, the mc1.End is taken as the PSP mode as an example, that is, the MC1 forwards the first detection packet shown in table 12 to the first network device (ACC). When MC1 sends the first detection packet to the first network device (ACC), if the mc1.End is in no PSP mode, then MC1 does not need to strip the SRH of the first detection packet, i.e. forwards it to the first network device (ACC), i.e. the first detection packet shown in table 11.
Through the forwarding process, the first network device (ACC) receives the first detection packet. It should be noted that if the SLA quality of the tunnel is poor, there is an opportunity for packet loss at each step of the above process. If the packet loss occurs, the first detection message cannot be sent to the first network equipment (ACC). Similarly, the forwarding process of the first detection packet in table 4 and table 5 is similar to the above forwarding process, and is not described herein again.
(2) Manner of insert.
It should be noted that the insert method is to directly expand the current first detection packet at the BSID position to obtain a new first detection packet, and then directly insert the second segment list path into the first segment list path in the new first detection packet.
Exemplarily, as shown in fig. 2 to 6, it is a schematic diagram of a forwarding process of a first detection packet between a second network device (PE 3), a P1, an MC1 and a first network device (ACC). For the first detection packet shown in table 3, the BSID is expanded in an encaps manner, so as to obtain the first detection packet shown in table 13:
watch 13
Figure BDA0003186924000000161
Setting SA as the local address of the second network device, i.e. PE3.END, successively pushing MC1.END and ACC. END to 1::1, modifying the direction of SL (as shown in Table 14), making SL =2 (i.e. pointing to SID on 1:: 1), setting DA as the segment list pointed by SL =2, i.e. P1.END, i.e. P1 is the next destination network device. Then, the second network device (PE 3) forwards the first detection message to the P1. As shown in fig. 1, P1 is a network device adjacent to PE3, and PE3 directly forwards the first detection packet to P1 through a corresponding interface. In some possible implementation manners, if a link between PE3 and P1 fails, PE3 may also forward the first detection packet to P1 through the standby link.
After P1 receives the first detection message, if SL =1, it points to mc1.End, and DA is set to "DA = mc1.End", that is, MC1 is the next destination network device. Then, P1 forwards the first detection packet to MC1. As can be seen from FIG. 1, there can be two paths from P1 to MC1, one is P1- > PE1- > MC1, and the other is P1- > PE1- > PE2- > MC2- > MC1. By means of a preset policy or BE, P1 may select one of the paths, for example, P1- > PE1- > MC1 is selected.
When MC1 receives the first detection message, let SL =0 point to 1::1, and set DA to "DA =1::1", that is, the network device (i.e., ACC, first network device) whose IPv6 address is 1::1 is the next destination network device. Then, MC1 forwards the first detection packet to the first network device (ACC). As can be seen from FIG. 1, there are two pathways from MC1 to ACC, one is MC1- > AGG1- > ACC and one is MC1- > MC2- > AGG2- > AGG1- > ACC. By means of a preset policy or BE, MC1 may select one of the paths, for example, MC1- > AGG1- > ACC.
When MC1 sends the first detection packet to the first network device (ACC), MC1 executes USP to obtain the first detection packet as shown in table 14:
TABLE 14
Figure BDA0003186924000000171
If mc1.End is in PSP mode, MC1 strips the SRH of the first detection packet to obtain the first detection packet as shown in table 12, and then forwards it to the first network device (ACC). When MC1 sends the first detection packet to the first network device (ACC), if mc1.End is in the reciprocal no PSP mode, then MC1 does not need to strip the SRH of the first detection packet, i.e. forwards it to the first network device (ACC), i.e. the first detection packet shown in table 15:
watch 15
Figure BDA0003186924000000172
Through the forwarding process, the first network device (ACC) receives the first detection packet. It should be noted that if the SLA quality of the tunnel is poor, there is an opportunity for packet loss at each step of the above process. If the packet loss occurs, the first detection message cannot be sent to the first network equipment (ACC).
In some possible implementations, the second network device (PE 3) may decide on its own, using either encaps or insert. In some possible implementations, it may be determined that the first detection packet is good by using encaps or insert. In some possible implementations, the manner in which encaps or insert are used may also be determined by the controller, and, for example, the second network device (PE 3) queries the controller to determine the manner in which encaps or insert are used. And is not limited herein.
And (II) a bilateral TWAMP scene.
For example, as shown in fig. 2 to 7, schematic diagrams of a forwarding process of a first detection packet between a second network device (PE 3), a P1, an MC1, and a first network device (ACC) are shown. If the first detection packet is shown in table 7, after the second network device (PE 3) receives the first detection packet, the information of the second segment list path is obtained from the load of the first detection packet: "P1- > MC1- > ACC", then the second network device may generate the first detection packet as shown in table 16:
TABLE 16
Figure BDA0003186924000000181
Where SL =2, i.e. setting "DA = P1.End", i.e. P1 is the next destination network device. Then, the second network equipment (PE 3) forwards the first detection message to P1, P1 forwards the first detection message to MC1 according to SRH, and MC1 forwards the first detection message to ACC according to SRH. The specific process of forwarding the first detection packet among the second network device (PE 3), P1, MC1, and ACC is similar to the foregoing, and is not described herein again. Any section in the second section list path can be compressed into the BSID, then for any network device receiving the first detection message, if the value of SL points to the BSID, the BSID is expanded, and the first detection message is forwarded according to the expanded path information. The specific expansion manner (encaps manner or insert manner) of the BSID and the corresponding forwarding method are similar to the foregoing, and are not described herein again.
207. The first network device receives the first detection message.
For example, if in a single-arm TWAMP scenario, the first network device generates and sends the first detection packet shown in table 2 in step 202, and when the first network device receives the first detection packet, SL =0 points to 1::1, that is, the DA is set to obtain the first detection packet shown in table 17 below:
TABLE 17
Figure BDA0003186924000000182
Since SL =0, the first network device executes the last segment to execute outer IPv6 decapsulation (USD), that is, removes the SRH in the first detection packet, which is shown in table 18:
watch 18
DA=1::1
SA=ACC::1
Load(s)
For another example, if in the scenario of two-way TWAMP, the first network device generates and sends the first detection packet shown in table 7 in step 202, and when the first network device receives the first detection packet, SL =0 points to 1::1, that is, the DA is set to obtain the first detection packet shown in table 19 below:
watch 19
Figure BDA0003186924000000191
Since SL =0, the first network device executes the last segment to execute outer IPv6 decapsulation (USD), that is, removes the SRH in the first detection packet, which is shown in table 20:
watch 20
DA=1::1
SA=PE3::1
Load(s)
Then, the first network device obtains a quintuple (or a quintuple and a session identifier) in the received detection message, and determines that the first detection message is received according to the quintuple (or the quintuple and the session identifier).
It should be noted that, for the first detection packet sent by the first network device, for example, in table 3, table 4, or table 5, when the first network device receives the first detection packet, the processing manner is similar to that described above, and details are not described here.
208. The first network device detects the SLA quality of the first tunnel and the second tunnel.
In the embodiment of the present application, the SLA quality includes a packet loss rate, a time delay, and jitter. The following description will be made separately.
1. And (4) the packet loss rate.
In some possible implementations, the first network device may send multiple detection packets, where the detection packets have the same five-tuple (or the same five-tuple and the same session identifier), and the first detection packet includes the multiple detection packets. After receiving the first detection message, the first network device checks the number of the received first detection messages to determine the packet loss rate. For example, the first network device sends 100 first detection packets, and if 99 first detection packets are received, it is determined that the packet loss rate is 1%. In some possible implementation manners, the first network device may send a plurality of first detection packets for multiple times, then count the packet loss rate each time, and then obtain an average value to obtain a more accurate packet loss rate.
2. And (4) time delay.
For example, the first network device determines the bidirectional delay of the first detection packet according to the receiving time point of the first detection packet and the sending timestamp of the first detection packet.
3. And (4) dithering.
It should be noted that jitter, i.e. delay jitter, is used to characterize the change of delay. In some possible implementations, the first network device may determine the jitter of the first tunnel or the second tunnel according to a time delay (or a bi-directional time delay).
It should be noted that, for simplicity of description, the above-mentioned method embodiments are described as a series of acts or combination of acts, but those skilled in the art will recognize that the present application is not limited by the order of acts described, as some steps may occur in other orders or concurrently depending on the application. Further, those skilled in the art should also appreciate that the embodiments described in the specification are preferred embodiments and that the acts and modules referred to are not necessarily required in this application.
To facilitate better implementation of the above-described aspects of the embodiments of the present application, the following also provides relevant means for implementing the above-described aspects.
Referring to fig. 3, a network device 300 provided in an embodiment of the present application, serving as a first network device, may include: a transceiver module 301 and a processing module 302. Wherein, the first and the second end of the pipe are connected with each other,
the processing module 302 is configured to generate a first detection packet, where the first detection packet carries a first segment list path and a second segment list path, the first segment list path is used to represent a first tunnel, the second segment list path is used to represent a second tunnel, the first tunnel is a tunnel from a first network device to a second network device, and the second tunnel is a tunnel from the second network device to the first network device. The transceiver module 301 is configured to send a first detection packet. The transceiver module 301 is further configured to monitor the first detection packet.
In some possible implementations, the transceiver module 301 is specifically configured to: and sending a first detection message through a tunnel interface of a first tunnel, wherein the first tunnel is a tunnel created according to the first section list path.
In some possible implementations, the first segment list path and the second segment list path are forward and reverse co-routed.
In some possible implementations, the transceiver module 301 is further configured to receive a first detection packet. The processing module 302 is further configured to determine a bidirectional delay of the first detection packet according to a receiving time point of the first detection packet and a sending timestamp of the first detection packet.
In some possible implementations, the transceiver module 301 is further configured to receive a second detection packet. The processing module 302 is further configured to obtain a session identifier and a five-tuple of the second detection packet. The processing module 302 is further configured to determine that the second detection packet is the first detection packet if the session identifier and the five-tuple of the second detection packet are the same as the session identifier and the five-tuple of the first detection packet.
In some possible implementations, the first detection packet is a TWAMP packet and takes effect, the TWAMP is configured and takes effect in the first network device, and the TWAMP is not configured or takes effect in the second network device. The first detection packet carries a first segment list path and a second segment list path, and specifically includes: the first section list path and the second section list path are successively pushed in the header of the first detection message, and the destination address of the first detection message is the local address of the first network equipment.
In some possible implementations, the first detection packet is a TWAMP packet, and the first network device and the TWAMP configured and validated in the first network device. The first detection message carrying the first segment list path and the second segment list path includes: and pushing the first section of list path in the header of the first detection message, and carrying the second section of list path in the load of the first detection message.
It should be noted that, because the contents of information interaction, execution process, and the like between the modules/units of the apparatus are based on the same concept as the method embodiment of the present application, the technical effect brought by the contents is the same as the method embodiment of the present application, and specific contents may refer to the description in the foregoing method embodiment of the present application, and are not described herein again.
The embodiment of the present application further provides a computer storage medium, where the computer storage medium stores a program, and the program executes some or all of the steps described in the above method embodiments.
Referring next to another network device 400 provided in an embodiment of the present application, which is used as a first network device, please refer to fig. 4, where the network device 400 includes:
a receiver 401, a transmitter 402, a processor 403, and a memory 404 (wherein the number of processors 403 in the network device 400 may be one or more, and one processor is taken as an example in fig. 4). In some embodiments of the present application, the receiver 401, the transmitter 402, the processor 403 and the memory 404 may be connected by a bus or other means, wherein fig. 4 illustrates the connection by a bus.
Memory 404, which may include both read-only memory and random-access memory, provides instructions and data to processor 403. A portion of memory 404 may also include non-volatile random access memory (NVRAM). The memory 404 stores an operating system and operating instructions, executable modules or data structures, or a subset or an expanded set thereof, wherein the operating instructions may include various operating instructions for performing various operations. The operating system may include various system programs for implementing various basic services and for handling hardware-based tasks.
Processor 403 controls the operation of network device 400, and processor 403 may also be referred to as a Central Processing Unit (CPU). In particular implementations, the various components of network device 400 are coupled together by a bus system that may include a power bus, a control bus, a status signal bus, etc., in addition to a data bus. For clarity of illustration, the various buses are referred to in the figures as a bus system.
The method disclosed in the embodiments of the present application may be applied to the processor 403, or implemented by the processor 403. The processor 403 may be an integrated circuit chip having signal processing capabilities. In implementation, the steps of the above method may be performed by integrated logic circuits of hardware or instructions in the form of software in the processor 403. The processor 403 may be a general-purpose processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a field-programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic device, or discrete hardware components. The various methods, steps, and logic blocks disclosed in the embodiments of the present application may be implemented or performed. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of the method disclosed in connection with the embodiments of the present application may be directly implemented by a hardware decoding processor, or implemented by a combination of hardware and software modules in the decoding processor. The software module may be located in ram, flash memory, rom, prom, or eprom, registers, etc. storage media as is well known in the art. The storage medium is located in the memory 404, and the processor 403 reads the information in the memory 404 and completes the steps of the method in combination with the hardware.
The receiver 401 may be configured to receive input numeric or character information and generate signal inputs related to related settings and function control of the network device, the transmitter 402 may include a display device such as a display screen, and the transmitter 402 may be configured to output numeric or character information through an external interface.
In this embodiment, the processor 403 is configured to execute the method for detecting tunnel quality based on SRv executed by the foregoing network device 400.
In another possible design, when the network device is a chip, the method includes: a processing unit, which may be, for example, a processor, and a communication unit, which may be, for example, an input/output interface, a pin or a circuit, etc. The processing unit may execute the computer-executable instructions stored in the storage unit to cause the chip in the terminal to execute the method for transmitting the wireless report information according to any one of the first aspect. Optionally, the storage unit is a storage unit in the chip, such as a register, a cache, and the like, and the storage unit may also be a storage unit located outside the chip in the terminal, such as a read-only memory (ROM) or another type of static storage device that can store static information and instructions, a Random Access Memory (RAM), and the like.
The processor mentioned in any of the above may be a general purpose central processing unit, a microprocessor, an ASIC, or one or more integrated circuits for controlling the execution of the programs of the above methods.
It should be noted that the above-described embodiments of the apparatus are merely schematic, where the units described as separate parts may or may not be physically separate, and the parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment. In addition, in the drawings of the embodiments of the apparatus provided in the present application, the connection relationship between the modules indicates that there is a communication connection therebetween, and may be implemented as one or more communication buses or signal lines.
Through the above description of the embodiments, those skilled in the art will clearly understand that the present application can be implemented by software plus necessary general-purpose hardware, and certainly can also be implemented by special-purpose hardware including special-purpose integrated circuits, special-purpose CPUs, special-purpose memories, special-purpose components and the like. Generally, functions performed by computer programs can be easily implemented by corresponding hardware, and specific hardware structures for implementing the same functions may be various, such as analog circuits, digital circuits, or dedicated circuits. However, for the present application, the implementation of a software program is more preferable. Based on such understanding, the technical solutions of the present application or portions contributing to the prior art may be substantially embodied in the form of a software product, where the computer software product is stored in a readable storage medium, such as a floppy disk, a usb disk, a removable hard disk, a ROM, a RAM, a magnetic disk, or an optical disk of a computer, and includes several instructions for enabling a computer device (which may be a personal computer, a server, or a network device) to execute the method according to the embodiments of the present application.
In the above embodiments, all or part of the implementation may be realized by software, hardware, firmware, or any combination thereof. When implemented in software, may be implemented in whole or in part in the form of a computer program product.
The computer program product includes one or more computer instructions. When loaded and executed on a computer, cause the processes or functions described in accordance with the embodiments of the application to occur, in whole or in part. The computer may be a general purpose computer, a special purpose computer, a network of computers, or other programmable device. The computer instructions may be stored in a computer readable storage medium or transmitted from one computer readable storage medium to another, for example, from one website site, computer, server, or data center to another website site, computer, server, or data center via wired (e.g., coaxial cable, fiber optic, digital Subscriber Line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.). The computer-readable storage medium can be any available medium that a computer can store or a data storage device, such as a server, a data center, etc., that is integrated with one or more available media. The usable medium may be a magnetic medium (e.g., floppy Disk, hard Disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium (e.g., solid State Disk (SSD)), among others.

Claims (20)

1. A tunnel quality detection method based on Internet protocol version 6 segmented routing SRv is characterized by comprising the following steps:
a first network device generates a first detection message, wherein the first detection message carries a first section list path and a second section list path, the first section list path is used for representing a first tunnel, the second section list path is used for representing a second tunnel, the first tunnel is a tunnel from the first network device to a second network device, and the second tunnel is a tunnel from the second network device to the first network device;
the first network equipment sends the first detection message;
and the first network equipment monitors the first detection message.
2. The method of claim 1, wherein sending, by the first network device, the first detection packet comprises:
and the first network equipment sends the first detection message through a tunnel interface of a first tunnel, wherein the first tunnel is a tunnel created according to the first section list path.
3. The method according to claim 1 or 2, wherein the first segment list path and the second segment list path are forward and backward common.
4. The method according to any of claims 1-3, wherein after the first network device listens for the first detection packet, further comprising:
the first network equipment receives the first detection message;
and the first network equipment determines the bidirectional time delay of the first detection message according to the receiving time point of the first detection message and the sending timestamp of the first detection message.
5. The method of claim 4, wherein the receiving, by the first network device, the first detection packet comprises:
the first network equipment receives a second detection message;
the first network equipment acquires a session identifier and a quintuple of the second detection message;
and if the session identifier and the quintuple of the second detection message are the same as the session identifier and the quintuple of the first detection message, the first network equipment determines that the second detection message is the first detection message.
6. The method according to any of claims 1-5, wherein the first detection packet is a two-way active measurement protocol, TWAMP, packet and is validated, the TWAMP is configured and validated in the first network device, and the TWAMP is not configured or validated in the second network device;
the first detection packet carries a first segment list path and a second segment list path, and specifically includes:
and the first section list path and the second section list path are successively pushed in the header of the first detection message, and the destination address of the first detection message is the local address of the first network equipment.
7. The method according to any of claims 1-6, wherein the second segment list path compression is in a binding segment identity, BSID.
8. The method of claim 7, wherein the BSID is expanded by an encaps method or an insert method.
9. The method according to any of claims 1-5, wherein the first detection packet is a TWAMP packet, and the first network device configure and validate TWAMP;
the first detection message carrying the first segment list path and the second segment list path includes:
and the header of the first detection message pushes the first section of list path, and the load of the first detection message carries the second section of list path.
10. A network device, operable as a first network device, comprising:
a processing module, configured to generate a first detection packet, where the first detection packet carries a first segment list path and a second segment list path, the first segment list path is used to represent a first tunnel, the second segment list path is used to represent a second tunnel, the first tunnel is a tunnel from the first network device to a second network device, and the second tunnel is a tunnel from the second network device to the first network device;
the receiving and sending module is used for sending the first detection message;
the transceiver module is further configured to monitor the first detection packet.
11. The network device of claim 10, wherein the transceiver module is specifically configured to:
and sending the first detection message through a tunnel interface of a first tunnel, wherein the first tunnel is a tunnel created according to the first segment list path.
12. The network device according to claim 10 or 11, wherein the first segment list path and the second segment list path are forward and backward shared.
13. The network device of any one of claims 10-12,
the transceiver module is further configured to receive the first detection packet;
the processing module is further configured to determine a bidirectional delay of the first detection packet according to a receiving time point of the first detection packet and a sending timestamp of the first detection packet.
14. The network device of claim 13,
the transceiver module is further configured to receive a second detection packet;
the processing module is further configured to obtain a session identifier and a quintuple of the second detection packet;
the processing module is further configured to determine that the second detection packet is the first detection packet if the session identifier and the quintuple of the second detection packet are the same as the session identifier and the quintuple of the first detection packet.
15. The network device according to any of claims 10-14, wherein the first detection packet is a TWAMP packet and is validated, the TWAMP is configured and validated in the first network device, and the TWAMP is not configured or validated in the second network device;
the first detection packet carries a first segment list path and a second segment list path, and specifically includes:
and the first section of list path and the second section of list path are successively pushed in the header of the first detection message, and the destination address of the first detection message is the local address of the first network device.
16. The network device of any of claims 10-14, wherein the first detection packet is a TWAMP packet, and wherein the first network device and the first network device configure and validate TWAMP;
the first detection message carrying the first segment list path and the second segment list path includes:
and the header of the first detection message pushes the first section of list path, and the load of the first detection message carries the second section of list path.
17. A computer-readable storage medium, characterized in that the computer-readable storage medium stores a program that causes a computer device to execute the method of any one of claims 1-9.
18. A computer program product, comprising computer executable instructions, the computer executable instructions being stored in a computer readable storage medium; at least one processor of a device reads the computer-executable instructions from the computer-readable storage medium, execution of the computer-executable instructions by the at least one processor causing the device to perform the method of any of claims 1-9.
19. A network device, comprising at least one processor, memory, and a communication interface;
the at least one processor is coupled with the memory and the communication interface;
the memory is configured to store instructions, the processor is configured to execute the instructions, and the communication interface is configured to communicate with other network devices under control of the at least one processor;
the instructions, when executed by the at least one processor, cause the at least one processor to perform the method of any of claims 1-9.
20. A chip system, characterized in that the chip system comprises a processor and a memory, the memory and the processor being interconnected by a line, the memory having stored therein instructions, the processor being adapted to perform the method according to any one of claims 1 to 9.
CN202110864909.1A 2021-07-29 2021-07-29 Tunnel quality detection method based on SRv and related device Pending CN115695246A (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN202110864909.1A CN115695246A (en) 2021-07-29 2021-07-29 Tunnel quality detection method based on SRv and related device
PCT/CN2022/107929 WO2023005927A1 (en) 2021-07-29 2022-07-26 Srv6-based tunnel quality measurement method and related apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110864909.1A CN115695246A (en) 2021-07-29 2021-07-29 Tunnel quality detection method based on SRv and related device

Publications (1)

Publication Number Publication Date
CN115695246A true CN115695246A (en) 2023-02-03

Family

ID=85058823

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110864909.1A Pending CN115695246A (en) 2021-07-29 2021-07-29 Tunnel quality detection method based on SRv and related device

Country Status (2)

Country Link
CN (1) CN115695246A (en)
WO (1) WO2023005927A1 (en)

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110971433B (en) * 2018-09-29 2022-02-22 华为技术有限公司 Method, device and system for acquiring SRv6 tunnel information
US10892967B2 (en) * 2018-12-21 2021-01-12 Cisco Technology, Inc. End-to-end path delay measurements in a network
CN110855531B (en) * 2019-12-02 2021-09-14 锐捷网络股份有限公司 Forwarding path detection method and device
CN112994961B (en) * 2019-12-02 2023-02-07 华为技术有限公司 Transmission quality detection method, device, system and storage medium
CN114650242A (en) * 2020-12-21 2022-06-21 华为技术有限公司 Path fault detection method, device, related equipment and storage medium

Also Published As

Publication number Publication date
WO2023005927A1 (en) 2023-02-02

Similar Documents

Publication Publication Date Title
CN109391560B (en) Network congestion notification method, proxy node and computer equipment
US11711288B2 (en) Centralized error telemetry using segment routing header tunneling
CN104506408A (en) Data transmission method and device based on SDN
US20230261962A1 (en) Method for Detecting Multicast Service Flow and Related Apparatus
US8599692B2 (en) System, apparatus and method for removing unwanted information from captured data packets
CN111371634B (en) Communication method, device and system
CN111026324B (en) Updating method and device of forwarding table entry
US11356372B2 (en) Data traffic processing method, device, and system
CN113055293B (en) Routing method and device in software defined wide area network and communication system
US20230327983A1 (en) Performance measurement in a segment routing network
CN114826973A (en) Transmission quality detection method, device and system
CN109150707B (en) Routing path analysis method and device
WO2022121638A1 (en) Packet processing method and device
CN115695246A (en) Tunnel quality detection method based on SRv and related device
CN112332956B (en) Information sharing method and device in redundant network and computer storage medium
CN115242699A (en) Message transmission method, slice generation method, device and system
CN115208781A (en) Transmission method, device and system for detection message
CN111953786A (en) System, method and device for recording messages in whole network, network equipment and storage medium
CN114006780A (en) Method, equipment and system for forwarding message
CN111884950B (en) Data transmission method, target switch, designated switch and switch system
CN114567679B (en) Data transmission method and device
CN108881015B (en) Message broadcasting method and device
US20230216780A1 (en) Method and apparatus for failure detection and pe device
WO2024021878A1 (en) Method for sending load information, method for sending message, and apparatus
CN116781498A (en) Flow analysis system, method and related equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication