[go: up one dir, main page]
More Web Proxy on the site http://driver.im/

CN114666681B - Stateful in-band network telemetry method and system - Google Patents

Stateful in-band network telemetry method and system Download PDF

Info

Publication number
CN114666681B
CN114666681B CN202210277734.9A CN202210277734A CN114666681B CN 114666681 B CN114666681 B CN 114666681B CN 202210277734 A CN202210277734 A CN 202210277734A CN 114666681 B CN114666681 B CN 114666681B
Authority
CN
China
Prior art keywords
int
header
metadata
effective
register
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202210277734.9A
Other languages
Chinese (zh)
Other versions
CN114666681A (en
Inventor
陈晓筹
黄文菊
谢怡
杨奕锦
卢晓莉
郑少杰
覃翔
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Xiamen University
Original Assignee
Xiamen University
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Xiamen University filed Critical Xiamen University
Priority to CN202210277734.9A priority Critical patent/CN114666681B/en
Publication of CN114666681A publication Critical patent/CN114666681A/en
Application granted granted Critical
Publication of CN114666681B publication Critical patent/CN114666681B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04QSELECTING
    • H04Q9/00Arrangements in telecontrol or telemetry systems for selectively calling a substation from a main station, in which substation desired apparatus is selected for applying a control signal thereto or for obtaining measured values therefrom
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/12Network monitoring probes
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/06Notations for structuring of protocol data, e.g. abstract syntax notation one [ASN.1]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/22Parsing or analysis of headers

Landscapes

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

Abstract

The invention discloses a stateful in-band network telemetry method and system (Stateful In-band Network Telemetry, SF-INT), comprising: defining an instruction header of the SF-INT, wherein a new field specific to the SF-INT is contained; the network node uses the self register to store INT state information in a distributed way, processes and forwards the INT header information which is reached, and the size of a normally forwarded metadata stack is unchanged; a Network Monitoring System (NMS) calculates a plurality of received INT headers, and can obtain complete network telemetry results; the network node can switch to the current INT protocol in real time and seamlessly in case of emergency, and the NMS can correctly recognize the situation and make corresponding calculation. Compared with the stateless current INT protocol, the stateful INT of the invention not only can meet the network telemetry requirement, but also saves the Internet bandwidth by greatly reducing the INT metadata carried by the service packet.

Description

Stateful in-band network telemetry method and system
Technical Field
The invention relates to the technical field of network communication, in particular to a method and a system for in-band network telemetry (Inband Network Telemetry, INT) with a state (Stateful), which are abbreviated as SF-INT.
Background
In-band network telemetry (In-band Network Telemetry, INT) is a new type of network measurement technology. Most of traditional network measurement methods pay attention to network performance between terminals, and measurement results thereof are often based on packet loss and delay information; whereas INT focuses on the real-time network status of each network node. The INT current protocol embeds an INT instruction header containing telemetry instructions in the header of the service message, and each network node adds corresponding network state information (i.e., metadata) to the INT header according to the telemetry instructions so that network measurements no longer face a "black box". After the network monitoring system (Network Monitoring System, NMS) receives the INT header, the network monitoring system can dynamically sense the details of the network quality and improve the analysis capability.
The INT is capable of providing status information of each network device on the telemetry path, but the problem of excessive measurement overhead is to be solved. In the normal working mode of the INT, each time the data packet passes through a network node, the node will add metadata of itself, so the number of bits occupied by the INT header will increase with the increase of the number of nodes through which the data packet passes, and the excessive overhead of the INT header will cause a serious drop in bandwidth utilization. In addition, because the telemetry path is dynamically changing, it is difficult to estimate and reserve the space required for the INT header, which can cause network state information for some nodes to be discarded due to insufficient space, or to form a large number of data slices that affect network performance. Another "postcard" mode of operation is to insert an INT command header containing telemetry commands only in the header of the traffic packet, each network node executing the telemetry commands in the packet header and transmitting metadata representing its current network state in the form of a separate packet. This, while fixing the overhead of the INT header, can cause several times the number of telemetry packets than normal traffic packets, which can seriously impact the accuracy of the network measurements. In addition, the processing load of the network node is greatly increased.
In order to reduce the overhead of the INT header, some studies compress the INT header for the nature of the network state that needs to be collected. For example, for the buffer occupancy ratio on the packet output port, the occupancy ratio of each node is no longer recorded but only the maximum value is kept; for residence processing time on a node, the time of each node is no longer recorded, only the cumulative time sum is recorded or the maximum time on a single node is reserved. Unfortunately, such compression process sacrifices node state details, losing global visualization and versatility of network telemetry. Still other research efforts have employed sampling strategies (based on probabilistic predictions, etc.) to have only a portion of the traffic packets carry the INT metadata to reduce the average overhead of the INT header. But this does not completely solve the problem of excessive INT overhead, and the payload of the data packet carrying the INT metadata is still difficult to estimate.
The bandwidth of the network physical interface is continuously improved to 10G, 100G or even higher, and the arrival interval of the data packet is very short. In addition to the packet-following detection characteristics of INT, INT reports generated continuously at high speed form data lakes in NMS, and network states carried in a large number of INT reports are repetitive or very little different, resulting in information redundancy. How to process massive INT headers, efficiently recording network state changes, is a new challenge facing INT.
Disclosure of Invention
The invention provides a stateful in-band network telemetry method and a stateful in-band network telemetry system, which are based on a state register of a network node and SF-INT forwarding rules of state information, and can efficiently complete network telemetry tasks; in the standard mode of network telemetry, the INT header length remains set constant and no additional data packets are generated; in an emergency mode, seamless switching with the current INT can be realized; the 'sampling' attribute of the status register enables the NMS to avoid storing INT reports with extremely short intervals and information redundancy, and better solves the problem of mass data.
The invention adopts the following technical scheme:
In one aspect, a method of stateful in-band network telemetry includes:
INT source node processing step: the INT source node receives a data packet which needs to execute network telemetry, inserts an INT header after analysis, and sends the data packet to the next node after repackaging; the INT header includes an INT valid header; the INT effective head comprises an INT instruction head and a metadata stack; the INT instruction head comprises a C field, a U field, an ST field and packetID fields; the C field is set to be whether SF-INT is adopted; the U field is set to an emergency mode or a standard mode; the ST field is set to X, and is used for indicating that the INT header carries a metadata segment which needs exclusive OR operation to the subsequent INT forwarding node; the packetID field is set to a packet ID; the metadata stack is used for inserting metadata segments of the INT source node;
INT transmitting node processing step: when the U field is set to be in a standard mode, after the INT forwarding node receives a data packet from a previous node, an effective INT head carried in the arrived data packet is analyzed; the arrived INT effective head is compared with the INT effective head in the register, and based on an SF-INT forwarding rule, the INT effective head to be transmitted and the INT effective head to be stored in the register are obtained; the INT effective head to be sent is packaged and then sent to the next node; the data packet to be stored is stored in a register;
INT end node processing step: after receiving the data packet of the previous node, the INT terminal node analyzes the INT header in the data packet, directly adds the metadata segment of the INT terminal node into the metadata stack to generate an INT report, and encapsulates the INT report in an independent message to be sent to the NMS;
NMS processing steps: after receiving INT reports of SF-INT, NMS processes the INT reports of same packetID received before and after, and obtains bare metadata segment of each node.
Preferably, the INT forwarding node processing step further includes:
When the U field is set to an emergency mode, or a node detects a network event or receives a related network event notification, the node directly switches to the emergency mode to realize instant seamless switching; judging whether an INT effective header is stored in a register, if so, packaging the INT effective header stored in the register into an INT report, and sending the INT report to the NMS in an independent data packet; thereafter, the node no longer uses the register to store historical network state information, but adds its own metadata segment directly in the metadata stack carried by the arriving packet.
Preferably, before the INT source node processing step, a telemetry control step is further included, specifically as follows:
Based on the configuration data, the terminal APP or the SDN northbound APP sends a message to the INT source node; the message includes the data packet that needs telemetry, telemetry instructions, the maximum number of telemetry nodes, and whether SF-INT is enabled.
Preferably, the method further comprises:
When an INT source node, an INT forwarding node, or an INT end node inserts or exclusive-ors its own metadata segment in the metadata stack, the value in the "RemainingHop Cnt" field in the INT instruction header is decremented by 1.
Preferably, the value of the ST field can also be set to H, L and E; h represents a high priority; l represents low priority; e indicates that no metadata segment is contained in the metadata stack.
Preferably, the arriving INT effective header is compared with the INT effective header in the register, and the INT effective header to be sent and the INT effective header to be stored in the register are obtained according to an SF-INT forwarding rule, wherein the specific rule comprises:
if the ST field of the arrived INT effective header is X and the ST field of the INT effective header in the register is H, the INT effective header to be transmitted is set as the INT effective header in the register, the metadata segment of the INT effective header to be stored in the register is set as the metadata segment of the arrived INT effective header, and the ST field of the INT effective header to be stored in the register is set as L;
If the ST field of the arrived INT effective header is X and the ST field of the INT effective header in the register is L, setting the metadata segment of the INT effective header to be transmitted as a data segment generated after the metadata segment of the arrived INT effective header and the metadata segment of the current node are subjected to exclusive OR, and setting the corresponding ST field as X; setting a metadata segment of an INT effective header to be stored in a register as a metadata segment of an arriving INT effective header, and setting a corresponding ST field as H;
If the ST field of the arrived INT effective header is X, the register does not store the INT effective header, the metadata segment of the INT effective header to be transmitted is set as the data segment generated after the metadata segment of the arrived INT effective header and the metadata segment of the current node are subjected to exclusive OR, and the corresponding ST field is set as X; setting a metadata segment of an INT effective header to be stored in a register as a metadata segment of an arriving INT effective header, and setting a corresponding ST field as H;
If the ST field of the arrived INT effective header is H and the ST field of the INT effective header in the register is H, the INT effective header to be transmitted is set as the INT effective header in the register; setting an INT valid header to be stored in a register as an arriving INT valid header;
If the ST field of the arrived INT effective header is H, the ST field of the INT effective header in the register is L, and the arrived INT effective header and the INT effective header in the register comprise the same data packet ID, the INT effective header to be sent is set as the INT effective header in the register; setting a metadata segment of an INT effective header to be stored in a register as a metadata segment of an arriving INT effective header, and setting an ST field of the INT effective header to be stored in the register as L;
If the ST field of the arrived INT effective header is H, the ST field of the INT effective header in the register is L, and the arrived INT effective header and the INT effective header in the register comprise different data packet IDs, the INT effective header to be sent is set as the arrived INT effective header; while the INT valid header in the register is unchanged;
if the ST field of the arrived INT effective header is H and the INT effective header is not stored in the register, the INT effective header to be sent is set as the arrived INT effective header, and the register is still empty;
If the ST field of the arrived INT effective header is L and the ST field of the INT effective header in the register is H, the INT effective header to be transmitted is set as the INT effective header in the register; setting an INT valid header to be stored in a register as an arriving INT valid header;
if the ST field of the arrived INT effective header is L and the ST field of the INT effective header in the register is L, the INT effective header to be transmitted is set as the INT effective header in the register; setting an INT valid header to be stored in a register as an arriving INT valid header;
if the ST field of the arrived INT valid header is L and the INT valid header is not stored in the register, the INT valid header to be transmitted is set to the arrived INT valid header, and the register is still empty.
Preferably, the NMS processing step specifically includes:
if the current data packet ID is equal to 255, judging whether the number of nodes contained in the bottom metadata segment of the metadata stack is greater than 1, if so, discarding the bottom metadata segment, reading the non-bottom bare metadata segment, finishing all the bare metadata segments, and ending the processing of the current data packet ID; otherwise, reading the bottom bare metadata segment and the non-bottom bare metadata segment, sorting all the bare metadata segments, and ending the processing of the current data packet ID;
If the ID of the current data packet is not equal to 255 and the ST field in the data packet is equal to X, judging whether the number of nodes contained in the bottom metadata segment of the metadata stack is more than 1, if so, reading the bottom exclusive-OR metadata segment, carrying out exclusive-OR reduction on the bottom exclusive-OR metadata segment and metadata segments with packetID from other data packets, reading non-bottom bare metadata segments, and sorting all bare metadata segments with packetID; otherwise, reading the bottom bare metadata segment and the non-bottom bare metadata segment, and finishing all bare metadata segments which are same as packetID, and ending the processing of the current data packet ID;
If the ID of the current data packet is not equal to 255 and the ST field in the data packet is not equal to X, judging whether the number of nodes contained in the bottom metadata segment of the metadata stack is more than 1, if so, reading the bottom exclusive-OR metadata segment, carrying out exclusive-OR reduction on the bottom exclusive-OR metadata segment and metadata segments with packetID from other data packets, finishing all bare metadata segments with packetID, and ending the processing of the ID of the current data packet; otherwise, reading the bottom bare metadata segment, sorting all bare metadata segments which are identical to packetID, and ending the processing of the current data packet ID;
If the current packet ID is not equal to 255 and the ST field in the packet is not equal to X, the process further includes: and reading the non-bottom bare metadata segments, finishing all the bare metadata segments, and ending the processing of the current data packet ID.
Preferably, the method for obtaining the number of nodes included in the bottom metadata segment of the metadata stack is as follows:
N3=N1-(N2-1)=N1+1-N2
Wherein N1 represents network state information of N1 nodes contained in the metadata stack; n1=max-R, MAX being the maximum number of nodes that telemetry allows, R representing the value in the "RemainingHop Cnt" field of the INT instruction header; n2 represents the number of metadata segments contained in the metadata stack, n2= (L2-12)/L0, where L0 represents the length of the metadata segment and L2 is the length of the INT effective header.
Preferably, the NMS processing step further comprises:
And if the U field is in an emergency mode, executing related processing of the emergency message.
In another aspect, a stateful in-band network telemetry system includes:
The telemetry control module is used for sending the configuration data to the INT source node; the configuration data includes data packets to be telemetered, telemetry instructions, maximum number of telemetry nodes, and whether SF-INT is enabled;
the telemetry data packet processing module comprises a source node processing sub-module, a forwarding node processing sub-module and an end node processing sub-module;
The source node processing submodule is used for receiving a data packet which needs to execute network telemetry, analyzing the data packet, inserting an INT header, and sending the data packet to the next node after repackaging; the INT header includes an INT valid header including an INT instruction header and a metadata stack; the INT instruction head comprises a C field, a U field, an ST field and packetID fields; the C field is set to be whether SF-INT is adopted; the U field is set to an emergency mode or a standard mode; the ST field is set to X, and is used for indicating that the INT header carries a metadata segment which needs exclusive OR operation to the subsequent INT forwarding node; the packetID field is set to a packet ID; the metadata stack is used for inserting metadata segments of the INT source node;
The forwarding node processing submodule is used for analyzing an effective INT head carried in an arriving data packet after the INT forwarding node receives the data packet from the previous node when the U field is set to be in a standard mode; the arrived INT effective head is compared with the INT effective head in the register, and based on an SF-INT forwarding rule, the INT effective head to be transmitted and the INT effective head to be stored in the register are obtained; the INT effective head to be sent is packaged and then sent to the next node; the data packet to be stored is stored in a register;
the end node processing sub-module is used for analyzing an INT header in a data packet after receiving the data packet of the previous node, directly adding a metadata segment of the end node processing sub-module into a metadata stack, generating an INT report, and packaging the INT report in an independent message and sending the independent message to the NMS;
and the NMS collecting and calculating module is used for processing the INT reports received before and after receiving the SF-INT reports and combining a plurality of identical packetID INT reports received before and after the INT reports to obtain the bare metadata segments of each node.
The beneficial effects of the invention are as follows:
(1) In current INT, the space occupied by the INT header increases with the number of nodes on the telemetry path; the SF-INT of the invention has fixed overhead of the INT header no matter how many nodes are passed, so the SF-INT is insensitive to the number of nodes on a telemetry path, and telemetry can be implemented in a larger range;
(2) After the current INT deployment, the significant overhead of the INT header will inevitably reduce the payload; the metadata stack in the SF-INT header of the invention usually has only one metadata segment, which leads to the sharp decrease of the overhead of the INT header and the great improvement of the effective utilization rate of the bandwidth;
(3) The SF-INT of the invention introduces a lot of improvements, including realizing stateful INT by using node registers for distributed storage, improving the calculation capability of NMS, being fully compatible with the working mode of the current INT and realizing instant seamless switching;
(4) The existing INT lacks enough processing capacity for packet loss, and when packet loss occurs in R3, the NMS under the existing INT cannot know that the packet loss occurs (because the service data packet carrying the network state information of R1 and R2 is lost and cannot reach the NMS) by considering the situation that a telemetry path is R1- > R2- > R3- > R4- > R5- > R6; however, under the SF-INT of the present invention, although packet loss occurs at R3, the history status information is stored by the previous node, so that the NMS still has an opportunity to acquire network status information of forwarding nodes (R1 and R2) before packet loss;
The present invention is described in further detail below with reference to the accompanying drawings and examples, but the present invention is not limited to the examples.
Drawings
FIG. 1 is a schematic diagram of a process of active in-band network telemetry (INT);
FIG. 2 is a schematic diagram of a stateful in-band network telemetry (SF-INT) process of the present invention;
FIG. 3 is a format diagram of the active header of the present INT;
FIG. 4 is a format diagram of the INT active header of SF-INT of the present invention;
FIG. 5 is a flow chart of a stateful in-band network telemetry method of the present invention;
FIG. 6 is a basic process diagram of the telemetry process of an INT forwarding node of the present invention;
fig. 7 is a flowchart of NMS processing of the present invention;
FIG. 8 is a SF-INT process diagram of 6 nodes of the present invention;
FIG. 9 is a schematic diagram of two example processes of SF-INT of the present invention in emergency mode;
Fig. 10 is a block diagram of a stateful in-band network telemetry system of the present invention.
Detailed Description
The invention is further described below by means of specific embodiments. It should be noted that the specific examples described herein are for convenience of description and explanation of the specific embodiments of the present invention and are not intended to limit the present invention.
The present invention will be further described with reference to the drawings and examples below in order to make the objects and technical solutions of the present invention more clear. It should be understood that the examples described herein are for illustration only and are not intended to limit the invention.
First, some terms used in the present invention will be described in a list to facilitate understanding by those skilled in the art to avoid ambiguity.
Metadata (metadata): the telemetry control module may issue telemetry instructions. For each telemetry instruction, the network node needs to provide its own network state information, which is referred to as metadata.
Metadata segment: in a primary telemetry process, a telemetry control module gives a telemetry instruction set; and the network node provides different metadata for different instructions. The sum of all metadata is called a metadata segment.
Length of metadata segment: the bits occupied by the metadata segment are in bytes. The invention is represented by L0.
Bare metadata segment: if the content of a metadata segment is from the original network state information of a certain node, it is called a bare metadata segment.
Exclusive or metadata segment: the new metadata segment generated by exclusive-or calculation of the plurality of metadata segments is called an exclusive-or metadata segment. This is also an innovative definition of SF-INT.
Metadata stack: zero to a plurality of metadata segments are included in the metadata stack, the metadata segments being from different network nodes. SF-INT specifies that there is at most one exclusive OR metadata segment in a metadata stack (at the very bottom in the stack), and that the metadata segments not at the bottom are bare metadata segments. Whereas in current INT, the metadata stack is all bare metadata segments.
INT instruction header (INT METADATA HEADER): the method comprises the steps of telemetry instruction set, 4 fields customized by SF-INT, the number of nodes of the path, the length of metadata segments and the like.
INT active header: consists of an INT instruction header and a metadata stack.
Length of INT active header: the invention is represented by L2 in bytes. Assuming that the number of metadata pieces in the metadata stack is N, l2=12+l0×n.
INT interlayer head (INT SHIM HEADER): the INT interlayer head can have different definitions in different scenes, e.g., the INT interlayer head definition is different in INT over GRE and INT over TCP/UDP scenes. The "length" field in the INT mezzanine header is important for calculating the occupied length of the INT active header.
INT header: an INT interlayer header, an INT instruction header, and a metadata stack are included.
INT source node: refers to INT source node.
INT forwarding node: refers to INT TRANSIT nodes.
INT end node: refers to INT sink node.
The NMS receives the INT report from the INT end node, and analyzes and calculates the INT metadata segment of each node on the telemetry path. These calculations are stored and can be used for network measurements and network management.
Data packets of interest: the telemetry control module typically specifies which types of data packets to sample to obtain network state information on its forwarding path. These data packets for which information is required to be collected are referred to as data packets of interest.
P4-INT: refers to the INT standard established by the P4 working group, the latest being the INT v2.1 standard (https:// P4.Org/specs /). The implementation of INT is currently mainly dependent on the programmable data plane, and the fact that the programmable language standard is P4, so the P4-INT standard is widely accepted by academia and industry as the current INT technical standard.
ID of network node: refers to the order number in which the network nodes appear in the telemetry path. For simplicity, the invention names the network node with an "r+id of the network node". For example, the first network node of the telemetry path has an ID of 1, named R1. R1 is also an INT source node, and the subsequent network forwarding nodes are sequentially marked as R2, R3 and … …
Referring to fig. 1, in the existing telemetry of the INT, each forwarding node generates the INT metadata, so that the length of the metadata stack increases with the number of times of forwarding, and the entire length of the INT header increases. Referring to fig. 2, in the telemetry process of SF-INT of the present invention, only one metadata segment is always in the metadata stack of the network nodes (the INT source node, the INT forwarding node, and the INT end node), so that the INT header does not grow with the increase of the number of nodes through which the data packet passes. The network information in the INT forwarding node registers and the transmitted metadata are both calculated by SF-INT forwarding rules (Table 1), and are therefore also referred to as stateful (stateful); in contrast, current INT is considered stateless. Specifically, FIG. 2 shows the SF-INT in the standard mode; in emergency mode, the node will automatically switch to the active INT mode.
To enable transmission of unit data segments, SF-INT defines a new field in the INT instruction header to enable stateful network telemetry. Specifically, referring to fig. 3 and 4,4 new fields (fig. 4) required for SF-INT are defined by an INT header Reserved field (Reserved field, fig. 3) in the current INT protocol for a total of 12 bits. SF-INT is compatible with the meaning and location of other fields in the current INT instruction header, as it does not change.
Four new fields of SF-INT are:
(1) The 1 st C field occupies one bit. If the value is 1, the indication is SF-INT header; otherwise, the active INT header.
(2) The 2 nd U field/emergency field occupies one bit. If the value is 1, it indicates that the SF-INT emergency mode (urgent) is in; 0 represents the SF-INT standard mode.
(3) The 3 rd ST state field, which occupies 2 bits, may represent the following four INT states:
00: representing Empty (abbreviated E), the metadata stack is described as not containing a metadata segment.
01: Representing High (abbreviated as H), is a High priority meaning, and also represents History (History) information.
10: Representing Low (abbreviation L), meaning Low priority.
11: Representing XOR (abbreviation X), i.e. exclusive or.
The bottom metadata segment in the metadata stack is associated with a status field, which may be labeled with its abbreviation. For example, when the value of the status field is 11, the bottom metadata segment in the metadata stack is referred to as an X metadata segment.
(4) The 4 th "packetID" field, which takes 8 bits, is used to represent the packet ID. The ID of the data packet generated by the INT source node is from 0 to 254, and the data packet can be recycled; and 255 is a reserved number to indicate the ID of the current packet. The purpose of this field is to allow the INT forwarding node and NMS to be used to distinguish between adjacent data packets. There may be multiple metadata segments in a metadata stack. packetID of the data packet to which the bottom metadata segment in the metadata stack belongs is the value in the "packetID" field. The packet to which the non-bottom metadata segment in the metadata stack belongs is the current packet, here packetID =255. If the NMS receives two INT reports, the NMS considers that the two INT packet heads report telemetry information of two independent data packets even if the data packet ID in the INT instruction header in the report is 255.
Obviously, the metadata segment in SF-INT needs to be associated with the INT forwarding nodes, INT states, packetID. For convenience of description, the invention designs a sign of SF-INT metadata segment, which is in the form of:
Status symbol
Where M represents Metadata, and the "status symbol" on the right represents the "status field" in the INT instruction header. Three states, X, H and L are considered herein. Only the bottom metadata segment in the metadata stack needs to be marked with a state symbol, whereas the non-bottom metadata segment is state independent and does not need to be identified. The upper corner mark packetID on M represents packetID of the data packet to which the metadata segment belongs; the IDs of the subscript represent the IDs of one to multiple nodes. IDs indicates that the metadata segment is network status information collected after a certain data packet passes through which nodes. The standard writing specification for IDs includes:
1. If commas exist, the number between two commas represents an ID;
2. each digit that is not between two commas represents a node ID;
3. commas are the partitions between nodes.
For example, ids= "1,2" represents R1 and R2; ids= "12" also represents R1 and R2; ids= "12," representing R1, R2 and R12; ids= ",12,13," represents R12 and R13. Also for example, marksRepresenting that the present metadata segment is the result of exclusive or of the metadata segment collected when the data packet packetID =1 passes through the nodes R1 and R2. The lower middle 1,2 represents the node ID, i.e. the metadata contains the network state information obtained when the packet passes through nodes R1 and R2. Because two nodes are marked, the metadata segment is described as an exclusive or metadata segment, which is formed by exclusive or of the bare metadata segment of the node R1 and the bare metadata segment of the node R2. If there is only one node ID, then the metadata segment is a bare metadata segment. The upper 1 in the middle represents packetID, the ID value assigned by the INT source node.
Referring to fig. 5, in this embodiment, a method for in-band network telemetry with status includes: telemetry control step S51, network node processing step S52 and NMS processing step S53.
The telemetry control step S51 includes: based on the configuration data, the terminal APP sends a message to the INT source node; the message includes the data packet that needs telemetry, telemetry instructions, the maximum number of telemetry nodes, and whether SF-INT is enabled.
Specifically, the execution body of the telemetry control step may be a stand-alone program installed on the terminal, or may be a northbound application on an SDN (software defined network, software Define Network) controller.
Informing the INT source node which data packets to telemetry to (i.e., which are data packets of interest) through a telemetry control step; issuing telemetry instructions (which network states to collect), maximum number of telemetry nodes, indication of whether SF-INT is activated, etc. The telemetry control step belongs to the control plane and is only executed when network telemetry is started, and the telemetry process is completely completed by the data plane.
The network node processes step S52, including: INT source node processing step S521, INT forwarding node processing step S522, and INT end node processing step S523.
The INT source node processing step S521 includes: the INT source node receives a data packet which needs to execute network telemetry, inserts an INT header after analysis, and sends the data packet to the next node after repackaging; the INT header includes an INT valid header including an INT instruction header and an INT metadata stack.
Specifically, the INT source node inserts an INT header after receiving a data packet that requires network telemetry to be performed. According to the issued telemetry instruction, the INT source node sets Instruction Bitmap fields; calculating the length required by a metadata segment, and setting HopML fields according to the length; the value of the length field in the INT mezzanine header is set to L0+12 bytes (equal to the length of the INT valid header), where 12 bytes are the fixed length of the INT instruction header. The INT source node also sets the special field of SF-INT: setting the C field to 1, indicating to the subsequent forwarding node and NMS that this is an SF-INT header; setting the ST field as X, and indicating that the INT header carries a metadata segment needing exclusive OR operation to a subsequent forwarding node; in packeID field, an ID of data packet sequence is inserted (the value range is 0-254, automatic increment and recycling use are realized); the U field is set to 1 when a network event is encountered, and to 0 otherwise.
Meanwhile, the INT source node inserts its own metadata segment, also the first metadata segment, in the metadata stack according to the telemetry command requirements, and updates the relevant fields in the INT header, including subtracting 1 from the value in the "RemainingHop Cnt" field. The metadata segment transmitted by the INT source node may refer to the metadata segment transmitted from R1 to R2 shown in fig. 8 in embodiment 1.
The INT forwarding node processes step S522, including:
s5221, when the U field is set to be in a standard mode (the value in the U field is 0, and when no network event is encountered or notification of the network event is received, the forwarding node is in a standard mode of SF-INT), and after the INT forwarding node receives a data packet from a previous node, the INT forwarding node analyzes a valid INT header carried in the arrived data packet; the arrived INT effective head is compared with the INT effective head in the register, and based on SF-INT transmitting rules, the INT effective head to be transmitted and the INT effective head to be stored in the register are obtained; the INT effective head to be sent is packaged and then sent to the next node; storing the data packet to be stored into a register;
The INT forwarding node processes the data packet according to the SF-INT forwarding rule after receiving the SF-INT header from the previous node (i.e., the value in the C field is 1).
Referring to fig. 6, the SF-INT forwarding node uses registers to store historical network state information, and its packet processing method involves transitions in the INT state. The node analyzes the information of the INT header carried in the received data packet, compares the information with the information in the INT effective header in the register, and finally decides what INT header should be carried in the transmitted data packet and what content of the INT effective header to be newly stored in the register according to an SF-INT transmission rule table (such as table 1) of the INT transmission node. The metadata segment stored in the local register is either an H metadata segment or an L metadata segment.
The notation M (N) is used in the rule table of Table 1, where N ε { Arrival (abbreviated A), storage (abbreviated S) }, INT state set M ε { X, H, L, E }. Specifically, a represents an INT valid header carried in an arriving packet; s represents the INT active header that each node stores in the register. For example, X (A) represents that the "status" field in the arriving INT data header is X; in particular, E () represents the INT active header that is not stored in the node. In addition, a C metadata segment (C stands for Current) is used to represent Current network state information of the node.
Taking forwarding rules 1, 5 and 6 as examples, it is explained how the rules in table 1 are applied on forwarding nodes.
Rule 1: the arrival of X (a) in rule 1 means that the arriving packet contains an X metadata segment; stored in the node at the time of arrival is an H metadata segment. When the situation is met, the node sends out the H metadata segment in the storage, and the state is kept as H; the arriving X metadata segment is stored with a state of L, i.e., the arriving X metadata segment is converted into an L metadata segment for storage. It can be seen here that the H metadata segment has a higher priority than the X metadata segment. Examples: assume that, at a forwarding node, a received packet carriesAt this time the register stores/>Rule 1 is applied and therefore the packet processing results in: the stored metadata segment in the register is/>The sent data packet carries metadata segment/>(Reference example 1)
Table 1 INT SF-INT forwarding rules table for forwarding nodes
Table 1 INT SF-INT forwarding rules table for forwarding nodes
* Indicating that E () is encountered on the INT forwarding node, meaning that the path of the data packet may have changed.
And then look at rule 5. Arriving in rule 5 is H (a), meaning that the arriving packet carries an H metadata segment; stored in the node at the time of arrival is the L metadata segment. The received metadata segment and the stored metadata segment belong to the same data packet, meaning that the exclusive-or process of the data packet has been blocked. At this point the stored metadata segment is sent out. Examples: suppose that the metadata segment stored on the R3 node isThe received data packet carries metadata segmentThe received and stored metadata segment belongs to the data packet with packetID being 2, so rule 5 is applicable, and after the data packet is processed according to rule 5, the metadata segment stored in the register is/>The metadata segment carried in the sent data packet is/>(Reference example 1)
Rule 6 differs from rule 5 in that rule 6 applies to scenarios where the received metadata segment and the stored metadata segment do not belong to the same data packet. Examples: suppose that a metadata segment is stored on an R3 nodeThe received data packet carries metadata segment/>The meta-data segment stored thereafter is/>The metadata segment carried in the sent data packet is/>
Table 1 designs ten forwarding rules, including all possible scenarios that an INT forwarding node may encounter. These rules are clearly defined and facilitate the writing of relevant code on the switch. The basic idea is that if a certain data packet fails to obtain a new network state at a certain node, the state is set to a low priority L so that the NMS can obtain metadata for the whole course of other data packets as soon as possible. The priority order followed is therefore: h is higher than X, which is higher than L. The NMS needs the H metadata segment which arrives later to restore the bare metadata segment of each node, so the H metadata segment needs to pass preferentially; l means that the packet to which the metadata belongs fails to obtain the network state of a node at that node, so L yields H and X.
Note that in rule 2 and rule 3, the node adds its own network state information for the metadata segment to the metadata stack, at which point the value in the "RemainingHop Cnt" field needs to be subtracted by 1. In other rules, only historical network state information is passed, and the current network state information of the user is not added, so the value in the 'RemainingHop Cnt' field is not modified.
S5222: when the value in the U field is 1, or a network event is detected or an announcement of the relevant network event is received, the SF-INT is switched to an emergency mode, and enough network state information is transmitted as soon as possible. If there is an INT valid header in the node register that triggers the emergency mode, the INT valid header stored in the register is encapsulated into an INT report that is sent to the NMS in separate data packets (i.e., only a separate "postcard" message is generated). Thereafter, the node does not store the historical network state information by using the register any more, but directly sends the network state information out, that is, directly adds the metadata segment of itself to the metadata stack carried by the arriving data packet, and updates the relevant field in the INT header.
The INT end node processes step S523, including: after receiving the data packet of the previous node, the INT terminal node analyzes the INT header in the data packet, directly adds the metadata segment of the INT terminal node to the INT metadata stack, generates an INT report, and encapsulates the INT report in an independent message to be sent to the NMS.
Specifically, the INT end node, upon receiving a data packet with a telemetry header, separates the INT header from the data packet, then directly adds its own metadata segment to the metadata stack, and updates the relevant fields in the INT header (e.g., subtracts 1 from the value in the "RemainingHop Cnt" field), then generates an INT report (INT report), and encapsulates the INT report in a separate message to the NMS. The INT end node also updates the relevant fields of the other headers in the data packet and then sends the data packet without the INT header to the destination. To facilitate NMS processing, SF-INT requires the end node to add its own metadata segment in the metadata stack. Current INTs allow the end node to separate its own metadata segment from the received metadata stack, but still report on the same INT.
The NMS processes step S53, including: after receiving INT reports of SF-INT, NMS processes the INT reports of same packetID received before and after, and obtains bare metadata segment of each node.
Specifically, when the NMS receives the INT report of the SF-INT, it needs to calculate in combination with multiple packetID identical INT reports received before and after to obtain the original metadata segment of each node, and the process flow on the SF-INT is shown in fig. 7.
The NMS first confirms how many metadata segments are in the metadata stack of the INT report. The length of the INT instruction header is fixed to 12 bytes, and the number of metadata segments contained in one metadata stack is denoted as N2:
N2=(L2-12)/L0
Next, the NMS needs to confirm information of how many nodes are contained in the metadata stack. When the value in the "RemainingHop Cnt" field is R bytes, the network state information of N1 nodes in the metadata stack is calculated, i.e., n1=max-R, where MAX is the maximum number of nodes allowed by the telemetry system. In SF-INT, the forwarding node will subtract 1 from the value in the "RemainingHop Cnt" field only if its own network state information is added to the metadata stack.
Finally, the NMS calculates the network status of how many nodes are contained in the bottom metadata segment in the SF-metadata stack:
N3=N1-(N2-1)=N1+1-N2
If n3=1, then the bottom metadata segment is not an exclusive or metadata segment. If N3>1, then the bottom metadata segment is an exclusive OR metadata segment.
The "exclusive-or restore with metadata segment from other data packet and packetID" in fig. 7 refers to the following method: the NMS, upon receipt of the report, will analyze based on the "status" field in the INT header. When the status bit is X, all metadata segments belong to the same data packet. However, when the status bit is H or L, the bottom metadata segment belongs to packetID in the INT instruction header, while the other non-bottom metadata segments belong to the current packet (i.e., packetID =255).
Assuming that the NMS receives the xor metadata segment of a certain data packet, which includes 4 nodes, and further receives the xor metadata segment in the same data packet (differentiated according to packetID) including 3 nodes, the NMS performs exclusive-or on the 2 xor metadata segments again, so that the metadata segment of the 4 th node can be obtained. Thus by comparing the previous and subsequent INT reports, the NMS can eventually gradually recover the bare metadata segments of the nodes on the path.
Example 1: in fig. 8 is shown an SF-INT telemetry procedure with 6 nodes, which is a procedure of SF-INT in standard mode during which no network event is detected, nor is it switched into emergency mode. R1 is the first node in the telemetry path and is therefore the INT source node. R2, R3, R4, R5 are INT forwarding nodes; r6 is the INT end node. The leftmost digit in the figure represents the sequential ID of the data packet. The INT source node will insert the ID in the SF-INT instruction header.
Take the data packet with sequence number 3 as an example. The packetID field of the SF-INT header carried in the data packet sent by R1 is 3, and the sequence number of the data packet is consistent; but when the packet leaves R2, the carried metadata segment is represented asThe value of packetID field in SF-INT header carried by the packet is 2, which means that the information of metadata segment carried by the packet is the network status information when the packet with sequence number 2 passes through the network.
The gray portion associated with the R3 forwarding node is then observed. To the left of R3 isRepresenting metadata segments carried by the arriving packets; above R3 is/>Representing the metadata segment in the INT valid header stored in the R3 node when the packet arrives; therefore, R3 will process the telemetry header according to the forwarding rule in table 1, and the node determines that rule 2 is applicable. The metadata segment carried in the transmitted data packet is/>(Indicated on the right side of R3), stored in the R3 register after telemetry processing is/>(Shown below the node).
The INT end node R6 is then observed. First row in the figure, R6 receivesThereafter, the metadata stack is added with the metadata segment/>PacketID is 255 because as long as it is a non-bottom metadata segment, its packetID is considered 255, which represents that the metadata segment belongs to the data packet carrying the INT header. Because the SF-INT header is in the X state, indicating that packetID in the SF-INT instruction header is packetID to which the INT source node is assigned to the present packet, the NMS will also assign/>, in this scenarioViewed as/>Line 2 of the figure, R6 received/>Self metadata segment/>, will be added in the metadata stackBecause the SF-INT header is in the H state, the NMS will attribute the bottom metadata segment and the non-bottom metadata segment to different data packets.
The NMS will receive the metadata segments in a plurality of consecutive INT reports The NMS can thus recover packetID full range telemetry of packets of data through R1, R2, R3, R4, R5 and R6 of 0. In fact, the NMS is receiving/>It is not known from which 5 nodes the metadata segment at the bottom of the stack is xored, but the network state information of 5 nodes is obtained by calculating N3.
The NMS receives a plurality ofBecause packetID is 255, these metadata segments will be considered to be metadata segments that are generated when different packets pass through the node.
As shown in fig. 8, there is only one metadata segment in the metadata stack in the INT header on the links between network nodes, and the overhead of the INT header is fixed. For these 8 packets, the NMS can obtain the global telemetry information of packet 0, and at the same time can obtain the partial telemetry information of packet 4, and in addition, can obtain the telemetry information of other packets at the end node.
Defining a packet convergence period refers to how many packets the NMS can obtain the global telemetry information of a packet per pass without packet loss or packet misordering. The packet convergence period in SF-INT is always 2 a, which is related to the number of nodes F on the telemetry path and satisfies 2 a-1≤F-2≤2a, a being a positive integer.
If there are 5 nodes on a telemetry path, then its period is 4;
If there are 6 nodes on a telemetry path, then its period is 8;
if there are 9 nodes on a telemetry path, then its period is 8.
Example 2: a practical SF-INT procedure (emergency mode): the node detects the network abnormal event or receives the notice and shifts to an emergency state.
When the packet with the sequence ID of 6 arrives at R3, R3 detects a network event or receives a notification of a network event, and R3 will switch to the emergency mode. As shown in FIG. 9, R3 will storeThe history status message is sent to the NMS as a separate report and is not stored by the register until the emergency mode is completed. It can thus be seen that the lower parts of R3, R4, R5 in the figure are blank, without the notation of the metadata segment, meaning without any new storage. R3 and thereafter nodes will add the metadata segment representing their current network state directly to the metadata stack.
When a packet with a sequence ID of 7 arrives at R3, R3 detects a network event or receives a notification of a network event, and R3 will switch to emergency mode. As shown in FIG. 9, R3 will storeThe history status message is sent to the NMS as a separate report and is not stored by the register until the emergency mode is completed. R3 will add a piece of metadata representing its current network state directly to the metadata stack.
It should be noted that, whether the forwarding node triggering the emergency mode receives the metadata segment in the X state or the metadata segment in the H/L state, the NMS can accurately distinguish and recover the bare metadata segment obtained when the data packet passes through the network according to fig. 7.
This embodiment illustrates that SF-INT can be seamlessly switched to the current INT technology in real-time in emergency mode. In addition, if a network event is detected at the INT source node's location, the overall telemetry process will be consistent with current INT procedures. By instant seamless switching, it is meant that any node detects a network event or receives notification of the occurrence of a network event, can switch directly to emergency mode, and does not need to wait until the next data packet of interest reaches the INT source node to begin switching.
It follows that stateful SF-INT is compatible with stateless active INT, which can be regarded as a special case of stateful SF-INT.
Referring to fig. 10, in accordance with another aspect of the present invention, a stateful in-band network telemetry system includes:
a telemetry control module 101 for sending configuration data messages to the INT source node; the configuration data includes data packets to be telemetered, telemetry instructions, maximum number of telemetry nodes, and whether SF-INT is enabled;
Telemetry packet processing module 102, including source node processing sub-module 1021, forwarding node processing sub-module 1022, and end node processing sub-module 1023;
The source node processing sub-module 1021 is configured to receive a data packet that needs to perform network telemetry, parse the data packet, insert an INT header, repackage the data packet, and send the data packet to a next node; the INT header includes an INT valid header including an INT instruction header and an INT metadata stack; the INT instruction head comprises a C field, a U field, an ST field and packetID fields; the C field is set to adopt SF-INT; the U field is set to an emergency mode or a standard mode; the ST field is set to X, and is used for indicating that the INT header carries a metadata segment which needs exclusive OR operation to the subsequent INT forwarding node; the packetID field is set to a packet ID; the INT metadata stack is used for inserting metadata segments of the INT source nodes;
The forwarding node processing sub-module 1022 is configured to parse out a valid INT header carried in an arriving data packet after the INT forwarding node receives the data packet from the previous node when the U field is set to a standard mode; the arrived INT effective head is compared with the INT effective head in the register, and based on SF-INT transmitting rules, the INT effective head to be transmitted and the INT effective head to be stored in the register are obtained; inserting an INT effective header to be transmitted into an INT header, and transmitting to a next node after repackaging; the method is also used for switching the instant seamless to the current INT protocol when the U field is set to be in an emergency mode;
The end node processing sub-module 1023 is configured to parse an INT header in a data packet after receiving the data packet of the previous node, directly add a metadata segment of itself to an INT metadata stack, generate an INT report, and encapsulate the INT report in an independent message and send the independent message to the NMS;
the NMS collecting and calculating module 103 is configured to, after receiving the INT report of the SF-INT, process the INT reports of the same packetID received before and after the INT report of the SF-INT, and obtain a bare metadata segment of each node.
Specific implementations of the modules of a stateful in-band network telemetry system are referred to a stateful in-band network telemetry method, and the description thereof will not be repeated.
It will be understood that modifications and variations will be apparent to those skilled in the art from the foregoing description, and it is intended that all such modifications and variations be included within the scope of the following claims.

Claims (7)

1. A method of stateful in-band network telemetry, comprising:
INT source node processing step: the INT source node receives a data packet which needs to execute network telemetry, inserts an INT header after analysis, and sends the data packet to the next node after repackaging; the INT header includes an INT valid header; the INT effective head comprises an INT instruction head and a metadata stack; the INT instruction head comprises a C field, a U field, an ST field and packetID fields; the C field is set to be whether SF-INT is adopted; the U field is set to an emergency mode or a standard mode; the ST field is set to X, and is used for indicating that the INT header carries a metadata segment which needs exclusive OR operation to the subsequent INT forwarding node; the packetID field is set to a packet ID; the metadata stack is used for inserting metadata segments of the INT source node;
INT transmitting node processing step: when the U field is set to be in a standard mode, after the INT forwarding node receives a data packet from a previous node, an effective INT head carried in the arrived data packet is analyzed; the arrived INT effective head is compared with the INT effective head in the register, and based on an SF-INT forwarding rule, the INT effective head to be transmitted and the INT effective head to be stored in the register are obtained; the INT effective head to be sent is packaged and then sent to the next node; the data packet to be stored is stored in a register;
INT end node processing step: after receiving the data packet of the previous node, the INT terminal node analyzes the INT header in the data packet, directly adds the metadata segment of the INT terminal node into the metadata stack to generate an INT report, and encapsulates the INT report in an independent message to be sent to the NMS;
NMS processing steps: after receiving INT reports of SF-INT, NMS processes the INT reports of same packetID received before and after combining to obtain bare metadata segment of each node;
specifically, the value of the ST field can also be set to H, L and E; h represents a high priority; l represents low priority; e represents that the metadata stack does not contain metadata segments;
In the step of processing the INT forwarding node, the arriving INT effective header is compared with the INT effective header in the register, and based on an SF-INT forwarding rule, the INT effective header to be sent and the INT effective header to be stored in the register are obtained, wherein the specific rule comprises the following steps:
if the ST field of the arrived INT effective header is X and the ST field of the INT effective header in the register is H, the INT effective header to be transmitted is set as the INT effective header in the register, the metadata segment of the INT effective header to be stored in the register is set as the metadata segment of the arrived INT effective header, and the ST field of the INT effective header to be stored in the register is set as L;
If the ST field of the arrived INT effective header is X and the ST field of the INT effective header in the register is L, setting the metadata segment of the INT effective header to be transmitted as a data segment generated after the metadata segment of the arrived INT effective header and the metadata segment of the current node are subjected to exclusive OR, and setting the corresponding ST field as X; setting a metadata segment of an INT effective header to be stored in a register as a metadata segment of an arriving INT effective header, and setting a corresponding ST field as H;
If the ST field of the arrived INT effective header is X, the register does not store the INT effective header, the metadata segment of the INT effective header to be transmitted is set as the data segment generated after the metadata segment of the arrived INT effective header and the metadata segment of the current node are subjected to exclusive OR, and the corresponding ST field is set as X; setting a metadata segment of an INT effective header to be stored in a register as a metadata segment of an arriving INT effective header, and setting a corresponding ST field as H;
If the ST field of the arrived INT effective header is H and the ST field of the INT effective header in the register is H, the INT effective header to be transmitted is set as the INT effective header in the register; setting an INT valid header to be stored in a register as an arriving INT valid header;
If the ST field of the arrived INT effective header is H, the ST field of the INT effective header in the register is L, and the arrived INT effective header and the INT effective header in the register comprise the same data packet ID, the INT effective header to be sent is set as the INT effective header in the register; setting a metadata segment of an INT effective header to be stored in a register as a metadata segment of an arriving INT effective header, and setting an ST field of the INT effective header to be stored in the register as L;
If the ST field of the arrived INT effective header is H, the ST field of the INT effective header in the register is L, and the arrived INT effective header and the INT effective header in the register comprise different data packet IDs, the INT effective header to be sent is set as the arrived INT effective header; while the INT valid header in the register is unchanged;
if the ST field of the arrived INT effective header is H and the INT effective header is not stored in the register, the INT effective header to be sent is set as the arrived INT effective header, and the register is still empty;
If the ST field of the arrived INT effective header is L and the ST field of the INT effective header in the register is H, the INT effective header to be transmitted is set as the INT effective header in the register; setting an INT valid header to be stored in a register as an arriving INT valid header;
if the ST field of the arrived INT effective header is L and the ST field of the INT effective header in the register is L, the INT effective header to be transmitted is set as the INT effective header in the register; setting an INT valid header to be stored in a register as an arriving INT valid header;
if the ST field of the arrived INT effective header is L and the INT effective header is not stored in the register, the INT effective header to be sent is set as the arrived INT effective header, and the register is still empty;
the NMS processing step specifically comprises the following steps:
if the current data packet ID is equal to 255, judging whether the number of nodes contained in the bottom metadata segment of the metadata stack is greater than 1, if so, discarding the bottom metadata segment, reading the non-bottom bare metadata segment, finishing all the bare metadata segments, and ending the processing of the current data packet ID; otherwise, reading the bottom bare metadata segment and the non-bottom bare metadata segment, sorting all the bare metadata segments, and ending the processing of the current data packet ID;
If the ID of the current data packet is not equal to 255 and the ST field in the data packet is equal to X, judging whether the number of nodes contained in the bottom metadata segment of the metadata stack is more than 1, if so, reading the bottom exclusive-OR metadata segment, carrying out exclusive-OR reduction on the bottom exclusive-OR metadata segment and metadata segments with packetID from other data packets, reading non-bottom bare metadata segments, and sorting all bare metadata segments with packetID; otherwise, reading the bottom bare metadata segment and the non-bottom bare metadata segment, and finishing all bare metadata segments which are same as packetID, and ending the processing of the current data packet ID;
If the ID of the current data packet is not equal to 255 and the ST field in the data packet is not equal to X, judging whether the number of nodes contained in the bottom metadata segment of the metadata stack is more than 1, if so, reading the bottom exclusive-OR metadata segment, carrying out exclusive-OR reduction on the bottom exclusive-OR metadata segment and metadata segments with packetID from other data packets, finishing all bare metadata segments with packetID, and ending the processing of the ID of the current data packet; otherwise, reading the bottom bare metadata segment, sorting all bare metadata segments which are identical to packetID, and ending the processing of the current data packet ID;
If the current packet ID is not equal to 255 and the ST field in the packet is not equal to X, the process further includes: and reading the non-bottom bare metadata segments, finishing all the bare metadata segments, and ending the processing of the current data packet ID.
2. The stateful in-band network telemetry method of claim 1, wherein the INT forwarding node processing step further comprises:
When the U field is set to an emergency mode, or a node detects a network event or receives a related network event notification, the node directly switches to the emergency mode to realize instant seamless switching; judging whether an INT effective header is stored in a register, if so, packaging the INT effective header stored in the register into an INT report, and sending the INT report to the NMS in an independent data packet; thereafter, the node no longer uses the register to store historical network state information, but adds its own metadata segment directly in the metadata stack carried by the arriving packet.
3. The method of claim 1, further comprising a telemetry control step prior to the INT source node processing step, comprising:
Based on the configuration data, the terminal APP or the SDN northbound APP sends a message to the INT source node; the message includes the data packet that needs telemetry, telemetry instructions, the maximum number of telemetry nodes, and whether SF-INT is enabled.
4. The stateful in-band network telemetry method of claim 1, further comprising:
When an INT source node, an INT forwarding node, or an INT end node inserts or exclusive-ors its own metadata segment in the metadata stack, the value in the "RemainingHop Cnt" field in the INT instruction header is decremented by 1.
5. The method of claim 1, wherein the method of obtaining the number of nodes included in the bottom metadata segment of the metadata stack is as follows:
N3=N1-(N2-1)=N1+1-N2
Wherein N1 represents network state information of N1 nodes contained in the metadata stack; n1=max-R, MAX being the maximum number of nodes that telemetry allows, R representing the value in the "RemainingHop Cnt" field of the INT instruction header; n2 represents the number of metadata segments contained in the metadata stack, n2= (L2-12)/L0, where L0 represents the length of the metadata segment and L2 is the length of the INT effective header.
6. The method of stateful in-band network telemetry of claim 1, wherein the NMS processing step further comprises:
And if the U field is in an emergency mode, executing related processing of the emergency message.
7. A stateful in-band network telemetry system, comprising:
The telemetry control module is used for sending the configuration data to the INT source node; the configuration data includes data packets to be telemetered, telemetry instructions, maximum number of telemetry nodes, and whether SF-INT is enabled;
the telemetry data packet processing module comprises a source node processing sub-module, a forwarding node processing sub-module and an end node processing sub-module;
The source node processing submodule is used for receiving a data packet which needs to execute network telemetry, analyzing the data packet, inserting an INT header, and sending the data packet to the next node after repackaging; the INT header includes an INT valid header including an INT instruction header and a metadata stack; the INT instruction head comprises a C field, a U field, an ST field and packetID fields; the C field is set to be whether SF-INT is adopted; the U field is set to an emergency mode or a standard mode; the ST field is set to X, and is used for indicating that the INT header carries a metadata segment which needs exclusive OR operation to the subsequent INT forwarding node; the packetID field is set to a packet ID; the metadata stack is used for inserting metadata segments of the INT source node;
The forwarding node processing submodule is used for analyzing an effective INT head carried in an arriving data packet after the INT forwarding node receives the data packet from the previous node when the U field is set to be in a standard mode; the arrived INT effective head is compared with the INT effective head in the register, and based on an SF-INT forwarding rule, the INT effective head to be transmitted and the INT effective head to be stored in the register are obtained; the INT effective head to be sent is packaged and then sent to the next node; the data packet to be stored is stored in a register;
the end node processing sub-module is used for analyzing an INT header in a data packet after receiving the data packet of the previous node, directly adding a metadata segment of the end node processing sub-module into a metadata stack, generating an INT report, and packaging the INT report in an independent message and sending the independent message to the NMS;
The NMS collecting and calculating module is used for processing the INT reports received before and after receiving the INT reports of the SF-INT and combining a plurality of the same packetID INT reports received before and after the INT reports to obtain the bare metadata segments of each node;
specifically, the value of the ST field can also be set to H, L and E; h represents a high priority; l represents low priority; e represents that the metadata stack does not contain metadata segments;
The forwarding node processing submodule compares the arrived INT effective header with the INT effective header in the register, acquires the INT effective header to be sent and the INT effective header to be stored in the register based on an SF-INT forwarding rule, and the specific rule comprises:
if the ST field of the arrived INT effective header is X and the ST field of the INT effective header in the register is H, the INT effective header to be transmitted is set as the INT effective header in the register, the metadata segment of the INT effective header to be stored in the register is set as the metadata segment of the arrived INT effective header, and the ST field of the INT effective header to be stored in the register is set as L;
If the ST field of the arrived INT effective header is X and the ST field of the INT effective header in the register is L, setting the metadata segment of the INT effective header to be transmitted as a data segment generated after the metadata segment of the arrived INT effective header and the metadata segment of the current node are subjected to exclusive OR, and setting the corresponding ST field as X; setting a metadata segment of an INT effective header to be stored in a register as a metadata segment of an arriving INT effective header, and setting a corresponding ST field as H;
If the ST field of the arrived INT effective header is X, the register does not store the INT effective header, the metadata segment of the INT effective header to be transmitted is set as the data segment generated after the metadata segment of the arrived INT effective header and the metadata segment of the current node are subjected to exclusive OR, and the corresponding ST field is set as X; setting a metadata segment of an INT effective header to be stored in a register as a metadata segment of an arriving INT effective header, and setting a corresponding ST field as H;
If the ST field of the arrived INT effective header is H and the ST field of the INT effective header in the register is H, the INT effective header to be transmitted is set as the INT effective header in the register; setting an INT valid header to be stored in a register as an arriving INT valid header;
If the ST field of the arrived INT effective header is H, the ST field of the INT effective header in the register is L, and the arrived INT effective header and the INT effective header in the register comprise the same data packet ID, the INT effective header to be sent is set as the INT effective header in the register; setting a metadata segment of an INT effective header to be stored in a register as a metadata segment of an arriving INT effective header, and setting an ST field of the INT effective header to be stored in the register as L;
If the ST field of the arrived INT effective header is H, the ST field of the INT effective header in the register is L, and the arrived INT effective header and the INT effective header in the register comprise different data packet IDs, the INT effective header to be sent is set as the arrived INT effective header; while the INT valid header in the register is unchanged;
if the ST field of the arrived INT effective header is H and the INT effective header is not stored in the register, the INT effective header to be sent is set as the arrived INT effective header, and the register is still empty;
If the ST field of the arrived INT effective header is L and the ST field of the INT effective header in the register is H, the INT effective header to be transmitted is set as the INT effective header in the register; setting an INT valid header to be stored in a register as an arriving INT valid header;
if the ST field of the arrived INT effective header is L and the ST field of the INT effective header in the register is L, the INT effective header to be transmitted is set as the INT effective header in the register; setting an INT valid header to be stored in a register as an arriving INT valid header;
if the ST field of the arrived INT effective header is L and the INT effective header is not stored in the register, the INT effective header to be sent is set as the arrived INT effective header, and the register is still empty;
the NMS collecting and calculating module is specifically used for:
if the current data packet ID is equal to 255, judging whether the number of nodes contained in the bottom metadata segment of the metadata stack is greater than 1, if so, discarding the bottom metadata segment, reading the non-bottom bare metadata segment, finishing all the bare metadata segments, and ending the processing of the current data packet ID; otherwise, reading the bottom bare metadata segment and the non-bottom bare metadata segment, sorting all the bare metadata segments, and ending the processing of the current data packet ID;
If the ID of the current data packet is not equal to 255 and the ST field in the data packet is equal to X, judging whether the number of nodes contained in the bottom metadata segment of the metadata stack is more than 1, if so, reading the bottom exclusive-OR metadata segment, carrying out exclusive-OR reduction on the bottom exclusive-OR metadata segment and metadata segments with packetID from other data packets, reading non-bottom bare metadata segments, and sorting all bare metadata segments with packetID; otherwise, reading the bottom bare metadata segment and the non-bottom bare metadata segment, and finishing all bare metadata segments which are same as packetID, and ending the processing of the current data packet ID;
If the ID of the current data packet is not equal to 255 and the ST field in the data packet is not equal to X, judging whether the number of nodes contained in the bottom metadata segment of the metadata stack is more than 1, if so, reading the bottom exclusive-OR metadata segment, carrying out exclusive-OR reduction on the bottom exclusive-OR metadata segment and metadata segments with packetID from other data packets, finishing all bare metadata segments with packetID, and ending the processing of the ID of the current data packet; otherwise, reading the bottom bare metadata segment, sorting all bare metadata segments which are identical to packetID, and ending the processing of the current data packet ID;
If the current packet ID is not equal to 255 and the ST field in the packet is not equal to X, the process further includes: and reading the non-bottom bare metadata segments, finishing all the bare metadata segments, and ending the processing of the current data packet ID.
CN202210277734.9A 2022-03-21 2022-03-21 Stateful in-band network telemetry method and system Active CN114666681B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210277734.9A CN114666681B (en) 2022-03-21 2022-03-21 Stateful in-band network telemetry method and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210277734.9A CN114666681B (en) 2022-03-21 2022-03-21 Stateful in-band network telemetry method and system

Publications (2)

Publication Number Publication Date
CN114666681A CN114666681A (en) 2022-06-24
CN114666681B true CN114666681B (en) 2024-05-10

Family

ID=82032116

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210277734.9A Active CN114666681B (en) 2022-03-21 2022-03-21 Stateful in-band network telemetry method and system

Country Status (1)

Country Link
CN (1) CN114666681B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115051959B (en) * 2022-08-16 2022-10-21 广东省新一代通信与网络创新研究院 Remote measuring method and system based on user content
CN115442282B (en) * 2022-08-31 2023-08-29 深圳市风云实业有限公司 Data acquisition system and method

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1574789A (en) * 1999-06-30 2005-02-02 倾向探测公司 Method and apparatus for monitoring traffic in a network
CN112422498A (en) * 2020-09-04 2021-02-26 网络通信与安全紫金山实验室 In-band network remote measuring method, system and computer readable storage medium
CN113422707A (en) * 2021-06-18 2021-09-21 新华三技术有限公司 In-band network remote measuring method and equipment

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11343261B2 (en) * 2019-04-05 2022-05-24 Cisco Technology, Inc. Technologies for proving packet transit through uncompromised nodes
US11563771B2 (en) * 2019-11-25 2023-01-24 Cisco Technology, Inc. Network telemetry collection with packet metadata filtering

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1574789A (en) * 1999-06-30 2005-02-02 倾向探测公司 Method and apparatus for monitoring traffic in a network
CN112422498A (en) * 2020-09-04 2021-02-26 网络通信与安全紫金山实验室 In-band network remote measuring method, system and computer readable storage medium
CN113422707A (en) * 2021-06-18 2021-09-21 新华三技术有限公司 In-band network remote measuring method and equipment

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
基于P4的主动网络遥测机制;刘争争;毕军;周禹;王旸旸;林耘森箫;;通信学报;20180930(第S1期);全文 *

Also Published As

Publication number Publication date
CN114666681A (en) 2022-06-24

Similar Documents

Publication Publication Date Title
CN114666681B (en) Stateful in-band network telemetry method and system
CN105684382A (en) Packet control method, switch and controller
KR101364369B1 (en) Node, monitoring and administration method used thereupon, and transfer system, input circuit, and output circuit using same
EP3605881B1 (en) Method and device for transmitting and receiving network management information, transmitting apparatus and receiving apparatus
CN110380970A (en) A kind of self-adapting data message forwarding method and device suitable for heterogeneous network
US9270367B2 (en) Method and system for automatically discovering ODUflex bandwith lossless adjustment capability
CN103369593B (en) A kind of method compressing reconciliation compressed ethernet message and network element device
KR20090053791A (en) A method for transmitting and analyzing data in the wireless communication network and the apparatus thereof
CN111464409A (en) Data exchange device and network with CAN bus incorporated into time-sensitive network
CN114050994B (en) Network telemetry method based on SRv6
CN102404152B (en) Method and equipment for identifying response messages
CN115118663A (en) Method for acquiring network congestion information by combining in-band network telemetry
CN113347096B (en) Transmission processing method of third party payment data
CN105763375A (en) Data packet transmission method, receiving method and microwave station
CN101771617B (en) Method and system for following point-to-point bandwidth, remote terminal equipment and home terminal equipment
CN114175595A (en) Apparatus and method for deriving telemetry data
TWI376917B (en) Frame merging apparatus and method thereof
JP2015126303A (en) Radio transmitter and radio communication method
CN115277504A (en) Network traffic monitoring method, device and system
CN112039790A (en) Method and device for realizing INT information editing in stacking system
CN110891073B (en) Multi-protocol stack communication method for mobile communication core network
WO2022078225A1 (en) Communication method, apparatus, and system
CN103200611B (en) A kind of data fusion method and device
WO2014174801A1 (en) Wireless communication device, wireless communication system, and wireless communication method
EP1873995A2 (en) Data transmission device, data reception device and data communication method

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant