Delay measurement method and equipment
By utilizing the stable transmission delay characteristics and timestamp calculation of the reference packet, combined with the reference delay information table and the global satellite navigation system module, the accuracy and cost issues of end-to-end one-way delay measurement in the 5G network are solved, achieving accurate and low-cost delay measurement.
Patent Information
- Application Number
- CN202110194450.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-02-20
- Publication Date
- 2025-09-12
- Estimated Expiration
- 2041-02-20
AI Technical Summary
Existing 5G network end-to-end one-way delay measurement methods have problems with insufficient measurement accuracy and high deployment costs. In particular, measurement solutions based on round-trip communication delay have low accuracy, while solutions based on time synchronization are difficult to deploy.
The stable transmission delay characteristics of the reference packet are adopted. By sending and receiving the reference packet and the measured packet between the sending device and the receiving device, and calculating the delay using the timestamp, the transmission delay of the measured packet is calculated by combining the reference delay information table and the global satellite navigation system module for time synchronization.
The accuracy of end-to-end one-way network delay measurement is improved, the measurement process is simplified, and the measurement cost is reduced. It can accurately measure end-to-end one-way network delay without deploying clock synchronization.
Smart Images

Figure CN115038109B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of mobile communication technology, and in particular to a delay measurement method and device. Background Art
[0002] With the gradual rollout of next-generation network technologies (such as 5G networks) and their implementation across numerous industries, ensuring network quality through service-level agreements (SLAs) is becoming increasingly important. For example, different 5G services have varying requirements for network performance metrics such as latency, jitter, packet loss, and bandwidth, as shown in Table 1. The latency metric for 5G networks is defined as the end-to-end one-way latency of the network.
[0003]
[0004] Table 1
[0005] A common scenario for network end-to-end one-way delay measurement is 5G network high-definition video surveillance business scenarios, such as Figure 1 As shown. One end of the network is the high-definition video surveillance service access device, as shown on the left side of the figure; the other end of the network is the video server (server); the end-to-end one-way delay measurement of the above network is the one-way delay from the video surveillance user access side to the video server user side, including the wireless network, transmission network, core network and IP bearer network. The delay is Figure 1 The sum of T1+T2+T3+T4.
[0006] Accurately measuring the end-to-end one-way network delay is crucial for ensuring the SLA of network services and has become an urgent and important requirement. Summary of the Invention
[0007] At least one embodiment of the present invention provides a delay measurement method, terminal, and network device, which can improve the accuracy of network end-to-end one-way delay measurement results, simplify the measurement process, and reduce measurement costs.
[0008] According to one aspect of the present invention, at least one embodiment provides a delay measurement method, including:
[0009] The second device receives a first reference packet sent by the first device, records a first reception timestamp of the first reference packet, and extracts a first transmission timestamp from the first reference packet; and receives a first tested packet sent by the first device, records a second reception timestamp of the first tested packet, and extracts a second transmission timestamp from the first tested packet.
[0010] The second device calculates the transmission delay of the first tested packet from the first device to the second device based on the first sending timestamp, the first receiving timestamp, the second sending timestamp, the second receiving timestamp and the first reference delay information related to the transmission of the first reference packet from the first device to the second device; wherein, the transmission of the first reference packet from the first device to the second device adopts end-to-end transmission delay guarantee technology.
[0011] Furthermore, according to at least one embodiment of the present invention, calculating the transmission delay of the first measured packet from the first device to the second device based on the first sending timestamp, the first receiving timestamp, the second sending timestamp, the second receiving timestamp, and information related to a first reference delay for transmitting a reference packet from the first device to the second device includes:
[0012] The transmission delay of the first measured packet from the first device to the second device is calculated according to the following formula:
[0013] Dtarget=Tr2+Ts1-Tr1-Ts2+Dref
[0014] Among them, Ts1, Ts2, Tr1, Tr2 and Dref respectively represent the first sending timestamp, the second sending timestamp, the first receiving timestamp, the second receiving timestamp and the first reference delay related information, and Dtarget represents the transmission delay of the first measured packet from the first device to the second device.
[0015] Furthermore, according to at least one embodiment of the present invention, before calculating the transmission delay of the first measured packet from the first device to the second device, the method further includes:
[0016] With the first device as a sending device and the second device as a receiving device, a reference delay information table is searched to obtain information related to a first reference delay of transmitting a first reference packet from the first device to the second device.
[0017] Furthermore, according to at least one embodiment of the present invention, the receiving, by the second device, the first reference packet sent by the first device specifically includes:
[0018] The second device receives at least one reference packet sent by the first device, and selects a reference packet from the at least one reference packet that is closest in reception time to the first packet under test as the first reference packet.
[0019] Furthermore, according to at least one embodiment of the present invention, information related to a reference delay of transmitting the reference packet between a transmitting device and a receiving device is obtained according to the following steps:
[0020] Configuring a network forwarding device with an equal-length period T, wherein the network forwarding device applies a preset scheduling and priority forwarding technology to forward reference packets, and the sum of the processing delay and queue buffering delay of the reference packets within the device is equal to the equal-length period T;
[0021] Determine the number of routing hops and the total link length between the sending device and the receiving device according to the network topology and routing rules, and determine the total link transmission time according to the total link length;
[0022] The product of 2T and the number of routing hops is calculated and added to the total link transmission time to obtain information related to a reference delay of transmitting a reference packet from the sending device to the receiving device.
[0023] Furthermore, according to at least one embodiment of the present invention, information related to a reference delay of transmitting the reference packet between a transmitting device and a receiving device is obtained according to the following steps:
[0024] Connecting a global satellite navigation system module to the sending device and the receiving device respectively, and performing time synchronization on the sending device and the receiving device through the global satellite navigation system module;
[0025] receiving a reference packet sent by the sending device, recording a receiving timestamp of the reference packet, and extracting a sending timestamp from the reference packet;
[0026] Information related to a reference delay of transmitting the reference packet from the transmitting device to the receiving device is calculated based on the transmitting timestamp and the receiving timestamp.
[0027] In addition, according to at least one embodiment of the present invention, the first reference packet and the first measured packet each include a measurement header including an identifier of the first device as a sending device, an identifier of the second device as a receiving device, and a corresponding sending timestamp.
[0028] According to another aspect of the present invention, at least one embodiment provides a delay measurement method, including:
[0029] The first device adds a first sending timestamp to a first reference packet and sends the first reference packet to a second device; and adds a second sending timestamp to a first tested packet and sends the first tested packet to the second device; wherein, the first reference packet is transmitted from the first device to the second device using end-to-end transmission delay guarantee technology.
[0030] In addition, according to at least one embodiment of the present invention, the first reference packet and the first measured packet each include a measurement header including an identifier of the first device as a sending device, an identifier of the second device as a receiving device, and a corresponding sending timestamp.
[0031] Furthermore, according to at least one embodiment of the present invention, the ingress timestamp module is configured to, upon receiving a first reference packet sent by a first device, record a first reception timestamp of the first reference packet, and, upon receiving a first tested packet sent by the first device, record a second reception timestamp of the first tested packet;
[0032] a decapsulation module, configured to extract a first sending timestamp from the first reference packet; and extract a second sending timestamp from the first tested packet;
[0033] A delay calculation module is used to calculate the transmission delay of the first measured packet from the first device to the second device based on the first sending timestamp, the first receiving timestamp, the second sending timestamp, the second receiving timestamp and the first reference delay related information of the first reference packet from the first device to the second device; wherein, the transmission of the first reference packet from the first device to the second device adopts end-to-end transmission delay guarantee technology.
[0034] In addition, according to at least one embodiment of the present invention, the delay calculation module is specifically configured to calculate the transmission delay of the first measured packet from the first device to the second device according to the following formula:
[0035] Dtarget=Tr2+Ts1-Tr1-Ts2+Dref
[0036] Among them, Ts1, Ts2, Tr1, Tr2 and Dref respectively represent the first sending timestamp, the second sending timestamp, the first receiving timestamp, the second receiving timestamp and the first reference delay related information, and Dtarget represents the transmission delay of the first measured packet from the first device to the second device.
[0037] Furthermore, according to at least one embodiment of the present invention, the present invention further comprises:
[0038] The reference delay search module is configured to use the first device as a sending device and the second device as a receiving device to search a reference delay information table to obtain information related to a first reference delay of transmitting a first reference packet from the first device to the second device.
[0039] In addition, according to at least one embodiment of the present invention, the first reference packet is a reference packet that is closest in reception time to the first packet under test.
[0040] Furthermore, according to at least one embodiment of the present invention, the present invention further comprises:
[0041] The first reference delay acquisition module is configured to acquire information related to the reference delay of transmitting the reference packet between the sending device and the receiving device according to the following steps:
[0042] Configuring a network forwarding device with an equal-length period T, wherein the network forwarding device applies a preset scheduling and priority forwarding technology to forward reference packets, and the sum of the processing delay and queue buffering delay of the reference packets within the device is equal to the equal-length period T;
[0043] Determine the number of routing hops and the total link length between the sending device and the receiving device according to the network topology and routing rules, and determine the total link transmission time according to the total link length;
[0044] The product of 2T and the number of routing hops is calculated and added to the total link transmission time to obtain information related to a reference delay of transmitting a reference packet from the sending device to the receiving device.
[0045] Furthermore, according to at least one embodiment of the present invention, the present invention further comprises:
[0046] The second reference delay acquisition module is configured to acquire information related to the reference delay of transmitting the reference packet between the sending device and the receiving device according to the following steps:
[0047] Connecting a global satellite navigation system module to the sending device and the receiving device respectively, and performing time synchronization on the sending device and the receiving device through the global satellite navigation system module;
[0048] receiving a reference packet sent by the sending device, recording a receiving timestamp of the reference packet, and extracting a sending timestamp from the reference packet;
[0049] Information related to a reference delay of transmitting the reference packet from the transmitting device to the receiving device is calculated based on the transmitting timestamp and the receiving timestamp.
[0050] In addition, according to at least one embodiment of the present invention, the first reference packet and the first measured packet each include a measurement header including an identifier of the first device as a sending device, an identifier of the second device as a receiving device, and a corresponding sending timestamp.
[0051] According to another aspect of the present invention, at least one embodiment provides a second device including a transceiver and a processor, wherein:
[0052] The transceiver is configured to receive a first reference packet sent by a first device, record a first reception timestamp of the first reference packet, and extract a first transmission timestamp from the first reference packet; and receive a first tested packet sent by the first device, record a second reception timestamp of the first tested packet, and extract a second transmission timestamp from the first tested packet;
[0053] The processor is configured to calculate the transmission delay of the first measured packet from the first device to the second device based on the first sending timestamp, the first receiving timestamp, the second sending timestamp, the second receiving timestamp, and information related to the first reference delay of the first reference packet from the first device to the second device; wherein the transmission of the first reference packet from the first device to the second device adopts end-to-end transmission delay guarantee technology.
[0054] Furthermore, according to at least one embodiment of the present invention, the processor is further configured to calculate a transmission delay of the first measured packet from the first device to the second device according to the following formula:
[0055] Dtarget=Tr2+Ts1-Tr1-Ts2+Dref
[0056] Among them, Ts1, Ts2, Tr1, Tr2 and Dref respectively represent the first sending timestamp, the second sending timestamp, the first receiving timestamp, the second receiving timestamp and the first reference delay related information, and Dtarget represents the transmission delay related information of the first measured packet from the first device to the second device.
[0057] According to another aspect of the present invention, at least one embodiment provides a second device comprising: a processor, a memory, and a program stored in the memory and executable on the processor, wherein the program implements the steps of the method described above when executed by the processor.
[0058] According to another aspect of the present invention, at least one embodiment provides a first device, including:
[0059] an egress timestamp module, configured to stamp a first transmission timestamp on a first reference packet and a second transmission timestamp on a first tested packet, wherein the transmission of the first reference packet from the first device to the second device uses an end-to-end transmission delay guarantee technology;
[0060] The encapsulation module is configured to encapsulate the first sending timestamp in a first reference packet and send the first reference packet to a second device, and to encapsulate the second sending timestamp in a first tested packet and send the first tested packet to the second device.
[0061] Furthermore, according to at least one embodiment of the present invention, the first reference packet and the first measured packet each include a measurement header, wherein the measurement header includes an identifier of the first device as a sending device, an identifier of the second device as a receiving device, and a corresponding sending timestamp;
[0062] The encapsulation module is further configured to encapsulate the first sending timestamp, the identifiers of the first device and the second device in the measurement header of the first reference packet, and to encapsulate the second sending timestamp, the identifiers of the first device and the second device in the measurement header of the first measured packet.
[0063] According to another aspect of the present invention, at least one embodiment provides a first device including a transceiver and a processor, wherein:
[0064] The processor is configured to stamp a first sending timestamp on a first reference packet and stamp a second sending timestamp on a first tested packet, wherein the transmission of the first reference packet from the first device to the second device uses an end-to-end transmission delay guarantee technology;
[0065] The transceiver is configured to encapsulate the first sending timestamp in a first reference packet and send the first reference packet to a second device, and to encapsulate the second sending timestamp in a first tested packet and send the first tested packet to the second device.
[0066] According to another aspect of the present invention, at least one embodiment provides a first device, characterized in that it includes: a processor, a memory, and a program stored in the memory and executable on the processor, wherein the program implements the steps of the method described above when executed by the processor.
[0067] According to another aspect of the present invention, at least one embodiment provides a computer-readable storage medium having a program stored thereon. When the program is executed by a processor, the steps of the method described above are implemented.
[0068] Compared with the prior art, the delay measurement method and device provided in the embodiments of the present invention use the stable transmission delay characteristics of the reference packet to calculate the transmission delay of the measured packet, which can improve the accuracy of the end-to-end one-way delay measurement results of the network, simplify the measurement process and reduce measurement costs. BRIEF DESCRIPTION OF THE DRAWINGS
[0069] Various other advantages and benefits will become apparent to those skilled in the art upon reading the detailed description of the preferred embodiment below. The accompanying drawings are for illustration purposes only and are not to be considered as limiting the present invention. The same reference symbols are used throughout the drawings to represent the same components. In the drawings:
[0070] Figure 1 This is a diagram of a common scenario for measuring end-to-end one-way network delay.
[0071] Figure 2 A schematic diagram of a network end-to-end one-way delay measurement solution;
[0072] Figure 3 A schematic diagram of another network end-to-end one-way delay measurement solution;
[0073] Figure 4 A schematic diagram of a delay measurement scenario according to an embodiment of the present invention;
[0074] Figure 5 This is a flow chart of the delay measurement method according to an embodiment of the present invention when it is applied to the second device side;
[0075] Figure 6 This is a flow chart of the delay measurement method according to an embodiment of the present invention when it is applied to the first device side;
[0076] Figure 7 Schematic diagram of the process of the delay measurement method at the receiving end and the transmitting end according to an embodiment of the present invention;
[0077] Figure 8 A schematic diagram of end-to-end transmission delay provided by an embodiment of the present invention;
[0078] Figure 9 A schematic structural diagram of a first device and a second device provided in an embodiment of the present invention;
[0079] Figure 10 Another structural diagram of the second device provided in an embodiment of the present invention;
[0080] Figure 11 Another structural diagram of the first device provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0081] Exemplary embodiments of the present invention will be described in more detail below with reference to the accompanying drawings. Although exemplary embodiments of the present invention are shown in the accompanying drawings, it should be understood that the present invention can be implemented in various forms and should not be limited by the embodiments set forth herein. Rather, these embodiments are provided to enable a more thorough understanding of the present invention and to fully convey the scope of the present invention to those skilled in the art.
[0082] The terms "first", "second" etc. in the specification and claims of the present application are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequential order. It should be understood that the data used in this way can be interchangeable in appropriate circumstances, so that the embodiments of the present application described herein, for example, can be implemented in an order other than those illustrated or described here. In addition, the terms "comprise" and "have" and any of their variations are intended to cover non-exclusive inclusions, for example, the process, method, system, product or equipment comprising a series of steps or units need not be limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or that are intrinsic to these processes, methods, products or equipment. "And / or" in the specification and claims represents at least one of the connected objects.
[0083] The following description provides examples and does not limit the scope, applicability, or configuration set forth in the claims. Changes may be made to the function and arrangement of the elements discussed without departing from the spirit and scope of this disclosure. The various examples may appropriately omit, substitute, or add various procedures or components. For example, the described methods may be performed in an order different from that described, and various steps may be added, omitted, or combined. In addition, features described with reference to certain examples may be combined in other examples.
[0084] One-way delay measurement technology solutions are divided into two categories: the first category is a one-way delay measurement solution based on round-trip time (RTT); the second category is a one-way delay measurement solution based on precise end-to-end time synchronization.
[0085] Among them, the one-way delay measurement scheme based on round-trip communication delay is as follows: Figure 2 As shown in the figure, network measurement probes are deployed on both the user access side and the server user side of the video surveillance acquisition system. The network measurement probe at the source sends a test packet. The network measurement probe at the destination reflects the received test packet (without processing and directly sending it back to the source). After the source receives the reflected test packet from the destination, the round-trip communication delay can be calculated. By dividing the round-trip communication delay by 2, the end-to-end one-way delay can be approximately calculated.
[0086] One-way delay measurement solution based on precise end-to-end time synchronization Figure 3As shown in the figure, there are two methods for end-to-end time synchronization: the first is based on the Global Positioning System (GPS) module; the second is based on the 1588v2 protocol. Either method can be used. After end-to-end time synchronization is complete, the network measurement probe at the source sends a test packet with an accurate egress timestamp. When the test packet is received at the destination, it is stamped with an accurate ingress timestamp. Since the source and destination are already end-to-end time synchronized, the end-to-end one-way delay can be obtained by subtracting the ingress timestamp from the egress timestamp.
[0087] The two major technical solutions for one-way delay measurement mentioned above have shortcomings in measuring the end-to-end one-way delay of 5G networks, which are described below.
[0088] The measurement accuracy of one-way delay measurement based on round-trip delay cannot meet application requirements. Because the uplink and downlink delays in network applications (such as 5G networks) are generally not equal, the accuracy of approximating the end-to-end one-way delay by dividing the round-trip delay by 2 is low and cannot meet the requirements for accurate end-to-end one-way delay measurement.
[0089] One-way latency measurement solutions based on precise end-to-end time synchronization rely on accurate time synchronization, resulting in high deployment costs and technical challenges. GPS-based time synchronization solutions, in real-world deployments, often involve equipment rooms located underground or in areas without GPS signals, making it impossible to continuously obtain GPS clock information for time synchronization. 1588v2-based time synchronization solutions require end-to-end network-wide time synchronization, requiring all devices in the wireless, transmission, core, and IP bearer networks to support the 1588v2 synchronization protocol. However, achieving full network support for 1588v2 is currently difficult.
[0090] The embodiment of the present invention provides a delay measurement method that can accurately measure the end-to-end network one-way delay without deploying clock synchronization, using the characteristic of reference packets having stable transmission delay during end-to-end transmission, thereby simplifying the measurement process and reducing measurement costs. The delay measurement method provided by the embodiment of the present invention is used to measure the end-to-end one-way delay of the network between a first device (sending device) and a second device (receiving device). Figure 4 A schematic diagram of the timestamps of the sending end (ie, the first device) and the receiving end (ie, the second device) is shown, wherein packet 1 is a reference packet (eg, the first reference packet) and packet 2 is a tested packet (eg, the first tested packet).
[0091] The end-to-end one-way delay of the reference packet with stable delay in the network can be used as the reference delay related information Dref. The reference delay value indicated by the reference delay related information is known in advance and has extremely low jitter. In the embodiment of the present invention, the transmission delay of the measured packet can be calculated using the pre-acquired reference delay value. The reference delay related information can be stored in the reference delay information table shown in Table 4 below. Assuming that the network end-to-end one-way delay from the sending end to the receiving end is measured, as shown in FIG. Figure 4 As shown. Network intermediate devices other than network end devices are Figure 4 The actual sending and receiving ends can be Figure 2 Network measurement probe device shown.
[0092] For details, please refer to Figure 5 When applied to a second device on a receiving end side, the delay measurement method includes:
[0093] Step 51: The second device receives a first reference packet sent by the first device, records a first receiving timestamp of the first reference packet, and extracts a first sending timestamp from the first reference packet; and receives a first tested packet sent by the first device, records a second receiving timestamp of the first tested packet, and extracts a second sending timestamp from the first tested packet.
[0094] Here, the first reference packet is a reference packet. Typically, the first device can send at least one reference packet to the second device. The reference packet is transmitted from the first device to the second device using end-to-end transmission delay guarantee technology. For example, the first device can periodically send reference packets to the second device according to a preset transmission period. Another example is that the first device can dynamically adjust the frequency of reference packet transmission based on indicators such as the link idle rate or the device's hardware processing pressure. Specifically, the transmission frequency can be positively correlated with the link idle rate or negatively correlated with the device's hardware processing pressure.
[0095] The end-to-end transmission delay guarantee technology can make the end-to-end one-way delay of the reference packet (such as the first reference packet) have a stable value with extremely small jitter. For example, it can be implemented by using technologies including but not limited to deterministic networks and 5G end-to-end network slicing. When measuring the one-way delay of the measured packet (such as the first measured packet), the embodiment of the present invention can send the measured packet and the reference packet on the first device side of the transmitting end, and mark the above packets with a sending timestamp; then, the receiving timestamp of the above packets is recorded on the second device side of the receiving end.
[0096] During a specific measurement, a packet under test (herein referred to as the first packet under test) and a reference packet with the smallest difference in reception timestamp with the first packet under test (herein referred to as the first reference packet) can be preferentially selected for subsequent calculations. In other words, the first reference packet is the reference packet that was received closest in time to the first packet under test. In other words, the first reference packet may be a reference packet received before the first packet under test, after the first packet under test, or simultaneously with the first packet under test.
[0097] Step 52: The second device calculates the transmission delay of the first measured packet from the first device to the second device based on the first sending timestamp, the first receiving timestamp, the second sending timestamp, the second receiving timestamp, and the first reference delay related information of the reference packet from the first device to the second device.
[0098] Here, the specific method of calculating the transmission delay of the first measured packet from the first device to the second device can be calculated according to the following formula:
[0099] Dtarget=Tr2+Ts1-Tr1-Ts2+Dref (Formula 1)
[0100] Among them, Ts1, Ts2, Tr1, Tr2 and Dref respectively represent the first sending timestamp, the second sending timestamp, the first receiving timestamp, the second receiving timestamp and the first reference delay related information, and Dtarget represents the transmission delay of the first measured packet from the first device to the second device.
[0101] The above formula 1 includes multiple parameters. During the specific calculation, the first sum of the second receiving timestamp and the first sending timestamp can be calculated; the second sum of the first receiving timestamp and the second sending timestamp can be calculated; then, the difference between the first sum and the second sum is calculated, and the third sum of the difference and the first reference delay related information is calculated to obtain the transmission delay of the first measured packet from the first device to the second device. In this case, the above formula 1 can be expressed as the following formula 1A:
[0102] Dtarget=(Tr2+Ts1)-(Tr1+Ts2)+Dref (Formula 1A)
[0103] It should be noted that the parameters in Formula 1 or Formula 1A can be used to calculate the sum or difference of any two or more parameters to ultimately determine the transmission delay. In other words, the present invention does not limit the order in which the sum and difference calculations of the parameters are performed; any calculation sequence that can determine the final transmission delay using the parameters is applicable to the present invention.
[0104] Through the above steps, the embodiment of the present invention utilizes the characteristic of a reference packet having a stable transmission delay during end-to-end transmission to calculate the transmission delay of the packet under test. This allows for real-time measurement of transmission delay without deploying a synchronous clock in the network, and enables relatively accurate measurement results to be obtained, thereby improving the accuracy of the measurement results, simplifying the measurement process, and reducing measurement costs.
[0105] To facilitate measurement, embodiments of the present invention can pre-acquire information related to the reference delay of the reference packet transmitted between the transmitting device and the receiving device. Based on the information related to the reference delay of the reference packet transmitted between different transmitting devices and receiving devices, a reference delay information table is established. This table includes information related to the reference delay of the reference packet transmitted between multiple groups of transmitting devices and receiving devices. The entire or partial contents of this reference delay information table can be stored in the second device. When storing partial contents of the table, reference delay modification information corresponding to different transmitting devices can be stored, with the second device as the receiving device.
[0106] Here, the reference delay-related information generally includes a specific value of the reference delay, which can be expressed in the form of a maximum value, a minimum value, or an average value of the reference delay. When calculating the transmission delay, the average value of the reference delay can be used for calculation, or the maximum or minimum value of the reference delay can be used for calculation. The reference delay-related information may also include information such as the level (e.g., microsecond level) or size (e.g., 50 microseconds) of the delay jitter corresponding to the reference delay.
[0107] In this way, before the above step 52, the second device uses the first device as a sending device and the second device as a receiving device, searches the reference delay information table, obtains the first reference delay related information of the first reference packet transmitted from the first device to the second device, and thus performs delay calculation in step 52.
[0108] The following are two specific methods for obtaining reference delay:
[0109] First approach: In the above delay measurement method of the embodiment of the present invention, the following steps may be followed to obtain information related to the reference delay of the reference packet transmitted between the transmitting device and the receiving device:
[0110] Configuring a network forwarding device with an equal-length period T, wherein the network forwarding device applies a preset scheduling and priority forwarding technology to forward reference packets, and the sum of the processing delay and queue buffering delay of the reference packets within the device is equal to the equal-length period T;
[0111] Determine the number of routing hops and the total link length between the sending device and the receiving device according to the network topology and routing rules, and determine the total link transmission time according to the total link length;
[0112] The product of 2T and the number of routing hops is calculated and added to the total link transmission time to obtain information related to a reference delay of transmitting a reference packet from the sending device to the receiving device.
[0113] The first method is particularly suitable for measuring the reference delay of a reference packet in a network that adopts a deterministic network forwarding technology.
[0114] Second approach: In the above delay measurement method of the embodiment of the present invention, information related to the reference delay of the reference packet transmitted between the sending device and the receiving device is obtained according to the following steps:
[0115] Connecting a global satellite navigation system module to the sending device and the receiving device respectively, and performing time synchronization on the sending device and the receiving device through the global satellite navigation system module;
[0116] receiving a reference packet sent by the sending device, recording a receiving timestamp of the reference packet, and extracting a sending timestamp from the reference packet;
[0117] Information related to a reference delay of transmitting the reference packet from the transmitting device to the receiving device is calculated based on the transmitting timestamp and the receiving timestamp.
[0118] This second method is particularly suitable for networks that adopt technologies such as end-to-end network slicing. Of course, it can also be adapted to networks that adopt deterministic network forwarding technology.
[0119] Please refer to Figure 6 When applied to a second device on a receiving end side, the delay measurement method includes:
[0120] Step 61: The first device adds a first sending timestamp to a first reference packet and sends the first reference packet to a second device; and adds a second sending timestamp to a first tested packet and sends the first tested packet to the second device.
[0121] Here, the transmission of the first reference packet from the first device to the second device adopts an end-to-end transmission delay guarantee technology.
[0122] Through the above steps, in an embodiment of the present invention, the first device at the transmitting end can send a reference packet and a packet under test and carry a sending timestamp, so that the receiving end device can calculate the transmission delay of the packet under test based on the reference packet, thereby utilizing the stable delay characteristics of the reference packet to calculate the delay of the packet under test, simplifying the delay measurement process and improving the accuracy of the delay results.
[0123] Figure 7 A schematic diagram of the measurement process at the transmitter and receiver is given.
[0124] For the sender, sending a reference packet specifically includes: the first step, the sender prepares to send a reference packet, recorded as packet 1; the second step, the sender stamps the egress timestamp Ts1 for the reference packet; the third step, the sender records the egress timestamp of the reference packet in the measurement header of packet 1; the fourth step, the sender sends the reference packet.
[0125] For the sending end, according to business needs, the measured packet is sent again, specifically including: the first step, the sending end prepares to send a measured packet, recorded as packet 2; the second step, the sending end adds the exit timestamp Ts2 to the reference packet; the third step, the sending end records the exit timestamp of the measured packet in the measurement header of packet 2; the fourth step, the sending end sends the measured packet out.
[0126] The transmitter can send reference packets at a fixed frequency or adjust the sending frequency according to the link utilization rate so that the packet under test can always find a nearby reference packet, making the sending interval between packet 1 and packet 2 smaller.
[0127] For the receiving end, receiving the reference packet specifically includes: the first step, the reference packet arrives at the receiving end, and the receiving end accepts the reference packet; the second step, the receiving end timestamps the reference packet entry, recorded as Tr1; the third step, the receiving end decapsulates the reference packet and obtains the sender's exit timestamp Ts1; the fourth step, the receiving end records the Ts1 and Tr1 timestamp information; the fifth step, the receiving end uses the sender / receiver pair obtained by decapsulation in the third step as the search key value, queries the reference delay information table and records the reference delay search result Dref.
[0128] For the receiving end, receiving the measured packet specifically includes: the first step, the measured packet arrives at the receiving end, and the receiving end receives the measured packet; the second step, the receiving end timestamps the measured packet entry, recorded as Tr2; the third step, the receiving end decapsulates the measured packet and obtains the sender's egress timestamp Ts2; the fourth step, the receiving end records the Ts2 and Tr2 timestamp information; the fifth step, the receiving end calculates the one-way delay of the measured packet based on the recorded timestamp information Ts1, Ts2, Tr1, Tr2 and the reference delay related information Dref, recorded as Dtarget.
[0129] The following introduces Figure 7 In step 5 of the measured packet process at the receiving end, the one-way delay Dtarget of the measured packet is calculated based on the recorded timestamp information Ts1, Ts2, Tr1, Tr2 and the reference delay related information Dref. For packet 1, the sending end timestamp is subtracted from the receiving end timestamp to obtain:
[0130] Tr1-Ts1=Dref+Offset1 (Formula 2)
[0131] Where Offset1 is the time offset between the sender and the receiver when the packet 1 transmission occurs.
[0132] Similarly, for group 2, we can get:
[0133] Tr2-Ts2=Dtarget+Offset2 (Formula 3)
[0134] Where Offset2 is the time offset between the sender and receiver when packet 2 is transmitted. Assuming that the interval between packets 1 and 2 is short, Offset1 and Offset2 are approximately equal. Subtracting Equation 2 from Equation 3 yields:
[0135] Dtarget=(Tr2+Ts1)-(Tr1+Ts2)+Dref (Formula 4)
[0136] Thus, the one-way delay value Dtarget of the measured packet can be calculated.
[0137] The reference group and the measurement group in the embodiment of the present invention both include a measurement head. A specific packaging structure of the measurement head is provided below. The following structure is only one of the structures that can be used in the embodiment of the present invention and is not intended to limit the present invention.
[0138] The specific encapsulation of the measurement header is shown in Table 2. The measurement information of the reference packet and the measured packet can be encapsulated in the measurement header of the corresponding packet respectively. In specific implementation, any encapsulation position that can provide sufficient byte space to carry the measurement header can be used in the protocol header, such as encapsulating the measurement header in the options field (maximum 40 bytes) in the TCP header. The following introduces a measurement header encapsulation for the reference packet and the measured packet. The position order of the encapsulation fields is not limited to that shown in Table 2. The sender ID and the receiver ID are 8 bits respectively, marking the starting point and the ending point of the end-to-end measurement, that is, the sender / receiver pair. The egress timestamp of the sending packet is 32 bits, marking the egress timestamp of the sender. The sender egress timestamps of the reference packet and the measured packet correspond to Ts1 and Ts2 in Formula 4 respectively. The reserved word is 16 bits and can be used to carry other useful information, such as the port number of the receiver / sender, or the type (Kind) and length (Length) of the TCP option field.
[0139]
[0140] Table 2
[0141] The following describes a specific method for obtaining information related to the reference delay of transmitting the reference packet between the sending device and the receiving device.
[0142] The end-to-end one-way delay of the network consists of three parts: line transmission delay, device internal processing delay and device internal queue buffer delay. Figure 8 As shown in the figure, the fixed portion of the delay includes line transmission delay and internal device processing delay. Line transmission delay is related to transmission distance and is approximately 5ns / meter. Once the transmission path is determined, it is essentially a fixed value. Internal device processing delay includes the processing delay of the device's internal pipeline or processor and the interface serial-to-parallel conversion delay. It is related to the device's input / output port rate, message length, and message forwarding behavior. The internal processing delay of each device is on the order of microseconds and is essentially a fixed value after the chip design specifications are determined. The variable portion of the delay is the device's internal cache queue delay. The device's internal cache queue delay is related to the queue depth, the outbound interface queue scheduling algorithm, message priority, and message length. It can reach microseconds or even milliseconds for each device, and the delay varies significantly depending on the values of these parameters. Table 3 shows the characteristics of these various delays.
[0143]
[0144] Table 3
[0145] With the continuous development of network application requirements, a series of network technologies have emerged to ensure that the end-to-end transmission delay value is stable and the jitter is bounded. An embodiment of obtaining reference delay related information will be described below. For example, the deterministic network forwarding technology that has been standardized in the IETF can fix the internal queue cache delay of the end-to-end network device by designing special queue scheduling algorithms and message priorities. Its delay jitter is extremely low and bounded, and the end-to-end one-way delay can be approximately considered to be a certain value. In the specific implementation process, the network packet transmitted by the above-mentioned deterministic network forwarding technology can be used as a reference packet, and its end-to-end one-way delay is used as the reference delay related information. The method for obtaining reference delay related information is not limited to the method based on deterministic networks. The end-to-end transmission delay of any packet network with low delay jitter can potentially be used for the reference delay related information of the embodiment of the present invention. The following describes in detail the method for obtaining reference delay related information based on deterministic network forwarding technology, including:
[0146] 1) Configuring a network forwarding device with an equal-length period T, wherein the network forwarding device applies a preset scheduling and priority forwarding technology to forward reference packets, and the sum of the processing delay and queue buffer delay of the reference packets within the network forwarding device is equal to the equal-length period T.
[0147] 2) According to the network topology and routing rules, the number of routing hops and the total link length between the sending device and the receiving device are determined, and according to the total link length, the total link transmission time is determined.
[0148] 3) Calculate the product of 2T and the number of routing hops, and add the product to the total link transmission time to obtain information related to the reference delay of the reference packet transmitted from the sending device to the receiving device.
[0149] The above steps are described in more detail below.
[0150] The network device of this embodiment first configures a preset network parameter; the reference delay theoretical value Dref0 of the reference packet can be calculated based on the configured preset network parameter, and the specific calculation method is as follows. In a deterministic network (Reference: Qiang Li, Liu Bingyang, Yu Delei, et al. Large-scale deterministic network forwarding technology [J]. Telecommunications Science, 2019, v.35(09):18-25.), the special scheduling and priority strategy implemented by the network device can greatly reduce the fluctuation of the internal queue cache delay of the device, and make the sum of the end-to-end device internal processing delay and the internal queue cache delay only related to the equal-length period T configured by each end-to-end device. Specifically, the relationship between the end-to-end one-way delay and the device equal-length period T is as follows:
[0151] One-way delay = total link transmission delay + 2T × number of hops
[0152] The first term in the above formula is the total link transmission delay, which can be calculated based on the link length and is a fixed value. The second term in the above formula is the sum of the device's internal processing delay and the internal queue buffer delay. The number of hops can be predetermined based on the network topology and pre-configured source routing rules and is a fixed value. What needs to be configured is the equal-length period T of the network device. Assuming that the equal-length period value T of the configured device is a typical value of 10 microseconds, the end-to-end one-way delay value can be obtained as a reference delay theoretical value. On the other hand, the delay jitter calculation formula for the above one-way delay theoretical value is as follows:
[0153] Delay jitter = 2T
[0154] Assuming that the device equal-length period T is typically 10 microseconds, the theoretical delay jitter of the deterministic network is 20 microseconds.
[0155] During actual deployment, a temporary external GPS antenna and GPS module can be used to pre-measure network links requiring end-to-end one-way delay measurement. This provides the link's actual no-load reference delay Dref1 and delay jitter, which are then stored in a reference delay lookup table. Once the network is operational and the link is no longer no-loaded, the reference packet's reference delay value, Dref2, is used. Due to deterministic network forwarding technology, the differences between Dref0, Dref1, and Dref2 are minimal and negligible. Therefore, the measured value of Dref1 can be used as the reference delay Dref2 during actual network operation. Table 4 shows the format and contents of the reference delay information table.
[0156]
[0157] Table 4
[0158] It should be noted that after the network is actually put into operation, the network traffic load may not be consistent with that at the time of network deployment. However, the deterministic network scheduling and priority mechanism based on the configured network parameters can ensure that the actual experienced delay Dref2 of the reference packet is basically consistent with the reference delay value Dref1 obtained by lookup, and the jitter value is within a bounded range that can be ignored.
[0159] For example, experimental results from a deployed deterministic network, CENI (Reference: Purple Mountain Laboratory for Network Communications and Security, Huawei Network Technology Laboratory, Beijing University of Posts and Telecommunications, Jiangsu Future Network Innovation Institute. CENI New IP Networking Test Report, Organizing Committee of the Fourth Future Network Development Conference, August 2020), show that the theoretical reference delay value Dref0, the initial no-load test value (no background traffic) Dref1, and the measured loaded delay value Dref2 (including interference flows 1 to 11) remain consistent. Furthermore, the end-to-end delay of the deterministic network DIP forwarding remains unchanged when including different background interference flows, as shown in Table 5, which shows the DIP test statistics for the 1,000-kilometer Beijing-Nanjing loop network.
[0160]
[0161] Table 5
[0162] The embodiment of the present invention also provides a device for implementing the above method.
[0163] The one-way delay measurement device based on reference delay consists of two parts: a transmitter and a receiver. Both the transmitter and receiver contain timestamp modules. The transmitter's egress timestamp module performs timestamps on outgoing packets, while the receiver's ingress timestamp module performs timestamps on incoming packets. Accurate egress and ingress timestamps at the physical layer or data link layer are common functions of end-side network cards or similar network devices. The reference delay lookup module is a lookup table whose key is the transmitter ID and receiver ID pair, and whose result is the reference delay value and jitter value. The data structure of the reference delay lookup table is shown in Table 4. The reference delay lookup table for each receiver only needs to store entries for the receiver itself (e.g., the reference delay lookup table for receiver B does not need to store entries for receiver C). The reference delay information table is initialized in advance based on the network configuration. The transmitter encapsulation module encapsulates the egress timestamps and transmitter / receiver pairs of the reference packet and the packet under test in the corresponding measurement headers. The detailed encapsulation of the measurement headers is shown in Table 2. The decapsulation module decapsulates the measurement headers of the reference and measured packets to obtain the input for the delay calculation module, which calculates the end-to-end one-way delay value Dtarget of the measured packet according to the aforementioned formula 4.
[0164] For details, please refer to Figure 9 , an embodiment of the present invention provides a first device (transmitter) and a second device (receiver). In which:
[0165] The second device includes:
[0166] an ingress timestamp module 911, configured to, upon receiving a first reference packet sent by a first device, record a first reception timestamp of the first reference packet, and upon receiving a first tested packet sent by the first device, record a second reception timestamp of the first tested packet;
[0167] a decapsulation module 912 configured to extract a first sending timestamp from the first reference packet; and extract a second sending timestamp from the first tested packet;
[0168] The delay calculation module 913 is used to calculate the transmission delay of the first measured packet from the first device to the second device based on the first sending timestamp, the first receiving timestamp, the second sending timestamp, the second receiving timestamp and the first reference delay information of the first reference packet from the first device to the second device; wherein, the transmission of the first reference packet from the first device to the second device adopts end-to-end transmission delay guarantee technology.
[0169] Optionally, the delay calculation module 913 is specifically configured to calculate the transmission delay of the first measured packet from the first device to the second device according to the following formula:
[0170] Dtarget=Tr2+Ts1-Tr1-Ts2+Dref
[0171] Among them, Ts1, Ts2, Tr1, Tr2 and Dref respectively represent the first sending timestamp, the second sending timestamp, the first receiving timestamp, the second receiving timestamp and the first reference delay related information, and Dtarget represents the transmission delay of the first measured packet from the first device to the second device.
[0172] Optionally, the second device further includes:
[0173] The reference delay search module 914 is configured to search a reference delay information table, with the first device serving as a sending device and the second device serving as a receiving device, to obtain information related to a first reference delay for transmitting a first reference packet from the first device to the second device. The reference delay information table includes information related to reference delays for transmitting reference packets between different sending and receiving devices.
[0174] Optionally, the first reference group is a reference group that is closest in reception time to the first packet under test.
[0175] Optionally, the second device further includes the following modules ( Figure 9 Not shown):
[0176] The first reference delay acquisition module is configured to acquire information related to the reference delay of transmitting the reference packet between the sending device and the receiving device according to the following steps:
[0177] Configuring a network forwarding device with an equal-length period T, wherein the network forwarding device applies a preset scheduling and priority forwarding technology to forward reference packets, and the sum of the processing delay and queue buffering delay of the reference packets within the device is equal to the equal-length period T;
[0178] Determine the number of routing hops and the total link length between the sending device and the receiving device according to the network topology and routing rules, and determine the total link transmission time according to the total link length;
[0179] The product of 2T and the number of routing hops is calculated and added to the total link transmission time to obtain information related to a reference delay of transmitting a reference packet from the sending device to the receiving device.
[0180] Optionally, the second device further includes the following modules ( Figure 9 Not shown):
[0181] The second reference delay acquisition module is configured to acquire information related to the reference delay of transmitting the reference packet between the sending device and the receiving device according to the following steps:
[0182] Connecting a global satellite navigation system module to the sending device and the receiving device respectively, and performing time synchronization on the sending device and the receiving device through the global satellite navigation system module;
[0183] receiving a reference packet sent by the sending device, recording a receiving timestamp of the reference packet, and extracting a sending timestamp from the reference packet;
[0184] Information related to a reference delay of transmitting the reference packet from the transmitting device to the receiving device is calculated based on the transmitting timestamp and the receiving timestamp.
[0185] Optionally, both the first reference group and the first measured group include a measurement header, wherein the measurement header includes an identifier of a first device serving as a sending device, an identifier of a second device serving as a receiving device, and a corresponding sending timestamp.
[0186] like Figure 9 As shown, the first device includes:
[0187] an egress timestamp module 921, configured to stamp a first transmission timestamp on a first reference packet and a second transmission timestamp on a first tested packet, wherein the transmission of the first reference packet from the first device to the second device uses an end-to-end transmission delay guarantee technology;
[0188] The encapsulation module 922 is configured to encapsulate the first sending timestamp in a first reference packet and send the first reference packet to the second device, and to encapsulate the second sending timestamp in a first tested packet and send the first tested packet to the second device.
[0189] Optionally, the first reference group and the first measured group each include a measurement header, wherein the measurement header includes an identifier of the first device as a transmitting device, an identifier of the second device as a receiving device, and a corresponding transmission timestamp. The encapsulation module is further configured to encapsulate the first transmission timestamp, the identifiers of the first device and the second device in the measurement header of the first reference group, and to encapsulate the second transmission timestamp, the identifiers of the first device and the second device in the measurement header of the first measured group.
[0190] It should be noted that the device in this embodiment is the same as the above Figure 5 and Figure 6 The device corresponding to the method shown, the implementation methods in the above embodiments are all applicable to the embodiments of the device, and can also achieve the same technical effects. The above device provided by the embodiment of the present invention can implement all the method steps implemented by the above method embodiment and can achieve the same technical effects. The parts and beneficial effects of this embodiment that are the same as those of the method embodiment will not be detailed here.
[0191] Please refer to Figure 10 , another structural diagram of a second device provided by an embodiment of the present invention, the second device includes: a processor 1001, a transceiver 1002, a memory 1003, a user interface 1004 and a bus interface.
[0192] In the embodiment of the present invention, the terminal further includes: a program stored in the memory 1003 and executable on the processor 1001 .
[0193] When the processor 1001 executes the program, the following steps are implemented:
[0194] receiving a first reference packet sent by a first device, recording a first reception timestamp of the first reference packet, and extracting a first transmission timestamp from the first reference packet; and receiving a first tested packet sent by the first device, recording a second reception timestamp of the first tested packet, and extracting a second transmission timestamp from the first tested packet;
[0195] The transmission delay of the first measured packet from the first device to the second device is calculated based on the first sending timestamp, the first receiving timestamp, the second sending timestamp, the second receiving timestamp and the first reference delay information related to the transmission of the first reference packet from the first device to the second device; wherein, the transmission of the first reference packet from the first device to the second device adopts end-to-end transmission delay guarantee technology.
[0196] Optionally, when executing the program, the processor further implements the following steps:
[0197] The transmission delay of the first measured packet from the first device to the second device is calculated according to the following formula:
[0198] Dtarget=Tr2+Ts1-Tr1-Ts2+Dref
[0199] Among them, Ts1, Ts2, Tr1, Tr2 and Dref respectively represent the first sending timestamp, the second sending timestamp, the first receiving timestamp, the second receiving timestamp and the first reference delay related information, and Dtarget represents the transmission delay of the first measured packet from the first device to the second device.
[0200] Optionally, when executing the program, the processor further implements the following steps:
[0201] Before calculating the transmission delay of the first measured packet from the first device to the second device, with the first device as the sending device and the second device as the receiving device, a reference delay information table is searched to obtain information related to a first reference delay of the reference packet being transmitted from the first device to the second device; wherein the reference delay information table includes information related to reference delays of the reference packet being transmitted between different sending devices and receiving devices.
[0202] Optionally, the first reference group is a reference group that is closest in reception time to the first packet under test.
[0203] Optionally, when executing the program, the processor further implements the following steps:
[0204] Obtain information related to a reference delay of transmitting the reference packet between a transmitting device and a receiving device by following the steps below:
[0205] Configuring a network forwarding device with an equal-length period T, wherein the network forwarding device applies a preset scheduling and priority forwarding technology to forward reference packets, and the sum of the processing delay and queue buffering delay of the reference packets within the device is equal to the equal-length period T;
[0206] Determine the number of routing hops and the total link length between the sending device and the receiving device according to the network topology and routing rules, and determine the total link transmission time according to the total link length;
[0207] The product of 2T and the number of routing hops is calculated and added to the total link transmission time to obtain information related to a reference delay of transmitting a reference packet from the sending device to the receiving device.
[0208] Optionally, when executing the program, the processor further implements the following steps:
[0209] Obtain information related to a reference delay of transmitting the reference packet between a transmitting device and a receiving device by following the steps below:
[0210] Connecting a global satellite navigation system module to the sending device and the receiving device respectively, and performing time synchronization on the sending device and the receiving device through the global satellite navigation system module;
[0211] receiving a reference packet sent by the sending device, recording a receiving timestamp of the reference packet, and extracting a sending timestamp from the reference packet;
[0212] Information related to a reference delay of transmitting the reference packet from the transmitting device to the receiving device is calculated based on the transmitting timestamp and the receiving timestamp.
[0213] Optionally, both the first reference group and the first measured group include a measurement header, wherein the measurement header includes an identifier of a first device serving as a sending device, an identifier of a second device serving as a receiving device, and a corresponding sending timestamp.
[0214] It is understandable that in the embodiment of the present invention, when the computer program is executed by the processor 1001, the above Figure 5 The various processes of the method embodiment shown can achieve the same technical effect, and to avoid repetition, they will not be described again here.
[0215] exist Figure 10In the embodiment, the bus architecture may include any number of interconnected buses and bridges, specifically linking together various circuits of one or more processors represented by processor 1001 and memory represented by memory 1003. The bus architecture may also link together various other circuits such as peripheral devices, voltage regulators, and power management circuits, which are well known in the art and therefore will not be described further herein. The bus interface provides an interface. The transceiver 1002 may be a plurality of components, i.e., a transmitter and a receiver, providing a unit for communicating with various other devices on a transmission medium. For different user devices, the user interface 1004 may also be an interface capable of connecting external or internal devices as required, and the connected devices include but are not limited to a keypad, a display, a speaker, a microphone, a joystick, etc.
[0216] The processor 1001 is responsible for managing the bus architecture and general processing, and the memory 1003 can store data used by the processor 1001 when performing operations.
[0217] It should be noted that the device in this embodiment is the same as the above Figure 5 The device corresponding to the method shown in the embodiment is applicable to the implementation methods in the above embodiments and can achieve the same technical effects. In the device, the transceiver 1002 and the memory 1003, as well as the transceiver 1002 and the processor 1001, can be communicatively connected via a bus interface. The functions of the processor 1001 can also be implemented by the transceiver 1002, and the functions of the transceiver 1002 can also be implemented by the processor 1001. It should be noted that the device provided in the embodiment of the present invention can implement all the method steps implemented in the above method embodiment and can achieve the same technical effects. The parts and beneficial effects of this embodiment that are the same as those in the method embodiment will not be detailed here.
[0218] In some embodiments of the present invention, a computer-readable storage medium is further provided, on which a program is stored. When the program is executed by a processor, the following steps are implemented:
[0219] receiving a first reference packet sent by a first device, recording a first reception timestamp of the first reference packet, and extracting a first transmission timestamp from the first reference packet; and receiving a first tested packet sent by the first device, recording a second reception timestamp of the first tested packet, and extracting a second transmission timestamp from the first tested packet;
[0220] The transmission delay of the first measured packet from the first device to the second device is calculated based on the first sending timestamp, the first receiving timestamp, the second sending timestamp, the second receiving timestamp and the first reference delay information related to the transmission of the first reference packet from the first device to the second device; wherein, the transmission of the first reference packet from the first device to the second device adopts end-to-end transmission delay guarantee technology.
[0221] When the program is executed by the processor, it can implement all the implementation methods of the above-mentioned delay measurement method applied to the second device side and achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0222] Please refer to Figure 11 , another structural diagram of a first device provided by an embodiment of the present invention, the first device includes: a processor 1101, a transceiver 1102, a memory 1103, a user interface 1104 and a bus interface.
[0223] In the embodiment of the present invention, the terminal further includes: a program stored in the memory 1103 and executable on the processor 1101 .
[0224] When the processor 1101 executes the program, the following steps are implemented:
[0225] A first reference packet is marked with a first sending timestamp, and the first reference packet is sent to a second device; and a first tested packet is marked with a second sending timestamp, and the first tested packet is sent to the second device; wherein, the transmission of the first reference packet from the first device to the second device adopts end-to-end transmission delay guarantee technology.
[0226] Optionally, both the first reference group and the first measured group include a measurement header, wherein the measurement header includes an identifier of a first device serving as a sending device, an identifier of a second device serving as a receiving device, and a corresponding sending timestamp.
[0227] It is understandable that in the embodiment of the present invention, when the computer program is executed by the processor 1101, the above Figure 6 The various processes of the method embodiment shown can achieve the same technical effect, and to avoid repetition, they will not be described again here.
[0228] exist Figure 11In the embodiment, the bus architecture may include any number of interconnected buses and bridges, specifically linking together various circuits of one or more processors represented by processor 1101 and memory represented by memory 1103. The bus architecture may also link together various other circuits such as peripheral devices, voltage regulators, and power management circuits, which are well known in the art and therefore will not be described further herein. The bus interface provides an interface. The transceiver 1102 may be a plurality of components, i.e., a transmitter and a receiver, providing a unit for communicating with various other devices on a transmission medium. For different user devices, the user interface 1104 may also be an interface capable of connecting external or internal devices as required, and the connected devices include but are not limited to a keypad, a display, a speaker, a microphone, a joystick, etc.
[0229] The processor 1101 is responsible for managing the bus architecture and general processing, and the memory 1103 can store data used by the processor 1101 when performing operations.
[0230] It should be noted that the device in this embodiment is the same as the above Figure 6 The device corresponding to the method shown in the embodiment is applicable to the implementation methods in the above embodiments of the device and can achieve the same technical effects. In the device, the transceiver 1102 and the memory 1103, as well as the transceiver 1102 and the processor 1101, can be connected to each other through a bus interface. The functions of the processor 1101 can also be implemented by the transceiver 1102, and the functions of the transceiver 1102 can also be implemented by the processor 1101. It should be noted that the above device provided by the embodiment of the present invention can implement all the method steps implemented by the above method embodiment and can achieve the same technical effects. The parts and beneficial effects of this embodiment that are the same as those of the method embodiment will not be detailed here.
[0231] In some embodiments of the present invention, a computer-readable storage medium is further provided, on which a program is stored. When the program is executed by a processor, the following steps are implemented:
[0232] A first reference packet is marked with a first sending timestamp, and the first reference packet is sent to a second device; and a first tested packet is marked with a second sending timestamp, and the first tested packet is sent to the second device; wherein, the transmission of the first reference packet from the first device to the second device adopts end-to-end transmission delay guarantee technology.
[0233] When the program is executed by the processor, it can implement all the implementation methods of the above-mentioned delay measurement method applied to the first device side and achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0234] Those skilled in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of the present invention.
[0235] Those skilled in the art will clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0236] In the embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are merely schematic. For example, the division of the units is merely a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0237] The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected according to actual needs to achieve the objectives of the embodiments of the present invention.
[0238] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0239] If the functions are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the portion that contributes to the prior art, or the portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions for enabling a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in various embodiments of the present invention. The aforementioned storage medium includes various media that can store program code, such as a USB flash drive, a mobile hard drive, ROM, RAM, a magnetic disk, or an optical disk.
[0240] The above description is merely a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any modifications or substitutions that can be easily conceived by a person skilled in the art within the technical scope disclosed in the present invention should be included within the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be based on the scope of protection of the claims.
Claims
1. A method for measuring time delay, characterized in that: include: The second device receives the first reference packet sent by the first device, records the first receiving timestamp of the first reference packet, and extracts the first sending timestamp from the first reference packet; and, receiving a first packet under test sent by the first device, recording a second receiving timestamp of the first packet under test, and extracting a second sending timestamp from the first packet under test; The second device calculates, based on the first sending timestamp, the first receiving timestamp, the second sending timestamp, the second receiving timestamp, and the first reference delay information related to the transmission of the first reference packet from the first device to the second device, the transmission delay of the first tested packet from the first device to the second device; wherein the transmission of the first reference packet from the first device to the second device adopts an end-to-end transmission delay guarantee technology, and the first reference delay information related to the first reference delay is a pre-acquired end-to-end one-way delay of the first reference packet; Obtain information related to a reference delay of transmitting the reference packet between a transmitting device and a receiving device by following the steps below: Configuring a network forwarding device with an equal-length period T, wherein the network forwarding device applies a preset scheduling and priority forwarding technology to forward reference packets, and the sum of the processing delay and queue buffering delay of the reference packets within the device is equal to the equal-length period T; Determine the number of routing hops and the total link length between the sending device and the receiving device according to the network topology and routing rules, and determine the total link transmission time according to the total link length; The product of 2T and the number of routing hops is calculated and added to the total link transmission time to obtain information related to a reference delay of transmitting a reference packet from the sending device to the receiving device.
2. The method according to claim 1, wherein The calculating, based on the first sending timestamp, the first receiving timestamp, the second sending timestamp, the second receiving timestamp, and the first reference delay of the first reference packet being transmitted from the first device to the second device, a transmission delay of the first measured packet from the first device to the second device includes: The transmission delay of the first measured packet from the first device to the second device is calculated according to the following formula: Dtarget=Tr2+Ts1-Tr1-Ts2+Dref Among them, Ts1, Ts2, Tr1, Tr2 and Dref respectively represent the first sending timestamp, the second sending timestamp, the first receiving timestamp, the second receiving timestamp and the first reference delay related information, and Dtarget represents the transmission delay of the first measured packet from the first device to the second device.
3. The method according to claim 1, wherein Before calculating the transmission delay of the first packet under test from the first device to the second device, the method further includes: With the first device as a sending device and the second device as a receiving device, a reference delay information table is searched to obtain information related to a first reference delay of transmitting a first reference packet from the first device to the second device.
4. The method according to any one of claims 1 to 3, wherein The step of receiving, by the second device, a first reference packet sent by the first device specifically includes: The second device receives at least one reference packet sent by the first device, and selects a reference packet from the at least one reference packet that is closest in reception time to the first packet under test as the first reference packet.
5. The method according to claim 1, wherein Obtain information related to a reference delay of transmitting the reference packet between a transmitting device and a receiving device by following the steps below: Connecting a global satellite navigation system module to the sending device and the receiving device respectively, and performing time synchronization on the sending device and the receiving device through the global satellite navigation system module; receiving a reference packet sent by the sending device, recording a receiving timestamp of the reference packet, and extracting a sending timestamp from the reference packet; Information related to a reference delay of transmitting the reference packet from the transmitting device to the receiving device is calculated based on the transmitting timestamp and the receiving timestamp.
6. The method according to claim 1, wherein The first reference packet and the first measured packet each include a measurement header, wherein the measurement header includes an identifier of a first device serving as a sending device, an identifier of a second device serving as a receiving device, and a corresponding sending timestamp.
7. A delay measurement method, characterized in that: include: The first device adds a first sending timestamp to the first reference packet, and sends the first reference packet to the second device; and, marking the first tested packet with a second sending timestamp, and sending the first tested packet to the second device; wherein the first reference packet is transmitted from the first device to the second device using an end-to-end transmission delay guarantee technology, and the first reference delay related information is a pre-acquired end-to-end one-way delay of the first reference packet; The reference delay related information of the reference packet transmitted between the sending device and the receiving device is obtained according to the following steps: Configuring a network forwarding device with an equal-length period T, wherein the network forwarding device applies a preset scheduling and priority forwarding technology to forward reference packets, and the sum of the processing delay and queue buffering delay of the reference packets within the device is equal to the equal-length period T; Determine the number of routing hops and the total link length between the sending device and the receiving device according to the network topology and routing rules, and determine the total link transmission time according to the total link length; The product of 2T and the number of routing hops is calculated and added to the total link transmission time to obtain information related to a reference delay of transmitting a reference packet from the sending device to the receiving device.
8. The method according to claim 7, wherein The first reference packet and the first measured packet each include a measurement header, wherein the measurement header includes an identifier of a first device serving as a sending device, an identifier of a second device serving as a receiving device, and a corresponding sending timestamp.
9. A second delay measurement device, characterized in that: include: an ingress timestamp module, configured to, upon receiving a first reference packet sent by a first delay measurement device, record a first reception timestamp of the first reference packet, and upon receiving a first measured packet sent by the first delay measurement device, record a second reception timestamp of the first measured packet; a decapsulation module, configured to extract a first sending timestamp from the first reference packet; and, extracting a second sending timestamp from the first tested packet; a delay calculation module, configured to calculate a transmission delay of the first measured packet from the first delay measurement device to the second delay measurement device based on the first transmission timestamp, the first reception timestamp, the second transmission timestamp, the second reception timestamp, and first reference delay related information for transmitting the first reference packet from the first delay measurement device to the second delay measurement device; wherein the transmission of the first reference packet from the first delay measurement device to the second delay measurement device employs an end-to-end transmission delay guarantee technology, and the first reference delay related information is a pre-acquired end-to-end one-way delay of the first reference packet; The second delay measurement device also includes: The first reference delay acquisition module is configured to acquire information related to the reference delay of transmitting the reference packet between the sending device and the receiving device according to the following steps: Configuring a network forwarding device with an equal-length period T, wherein the network forwarding device applies a preset scheduling and priority forwarding technology to forward reference packets, and the sum of the processing delay and queue buffering delay of the reference packets within the device is equal to the equal-length period T; Determine the number of routing hops and the total link length between the sending device and the receiving device according to the network topology and routing rules, and determine the total link transmission time according to the total link length; The product of 2T and the number of routing hops is calculated and added to the total link transmission time to obtain information related to a reference delay of transmitting a reference packet from the sending device to the receiving device.
10. The second delay measurement device according to claim 9, wherein: The delay calculation module is specifically configured to calculate the transmission delay of the first measured packet from the first delay measurement device to the second delay measurement device according to the following formula: Dtarget=Tr2+Ts1-Tr1-Ts2+Dref Among them, Ts1, Ts2, Tr1, Tr2 and Dref respectively represent the first sending timestamp, the second sending timestamp, the first receiving timestamp, the second receiving timestamp and the first reference delay related information, and Dtarget represents the transmission delay related information of the first measured packet from the first delay measurement device to the second delay measurement device.
11. The second delay measurement device according to claim 9, wherein: Also includes: The reference delay search module is configured to use the first delay measurement device as a sending device and the second delay measurement device as a receiving device to search the reference delay information table to obtain first reference delay related information when the first reference packet is transmitted from the first delay measurement device to the second delay measurement device.
12. The second delay measurement device according to any one of claims 9 to 11, characterized in that: The first reference packet is a reference packet that is closest in reception time to the first packet under test.
13. The second delay measurement device according to claim 9, wherein: Also includes: The second reference delay acquisition module is configured to acquire information related to the reference delay of transmitting the reference packet between the sending device and the receiving device according to the following steps: Connecting a global satellite navigation system module to the sending device and the receiving device respectively, and performing time synchronization on the sending device and the receiving device through the global satellite navigation system module; receiving a reference packet sent by the sending device, recording a receiving timestamp of the reference packet, and extracting a sending timestamp from the reference packet; Information related to a reference delay of transmitting the reference packet from the transmitting device to the receiving device is calculated based on the transmitting timestamp and the receiving timestamp.
14. The second delay measurement device according to claim 9, wherein: The first reference packet and the first measured packet each include a measurement header, wherein the measurement header includes an identifier of a first delay measurement device as a sending device, an identifier of a second delay measurement device as a receiving device, and a corresponding sending timestamp.
15. A second delay measurement device, characterized in that: including a transceiver and a processor, wherein The transceiver is configured to receive a first reference packet sent by a first delay measurement device, record a first reception timestamp of the first reference packet, and extract a first transmission timestamp from the first reference packet; and receive a first measured packet sent by the first delay measurement device, record a second reception timestamp of the first measured packet, and extract a second transmission timestamp from the first measured packet; The processor is configured to calculate the transmission delay of the first measured packet from the first delay measurement device to the second delay measurement device based on the first sending timestamp, the first receiving timestamp, the second sending timestamp, the second receiving timestamp, and first reference delay related information when the first reference packet is transmitted from the first delay measurement device to the second delay measurement device; wherein the transmission of the first reference packet from the first delay measurement device to the second delay measurement device adopts an end-to-end transmission delay guarantee technology, and the first reference delay related information is a pre-acquired end-to-end one-way delay of the first reference packet; The reference delay related information of the reference packet transmitted between the sending device and the receiving device is obtained according to the following steps: Configuring a network forwarding device with an equal-length period T, wherein the network forwarding device applies a preset scheduling and priority forwarding technology to forward reference packets, and the sum of the processing delay and queue buffering delay of the reference packets within the device is equal to the equal-length period T; Determine the number of routing hops and the total link length between the sending device and the receiving device according to the network topology and routing rules, and determine the total link transmission time according to the total link length; The product of 2T and the number of routing hops is calculated and added to the total link transmission time to obtain information related to a reference delay of transmitting a reference packet from the sending device to the receiving device.
16. The second delay measurement device according to claim 15, wherein: The processor is further configured to calculate a transmission delay of the first measured packet from the first delay measurement device to the second delay measurement device according to the following formula: Dtarget=Tr2+Ts1-Tr1-Ts2+Dref Among them, Ts1, Ts2, Tr1, Tr2 and Dref respectively represent the first sending timestamp, the second sending timestamp, the first receiving timestamp, the second receiving timestamp and the first reference delay related information, and Dtarget represents the transmission delay related information of the first measured packet from the first delay measurement device to the second delay measurement device.
17. A second delay measurement device, characterized in that: include: A processor, a memory, and a program stored in the memory and executable on the processor, wherein when the program is executed by the processor, the steps of the method according to any one of claims 1 to 6 are implemented.
18. A first delay measurement device, characterized in that: include: an egress timestamp module, configured to stamp a first transmission timestamp on a first reference packet and a second transmission timestamp on a first measured packet, wherein the transmission of the first reference packet from the first delay measurement device to the second delay measurement device adopts an end-to-end transmission delay guarantee technology; an encapsulation module, configured to encapsulate the first sending timestamp in a first reference packet and send the first reference packet to a second delay measurement device, and to encapsulate the second sending timestamp in a first measured packet and send the first measured packet to the second delay measurement device, where the first reference delay-related information is a pre-acquired end-to-end one-way delay of the first reference packet; The reference delay related information of the reference packet transmitted between the sending device and the receiving device is obtained according to the following steps: Configuring a network forwarding device with an equal-length period T, wherein the network forwarding device applies a preset scheduling and priority forwarding technology to forward reference packets, and the sum of the processing delay and queue buffering delay of the reference packets within the device is equal to the equal-length period T; Determine the number of routing hops and the total link length between the sending device and the receiving device according to the network topology and routing rules, and determine the total link transmission time according to the total link length; The product of 2T and the number of routing hops is calculated and added to the total link transmission time to obtain information related to a reference delay of transmitting a reference packet from the sending device to the receiving device.
19. The first delay measurement device according to claim 18, wherein: The first reference packet and the first measured packet each include a measurement header, wherein the measurement header includes an identifier of a first delay measurement device as a sending device, an identifier of a second delay measurement device as a receiving device, and a corresponding sending timestamp; The encapsulation module is further configured to encapsulate the first sending timestamp, the identifiers of the first delay measurement device and the second delay measurement device in a measurement header of a first reference packet, and to encapsulate the second sending timestamp, the identifiers of the first delay measurement device and the second delay measurement device in a measurement header of a first measured packet.
20. A first delay measurement device, characterized in that: including a transceiver and a processor, wherein The processor is configured to stamp a first sending timestamp on a first reference packet and stamp a second sending timestamp on a first measured packet, wherein the transmission of the first reference packet from the first delay measurement device to the second delay measurement device adopts an end-to-end transmission delay guarantee technology; the transceiver being configured to encapsulate the first sending timestamp in a first reference packet and send the first reference packet to a second delay measurement device, and to encapsulate the second sending timestamp in a first measured packet and send the first measured packet to the second delay measurement device, where the first reference delay-related information is a pre-acquired end-to-end one-way delay of the first reference packet; The reference delay related information of the reference packet transmitted between the sending device and the receiving device is obtained according to the following steps: Configuring a network forwarding device with an equal-length period T, wherein the network forwarding device applies a preset scheduling and priority forwarding technology to forward reference packets, and the sum of the processing delay and queue buffering delay of the reference packets within the device is equal to the equal-length period T; Determine the number of routing hops and the total link length between the sending device and the receiving device according to the network topology and routing rules, and determine the total link transmission time according to the total link length; The product of 2T and the number of routing hops is calculated and added to the total link transmission time to obtain information related to a reference delay of transmitting a reference packet from the sending device to the receiving device.
21. A first delay measurement device, characterized in that: include: A processor, a memory, and a program stored in the memory and executable on the processor, wherein when the program is executed by the processor, the steps of the method according to any one of claims 7 to 8 are implemented.
22. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, which, when executed by a processor, implements the steps of the method according to any one of claims 1 to 8.
Citation Information
Patent Citations
Measurement one way delay method and equipment thereof, and communication system
CN102227110A
Method and device for acquiring data transmission delay
CN105610652A
Method and system for measuring one-way delay variation
WO2001091375A2