Message processing method and device, network element equipment and readable storage medium
By encapsulating the extended trace option for service flow packets in the message forwarding path, the problem of IOAM data cannot be obtained due to packet loss is solved, and the integrity and accuracy of network state measurement is achieved.
Patent Information
- Application Number
- CN202410238270.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-03-03
- Publication Date
- 2025-09-05
AI Technical Summary
In the prior art, if the service flow message is lost on the network path, the decapsulation node cannot obtain the IOAM data, resulting in the inability to measure the key network indicators.
The packet encapsulation extended trace options for the target service flow in the message forwarding path include the IOAM trace type field and the measurement field, which are used to instruct nodes to fill IOAM data and perform packet loss and delay measurements, allowing each node to report network status measurement data directly to the receiving entity.
Even if packet loss occurs during packet transmission, network status measurement data generated before packet loss can be received to ensure the integrity and accuracy of network status measurement.
Smart Images

Figure CN120602382A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of communication technology, and in particular to a message processing method, apparatus, network element equipment, and readable storage medium. Background Art
[0002] The IETF specifies an in-band operation, administration, and maintenance (IOAM) method for collecting IOAM data, including node IDs, inbound interface IDs, outbound interface IDs, timestamps, and forwarding delays, as traffic flow packets traverse the network path. The current IETF standard, RFC 9197, specifies the IOAM Trace Option (IOAMTrace Option), also known as the passport method. This defines the field format for collecting and carrying IOAM data at each hop along the traffic flow packet path. The decapsulation node (destination node) extracts the IOAM data collected by the path nodes and sends it to a receiving device, such as a collection controller.
[0003] However, if any node on the service flow measurement path discards the service message for some reason, the service message carrying IOAM data cannot be forwarded to the decapsulation node. The decapsulation node cannot obtain the service message in any way, and thus cannot perform periodic measurements of key network indicators (packet loss, latency, jitter, etc.) using IOAM data. Summary of the Invention
[0004] Based on this, it is necessary to provide a message processing method, apparatus, network element equipment and readable storage medium to address the above technical problems.
[0005] In a first aspect, the present application provides a message processing method, which is applied to a message encapsulation node in a message forwarding path. The method comprises:
[0006] Encapsulate an extended trace option for each message in the forwarded target service flow, wherein the extended trace option includes an IOAM trace type field and a measurement field; wherein:
[0007] The IOAM trace type field is used to instruct the nodes in the message forwarding path to fill the IOAM data into the node data list field of the message according to the IOAM data type indicated by the IOAM trace type field;
[0008] The measurement field is used to instruct the nodes in the message forwarding path to perform packet loss measurement and / or delay measurement.
[0009] In one embodiment, the extended trace option also includes a flow identification bit, a message sequence number bit and a measurement period number bit. When the flow identification bit is set to the first value, an optional flow identification field exists in the extended trace option; when the message sequence number bit is set to the first value, an optional message sequence number field exists in the extended trace option; when the measurement period number bit is set to the first value, an optional measurement period number field exists in the extended trace option.
[0010] In one embodiment, the IOAM trace type field includes multiple bits for indicating the type of IOAM data used; the nodes in the message forwarding path fill the IOAM data into the node data list field of the message according to the settings of each bit of the IOAM trace type field.
[0011] In one embodiment, encapsulating an extended trace option for each packet in the forwarded target service flow includes:
[0012] Selecting a monitoring message from the target service flow;
[0013] For the selected monitoring message, set a target bit position in the IOAM trace type field of the monitoring message to a first value; for other messages not selected as the monitoring message, set all bit positions in the IOAM trace type field of the other messages to a second value, where the first value and the second value are different;
[0014] The target bit set to the first value is specifically used to instruct the nodes in the message forwarding path to fill the node data list field of the message with the IOAM data indicated by the target bit;
[0015] The target bit set to the second value is specifically used to instruct the nodes in the message forwarding path to prohibit filling the IOAM data indicated by the target bit into the node data list field of the message.
[0016] In one embodiment, the measurement field includes a packet loss measurement field, and the field value of the packet loss measurement field of all packets belonging to the same packet batch in the target service flow is the same;
[0017] The packet loss measurement field is specifically used to instruct the nodes in the message forwarding path to determine the message batch to which the message belongs according to the field value of the packet loss measurement field, and report the message count value corresponding to the message batch to the receiving entity.
[0018] In one embodiment, the measurement field includes a delay measurement field, and the encapsulation of the extended trace option for each message in the forwarded target service flow further includes:
[0019] A target message is determined from each message batch, a delay measurement field of the target message is set to a first value, and delay measurement fields of other messages in the message batch except the target message are set to a second value, where the first value and the second value are different.
[0020] In one of the embodiments, the delay measurement field set to the first value is specifically used to instruct the node in the message forwarding path to report the message timestamp of the target message to the receiving entity.
[0021] In a second aspect, the present application further provides a message processing method, which is applied to a message traversal node in a message forwarding path. The method comprises:
[0022] receiving each message of the target service flow encapsulated with an extended trace option sent by a message encapsulation node in the message forwarding path, wherein the extended trace option includes an IOAM trace type field and a measurement field;
[0023] Filling the node data list field of each of the messages with IOAM data according to the IOAM data type indicated by the IOAM trace type field, and performing packet loss measurement and / or latency measurement according to the indication of the measurement field;
[0024] The message filled with IOAM data is forwarded to the next node in the message forwarding path.
[0025] In one embodiment, the IOAM trace type field includes multiple bits, different bits correspond to different IOAM data types, and different bit values are used to indicate whether a node in the message forwarding path fills the IOAM data into the node data list field of the message, and filling the IOAM data into the node data list field of each message according to the IOAM data type indicated by the IOAM trace type field includes:
[0026] determining, according to the value of each bit in the IOAM trace type field, the IOAM data type to be filled into each of the messages;
[0027] The node data list field of each message is filled with IOAM data corresponding to the target IOAM data type.
[0028] In one embodiment, the extended trace option further includes a flow identification bit, a message sequence number bit, and a measurement period number bit, and performing packet loss measurement and / or delay measurement according to the indication of the measurement field includes:
[0029] Perform packet loss measurement and / or delay measurement according to the indication of the measurement field, and report at least one of the flow identifier of the target service flow, the message sequence number of the message in the target service flow, and the measurement period number of the message in the target service flow to the receiving entity according to the indication of the flow identifier bit, the message sequence number bit, and the measurement period number bit.
[0030] In one embodiment, the measurement field includes a packet loss measurement field, and performing packet loss measurement according to an instruction of the measurement field includes:
[0031] For each message in the target service flow, determining the message batch to which the message belongs according to the field value of the packet loss measurement field;
[0032] Reporting the message count value corresponding to each message batch to the receiving entity according to the message batch;
[0033] Among them, the field value of the packet loss measurement field of multiple consecutive messages belonging to the same message batch in the target service flow is the same.
[0034] In one embodiment, the reporting, to the receiving entity according to the indication of the flow identifier bit, the message sequence number bit, and the measurement period number bit, at least one of the flow identifier of the target service flow, the message sequence number of the message in the target service flow, and the measurement period number of the message in the target service flow, includes:
[0035] The flow identifier is reported to the receiving entity, and when the measurement period number bit of each message is set to a first value, the measurement period number of each message is reported to the receiving entity.
[0036] In one embodiment, the measurement field includes a delay measurement field, and performing delay measurement according to an instruction of the measurement field includes:
[0037] Determine, from each message in the message batch, a target message in which the delay measurement field is set to a first value;
[0038] Reporting the message timestamp of the target message to the receiving entity.
[0039] In one embodiment, the reporting, to the receiving entity according to the indication of the flow identifier bit, the message sequence number bit, and the measurement period number bit, at least one of the flow identifier of the target service flow, the message sequence number of the message in the target service flow, and the measurement period number of the message in the target service flow, includes:
[0040] Report the flow identifier to the receiving entity, and when the message sequence number bit of each message is set to the first value, report the message sequence number of each message to the receiving entity, and when the measurement period number bit is set to the first value, report the measurement period number of each message to the receiving entity.
[0041] In a third aspect, the present application further provides a message processing device. The device comprises:
[0042] An encapsulation module is configured to encapsulate an extended trace option for each message in the forwarded target service flow; the extended trace option includes an IOAM trace type field and a measurement field; wherein:
[0043] The IOAM trace type field is used to instruct the nodes in the message forwarding path to fill the IOAM data into the node data list field of the message according to the IOAM data type indicated by the IOAM trace type field;
[0044] The measurement field is used to instruct the nodes in the message forwarding path to perform packet loss measurement and / or delay measurement.
[0045] In one embodiment, the extended trace option also includes a flow identification bit, a message sequence number bit and a measurement period number bit. When the flow identification bit is set to the first value, an optional flow identification field exists in the extended trace option; when the message sequence number bit is set to the first value, an optional message sequence number field exists in the extended trace option; when the measurement period number bit is set to the first value, an optional measurement period number field exists in the extended trace option.
[0046] In one embodiment, the IOAM trace type field includes multiple bits for indicating the type of IOAM data used; the nodes in the message forwarding path fill the IOAM data into the node data list field of the message according to the settings of each bit of the IOAM trace type field.
[0047] In one embodiment, the encapsulation module is further used to:
[0048] Selecting a monitoring message from the target service flow;
[0049] For the selected monitoring message, set a target bit position in the IOAM trace type field of the monitoring message to a first value; for other messages not selected as the monitoring message, set all bit positions in the IOAM trace type field of the other messages to a second value, where the first value and the second value are different;
[0050] The target bit set to the first value is specifically used to instruct the nodes in the message forwarding path to fill the node data list field of the message with the IOAM data indicated by the target bit;
[0051] The target bit set to the second value is specifically used to instruct the nodes in the message forwarding path to prohibit filling the IOAM data indicated by the target bit into the node data list field of the message.
[0052] In one embodiment, the measurement field includes a packet loss measurement field, and the field value of the packet loss measurement field of all packets belonging to the same packet batch in the target service flow is the same;
[0053] The packet loss measurement field is specifically used to instruct the nodes in the message forwarding path to determine the message batch to which the message belongs according to the field value of the packet loss measurement field, and report the message count value corresponding to the message batch to the receiving entity.
[0054] In one embodiment, the measurement field includes a delay measurement field, and the encapsulation module is further configured to:
[0055] A target message is determined from each message batch, a delay measurement field of the target message is set to a first value, and delay measurement fields of other messages in the message batch except the target message are set to a second value, where the first value and the second value are different.
[0056] In one of the embodiments, the delay measurement field set to the first value is specifically used to instruct the node in the message forwarding path to report the message timestamp of the target message to the receiving entity.
[0057] In a fourth aspect, the present application further provides a message processing device. The device comprises:
[0058] a receiving module, configured to receive each message of a target service flow encapsulated with an extended trace option sent by a message encapsulation node in the message forwarding path, wherein the extended trace option includes an IOAM trace type field and a measurement field;
[0059] a filling module, configured to fill the node data list field of each message with IOAM data according to the IOAM data type indicated by the IOAM trace type field, and perform packet loss measurement and / or delay measurement according to the indication of the measurement field;
[0060] The sending module is used to forward the message filled with IOAM data to the next node in the message forwarding path.
[0061] In one embodiment, the IOAM trace type field includes multiple bits, different bits correspond to different IOAM data types, and different bit values are used to indicate whether a node in the message forwarding path fills the IOAM data into the node data list field of the message, and the filling module is further used to:
[0062] determining, according to the value of each bit in the IOAM trace type field, the IOAM data type to be filled into each of the messages;
[0063] The node data list field of each message is filled with IOAM data corresponding to the target IOAM data type.
[0064] In one embodiment, the extended trace option further includes a flow identification bit, a message sequence number bit, and a measurement period number bit, and the filling module is further configured to:
[0065] Perform packet loss measurement and / or delay measurement according to the indication of the measurement field, and report at least one of the flow identifier of the target service flow, the message sequence number of the message in the target service flow, and the measurement period number of the message in the target service flow to the receiving entity according to the indication of the flow identifier bit, the message sequence number bit, and the measurement period number bit.
[0066] In one embodiment, the measurement field includes a packet loss measurement field, and the filling module is further configured to:
[0067] For each message in the target service flow, determining the message batch to which the message belongs according to the field value of the packet loss measurement field;
[0068] Reporting the message count value corresponding to each message batch to the receiving entity according to the message batch;
[0069] Among them, the field value of the packet loss measurement field of multiple consecutive messages belonging to the same message batch in the target service flow is the same.
[0070] In one embodiment, the filling module is further used to:
[0071] The flow identifier is reported to the receiving entity, and when the measurement period number bit of each message is set to a first value, the measurement period number of each message is reported to the receiving entity.
[0072] In one embodiment, the measurement field includes a delay measurement field, and the filling module is further configured to:
[0073] Determine, from each message in the message batch, a target message in which the delay measurement field is set to a first value;
[0074] Reporting the message timestamp of the target message to the receiving entity.
[0075] In one embodiment, the filling module is further used to:
[0076] Report the flow identifier to the receiving entity, and when the message sequence number bit of each message is set to the first value, report the message sequence number of each message to the receiving entity, and when the measurement period number bit is set to the first value, report the measurement period number of each message to the receiving entity.
[0077] In a fifth aspect, the present application further provides a network element device, including a processor and a transmitter:
[0078] The processor is configured to encapsulate an extended trace option for each message in the forwarded target service flow; the extended trace option includes an IOAM trace type field and a measurement field; wherein:
[0079] The IOAM trace type field is used to instruct the nodes in the message forwarding path to fill the IOAM data into the node data list field of the message according to the IOAM data type indicated by the IOAM trace type field;
[0080] The measurement field is used to instruct the nodes in the message forwarding path to perform packet loss measurement and / or delay measurement.
[0081] In a sixth aspect, the present application further provides a network element device, including a receiver, a processor, and a transmitter:
[0082] The receiver is configured to receive each message of a target service flow encapsulated with an extended trace option sent by a message encapsulation node in a message forwarding path, wherein the extended trace option includes an IOAM trace type field and a measurement field;
[0083] The processor is configured to fill the node data list field of each of the messages with IOAM data according to the IOAM data type indicated by the IOAM trace type field, and perform packet loss measurement and / or latency measurement according to the indication of the measurement field;
[0084] The transmitter is configured to report the network status measurement data to a receiving entity, and is further configured to forward the message filled with IOAM data to a next node in the message forwarding path.
[0085] In a seventh aspect, the present application further provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program implements any of the above methods when executed by a processor.
[0086] In an eighth aspect, the present application further provides a computer program product, comprising a computer program, which implements any of the above methods when executed by a processor.
[0087] The above-described message processing method, apparatus, network element device, and readable storage medium encapsulate an extended trace option in a message, instructing each node in the message forwarding path to fill the message with IOAM data and directly report network status measurement data to a receiving entity. Because the embodiments of the present application do not rely on the message decapsulation node to collect IOAM data and report the IOAM data to the receiving entity, but instead allow each node to directly report relevant network measurement data to the receiving entity, even if a message is lost during transmission, the network status measurement data generated by the message before the loss can be received and used to determine the network status based on this data. BRIEF DESCRIPTION OF THE DRAWINGS
[0088] Figure 1 FIG1 is an implementation environment diagram of a message processing method in one embodiment;
[0089] Figure 2 1 is a flow chart of a message processing method according to an embodiment;
[0090] Figure 3 is a schematic diagram of an extended trace option in one embodiment;
[0091] Figure 4 is a schematic diagram of an extended trace option in one embodiment;
[0092] Figure 5 A schematic diagram of an IOAM trace option node data list field in one embodiment;
[0093] Figure 6 is a schematic diagram of an extended trace option in one embodiment;
[0094] Figure 7 A schematic diagram of setting a packet loss measurement flag in one embodiment;
[0095] Figure 8 is a schematic diagram of an extended trace option in one embodiment;
[0096] Figure 9 A schematic diagram of setting a delay measurement flag in one embodiment;
[0097] Figure 10 1 is a flow chart of a message processing method according to an embodiment;
[0098] Figure 11 is a structural block diagram of a message processing device in one embodiment;
[0099] Figure 12 is a structural block diagram of a message processing device in one embodiment;
[0100] Figure 13 is a diagram showing the internal structure of a network element device in one embodiment;
[0101] Figure 14 FIG. 4 is a diagram showing the internal structure of a network element device in an embodiment. DETAILED DESCRIPTION
[0102] In order to make the purpose, technical solutions and advantages of this application more clear, the following further describes this application in detail with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain this application and are not intended to limit this application.
[0103] Figure 1 A schematic diagram of the implementation environment of a message processing method provided in an embodiment of the present application. The message forwarding path includes a message encapsulation node, a message penetration node, and a message decapsulation node. The message encapsulation node is used to encapsulate the extended trace option into the business flow message, and the message penetration node is used to obtain network status measurement data and IOAM data based on the extended trace option, report the network status measurement data to the receiving entity (such as a centralized acquisition controller), fill the IOAM data into the message, and forward the message to the next node. The message decapsulation node is used to obtain each IOAM data in the message and report each IOAM data to the receiving entity.
[0104] In one embodiment, Figure 2 As shown, a message processing method is provided, which is applied to Figure 1 Taking the packet encapsulation node in the packet forwarding path as an example, the following steps are included:
[0105] Step 202: Encapsulate an extended trace option for each message in the forwarded target service flow.
[0106] In an embodiment of the present application, the target service flow refers to all network packets corresponding to a certain service. In order to monitor the information of the packet forwarding path and the network status of the service flow, the packet encapsulation node needs to encapsulate the extended trace option for each packet in the target service flow. The extended trace option includes an IOAM trace type field and a measurement field. The IOAM trace type field is used to instruct each node in the packet forwarding path (which may include the packet encapsulation node itself, each packet penetration node, and the packet decapsulation node) to collect IOAM data (which may include node ID, input interface ID, output interface ID, etc.), and the measurement field is used to instruct each node in the packet forwarding path to collect network status measurement data (which may include data related to packet loss, delay, and jitter, such as timestamp, forwarding delay, etc.). The IOAM trace type field may include a first identifier instructing the node to collect IOAM data and a second identifier instructing the node not to collect IOAM data. The measurement field may also include a first identifier instructing the node to collect network status measurement data and a second identifier instructing the node not to collect network status measurement data. For a particular message, the message encapsulation node can simultaneously set the IOAM trace type field and the measurement field in the message's extended trace options to the first flag, meaning that IOAM data and network status measurements are collected through the message. Alternatively, the message encapsulation node can simultaneously set the IOAM trace type field and the measurement field in the message's extended trace options to the second flag, meaning that IOAM data and network status measurements are not collected through the message. Alternatively, the message encapsulation node can set the IOAM trace type field to the first flag and the measurement field to the second flag, or the IOAM trace type field to the second flag and the measurement field to the first flag. This method allows the message traversal node to collect IOAM data or network status measurement data only when it receives a portion of the message, thus saving network resources.
[0107] For example, the extended trace option can be a field obtained by modifying the IOAM protocol header. Adding an IOAM trace type field ( Figure 3 The extended trace options obtained after adding the IOAM-Trace-Type and measurement fields in the IOAM-Trace-Type field can be found in Figure 3As shown. Among them, Namespace-ID refers to the namespace ID, the field length is 16 bits, and is used to characterize the IOAM namespace identifier. NodeLen refers to the node length, the field length is 5 bits, and is used to indicate the IOAM data length added by the message penetration node in the data field of the message. Flags refers to the flag, the field length is 4 bits. RemainingLen refers to the remaining length, the field length is 7 bits, and is used to indicate the data space that can be filled with IOAM data in the message penetration node. The length of the IOAM trace type field and the measurement field can be selected by those skilled in the art according to actual needs.
[0108] Step 204: Send each message encapsulated with the extended trace option.
[0109] In the embodiment of the present application, after encapsulating each message with an extended trace option, the message encapsulation node sends the message to the next node connected to the message encapsulation node in the message forwarding path. It should be noted that the next node may be a message traversal node or a message decapsulation node, and this embodiment of the present application does not specifically limit this.
[0110] For a particular message, if the IOAM trace type field in the message instructs the message encapsulation node to collect IOAM data, the message encapsulation node also needs to obtain the IOAM data corresponding to the IOAM trace type field, and fill the IOAM data into the message before forwarding the message. For example, if the second bit of the IOAM trace type field is preset to 1, the message encapsulation node needs to fill the node ID into the message, then the message encapsulation node fills its own node ID into the message and forwards the message to the next node. If the measurement field in the message instructs the message encapsulation node to collect network status measurement data, then the message encapsulation node also needs to send the network status measurement data to the receiving entity. For example, if the first bit of the measurement field is preset to 1, the message encapsulation node needs to report the timestamp of sending the message to the receiving entity, then the message encapsulation node needs to report the timestamp of sending the message to the receiving entity after sending the message to the next node.
[0111] The message processing method provided in an embodiment of the present application encapsulates an extended trace option in a message, instructing each node in the message forwarding path to fill the message with IOAM data and directly report network status measurement data to a receiving entity. Because this embodiment of the present application does not rely on the message decapsulation node to collect IOAM data and report the IOAM data to the receiving entity, but instead allows each node to directly report relevant network measurement data to the receiving entity, even if the message is lost during transmission, the network status measurement data generated before the packet loss can be received and used to determine the network status based on this data.
[0112] In one embodiment, see Figure 4 As shown, the extended trace option also includes the stream identification bit ( Figure 4 F in), message sequence number bit ( Figure 4 S in) and the measurement cycle number bit ( Figure 4 The M in.
[0113] In the embodiment of the present application, the flow identification bit is used to indicate whether the extended trace option carries a flow identification (Flow ID), the message sequence number bit is used to indicate whether the extended trace option carries a message sequence number (Sequence Number), and the measurement period number bit is used to indicate whether the extended trace option carries a measurement period number (Measurement Period Number). If a bit is set to the first value (the first value can be 0 or 1), it indicates that the corresponding position of the extended trace option carries corresponding data. It should be noted that, Figure 4 The above-mentioned bits are arranged after the measurement field for illustration. However, in fact, the embodiment of the present application does not specifically limit the position of the above-mentioned bits in the extended trace option.
[0114] In one embodiment, an optional flow identification field is present in the extended trace option with the flow identification bit set to a first value.
[0115] In an embodiment of the present application, if the flow identifier bit is a first value, it indicates that the extended trace option contains an optional flow identifier field, which carries a flow identifier. The flow identifier is used to identify the network flow to which the message belongs. Messages belonging to the same network flow mean that the messages have the same source port number, destination port number, network protocol, source address, and destination address. The flow identifier can be determined by the message encapsulation node. For example, to avoid conflicts between flow identifiers set by different message encapsulation nodes, the flow identifier can also be assigned by the receiving entity. The message encapsulation node can decide whether to carry the flow identifier in the message based on actual needs. If the message encapsulation node requires the flow identifier to be carried in the message, it can set the flow identifier bit to the first value after inserting the flow identifier into the preset field in the extended trace option. If the message encapsulation node does not require the flow identifier to be carried in the message, it can set the flow identifier bit to the second value. The first and second values are different. In one embodiment, the length of the preset field corresponding to the flow identifier is an integer multiple of 4. In another embodiment, the length of the preset field corresponding to the flow identifier is 32 bits.
[0116] In one embodiment, when the message sequence number bit is set to the first value, an optional message sequence number field is present in the extended trace option.
[0117] In an embodiment of the present application, if the message sequence number bit is the first value, it indicates that an optional message sequence number field exists in the extended trace option, and the optional message sequence number field carries the message sequence number. The message sequence number is used to represent the sequence number of the message in the network flow. Exemplarily, the sequence number can be incremented by 1 starting from 0. The sequence number of each message can be determined by the message encapsulation node. The message encapsulation node can decide whether to carry the message sequence number in the message based on actual needs. If the message encapsulation node needs to carry the message sequence number in the message, the message sequence number bit can be set to the first value after inserting the message sequence number into the preset position in the extended trace option. If the message encapsulation node does not need to carry the message sequence number in the message, the message sequence number bit can be set to the second value. In one embodiment, the length of the preset field corresponding to the message sequence number is an integer multiple of 4. In another embodiment, the length of the preset field corresponding to the message sequence number is 32 bits.
[0118] In one embodiment, when the measurement period number bit is set to the first value, an optional measurement period number field is present in the extended trace option.
[0119] In an embodiment of the present application, if the measurement period number bit is a first value, it indicates that the extended trace option contains an optional measurement period number field, which carries the measurement period number. The measurement period number is used to identify the measurement period to which a message belongs in a network flow, allowing the receiving entity to determine the network status based on the measurement period. For example, the measurement period number may start at 0 and increment by 1. The measurement period number for each message may be determined by the message encapsulation node. The message encapsulation node may decide whether to include the measurement period number in the message based on actual needs. If the message encapsulation node requires the measurement period number to be included in the message, it may set the measurement period number bit to the first value after inserting the measurement period number into the preset position in the extended trace option. If the message encapsulation node does not require the measurement period number to be included in the message, it may set the measurement period number bit to the second value. In one embodiment, the length of the preset field corresponding to the measurement period number is an integer multiple of 4. In another embodiment, the length of the preset field corresponding to the measurement period number is 32 bits.
[0120] The extended trace option may also include other bits, and technicians may set the meaning of other bits according to actual needs. In the case where other bits have no meaning, all other bits may be set to the second value. For example, the extended trace option may also include three reserved other bits ( Figure 4 in the Reserved section).
[0121] The message processing method provided in the embodiments of the present application sets multiple bits in an extended trace option. Whether the bits in corresponding positions are set to a first value is used to indicate whether the extended trace option contains extended data required for network status measurement, such as a flow identifier, a message sequence number, and a measurement period number. This allows a receiving entity to determine the network status corresponding to a particular network flow and a particular measurement period based on the extended data.
[0122] In one embodiment, the IOAM trace type field includes multiple bits for indicating the type of IOAM data used; nodes in the message forwarding path fill IOAM data into the node data list field of the message according to the settings of each bit of the IOAM trace type field.
[0123] In the embodiment of the present application, each bit in the IOAM trace type field indicates an IOAM data type. For example, the IOAM trace type field may include 24 bits. The IOAM data type corresponding to each bit can be set by a technician based on actual needs. For example, the 0th bit can correspond to the ID of the incoming interface of the packet on the node, the 1st bit can correspond to the ID of the outgoing interface of the packet on the node, and the 2nd bit can correspond to the node ID.
[0124] The packet encapsulation node can set the value of each bit to instruct the packet traversal node which specific IOAM data field to be added to the packet. For example, when the packet encapsulation node sets a bit to a first value (which can be 1 or 0), it instructs the packet traversal node to add the IOAM data type corresponding to that bit to the packet. Setting a bit to a second value (which can be 0 or 1) instructs the packet traversal node not to add the IOAM data type corresponding to that bit to the packet. The first and second values are different. For example, if bit 0 corresponds to the ID of the packet's inbound interface on the node, bit 1 corresponds to the ID of the packet's outbound interface on the node, and bit 2 corresponds to the node ID, and the packet encapsulation node sets bit 0 to 1 (the first value), bit 1 to 0 (the second value), and bit 2 to 1, then upon receiving the packet, the packet traversal node must add the ID of the packet's inbound interface on the traversal node and the node ID of the node it traverses.
[0125] For example, the length of the IOAM data generated by the message traversal node can be a multiple of 4 bytes, and each message traversal node can determine the position of the message data field (IOAM trace option node data list field, or node data list) where the IOAM data needs to be filled based on the two fields RemainingLen and NodeLen in the extended trace option after receiving the message. Figure 5 As shown, each message traversal node can fill the IOAM data in the data field in reverse order, that is, the first node to fill the IOAM data into the message fills the IOAM data to the end of the data field ( Figure 5 The second node that fills the IOAM data into the message is next to the IOAM data filled by the previous node, and fills the IOAM data to the end of the remaining data field ( Figure 5 The process continues in this way until the message reaches the decapsulation node, which takes out all the IOAM data in the data field and reports all the IOAM data to the receiving entity.
[0126] In one embodiment, an extended trace option is encapsulated for each message in the forwarded target service flow, including:
[0127] Select monitoring messages from the target service flow;
[0128] For the selected monitoring message, the target bit position in the IOAM trace type field of the monitoring message is set to the first value.
[0129] In an embodiment of the present application, the message encapsulation node selects some messages in the target business flow as monitoring messages, and the monitoring messages are messages that need to carry IOAM data. Other messages that are not selected as monitoring messages do not need to carry IOAM data. This can reduce the processing burden of each node. A target bit can be set to indicate whether the node needs to fill IOAM data into the message. When the bit is a first value (the first value can be 1 or 0), the node collects the pre-set required IOAM data and fills the IOAM data into the message. When the bit is a second value (the first value can be 0 or 1), the node does not collect any IOAM data.
[0130] In one embodiment, encapsulating an extended trace option for each message in the forwarded target service flow further includes:
[0131] For other messages that are not selected as monitoring messages, all bits in the IOAM trace type field of the other messages are set to a second value, where the first value and the second value are different.
[0132] The target bit set to the first value is specifically used to instruct the node in the message forwarding path to fill the node data list field of the message with the IOAM data indicated by the target bit;
[0133] The target bit set to the second value is specifically used to instruct the nodes in the message forwarding path to prohibit filling the IOAM data indicated by the target bit into the node data list field of the message.
[0134] In this embodiment of the present application, each bit indicates an IOAM data type. A message encapsulation node may set a target bit in the IOAM trace type field of a monitoring message to a first value (the first value may be 1 or 0) based on the IOAM data type to be collected. This allows nodes in the message forwarding path to fill the monitoring message with IOAM data of the IOAM data type corresponding to the target bit upon receiving the monitoring message.
[0135] The message encapsulation node may also set other bits in the IOAM trace type field of the monitoring message to a second value, so that after receiving the monitoring message, the nodes in the message forwarding path will not fill the monitoring message with IOAM data of the IOAM data type corresponding to other bits.
[0136] For other messages, the message encapsulation node sets all bits of the IOAM trace type field to the second value, so that nodes in the message forwarding path do not fill any IOAM data into the message, reducing the processing burden of each node.
[0137] The message processing method provided in the embodiment of the present application sets multiple bits in the IOAM trace type field. The bits at corresponding positions are used to indicate which IOAM data type the node through which the message passes needs to fill in the message, allowing the node to fill the specified IOAM data type into the message.
[0138] In one embodiment, the measurement field includes a packet loss measurement field, and the field value of the packet loss measurement field of all packets belonging to the same packet batch in the target service flow is the same;
[0139] The packet loss measurement field is specifically used to instruct the nodes in the message forwarding path to determine the message batch to which the message belongs according to the field value of the packet loss measurement field, and report the message count value corresponding to the message batch to the receiving entity.
[0140] In the embodiment of the present application, the measurement field includes a packet loss measurement field, referring to Figure 6 As shown (the packet loss measurement field is Figure 6 The packet loss measurement field can be set after the IOAM trace type field and before the extension flag field. Each node in the message forwarding path can report relevant information used to measure the network packet loss rate to the receiving entity based on the packet loss measurement field.
[0141] The packet encapsulation node can divide the target service flow into multiple packet batches. The packet batch is the unit for measuring the network packet loss rate. The packet loss measurement field value of the packets belonging to the same packet batch is the same, and the packet loss measurement field value of the packets belonging to different packet batches is different, so as to distinguish different packet batches. In one embodiment, the length of the packet loss measurement field is 1 bit, see Figure 7 As shown in the figure, after the packet encapsulation node sends all packets in a batch, it marks the start of the next packet batch by setting the packet loss measurement field value in the next packet to a different value from the field value in the previous batch (i.e., swapping bits). For example, if the packet loss measurement field value in the previous batch is all 1, the packet encapsulation node will set the packet loss measurement field value in the next batch to 0 when sending the next batch of packets. When sending the next batch of packets, it will reset the packet loss measurement field value to 1.
[0142] The message encapsulation node may group a fixed number of messages as a message batch, or may group messages received or sent by the message encapsulation node within a certain period of time as a message batch.
[0143] For each message batch, each node on the message forwarding path counts the messages it receives belonging to that message batch. After receiving each message batch, the node reports the message count value at that time to the receiving entity. In this way, the receiving entity can determine the overall packet loss rate of the message forwarding path and the packet loss rate between each two nodes through the message count value reported by each node on the message forwarding path. For example, if there are 1000 messages in a message batch, the message count value reported by node A is 990, and the message count value reported by node B is 950. The receiving entity can determine that the packet loss rate between node A and the message encapsulation node is 10 / 1000 = 1%, and the packet loss rate between node B and node A is 40 / 990 = 4%.
[0144] The message processing method provided in the embodiment of the present application sets a packet loss measurement field in the measurement field, and the packet loss rate of the message forwarding path can be measured through the packet loss measurement field.
[0145] In one embodiment, the measurement field includes a delay measurement field, and an extended trace option is encapsulated for each message in the target service flow corresponding to the message forwarding path, including:
[0146] A target message is determined from each message batch, a delay measurement field of the target message is set to a first value, and delay measurement fields of other messages in the message batch except the target message are set to a second value, where the first value and the second value are different.
[0147] In the embodiment of the present application, the measurement field includes a delay measurement field, referring to Figure 8 As shown (the delay measurement field is Figure 8 The delay measurement field can be placed after the IOAM trace type field and before the extension flag field. If the measurement field includes both the packet loss measurement field and the delay measurement field, the delay measurement field can be placed after the packet loss measurement field. Each node in the packet forwarding path can report relevant information used to measure network delay to the receiving entity based on the delay measurement field.
[0148] One or more messages in each message batch can be selected as target messages, and network delay can be measured using the target messages. The delay measurement field of the target message is set to a first value, and the delay measurement fields of other messages are set to a second value. In one embodiment, the delay measurement field is 1 bit long. The first value can be 1 or 0, and the second value can be 0 or 1. Each node on the message forwarding path determines whether the message is the target message by identifying the field value of the delay measurement field in the message, and then measures the network delay based on the target message.
[0149] Reference Figure 9 As shown, a fixed number of messages can be placed between each target message (for example, the 10th, 20th, and 30th messages in the batch are selected as target messages). The node records the duration from receiving one target message to receiving the next and reports this duration to the receiving entity, which can then calculate network latency based on this duration. For example, if the duration between receiving the first and second target messages is 50ms, and the duration between receiving the second and third target messages is 66ms, it can be determined that the network latency increased by 16ms during this period.
[0150] In one embodiment, the delay measurement field set to the first value is specifically used to instruct a node in the message forwarding path to report a message timestamp of the target message to the receiving entity.
[0151] In an embodiment of the present application, the message timestamp refers to the timestamp when the node receives the target message. When the delay measurement field is the first value, the node in the message forwarding path reports the message timestamp to the receiving entity. When the delay measurement field is the second value, the message timestamp is not reported to the receiving entity. The receiving entity determines the delay based on the message timestamp. For example, the message timestamp reported by the first node is 8:30:10:7.5 (hours: minutes: seconds: milliseconds), and the message timestamp reported by the second node is 8:30:10:13.8 (hours: minutes: seconds: milliseconds). It can be calculated that the message delay between the first node and the second node is: 13.8-7.5=6.3 milliseconds.
[0152] If there are multiple target messages, in extreme cases, due to network delays or packet loss, the target message sent after the previous node may arrive at the next node earlier, causing the receiving entity to misjudge the delay between the two nodes. To address the above problem, in one embodiment, one message can be selected as the target message in each message batch. This eliminates the need to consider whether different target messages arrive out of order when they arrive at the target node. In the event of packet loss of the target message, the receiving entity can directly skip the delay measurement for this message batch, and the delay measurement error will not occur.
[0153] The message processing method provided in the embodiment of the present application sets a delay measurement field in the measurement field, and the packet loss rate of the message forwarding path can be measured through the packet loss measurement field.
[0154] In one embodiment, Figure 10 As shown, a message processing method is provided, which is applied to Figure 1 Taking the packet traversal node in the packet forwarding path as an example, the following steps are included:
[0155] Step 1002: Receive packets of a target service flow encapsulated with an extended trace option sent by a packet encapsulation node in a packet forwarding path, where the extended trace option includes an IOAM trace type field and a measurement field.
[0156] Step 1004: Fill the node data list field of each message with IOAM data according to the IOAM data type indicated by the IOAM trace type field, and perform packet loss measurement and / or latency measurement according to the indication of the measurement field;
[0157] Step 1006: Forward the message filled with IOAM data to the next node in the message forwarding path.
[0158] In an embodiment of the present application, a message traversal node receives a message sent by a previous node on a message forwarding path. The message contains an extended trace option, which includes an IOAM trace type field and a measurement field. Based on the indication in the IOAM trace type field, the message traversal node generates IOAM data, inserts the IOAM data into the message, and forwards the message filled with IOAM data to the next node on the message forwarding path. The message traversal node can also obtain network status measurement data based on the indication in the measurement field and report the network status measurement data to the receiving entity.
[0159] Among them, the specific structure of the extended trace option can be found in the description of the above embodiment, and the embodiment of the present application will not be repeated here.
[0160] The message processing method provided in an embodiment of the present application encapsulates an extended trace option in a message, instructing each node in the message forwarding path to fill the message with IOAM data and directly report network status measurement data to a receiving entity. Because this embodiment of the present application does not rely on the message decapsulation node to collect IOAM data and report the IOAM data to the receiving entity, but instead allows each node to directly report relevant network measurement data to the receiving entity, even if the message is lost during transmission, the network status measurement data generated before the packet loss can be received and used to determine the network status based on this data.
[0161] In one embodiment, the IOAM trace type field includes multiple bits, different bits corresponding to different IOAM data types, and different bit values are used to indicate whether a node in a message forwarding path fills IOAM data into the node data list field of the message. Filling IOAM data into the node data list field of each message according to the IOAM data type indicated by the IOAM trace type field. Filling IOAM data into each message according to the IOAM data type indicated by the IOAM trace type field includes:
[0162] Determine the IOAM data type that needs to be filled in each message based on the value of each bit in the IOAM trace type field;
[0163] Fill each message with IOAM data corresponding to the target IOAM data type.
[0164] In the embodiment of the present application, each bit in the IOAM trace type field indicates an IOAM data type. The message traversal node determines which IOAM data type to fill in the message based on the value of the different bits.
[0165] Exemplarily, each bit in the IOAM trace type field can take a first value (which can be 1 or 0) or a second value (which can be 0 or 1). The first value is used to instruct the message penetration node to fill the message with IOAM data of the IOAM data type corresponding to the bit, and the second value is used to instruct the message penetration node to prohibit filling the message with IOAM data of the IOAM data type corresponding to the bit. The message penetration node obtains the value of each bit. When the value of a certain bit is the first value, it determines that the IOAM data type corresponding to the bit needs to be filled into the message; when the value of a certain bit is the second value, it determines that the IOAM data type corresponding to the bit is prohibited from being filled into the message. After filling the message with IOAM data of the IOAM data type corresponding to all bits with the first value, the message penetration node forwards the message to the next node.
[0166] The message processing method provided in the embodiment of the present application sets multiple bits in the IOAM trace type field. The bits at corresponding positions are used to indicate which IOAM data type the node through which the message passes needs to fill in the message, allowing the node to fill the specified IOAM data type into the message.
[0167] In one embodiment, the extended trace option further includes a flow identification bit, a message sequence number bit, and a measurement period number bit, and performs packet loss measurement and / or delay measurement according to the indication of the measurement field, including:
[0168] Perform packet loss measurement and / or delay measurement according to the indication of the measurement field, and report at least one of the flow identifier of the target service flow, the message sequence number of the message in the target service flow, and the measurement period number of the message in the target service flow to the receiving entity according to the indication of the flow identifier bit, the message sequence number bit, and the measurement period number bit.
[0169] In an embodiment of the present application, the message penetration node reports at least one of the flow identifier, message sequence number, and measurement cycle number to the receiving entity while reporting the network status measurement data, so that the receiving entity can calculate the network status based on these data. The specific data to be reported can be determined based on preset rules and the specific data carried in the message. For example, if it is pre-set that when reporting the message count value required for calculating the packet loss rate, the flow identifier and message sequence number need to be reported at the same time, so that the receiving entity can determine the packet loss rate of this network flow and determine which specific messages are lost, then the message penetration node can report the message count value, flow identifier, and message sequence number to the receiving entity at the same time.
[0170] If a message only includes the data specified in the preset rules, the message penetration node reports this portion of data along with the network status measurement data. Using the above example again, if a message only includes a flow identifier but not a message sequence number, the message penetration node reports the message count and flow identifier to the receiving entity, but does not report the non-existent message sequence number.
[0171] In one embodiment, the measurement field includes a packet loss measurement field, and performing packet loss measurement according to an instruction of the measurement field includes:
[0172] For each message in the target service flow, determine the message batch to which the message belongs based on the field value of the packet loss measurement field;
[0173] Report the message count value corresponding to each message batch to the receiving entity according to the message batch;
[0174] The field value of the packet loss measurement field of multiple consecutive packets belonging to the same packet batch in the target service flow is the same.
[0175] In an embodiment of the present application, if the field values of the packet loss measurement fields in consecutive messages are the same, then these messages belong to the same message batch. The message penetration node counts consecutive messages with the same field values of the packet loss measurement field, and increases the count value by 1 each time such a message is received. When a node receives a message in which the field value of the packet loss measurement field is different from the field value of the packet loss measurement field in the previous message, it is determined that the previous message batch has been received, and the count value at this time is used as the message count value, and the message count value is reported to the receiving entity, and the count value is reset. In this way, the receiving entity can determine the overall packet loss rate of the message forwarding path and the packet loss rate between each two nodes through the message count value reported by each node on the message forwarding path.
[0176] In one embodiment, a message traversal node can report message count values to a receiving entity based on message batches and measurement cycle numbers. The message traversal node counts consecutive messages with the same packet loss measurement field value and the same measurement cycle number, increasing the count by 1 for each such message received. When a node receives a message with a different packet loss measurement field value or a different measurement cycle number from the previous message, it determines that the messages of the previous message batch or measurement cycle have been received, uses the current count value as the message count value, reports the message count value to the receiving entity, and resets the count value.
[0177] In one embodiment, reporting at least one of a flow identifier of a target service flow, a message sequence number of a message in the target service flow, and a measurement period number of a message in the target service flow to a receiving entity according to an indication of a flow identifier bit, a message sequence number bit, and a measurement period number bit includes:
[0178] The flow identifier is reported to the receiving entity, and when the measurement period number bit of each message is set to the first value, the measurement period number of each message is reported to the receiving entity.
[0179] In the embodiment of the present application, while reporting the message count value, the message penetration node reports the flow identifier in the message and reports the measurement cycle number if the measurement cycle number bit indicates the presence of the measurement cycle number. After receiving the message count values, flow identifiers, and measurement cycle numbers reported by different nodes, the receiving entity can associate the message count values belonging to the same network flow and the same measurement cycle to obtain the packet loss rate of a specific network flow in a certain measurement cycle. For example, node A reports to the receiving entity that the message count value with flow identifier A1 and measurement cycle number B1 is 1000, and the message count value with flow identifier A2 and measurement cycle number B2 is 980; node B reports to the receiving entity that the message count value with flow identifier A1 and measurement cycle number B3 is 920, and the message count value with flow identifier A2 and measurement cycle number B2 is 980. The receiving entity can then associate the message count value (980) of node A for flow identifier A2 and measurement cycle number B2 with the message count value (980) of node B for flow identifier A2 and measurement cycle number B2, and derive that the packet loss rate of the message with flow identifier A2 and measurement cycle number B2 between node A and node B is 0%.
[0180] The message processing method provided in the embodiment of the present application reports the flow identifier and measurement period number at the same time as reporting the message count value, so as to facilitate the receiving entity to associate the message count values reported by each node belonging to the same network flow and the same measurement period, and calculate the packet loss rate of a certain measurement period of a certain network flow.
[0181] In one embodiment, the measurement field includes a delay measurement field, performing network status measurement according to an instruction of the measurement field to obtain network status measurement data, and reporting the network status measurement data to a receiving entity includes:
[0182] Determine, from each message in the message batch, a target message whose delay measurement field is set to a first value;
[0183] Reports the message timestamp of the target message to the receiving entity.
[0184] In this embodiment of the present application, the delay measurement field includes a first value or a second value. If the delay measurement field is the first value, it indicates that the message is the target message. The message traversal node is required to report the message timestamp of the target message to the receiving entity (the message timestamp is the timestamp when the message traversal node receives the target message). If the delay measurement field is the second value, the message traversal node is not required to report the message timestamp of the target message to the receiving entity.
[0185] In one embodiment, reporting at least one of a flow identifier of a target service flow, a message sequence number of a message in the target service flow, and a measurement period number of a message in the target service flow to a receiving entity according to an indication of a flow identifier bit, a message sequence number bit, and a measurement period number bit includes:
[0186] Report the flow identifier to the receiving entity, and when the message sequence number bit of each message is set to the first value, report the message sequence number of each message to the receiving entity, and when the measurement period number bit is set to the first value, report the measurement period number of each message to the receiving entity.
[0187] In an embodiment of the present application, while reporting the timestamp, the message penetration node reports the flow identifier in the target message, reports the message sequence number when the message sequence number bit indicates the existence of the message sequence number, and reports the measurement cycle number when the measurement cycle number bit indicates the existence of the measurement cycle number. After the receiving entity receives the timestamp, flow identifier, message sequence number and measurement cycle number reported by different nodes, it can associate the timestamps belonging to the same target message to obtain the delay of a specific network flow in a certain measurement cycle. It should be noted that since the message sequence number of the target message in a certain network flow is unique, the unique target message can be located by the flow identifier and the message sequence number. The unique target message cannot be located only by the flow identifier or only by the message sequence number.
[0188] An example is given to illustrate the delay calculation method. For example, node A reports to the receiving entity that the flow ID is A1, the message sequence number is B1, and the measurement cycle number is C1. The timestamp is 8:30:10:5 (hour: minute: second: millisecond), and the message count value is 8:30:10:7 for the flow ID is A2, the message sequence number is B1, and the measurement cycle number is C2. Node B reports to the receiving entity that the flow ID is A1, the message sequence number is B1, and the measurement cycle number is C1. The timestamp is 8:30:10:13.8, the flow ID is A2, and the message sequence number is B2. , the timestamp of measurement cycle number C2 is 8:31:10:13.8. The receiving entity can associate the timestamp (8:30:10:5) of node A for the flow identifier A1, message sequence number B1, and measurement cycle number C1 with the timestamp (8:30:10:13.8) of node B for the flow identifier A1, message sequence number B1, and measurement cycle number C1, and deduce that the delay of the message with flow identifier A1 and measurement cycle number C1 between nodes A and B is 8.8 ms.
[0189] The message processing method provided in the embodiment of the present application reports the flow identifier, message sequence number and measurement period number at the same time as the message timestamp, so as to facilitate the receiving entity to associate the message timestamps reported by each node belonging to the same target message and calculate the delay of a certain measurement period of a certain network flow.
[0190] It should be understood that, although the various steps in the flowcharts involved in the various embodiments described above are displayed in sequence according to the instructions of the arrows, these steps are not necessarily executed in sequence in the order indicated by the arrows. Unless otherwise specified herein, there is no strict order restriction on the execution of these steps, and these steps can be executed in other orders. Moreover, at least a portion of the steps in the flowcharts involved in the various embodiments described above can include multiple steps or multiple stages, and these steps or stages are not necessarily executed and completed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a portion of steps or stages in other steps.
[0191] Based on the same inventive concept, embodiments of the present application further provide a message processing device for implementing the aforementioned message processing method. The implementation solution provided by the device is similar to the implementation solution described in the aforementioned method. Therefore, the specific limitations of one or more message processing device embodiments provided below can be found in the above-mentioned limitations of the message processing method and will not be repeated here.
[0192] In one embodiment, Figure 11 As shown, a message processing device 1100 is provided, including: an encapsulation module 1102, wherein:
[0193] The encapsulation module 1102 is configured to encapsulate an extended trace option for each message in the forwarded target service flow, wherein the extended trace option includes an IOAM trace type field and a measurement field; wherein:
[0194] The IOAM trace type field is used to instruct the nodes in the message forwarding path to fill the IOAM data into the node data list field of the message according to the IOAM data type indicated by the IOAM trace type field;
[0195] The measurement field is used to instruct the nodes in the message forwarding path to perform packet loss measurement and / or delay measurement.
[0196] The message processing device provided in an embodiment of the present application encapsulates an extended trace option in a message, instructing each node in the message forwarding path to fill the message with IOAM data and directly report network status measurement data to a receiving entity. Because the present embodiment of the application does not rely on the message decapsulation node to collect IOAM data and report the IOAM data to the receiving entity, but instead allows each node to directly report relevant network measurement data to the receiving entity, even if the message is lost during transmission, the network status measurement data generated before the packet loss can be received and used to determine the network status based on this data.
[0197] In one embodiment, the extended trace option also includes a flow identification bit, a message sequence number bit and a measurement period number bit. When the flow identification bit is set to the first value, an optional flow identification field exists in the extended trace option; when the message sequence number bit is set to the first value, an optional message sequence number field exists in the extended trace option; when the measurement period number bit is set to the first value, an optional measurement period number field exists in the extended trace option.
[0198] In one embodiment, the IOAM trace type field includes multiple bits for indicating the type of IOAM data used; the nodes in the message forwarding path fill the IOAM data into the node data list field of the message according to the settings of each bit of the IOAM trace type field.
[0199] In one embodiment, the encapsulation module 1102 is further configured to:
[0200] Selecting a monitoring message from the target service flow;
[0201] For the selected monitoring message, set a target bit position in the IOAM trace type field of the monitoring message to a first value; for other messages not selected as the monitoring message, set all bit positions in the IOAM trace type field of the other messages to a second value, where the first value and the second value are different;
[0202] The target bit set to the first value is specifically used to instruct the nodes in the message forwarding path to fill the node data list field of the message with the IOAM data indicated by the target bit;
[0203] The target bit set to the second value is specifically used to instruct the nodes in the message forwarding path to prohibit filling the IOAM data indicated by the target bit into the node data list field of the message.
[0204] In one embodiment, the measurement field includes a packet loss measurement field, and the field value of the packet loss measurement field of all packets belonging to the same packet batch in the target service flow is the same;
[0205] The packet loss measurement field is specifically used to instruct the nodes in the message forwarding path to determine the message batch to which the message belongs according to the field value of the packet loss measurement field, and report the message count value corresponding to the message batch to the receiving entity.
[0206] In one embodiment, the measurement field includes a delay measurement field, and the encapsulation module 1102 is further configured to:
[0207] A target message is determined from each message batch, a delay measurement field of the target message is set to a first value, and delay measurement fields of other messages in the message batch except the target message are set to a second value, where the first value and the second value are different.
[0208] In one of the embodiments, the delay measurement field set to the first value is specifically used to instruct the node in the message forwarding path to report the message timestamp of the target message to the receiving entity.
[0209] In one embodiment, Figure 12 As shown, a message processing device 1200 is provided, including: a receiving module 1202, a filling module 1204, and a sending module 1206, wherein:
[0210] A receiving module 1202 is configured to receive each message of a target service flow encapsulated with an extended trace option sent by a message encapsulation node in the message forwarding path, wherein the extended trace option includes an IOAM trace type field and a measurement field;
[0211] A filling module 1204 is configured to fill the node data list field of each message with IOAM data according to the IOAM data type indicated by the IOAM trace type field, and perform packet loss measurement and / or delay measurement according to the indication of the measurement field;
[0212] The sending module 1206 is configured to forward the message filled with IOAM data to the next node in the message forwarding path.
[0213] The message processing device provided in an embodiment of the present application encapsulates an extended trace option in a message, instructing each node in the message forwarding path to fill the message with IOAM data and directly report network status measurement data to a receiving entity. Because the present embodiment of the application does not rely on the message decapsulation node to collect IOAM data and report the IOAM data to the receiving entity, but instead allows each node to directly report relevant network measurement data to the receiving entity, even if the message is lost during transmission, the network status measurement data generated before the packet loss can be received and used to determine the network status based on this data.
[0214] In one embodiment, the IOAM trace type field includes multiple bits, different bits correspond to different IOAM data types, and different bit values are used to indicate whether a node in the message forwarding path fills the IOAM data into the node data list field of the message. The filling module 1204 is further used to:
[0215] determining, according to the value of each bit in the IOAM trace type field, the IOAM data type to be filled into each of the messages;
[0216] Fill each of the messages with IOAM data corresponding to the target IOAM data type.
[0217] In one embodiment, the extended trace option further includes a flow identification bit, a message sequence number bit, and a measurement period number bit, and the filling module 1204 is further configured to:
[0218] Perform packet loss measurement and / or delay measurement according to the indication of the measurement field, and report at least one of the flow identifier of the target service flow, the message sequence number of the message in the target service flow, and the measurement period number of the message in the target service flow to the receiving entity according to the indication of the flow identifier bit, the message sequence number bit, and the measurement period number bit.
[0219] In one embodiment, the measurement field includes a packet loss measurement field, and the filling module 1204 is further configured to:
[0220] For each message in the target service flow, determining the message batch to which the message belongs according to the field value of the packet loss measurement field;
[0221] Reporting the message count value corresponding to each message batch to the receiving entity according to the message batch;
[0222] Among them, the field value of the packet loss measurement field of multiple consecutive messages belonging to the same message batch in the target service flow is the same.
[0223] In one embodiment, the filling module 1204 is further configured to:
[0224] The flow identifier is reported to the receiving entity, and when the measurement period number bit of each message is set to a first value, the measurement period number of each message is reported to the receiving entity.
[0225] In one embodiment, the measurement field includes a delay measurement field, and the filling module 1204 is further configured to:
[0226] Determine, from each message in the message batch, a target message in which the delay measurement field is set to a first value;
[0227] Reporting the message timestamp of the target message to the receiving entity.
[0228] In one embodiment, the extended trace option further includes an extended flag field, and the filling module 1204 is further configured to:
[0229] Report the flow identifier to the receiving entity, and when the message sequence number bit of each message is set to the first value, report the message sequence number of each message to the receiving entity, and when the measurement period number bit is set to the first value, report the measurement period number of each message to the receiving entity.
[0230] Each module in the above-mentioned apparatus may be implemented in whole or in part by software, hardware, or a combination thereof. Each module may be embedded in or independent of a processor in a computer device in the form of hardware, or may be stored in a memory in the computer device in the form of software, so that the processor can call and execute the operations corresponding to each module.
[0231] In one embodiment, a network element device is provided. Figure 13 A schematic diagram of the structure of a network element device provided in an embodiment of the present application. The network element may include a receiver 1301, a memory 1302, a processor 1303, at least one communication bus 1304, and a transmitter 1305. The communication bus 1304 is used to implement communication connections between components. The memory 1302 may include a high-speed RAM memory, and may also include a non-volatile storage NVM, such as at least one disk storage. The memory 1302 may store various programs for performing various processing functions and implementing the method steps of this embodiment. In this embodiment, the transmitter 1305 may be a radio frequency processing module or a baseband processing module in an access network device, and the receiver 1301 may also be a radio frequency processing module or a baseband processing module in an access network device. The transmitter 1305 and the receiver 1301 may be integrated together to form a transceiver. Both the transmitter 1305 and the receiver 1301 may be coupled to the processor 1303, and may perform receiving or transmitting actions under the instruction or control of the processor 1303.
[0232] In this embodiment, the processor 1303 is configured to encapsulate an extended trace option for each message in the forwarded target service flow; the extended trace option includes an IOAM trace type field and a measurement field; wherein:
[0233] The IOAM trace type field is used to instruct the nodes in the message forwarding path to fill the IOAM data into the node data list field of the message according to the IOAM data type indicated by the IOAM trace type field;
[0234] The measurement field is used to instruct the nodes in the message forwarding path to perform packet loss measurement and / or delay measurement.
[0235] In one embodiment, the extended trace option also includes a flow identification bit, a message sequence number bit and a measurement period number bit. When the flow identification bit is set to the first value, an optional flow identification field exists in the extended trace option; when the message sequence number bit is set to the first value, an optional message sequence number field exists in the extended trace option; when the measurement period number bit is set to the first value, an optional measurement period number field exists in the extended trace option.
[0236] In one embodiment, the IOAM trace type field includes multiple bits for indicating the type of IOAM data used; the nodes in the message forwarding path fill the IOAM data into the node data list field of the message according to the settings of each bit of the IOAM trace type field.
[0237] In one embodiment, the processor 1303 is further configured to select a monitoring message from the target service flow;
[0238] For the selected monitoring message, set a target bit position in the IOAM trace type field of the monitoring message to a first value; for other messages not selected as the monitoring message, set all bit positions in the IOAM trace type field of the other messages to a second value, where the first value and the second value are different;
[0239] The target bit set to the first value is specifically used to instruct the nodes in the message forwarding path to fill the node data list field of the message with the IOAM data indicated by the target bit;
[0240] The target bit set to the second value is specifically used to instruct the nodes in the message forwarding path to prohibit filling the IOAM data indicated by the target bit into the node data list field of the message.
[0241] In one embodiment, the measurement field includes a packet loss measurement field, and the field value of the packet loss measurement field of all packets belonging to the same packet batch in the target service flow is the same;
[0242] The packet loss measurement field is specifically used to instruct the nodes in the message forwarding path to determine the message batch to which the message belongs according to the field value of the packet loss measurement field, and report the message count value corresponding to the message batch to the receiving entity.
[0243] In one embodiment, the measurement field includes a delay measurement field, and the processor 1303 is further used to determine a target message from each of the message batches, set the delay measurement field of the target message to a first value, and set the delay measurement field of other messages in the message batch except the target message to a second value, and the first value and the second value are different.
[0244] In one of the embodiments, the delay measurement field set to the first value is specifically used to instruct the node in the message forwarding path to report the message timestamp of the target message to the receiving entity.
[0245] In one embodiment, a network element device is provided. Figure 14 A schematic diagram of the structure of a network element device provided in an embodiment of the present application. The network element may include a receiver 1401, a memory 1402, a processor 1403, at least one communication bus 1404, and a transmitter 1405. The specific definitions of the receiver 1401, the memory 1402, the processor 1403, the communication bus 1404, and the transmitter 1405 can be referred to in the aforementioned embodiment, and will not be repeated in detail in this embodiment of the present application.
[0246] In this embodiment, the receiver 1401 is configured to receive each packet of a target service flow encapsulated with an extended trace option sent by a packet encapsulation node in a packet forwarding path, wherein the extended trace option includes an IOAM trace type field and a measurement field;
[0247] Processor 1403 is configured to fill the node data list field of each message with IOAM data according to the IOAM data type indicated by the IOAM trace type field, and perform packet loss measurement and / or latency measurement according to the indication of the measurement field;
[0248] The transmitter 1405 is configured to report the network status measurement data to a receiving entity, and further configured to forward the message filled with IOAM data to the next node in the message forwarding path.
[0249] In one embodiment, the IOAM trace type field includes multiple bits, different bits correspond to different IOAM data types, and different bit values are used to indicate whether a node in the message forwarding path fills the IOAM data into the node data list field of the message. The processor 1403 is further configured to:
[0250] determining, according to the value of each bit in the IOAM trace type field, the IOAM data type to be filled into each of the messages;
[0251] Fill each of the messages with IOAM data corresponding to the target IOAM data type.
[0252] In one embodiment, the extended trace option also includes a flow identification bit, a message sequence number bit and a measurement period number bit, and the processor 1403 is further used to perform packet loss measurement and / or delay measurement according to the indication of the measurement field, and control the transmitter 1405 to report at least one of the flow identification of the target service flow, the message sequence number of the message in the target service flow, and the measurement period number of the message in the target service flow to the receiving entity according to the indication of the flow identification bit, the message sequence number bit and the measurement period number bit.
[0253] In one embodiment, the measurement field includes a packet loss measurement field, and the processor 1403 is further configured to determine, for each message in the target service flow, a message batch to which the message belongs based on a field value of the packet loss measurement field; and control the transmitter 1405 to report a message count value corresponding to each message batch to the receiving entity according to the message batch;
[0254] Among them, the field value of the packet loss measurement field of multiple consecutive messages belonging to the same message batch in the target service flow is the same.
[0255] In one embodiment, the transmitter 1405 is further configured to report the flow identifier to the receiving entity, and when the measurement period number bit of each message is set to the first value, report the measurement period number of each message to the receiving entity.
[0256] In one embodiment, the measurement field includes a delay measurement field, and the processor 1403 is further used to determine the target message in which the delay measurement field is set to the first value from each message in the message batch; and control the transmitter 1405 to report the message timestamp of the target message to the receiving entity.
[0257] In one embodiment, the transmitter 1405 is further used to report the flow identifier to the receiving entity, and when the message sequence number bit of each message is set to the first value, report the message sequence number of each message to the receiving entity, and when the measurement period number bit is set to the first value, report the measurement period number of each message to the receiving entity.
[0258] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps in the above-mentioned method embodiments are implemented.
[0259] In one embodiment, a computer program product is provided, including a computer program, which implements the steps in the above method embodiments when executed by a processor.
[0260] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties.
[0261] Those skilled in the art will appreciate that all or part of the processes in the above-mentioned embodiments can be implemented by instructing the relevant hardware through a computer program. The computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the above-mentioned embodiments. In particular, any reference to memory, database, or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The databases involved in the various embodiments provided herein may include at least one of a relational database and a non-relational database. Non-relational databases may include, but are not limited to, distributed databases based on blockchains. The processors involved in the various embodiments provided herein may be, but are not limited to, general-purpose processors, central processing units (CPUs), graphics processing units (GPUs), digital signal processors (DSPs), programmable logic devices (PLDs), data processing logic devices based on quantum computing, and the like.
[0262] The technical features of the above embodiments can be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0263] The above-described embodiments merely represent several implementation methods of the present application. While the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the present application. It should be noted that a person of ordinary skill in the art may make various modifications and improvements without departing from the spirit of the present application, and these modifications and improvements fall within the scope of protection of the present application. Therefore, the scope of protection of the present application shall be determined by the appended claims.
Claims
1. A message processing method, characterized in that: Applied to a message encapsulation node in a message forwarding path, the method comprises: Encapsulate an extended trace option for each message in the forwarded target service flow, wherein the extended trace option includes an IOAM trace type field and a measurement field; wherein: The IOAM trace type field is used to instruct the nodes in the message forwarding path to fill the IOAM data into the node data list field of the message according to the IOAM data type indicated by the IOAM trace type field; The measurement field is used to instruct the nodes in the message forwarding path to perform packet loss measurement and / or delay measurement.
2. The method according to claim 1, characterized in that The extended trace option also includes a flow identification bit, a message sequence number bit, and a measurement period number bit. When the flow identification bit is set to a first value, an optional flow identification field exists in the extended trace option; when the message sequence number bit is set to a first value, an optional message sequence number field exists in the extended trace option; when the measurement period number bit is set to a first value, an optional measurement period number field exists in the extended trace option.
3. The method according to claim 1, characterized in that The IOAM trace type field includes multiple bits for indicating the type of IOAM data used; the nodes in the message forwarding path fill the IOAM data into the node data list field of the message according to the settings of the bits of the IOAM trace type field.
4. The method according to claim 3, characterized in that The extended trace options for each message encapsulation in the forwarded target service flow include: Selecting a monitoring message from the target service flow; For the selected monitoring message, set a target bit position in the IOAM trace type field of the monitoring message to a first value; for other messages not selected as the monitoring message, set all bit positions in the IOAM trace type field of the other messages to a second value, where the first value and the second value are different; The target bit set to the first value is specifically used to instruct the nodes in the message forwarding path to fill the node data list field of the message with the IOAM data indicated by the target bit; The target bit set to the second value is specifically used to instruct the nodes in the message forwarding path to prohibit filling the IOAM data indicated by the target bit into the node data list field of the message.
5. The method according to claim 1, wherein The measurement field includes a packet loss measurement field, and the field value of the packet loss measurement field of all packets belonging to the same packet batch in the target service flow is the same; The packet loss measurement field is specifically used to instruct the nodes in the message forwarding path to determine the message batch to which the message belongs according to the field value of the packet loss measurement field, and report the message count value corresponding to the message batch to the receiving entity.
6. The method according to claim 1, wherein The measurement field includes a delay measurement field, and the extended trace option for each message encapsulation in the forwarded target service flow also includes: A target message is determined from each message batch, a delay measurement field of the target message is set to a first value, and delay measurement fields of other messages in the message batch except the target message are set to a second value, where the first value and the second value are different.
7. The method according to claim 6, characterized in that The delay measurement field set to the first value is specifically used to instruct the node in the message forwarding path to report the message timestamp of the target message to the receiving entity.
8. A message processing method, characterized in that: Applied to a message traversal node in a message forwarding path, the method includes: receiving each message of the target service flow encapsulated with an extended trace option sent by a message encapsulation node in the message forwarding path, wherein the extended trace option includes an IOAM trace type field and a measurement field; Filling the node data list field of each of the messages with IOAM data according to the IOAM data type indicated by the IOAM trace type field, and performing packet loss measurement and / or latency measurement according to the indication of the measurement field; The message filled with IOAM data is forwarded to the next node in the message forwarding path.
9. The method according to claim 8, characterized in that The IOAM trace type field includes a plurality of bits, where different bits correspond to different IOAM data types, and different bit values are used to indicate whether a node in the message forwarding path fills the node data list field of the message with the IOAM data. Filling the node data list field of each message with IOAM data according to the IOAM data type indicated by the IOAM trace type field includes: determining, according to the value of each bit in the IOAM trace type field, the IOAM data type to be filled into each of the messages; The node data list field of each message is filled with IOAM data corresponding to the target IOAM data type.
10. The method according to claim 8, characterized in that The extended trace option further includes a flow identification bit, a message sequence number bit, and a measurement period number bit. The performing of packet loss measurement and / or delay measurement according to the indication of the measurement field includes: Perform packet loss measurement and / or delay measurement according to the indication of the measurement field, and report at least one of the flow identifier of the target service flow, the message sequence number of the message in the target service flow, and the measurement period number of the message in the target service flow to the receiving entity according to the indication of the flow identifier bit, the message sequence number bit, and the measurement period number bit.
11. The method according to claim 10, characterized in that The measurement field includes a packet loss measurement field, and performing packet loss measurement according to an instruction of the measurement field includes: For each message in the target service flow, determining the message batch to which the message belongs according to the field value of the packet loss measurement field; Reporting the message count value corresponding to each message batch to the receiving entity according to the message batch; Among them, the field value of the packet loss measurement field of multiple consecutive messages belonging to the same message batch in the target service flow is the same.
12. The method according to claim 11, characterized in that The reporting, according to the indication of the flow identifier bit, the message sequence number bit, and the measurement period number bit, to the receiving entity, at least one of the flow identifier of the target service flow, the message sequence number of the message in the target service flow, and the measurement period number of the message in the target service flow, includes: The flow identifier is reported to the receiving entity, and when the measurement period number bit of each message is set to a first value, the measurement period number of each message is reported to the receiving entity.
13. The method according to claim 10, characterized in that The measurement field includes a delay measurement field, and performing delay measurement according to an instruction of the measurement field includes: Determine, from each message in the message batch, a target message in which the delay measurement field is set to a first value; Reporting the message timestamp of the target message to the receiving entity.
14. The method according to claim 13, characterized in that The reporting, according to the indication of the flow identifier bit, the message sequence number bit, and the measurement period number bit, to the receiving entity, at least one of the flow identifier of the target service flow, the message sequence number of the message in the target service flow, and the measurement period number of the message in the target service flow, includes: Report the flow identifier to the receiving entity, and when the message sequence number bit of each message is set to the first value, report the message sequence number of each message to the receiving entity, and when the measurement period number bit is set to the first value, report the measurement period number of each message to the receiving entity.
15. A message processing device, characterized in that: Applicable to a message encapsulation node in a message forwarding path, the device comprises: An encapsulation module is configured to encapsulate an extended trace option for each message in the forwarded target service flow; the extended trace option includes an IOAM trace type field and a measurement field; wherein: The IOAM trace type field is used to instruct the nodes in the message forwarding path to fill the IOAM data into the node data list field of the message according to the IOAM data type indicated by the IOAM trace type field; The measurement field is used to instruct the nodes in the message forwarding path to perform packet loss measurement and / or delay measurement.
16. A message processing device, characterized in that: Applicable to a message penetration node in a message forwarding path, the device comprises: a receiving module, configured to receive each message of a target service flow encapsulated with an extended trace option sent by a message encapsulation node in the message forwarding path, wherein the extended trace option includes an IOAM trace type field and a measurement field; a filling module, configured to fill the node data list field of each message with IOAM data according to the IOAM data type indicated by the IOAM trace type field, and perform packet loss measurement and / or delay measurement according to the indication of the measurement field; The sending module is used to forward the message filled with IOAM data to the next node in the message forwarding path.
17. A network element device, characterized in that: Processors included: The processor is configured to encapsulate an extended trace option for each message in the forwarded target service flow; the extended trace option includes an IOAM trace type field and a measurement field; wherein: The IOAM trace type field is used to instruct the nodes in the message forwarding path to fill the IOAM data into the node data list field of the message according to the IOAM data type indicated by the IOAM trace type field; The measurement field is used to instruct the nodes in the message forwarding path to perform packet loss measurement and / or delay measurement.
18. A network element device, characterized in that: Includes receiver, processor and transmitter: The receiver is configured to receive each message of a target service flow encapsulated with an extended trace option sent by a message encapsulation node in a message forwarding path, wherein the extended trace option includes an IOAM trace type field and a measurement field; The processor is configured to fill the node data list field of each of the messages with IOAM data according to the IOAM data type indicated by the IOAM trace type field, and perform packet loss measurement and / or latency measurement according to the indication of the measurement field; The transmitter is configured to report the network status measurement data to a receiving entity, and is further configured to forward the message filled with IOAM data to a next node in the message forwarding path.
19. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 14 are implemented.
20. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 14 are implemented.