Delay measurement method and system based on in-band dyeing mechanism
By coloring and adding sequence numbers to data packets for delay measurement on the node device, and reporting the transmission timestamp, the problems of low delay measurement accuracy and poor real-time performance in the prior art are solved, and higher delay measurement accuracy and real-time performance are achieved.
Patent Information
- Application Number
- CN202310452133.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-04-25
- Publication Date
- 2025-11-21
- Estimated Expiration
- 2043-04-25
AI Technical Summary
Existing delay measurement methods based on in-band coloring mechanisms suffer from low accuracy and poor real-time performance, especially when messages are lost or out of order, they cannot accurately measure delay.
By performing latency measurement, staining, and adding sequence numbers to the data packets to be stained on each node device, stained packets are generated, and transmission timestamps are reported during transmission. The network management platform uses this information to perform latency measurement, ensuring the accuracy and real-time performance of latency measurement.
It improves the accuracy and real-time performance of delay measurement, reduces the impact of out-of-order messages and packet loss on measurement, and ensures the reliability of delay measurement.
Smart Images

Figure CN116614415B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of communication, in particular to a time delay measurement method and system based on in-band dyeing mechanism. BACKGROUND
[0002] With the network expansion, network devices are more and more, the type of service increases, bandwidth increases, which puts forward higher requirements for network operation and management, network state capture, and service forwarding information perception.
[0003] Network visualization develops from the initial SPAN, IPFIX and other data mirror analysis server, service forwarding information reporting, to INT, Insuit OAM, InBand OAM and other service packet information detection. The development of visualization technology gradually changes from multi-service large bandwidth to end-to-end service hop-by-hop detection. InBand OAM technology can measure the time delay based on in-band dyeing mechanism to dye the actual service flow, that is, to mark it. The current time delay measurement method using InBand OAM technology often has the problems of low accuracy and poor real-time performance. SUMMARY
[0004] Therefore, the purpose of the present application is to provide a time delay measurement method and system based on in-band dyeing mechanism.
[0005] In order to achieve the above purpose, the technical scheme adopted by the present application is as follows:
[0006] In the first aspect, the present application provides a time delay measurement method based on in-band dyeing mechanism, which is applied to a time delay measurement system. The time delay measurement system comprises a plurality of node devices connected in sequence. Each node device is connected with a network management platform. The method comprises the following steps:
[0007] When the first node device receives a to-be-dyed data packet, it performs time delay measurement dyeing and adds a sequence number to obtain a dyed packet, and sends the dyed packet to the next node device;
[0008] Each intermediate node device receives the dyed packet sent by the previous node device, and sends the dyed packet to the next node device;
[0009] The tail node device receives the dyed packet;
[0010] Each node device obtains a target packet corresponding to itself based on the dyed packet and a dyeing packet transmission timestamp corresponding to itself, and sends the target packet to the network management platform, so that the network management platform performs time delay measurement based on the target packet sent by each node device.
[0011] In an optional implementation, the first node device performs time delay measurement coloring and adds a sequence number to the to-be-colored data packet to obtain the colored packet, including:
[0012] The first node device encapsulates the to-be-colored data packet to obtain the to-be-colored packet, and the to-be-colored packet includes a time delay measurement coloring field, an extended data type field and an extended data field;
[0013] The first node device sets the time delay measurement coloring field in the to-be-colored packet to a preset coloring value;
[0014] The first node device sets the extended data type field in the to-be-colored packet to a preset type value;
[0015] The first node device obtains the sequence number of the to-be-colored data packet, and sets the extended data field in the to-be-colored packet to the sequence number of the to-be-colored data packet to obtain the colored packet.
[0016] In an optional implementation, the first node device receives N to-be-colored data packets in a time delay measurement period, and the sequence number of the to-be-colored data packet represents the order of the to-be-colored data packet in the N to-be-colored data packets, and N is an integer greater than 1.
[0017] In an optional implementation, the coloring packet transmission timestamp is a receiving timestamp, and the target packet includes a first target packet;
[0018] Each node device obtains a corresponding target packet based on the colored packet and a coloring packet transmission timestamp corresponding to the node device, and sends the corresponding target packet to the network management platform, including:
[0019] The first node device obtains a receiving timestamp corresponding to the first node device when the to-be-colored data packet is received;
[0020] The first node device adds the receiving timestamp corresponding to the first node device to the extended data field of the colored packet, obtains a first target packet corresponding to the first node device, and sends the first target packet to the network management platform;
[0021] Each intermediate node device and the tail node device obtains a receiving timestamp corresponding to the device when the colored packet is received;
[0022] Each intermediate node device and the tail node device adds the receiving timestamp corresponding to the device to the extended data field of the colored packet, obtains a first target packet corresponding to the device, and sends the first target packet to the network management platform.
[0023] In an optional implementation, the coloring packet transmission timestamp is a sending timestamp, and the target packet includes a second target packet;
[0024] Each node device obtains a target packet corresponding to itself based on the colored packet and a transmission timestamp of a colored packet corresponding to itself, and sends the target packet to the network management platform, including:
[0025] The first node device and each intermediate node device obtain a transmission timestamp of the colored packet sent by itself.
[0026] The first node device and each intermediate node device add the transmission timestamp corresponding to itself in an extension data field of the colored packet, obtain a second target packet corresponding to itself, and send the second target packet to the network management platform.
[0027] In an optional embodiment, the network management platform performs the time delay measurement based on the target packet sent by each node device in the following manner:
[0028] The network management platform obtains a sequence number and a colored packet transmission timestamp in each target packet based on the target packet sent by each node device, and performs the time delay measurement based on multiple colored packet transmission timestamps corresponding to the same sequence number.
[0029] In a second aspect, the present application provides a time delay measurement system based on an in-band coloring mechanism, which includes a plurality of node devices connected in sequence, and each node device is connected with a network management platform in communication.
[0030] The first node device is configured to perform time delay measurement coloring and add a sequence number to the to-be-colored data packet to obtain a colored packet when receiving the to-be-colored data packet, and send the colored packet to a next node device.
[0031] Each intermediate node device is configured to receive the colored packet sent by a previous node device, and send the colored packet to a next node device.
[0032] The tail node device is configured to receive the colored packet.
[0033] Each node device is further configured to obtain a target packet corresponding to itself based on the colored packet and a transmission timestamp of a colored packet corresponding to itself, and send the target packet to the network management platform, so that the network management platform performs time delay measurement based on the target packet sent by each node device.
[0034] In an optional embodiment, the first node device is further configured to:
[0035] The to-be-colored data packet is encapsulated to obtain a to-be-colored packet, and the to-be-colored packet includes a time delay measurement coloring field, an extension data type field, and an extension data field.
[0036] setting a delay measurement coloring field in the to-be-colored packet to a preset coloring value;
[0037] setting an extended data type field in the to-be-colored packet to a preset type value;
[0038] obtaining a sequence number of the to-be-colored packet, and setting an extended data field in the to-be-colored packet to the sequence number of the to-be-colored packet to obtain the colored packet.
[0039] In an optional implementation, the first node device receives N to-be-colored packets in a delay measurement period, the sequence number of the to-be-colored packet represents the order of the to-be-colored packet in the N to-be-colored packets, and N is an integer greater than 1.
[0040] In an optional implementation, the coloring packet transmission timestamp is a receiving timestamp, and the target packet includes a first target packet.
[0041] The first node device is further configured to: obtain a timestamp at which the to-be-colored packet is received, to obtain a receiving timestamp corresponding to the first node device; add the receiving timestamp corresponding to the first node device in the extended data field of the colored packet, obtain a first target packet corresponding to the first node device, and send the first target packet to the network management platform.
[0042] Each intermediate node device and the tail node device are further configured to: obtain a timestamp at which the colored packet is received by the device itself, to obtain a receiving timestamp corresponding to the device itself; add the receiving timestamp corresponding to the device itself in the extended data field of the colored packet, obtain a first target packet corresponding to the device itself, and send the first target packet to the network management platform.
[0043] The present application provides a delay measurement method and system based on an in-band coloring mechanism, the delay measurement system including a plurality of node devices connected in sequence, each node device being connected to a network management platform, a first node device performing delay measurement coloring and adding a sequence number to a to-be-colored packet to obtain a colored packet when receiving the to-be-colored packet, and sending the colored packet to a next node device; each intermediate node device receiving a colored packet sent by a previous node device and sending the colored packet to a next node device; a tail node device receiving the colored packet; and each node device obtaining a target packet corresponding to the device itself based on the colored packet and a coloring packet transmission timestamp corresponding to the device itself, and sending the target packet to the network management platform, so that the network management platform performs delay measurement based on the target packet sent by each node device. The timestamp reported by each node device can reflect the delay in a timely manner, and adding the sequence number effectively reduces the measurement error caused by packet disorder, thereby improving the real-time performance and accuracy of delay measurement.
[0044] In order to make the above objectives, characteristics and advantages of the present application more apparent, the following preferred embodiments are specifically described in detail below, together with the accompanying drawings. BRIEF DESCRIPTION OF DRAWINGS
[0045] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the following will briefly introduce the drawings needed to be used in the embodiments, and it should be understood that the following drawings only show some of the embodiments of the present application, and therefore should not be regarded as a limitation to the scope, and for those skilled in the art, other related drawings can also be obtained without creative labor on the basis of these drawings.
[0046] Figure 1 An example diagram of the in-band dyeing mechanism based delay measurement method provided by the embodiments of the present application is shown;
[0047] Figure 2 A schematic diagram of the delay measurement system provided by the embodiments of the present application is shown;
[0048] Figure 3 A block schematic diagram of the electronic device provided by the embodiments of the present application is shown;
[0049] Figure 4 A flow schematic diagram of the in-band dyeing mechanism based delay measurement method provided by the embodiments of the present application is shown;
[0050] Figure 5 Another example diagram of the in-band dyeing mechanism based delay measurement method provided by the embodiments of the present application is shown.
[0051] Icon: 120-processor; 130-memory; 170-communication interface. DETAILED DESCRIPTION
[0052] The technical solutions in the embodiments of the present application will be described clearly and completely below in combination with the drawings in the embodiments of the present application, and obviously, the described embodiments are only some of the embodiments of the present application, but not all the embodiments. The components of the embodiments of the present application described and shown in the drawings herein can be arranged and designed in various different configurations.
[0053] Therefore, the following detailed description of the embodiments of the present application provided in the drawings is not intended to limit the scope of the claimed present application, but only represents selected embodiments of the present application. Based on the embodiments of the present application, all other embodiments obtained by those skilled in the art without creative labor are within the scope of the present application.
[0054] It is to be noted that the relational terms herein, such as first and second, and the like, are used solely to distinguish one from another entity or action without necessarily requiring or implying any actual relationship or order between such entities or actions. Moreover, the terms "comprises", "comprising", or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but can include other elements not expressly listed or inherent to such process, method, article, or apparatus. An element proceeded by "comprises... a" does not, without more constraints, exclude the presence of additional identical elements in the process, method, article, or apparatus that comprises the element.
[0055] With network expansion, network devices are more and more, the type of business increases, bandwidth increases, the network operation and management, network state capture, business forwarding information perception are put forward higher requirements. Network visualization from the initial SPAN, IPFIX and other data mirror analysis server, business forwarding information reporting, to INT, Insuit OAM, InBand OAM and other business packet information detection, the development of visualization technology corresponding to multi-service large bandwidth gradually changes into business end-to-end, hop-by-hop detection mode. InBand OAM technology can be based on in-band dyeing mechanism, dyeing, i.e. marking actual business flow to measure delay.
[0056] For ease of understanding, an InBand OAM technology delay measurement principle example diagram is provided in the embodiments of the present application. Please refer to Figure 1 , which includes a sending end, a receiving end and a network management platform. The sending end sends a message a in a business flow after dyeing by delay measurement to the receiving end, and the sending end and the receiving end report time stamps of transmitting the message a to the network management platform, such as t1 and t2; the receiving end sends a message b in a business flow after dyeing by delay measurement to the sending end, and the receiving end and the sending end report time stamps of transmitting the message b to the network management platform, such as t3 and t4. According to the time difference between t1 and t2, the one-way delay from the sending end to the receiving end, i.e. t2-t1, can be obtained, according to the time difference between t3 and t4, the one-way delay from the receiving end to the sending end, i.e. t4-t3, can be obtained, and the two-way delay, i.e. (t2-t1)+(t4-t3), can also be obtained.
[0057] The current delay measurement mode using InBand OAM technology often has problems of low accuracy and poor real-time performance. For example, at present, generally only one message dyed by delay measurement is sent in each delay measurement period, and then the time stamp of transmitting the message is reported to the network management platform by different node devices for delay measurement. Since there is only one dyed message, the measurement of delay is very dependent on the dyed message, so if the dyed message is lost in the link, the delay cannot be measured, and only one dyed message in the period will also cause poor real-time performance. Although currently multiple dyed messages are sent in a delay measurement period, and the average value is calculated to measure the delay, a new problem of message disorder is introduced, and if the dyed message is lost, the delay jitter will be large, resulting in inaccurate delay measurement. Therefore, the embodiment of the present application provides a delay measurement method based on an in-band dyeing mechanism to solve the above problems.
[0058] Please refer to Figure 2 , which is a schematic diagram of a delay measurement system provided by the embodiment of the present application, wherein the delay measurement system includes a plurality of node devices connected in sequence, and each node device is connected with a network management platform. The node device is used for transmitting a message and reporting the time stamp of transmitting the dyed message; and the network management platform is used for measuring the delay according to the time stamp reported by the plurality of node devices.
[0059] All node devices of the delay measurement system include a first node device, a last node device and at least one intermediate node device. The first node device can be understood as the input end of the delay measurement system, and the last node device can be understood as the output end of the delay measurement system.
[0060] Please refer to Figure 3 , which is a block schematic diagram of an electronic device provided by the embodiment of the present application, the structure of which can be used to implement the node device or the network management platform in the above Figure 2 , and the electronic device includes a processor 120, a memory 130 and a communication interface 170.
[0061] The processor 120, the memory 130 and the communication interface 170 are directly or indirectly electrically connected with each other to realize the transmission or interaction of data. For example, these elements can be electrically connected with each other through one or more communication buses or signal lines.
[0062] The processor 120 can be an integrated circuit chip with processing capability of signals, which can be a general processor, such as a central processing unit (CPU), a network processor (NP), etc.; or can be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.
[0063] The memory 130 can be a random access memory (RAM), a read only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), etc.
[0064] The communication interface 170 can be used for signaling or data communication with other node devices.
[0065] It can be understood that, Figure 3 The structure shown is only a structural schematic diagram of the electronic device, and the electronic device can further include more or less components than those shown in the description, or have a different configuration from that shown in the description. Figure 3 The components shown in the description can be implemented in hardware, software or a combination thereof. Figure 3 The components shown in the description can be implemented in hardware, software or a combination thereof. Figure 3 The components shown in the description can be implemented in hardware, software or a combination thereof.
[0066] The time delay measurement system described above will be taken as an execution subject to execute each step in each method provided by the embodiments of the present application, and to achieve the corresponding technical effects.
[0067] Please refer to Figure 4 , Figure 4 is a flowchart of a time delay measurement method based on an in-band dyeing mechanism provided by the embodiments of the present application.
[0068] In step S202, the first node device performs time delay measurement dyeing and adds a sequence number to the to-be-dyed data packet to obtain a dyed packet when receiving the to-be-dyed data packet, and sends the dyed packet to the next node device.
[0069] In the embodiment, the first node device in the time delay measurement system is configured to encapsulate the received data packet into a message and send the message to the next node device to start transmission of the message. If the first node device receives a data packet to be colored, i.e., a data packet used for measuring time delay, the first node device performs time delay measurement coloring on the data packet to be colored and adds a sequence number to the data packet to be colored to obtain a colored message and send the colored message to the next node device to start transmission of the colored message.
[0070] It can be understood that the time delay measurement coloring performed by the first node device on the data packet to be colored is to mark the data packet to be colored as a data packet used for measuring time delay, and the adding of the sequence number to the data packet to be colored by the first node device is to mark the sending order of the data packet to be colored.
[0071] In step S204, each intermediate node device receives the colored message sent by the previous node device and sends the colored message to the next node device.
[0072] In step S206, the tail node device receives the colored message.
[0073] In the embodiment, for each intermediate node device in the time delay measurement system, the intermediate node device is configured to send the received message to the next node device, i.e., sequentially transmit the message, and when the message is transmitted to the tail node device, the tail node device receives the message and obtains the content of the message from the message.
[0074] In a similar manner as described above, each intermediate node device receives the colored message sent by the previous node device and sends the colored message to the next node device, i.e., sequentially transmit the colored message, and when the colored message is transmitted to the tail node device, the tail node device obtains the content of the message from the colored message. It can be understood that the colored message is transmitted in a network composed of multiple node devices.
[0075] In step S208, each node device obtains a target message corresponding to the node device based on the colored message and a transmission time stamp of the colored message corresponding to the node device, and sends the target message to the network management platform, so that the network management platform performs time delay measurement based on the target messages sent by each node device.
[0076] In the embodiment, each node device can also obtain a target message corresponding to the node device based on the colored message and a transmission time stamp of the colored message corresponding to the node device, and send the target message to the network management platform; and the network management platform receives the target messages sent by each node device and performs time delay measurement based on the target messages.
[0077] It can be understood that each node device transmits the colored packet and reports the time stamp of the colored packet flowing through itself to the network management platform, so that the network management platform measures the time delay based on the time stamp of the colored packet flowing through each node device. The network management platform can reflect the time delay in time based on the time stamp reported by each node device, improve the real-time performance of time delay measurement, effectively reduce the measurement error caused by packet disordering by adding the sequence number, and improve the accuracy of time delay measurement.
[0078] It can be seen that based on the above steps, the first node device performs time delay measurement coloring and adds a sequence number to the to-be-colored data packet to obtain a colored packet when receiving the to-be-colored data packet, and sends the colored packet to the next node device; each intermediate node device receives the colored packet sent by the previous node device and sends it to the next node device; the tail node device receives the colored packet; and each node device obtains the target packet corresponding to itself based on the colored packet and the corresponding coloring packet transmission time stamp of itself, and sends it to the network management platform, so that the network management platform measures the time delay based on the target packet sent by each node device. The time delay can be reflected in time through the time stamp reported by each node device, and the measurement error caused by packet disordering can be effectively reduced by adding the sequence number, thereby improving the real-time performance and accuracy of time delay measurement.
[0079] Optionally, for the process of performing time delay measurement coloring and adding a sequence number to the to-be-colored data packet by the first node device in step S202, the embodiment of the present application provides a possible implementation manner.
[0080] In step S202-1, the first node device encapsulates the to-be-colored data packet to obtain a to-be-colored packet, and the to-be-colored packet includes a time delay measurement coloring field, an extended data type field, and an extended data field.
[0081] In step S202-3, the first node device sets the time delay measurement coloring field in the to-be-colored packet to a preset coloring value.
[0082] In step S202-5, the first node device sets the extended data type field in the to-be-colored packet to a preset type value.
[0083] In step S202-7, the first node device obtains the sequence number of the to-be-colored data packet, and sets the extended data field in the to-be-colored packet to the sequence number of the to-be-colored data packet to obtain a colored packet.
[0084] In this embodiment, the first node device encapsulates the to-be-colored data packet to obtain a to-be-colored packet, and the to-be-colored packet includes a time delay measurement coloring field, an extended data type field, and an extended data field. For ease of understanding, the embodiment of the present application provides a packet format example diagram.
[0085] Please refer to Figure 5 For the message using InBand OAM technology, the InBand OAM guide label can be referred to as IOAM FII, the InBand OAM flow instruction header can be referred to as IOAM FIH, and the InBand OAM extension data can be referred to as IOAM FIEH. Among them, the InBand OAM guide label and the InBand OAM flow instruction header are necessary parts in the message, and the InBand OAM extension data is an optional part.
[0086] The InBand OAM guide label occupies one MPLS label bit, that is, 32 bits, and is guided by a specific reserved label to indicate that the InBand OAM flow instruction header content is behind the label. The guide label is an MPLS reserved label (0-15), and the default value is "0xC". The TC, S and TTL fields are required to comply with the RFC 3032 standard.
[0087] The InBand OAM flow instruction header occupies one MPLS label bit, that is, 32 bits, and carries basic information used for in-band flow detection, including flow identification, coloring indication field, type indication field and the like. As shown in Figure 5 Flow ID in
[0088] As shown in Figure 5 D represents the delay measurement coloring field, and based on the value of the delay measurement coloring field, it can be marked whether the message is used for measuring delay. For example, if the delay measurement coloring field is set to 1, it indicates that the message is used for measuring delay, and if it is set to 0, it indicates that the message is not used for measuring delay.
[0089] As shown in Figure 5 NextHeader represents the extension data type field, which is used to indicate whether to carry extension data. Different values of the extension data type field represent different meanings. If the value is 0x00, it means reserved, if the value is 0x01, it means that no extension data is carried and the IOAM FIH carries basic information, if the value is 0x02, it means that no extension data is carried and the IOAM FIH carries optional hop-by-hop detection information, and if the value is 0x03 to 0xFF, it means that extension data is carried, that is, the InBand OAM extension data part is reserved for use.
[0090] The InBand OAM extension data is a self-defined extension content, and it can be understood that the embodiment of the application improves the real-time performance and accuracy of the delay measurement by using the InBand OAM extension data.
[0091] The first node device encapsulates the to-be-dyed data packet into a to-be-dyed message, sets a time delay measurement dyeing field in the to-be-dyed message to a preset dyeing value, such as setting the value of the time delay measurement dyeing field to 1 to mark the message as being used for measuring time delay, and sets an extension data type field in the to-be-dyed message to a preset type value, such as setting the value of the extension data type field to any one of 0x03 to 0xFF to indicate that the message carries extension data, and at the same time, acquires a sequence number of the to-be-dyed data packet and sets the sequence number as the value of the extension data field to mark the order of the to-be-dyed data packet, that is, to obtain a dyed message.
[0092] It can be understood that, in order to avoid the situation that a packet is lost and time delay cannot be measured, the first node device receives a plurality of, such as N, to-be-dyed data packets in a time delay measurement period, N can be set in advance according to actual application and N is an integer greater than 1. In order to reduce the measurement error caused by message disordering, the first node device also adds the sequence number of the to-be-dyed data packet in the process of encapsulating the to-be-dyed data packet to mark the order of each to-be-dyed data packet in a time delay measurement period.
[0093] Alternatively, the dyeing message transmission timestamp can be a receiving timestamp and also a sending timestamp, and then based on the two kinds of timestamps, the embodiment of the application provides two implementation manners for the above step S208, and the implementation manner in the case that the dyeing message transmission timestamp is a receiving timestamp is introduced first.
[0094] In step S208A-1, the first node device acquires a timestamp of receiving the to-be-dyed data packet to obtain a corresponding receiving timestamp of the first node device.
[0095] In step S208A-3, the first node device adds the corresponding receiving timestamp of the first node device to the extension data field of the dyed message to obtain a corresponding first target message of the first node device and send the first target message to the network management platform.
[0096] In the embodiment, since the first node device receives a data packet, the first node device takes the timestamp of receiving the to-be-dyed data packet as the corresponding receiving timestamp of the first node device, adds the corresponding receiving timestamp of the first node device to the extension data field of the dyed message, that is, obtains the corresponding first target message of the first node device and sends the first target message to the network management platform. It can be understood that the first node device reports the timestamp of receiving the to-be-dyed data packet to the network management platform.
[0097] In step S208A-5, each intermediate node device and tail node device acquires a timestamp of receiving the dyed message to obtain a corresponding receiving timestamp of the device.
[0098] In step S208A-7, each intermediate node device and tail node device adds the corresponding receiving timestamp of the device to the extension data field of the dyed message to obtain a corresponding first target message of the device and send the first target message to the network management platform.
[0099] It can be understood that the first node device and each intermediate node device send the first target message in a similar way. For brevity, any one of the first node device and all intermediate node devices is taken as a second node device for example description below.
[0100] In this embodiment, the first node device takes the time stamp of the received colored message as the corresponding receiving time stamp, and adds the corresponding receiving time stamp to the extension data field of the colored message, that is, obtains the corresponding first target message and sends it to the network management platform.
[0101] In a similar way, each intermediate node device and tail node device obtains the corresponding first target and sends it to the network management platform. It can be understood that each intermediate node device and tail node device will report the time stamp of the received colored message to the network management platform.
[0102] The network management platform receives the first target message sent by each node device, and performs time delay measurement based on the sequence number and receiving time stamp carried by each first target message.
[0103] The implementation manner when the time stamp of the colored message is the sending time stamp will be introduced below.
[0104] Step S208B-1, the first node device and each intermediate node device obtain the time stamp of sending the colored message, and obtain the corresponding sending time stamp;
[0105] Step S208B-3, the first node device and each intermediate node device add the corresponding sending time stamp to the extension data field of the colored message, obtain the corresponding second target message and send it to the network management platform.
[0106] It can be understood that the first node device and each intermediate node device send the second target message in a similar way. For brevity, any one of the first node device and all intermediate node devices is taken as a second node device for example description below.
[0107] In this embodiment, the second node device takes the time stamp of sending the colored message as the corresponding sending time stamp, and adds the corresponding sending time stamp to the extension data field of the colored message, that is, obtains the corresponding second target message and sends it to the network management platform.
[0108] In a similar way, the first node device and each intermediate node device obtain the corresponding second target and send it to the network management platform. It can be understood that the first node device and each intermediate node device will report the time stamp of sending the colored message to the network management platform.
[0109] The network management platform receives the second target message sent by each node device, and performs a time delay measurement based on the sequence number and the receiving time stamp carried by each second target message.
[0110] Optionally, for the process of performing a time delay measurement by the network management platform based on the target message sent by each node device, an embodiment of the present application provides an implementation manner: the network management platform obtains the sequence number and the colored message transmission time stamp in each target message based on the target message sent by each node device, and performs a time delay measurement based on the multiple colored message transmission time stamps corresponding to the same sequence number.
[0111] For the convenience of understanding, an embodiment of the present application provides an example. For example, the time delay measurement system includes node device 1, node device 2 and node device 3 which are sequentially connected in communication, and the node device 1 is the first node device, the node device 2 is the intermediate node device, and the node device 3 is the tail node device. It is assumed that N is 5, that is, there are 5 to-be-colored data packets in a time delay measurement period.
[0112] The first node device, that is, the node device 1, encapsulates the received data packet into a message and sends it to the next node device, that is, the node device 2; the node device 2 sends the received message to the next node device, that is, the node device 3; and the node device 3 receives the message sent by the previous node device, that is, the node device 2, and obtains the message content therefrom. That is, the message is transmitted in the node device 1, the node device 2 and the node device 3 in turn.
[0113] The node device 1 encapsulates the to-be-colored data packet into a to-be-colored message when receiving the to-be-colored data packet, sets the time delay measurement coloring field in the to-be-colored message to a preset coloring value, sets the extended data type field in the to-be-colored message to a preset type value, and sets the extended data field in the to-be-colored message to the sequence number of the to-be-colored data packet, that is, obtains the colored message and sends it to the node device 2.
[0114] Meanwhile, the node device 1 obtains a target message based on the colored message and the corresponding colored message transmission time stamp and sends it to the network management platform.
[0115] The node device 2 sends the received message to the node device 3. Meanwhile, the node device 2 identifies the received message, and if the time delay measurement coloring field in the message is the preset coloring value, it is determined that the message is the colored message, and then a target message is obtained based on the colored message and the corresponding colored message transmission time stamp and sent to the network management platform.
[0116] The node device 3 receives the message sent by the node device 2, and obtains the message content from the message. Meanwhile, the node device 3 identifies the received message, if the time delay measurement dyeing field in the message is the preset dyeing value, it is determined that the message is a dyed message, then the target message is obtained based on the dyed message and the dyeing message transmission timestamp corresponding to the dyed message, and is sent to the network management platform.
[0117] The network management platform receives each target message sent by the node device 1, the node device 2 and the node device 3, obtains the sequence number and the dyeing message transmission timestamp carried by each target message, and performs time delay measurement based on the multiple dyeing message transmission timestamps corresponding to the same sequence number.
[0118] Suppose that the sequence numbers of the five to-be-dyed data packets in a certain time delay measurement period are 1, 2, 3, 4 and 5 in turn, and the sequence number and the dyeing message transmission timestamp carried by each target message obtained by the network management platform are shown in Table 1.
[0119] Table 1
[0120]
[0121] Based on the data shown in Table 1, the time delay between the adjacent two node devices can be calculated, which is shown in Table 2.
[0122] Table 2
[0123]
[0124] Based on Table 2, it can be seen that each node device can report the timestamp of the dyed message flowing through itself to the network management platform, even if the message is sent out of order in the transmission process, the network management platform can determine the timestamp of the message flowing through each node device according to the sequence number, thereby effectively reducing the measurement error caused by the message out of order. And even if the packet is lost, the network management platform can also perform time delay measurement based on the multiple timestamp information of the other to-be-dyed data packets, thereby improving the real-time performance and accuracy of the time delay measurement.
[0125] The embodiment of the application also provides a time delay measurement system. It should be noted that the basic principle and technical effects of the time delay measurement system provided by the embodiment are the same as those of the above-mentioned embodiments. For brevity, the parts not mentioned in the embodiment are referred to the corresponding contents of the above-mentioned embodiments. The time delay measurement system provided by the embodiment comprises a plurality of node devices which are sequentially connected in communication, each node device is connected with a network management platform in communication;
[0126] The first node device is configured to perform time delay measurement coloring and add a sequence number to the to-be-colored data packet to obtain a colored packet when receiving the to-be-colored data packet, and send the colored packet to a next node device;
[0127] Each intermediate node device is configured to receive the colored packet sent by the previous node device, and send the colored packet to a next node device;
[0128] The tail node device is configured to receive the colored packet;
[0129] Each node device is further configured to obtain a target packet corresponding to the node device based on the colored packet and a coloring packet transmission timestamp corresponding to the node device, and send the target packet to a network management platform, so that the network management platform performs time delay measurement based on the target packet sent by each node device.
[0130] Optionally, the first node device is further configured to: encapsulate the to-be-colored data packet to obtain the to-be-colored packet, the to-be-colored packet comprising a time delay measurement coloring field, an extended data type field and an extended data field; set the time delay measurement coloring field in the to-be-colored packet to a preset coloring value; set the extended data type field in the to-be-colored packet to a preset type value; obtain a sequence number of the to-be-colored data packet, and set the extended data field in the to-be-colored packet to the sequence number of the to-be-colored data packet to obtain the colored packet.
[0131] Optionally, the first node device receives N to-be-colored data packets in one time delay measurement period, the sequence number of the to-be-colored data packet representing the order of the to-be-colored data packet in the N to-be-colored data packets, and N is an integer greater than 1.
[0132] Optionally, the coloring packet transmission timestamp is a receiving timestamp, and the target packet comprises a first target packet;
[0133] The first node device is further configured to: obtain a timestamp at which the to-be-colored data packet is received to obtain a receiving timestamp corresponding to the first node device; add the receiving timestamp corresponding to the first node device in the extended data field of the colored packet to obtain a first target packet corresponding to the first node device and send the first target packet to the network management platform;
[0134] Each intermediate node device and the tail node device are further configured to: obtain a timestamp at which the colored packet is received by the node device to obtain a receiving timestamp corresponding to the node device; add the receiving timestamp corresponding to the node device in the extended data field of the colored packet to obtain a first target packet corresponding to the node device and send the first target packet to the network management platform.
[0135] Optionally, the coloring packet transmission timestamp is a sending timestamp, and the target packet comprises a second target packet;
[0136] The first node device and each intermediate node device are further configured to: acquire a time stamp of sending the colored packet by itself, and obtain a sending time stamp corresponding to itself; add the sending time stamp corresponding to itself in an extension data field of the colored packet, and obtain a second target packet corresponding to itself and send the second target packet to the network management platform.
[0137] Optionally, the network management platform performs the time delay measurement based on the target packets sent by each node device in the following manner: the network management platform obtains the sequence number and the colored packet transmission time stamp in each target packet based on the target packets sent by each node device, and performs the time delay measurement based on the multiple colored packet transmission time stamps corresponding to the same sequence number.
[0138] In several embodiments provided by the present application, it should be understood that each block in the flowchart or block diagram can represent a module, a segment or a portion of code which includes one or more executable instructions for implementing the specified logic function. It should also be noted that in some alternative implementation, the functions noted in the blocks can occur out of the order noted in the accompanying figures. For example, two blocks noted in succession can in fact be executed substantially concurrently or in the reverse order, depending on the functionality involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations thereof, can be implemented by a dedicated hardware-based system that performs specified functions or actions, or can be implemented by a combination of dedicated hardware and computer instructions.
[0139] In addition, each functional module in each embodiment of the present application can be integrated together to form an independent part, or each module can exist independently, or two or more modules can be integrated to form an independent part.
[0140] If the functions are realized in the form of software function modules and sold or used as independent products, the software function modules can be stored in a computer readable storage medium. Based on this understanding, the technical solutions of the present application can be embodied in the form of a software product, and the computer software product is stored in a storage medium, and includes a plurality of instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in the embodiments of the present application. The aforementioned storage medium includes: a U disk, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, and various media that can store program codes.
[0141] The above merely provides the preferred embodiments of the present application, and is not used to limit the present application. For those skilled in the art, the present application can have various modifications and changes. Any modifications, equivalent replacements, improvements, etc. made within the principles and technical scope of the present application shall fall into the scope of the present application.
Claims
1. A time delay measurement method based on in-band staining mechanism, characterized in that, The method, applied to a time delay measurement system, comprising multiple node devices sequentially connected in communication, each node device being connected in communication with a network management platform, includes: When the first node device receives the data packet to be colored, it performs delay measurement, coloring, and adds a sequence number to the data packet to obtain a colored message, and then sends the colored message to the next node device. Each intermediate node device receives the stained message sent by the previous node device and sends the stained message to the next node device; The tail node device receives the stained message; Each node device obtains its own target packet based on the stained packet and its own corresponding stained packet transmission timestamp, and sends it to the network management platform so that the network management platform can perform latency measurement based on the target packets sent by each node device. Each node device, based on the stained packet and its corresponding stained packet transmission timestamp, obtains its own target packet and sends it to the network management platform, including: When the transmission timestamp of the stained message is the reception timestamp and the target message includes a first target message, the first node device obtains the timestamp of the received data packet to be stained, obtains its own corresponding reception timestamp, adds its own corresponding reception timestamp to the extended data field of the stained message, obtains its own corresponding first target message, and sends it to the network management platform. Each intermediate node device and the tail node device obtains the timestamp of the stained packet it received. After obtaining its own corresponding receiving timestamp, it adds its own corresponding receiving timestamp to the extended data field of the stained packet, obtains its own corresponding first target packet, and sends it to the network management platform. When the transmission timestamp of the stained message is the transmission timestamp and the target message includes a second target message, the first node device and each of the intermediate node devices obtain the timestamp of their own transmission of the stained message. After obtaining their own corresponding transmission timestamp, they add their own corresponding transmission timestamp to the extended data field of the stained message, obtain their own corresponding second target message, and send it to the network management platform.
2. The method according to claim 1, characterized in that, The first node device performs delay measurement, coloring, and sequence number addition on the data packet to be colored to obtain a colored message, including: The first node device encapsulates the data packet to be colored to obtain a message to be colored, the message to be colored including a delay measurement coloring field, an extended data type field, and an extended data field; The first node device sets the delay measurement coloring field in the message to be colored to a preset coloring value; The first node device sets the extended data type field in the message to be colored to a preset type value; The first node device obtains the sequence number of the data packet to be colored, and sets the extended data field in the message to be colored to the sequence number of the data packet to be colored, thereby obtaining the colored message.
3. The method according to claim 2, characterized in that, The first node device receives N data packets to be colored within one delay measurement period. The sequence number of the data packets to be colored indicates their order among the N data packets to be colored, where N is an integer greater than 1.
4. The method according to claim 1, characterized in that, The network management platform performs latency measurement based on the target packets sent by each node device in the following manner: The network management platform obtains the sequence number and colored message transmission timestamp in each target message sent by each node device, and performs latency measurement based on multiple colored message transmission timestamps corresponding to the same sequence number.
5. A time delay measurement system based on an in-band coloring mechanism, characterized in that, The delay measurement system includes multiple node devices that are sequentially connected in communication, and each node device is connected in communication with the network management platform; The first node device is used to perform delay measurement, coloring, and add sequence number to the data packet to be colored when it receives the data packet to be colored, and then send the colored message to the next node device. Each intermediate node device is used to receive the stained message sent by the previous node device and send the stained message to the next node device; The tail node device is used to receive the stained message; Each node device is also used to obtain its own target packet based on the stained packet and its own corresponding stained packet transmission timestamp, and send it to the network management platform so that the network management platform can perform latency measurement based on the target packet sent by each node device. Specifically, when the transmission timestamp of the stained message is the reception timestamp and the target message includes a first target message, the first node device is used to obtain the timestamp of the received data packet to be stained, and after obtaining its own corresponding reception timestamp, it adds its own corresponding reception timestamp to the extended data field of the stained message, obtains its own corresponding first target message, and sends it to the network management platform. Each of the intermediate node devices and the tail node devices is specifically used to obtain the timestamp of the stained packet it received. After obtaining its own corresponding receiving timestamp, it adds its own corresponding receiving timestamp to the extended data field of the stained packet, obtains its own corresponding first target packet, and sends it to the network management platform. Alternatively, when the transmission timestamp of the stained message is the transmission timestamp and the target message includes a second target message, the first node device and each of the intermediate node devices are specifically used to obtain the timestamp of their own transmission of the stained message. After obtaining their own corresponding transmission timestamp, they add their own corresponding transmission timestamp to the extended data field of the stained message, obtain their own corresponding second target message, and send it to the network management platform.
6. The time delay measurement system according to claim 5, characterized in that, The first node device is also used for: The data packet to be colored is encapsulated to obtain a message to be colored, the message to be colored including a delay measurement coloring field, an extended data type field, and an extended data field; Set the delay measurement coloring field in the message to be colored to a preset coloring value; Set the extended data type field in the message to be colored to a preset type value; Obtain the sequence number of the data packet to be colored, and set the extended data field in the message to be colored to the sequence number of the data packet to be colored, thus obtaining the colored message.
7. The time delay measurement system according to claim 6, characterized in that, The first node device receives N data packets to be colored within one delay measurement period. The sequence number of the data packets to be colored indicates their order among the N data packets to be colored, where N is an integer greater than 1.
Citation Information
Patent Citations
Time delay statistics method, device, storage medium and system
CN112398557A
In-band measurement method, device and node
CN113973063A