CN118250229A - Method and device for reporting service flow information, storage medium and electronic device - Google Patents

Method and device for reporting service flow information, storage medium and electronic device Download PDF

Info

Publication number
CN118250229A
CN118250229A CN202410328922.9A CN202410328922A CN118250229A CN 118250229 A CN118250229 A CN 118250229A CN 202410328922 A CN202410328922 A CN 202410328922A CN 118250229 A CN118250229 A CN 118250229A
Authority
CN
China
Prior art keywords
target
information
message
packet loss
service flow
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202410328922.9A
Other languages
Chinese (zh)
Inventor
胡绅
蒋英
张博超
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Suzhou Centec Communications Co Ltd
Original Assignee
Suzhou Centec Communications Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Suzhou Centec Communications Co Ltd filed Critical Suzhou Centec Communications Co Ltd
Priority to CN202410328922.9A priority Critical patent/CN118250229A/en
Publication of CN118250229A publication Critical patent/CN118250229A/en
Pending legal-status Critical Current

Links

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The application discloses a method and a device for reporting service flow information, a storage medium and an electronic device, wherein the method comprises the following steps: acquiring a target message of a target data stream in the transmission process of the network switching equipment; updating the initial packet loss information of the target data stream by using the target message to obtain target packet loss information; and under the condition that the target packet loss information is used for indicating that the data transmission quality of the target service flow is lower than the target transmission quality, sending a target notification message to a target processor according to the target packet loss information. By adopting the technical scheme, the problems that the processor cannot effectively realize the flow management of the service flow and the like in the related technology are solved, and the technical effect of improving the flow management efficiency of the processor on the service flow is realized.

Description

Method and device for reporting service flow information, storage medium and electronic device
Technical Field
The present application relates to the field of communications, and in particular, to a method and apparatus for reporting service flow information, a storage medium, and an electronic device.
Background
In the existing network environment, a switching chip on a switch is responsible for transmitting data streams among transmission ports of the switch, when the bandwidth of an output port is smaller than that of the data streams, the data are temporarily stored in a queue cache, and when the queue cache is full, an unprecedented message is discarded, namely, a packet loss condition occurs. In order to detect the packet loss of the data stream, the CPU on the switch periodically detects the space occupation of the queue buffer. However, due to the set time granularity problem, the CPU cannot accurately detect the packet loss condition and determine the traffic flow in the packet loss state after finding the packet loss condition, which finally results in that the traffic management on the traffic flow cannot be effectively realized.
Aiming at the problems of low monitoring efficiency of a processor to a service flow transmission process and the like in the related art, no effective solution has been proposed yet.
Disclosure of Invention
The embodiment of the application provides a method and a device for reporting service flow information, a storage medium and an electronic device, which are used for at least solving the problems of low monitoring efficiency and the like of a processor in a service flow transmission process in the related technology.
According to an embodiment of the present application, there is provided a method for reporting service flow information, including:
Acquiring a target message which appears in the transmission process of a target data stream on network switching equipment, wherein the target message is a message which is discarded due to the fact that the target message cannot be buffered to a target buffer space, and the target buffer space is used for temporarily storing a message which is included in the data stream to be transmitted and exceeds a port transmission bandwidth part of a data stream output port of the network switching equipment under the condition that the bandwidth of the data stream to be transmitted is larger than the port transmission bandwidth of the data stream output port of the network switching equipment;
Updating initial packet loss information of the target data stream by using the target message to obtain target packet loss information, wherein the initial packet loss information records packet loss conditions of each service stream in a plurality of service streams included in the target data stream;
And under the condition that the target packet loss information is used for indicating that the data transmission quality of the target service flow is lower than the target transmission quality, sending a target notification message to a target processor according to the target packet loss information, wherein the target service flow is the service flow to which the target message included in the plurality of service flows belongs, and the target processor is used for responding to the target notification message to perform flow control on the service flow in a packet loss state in the transmission process of the target data flow.
Optionally, the updating the initial packet loss information of the network switching device by using the target packet to obtain target packet loss information includes:
acquiring target attribute information of the target message;
Screening a target information set corresponding to the target message from a plurality of initial information sets, wherein the target information set is used for storing attribute information of the discarded message in a target service flow, and the initial packet loss information comprises the plurality of initial information sets;
and storing the target attribute information into the target information set.
Optionally, before the storing the target attribute information in the target information set, the method further includes:
Detecting a reference service flow to which the stored message attribute information in the target information set belongs;
Reporting the target attribute information to the target processor under the condition that the reference service flow and the target service flow are inconsistent;
And receiving a candidate information set allocated by the target processor in response to the target attribute information, and storing the target attribute information into the candidate information set.
Optionally, the sending, according to the target packet loss information, a target notification message to a target processor includes:
Screening a target information set from a plurality of initial information sets included in the target packet loss information, wherein the target information set is used for storing message attribute information of discarded messages in a target service flow;
counting the message attribute information stored in the target information set to obtain target statistical information of the target service flow, wherein the target statistical information is used for representing the packet loss condition of the target service flow in the transmission process;
and generating the target notification message carrying the target statistical information and sending the target notification message to the target processor.
Optionally, after updating the initial packet loss information of the target data stream by using the target packet to obtain target packet loss information, the method further includes:
Screening a target information set from a plurality of initial information sets included in the target packet loss information, wherein the target information set is used for storing message attribute information of discarded messages in a target service flow;
And determining the data transmission quality of the target service flow according to the message attribute information stored in the target information set.
Optionally, determining the data transmission quality of the target service flow according to the message attribute information stored in the target information set includes:
determining the number of discarded message targets in the target service flow according to the message attribute information stored in the target information set;
Under the condition that the target number is larger than or equal to the preset message number, determining that the data transmission quality of the target service flow is lower than the target transmission quality;
And under the condition that the target number is smaller than the preset message number, determining that the data transmission quality of the target service flow is higher than the target transmission quality.
Optionally, after the determining that the data transmission quality of the target traffic flow is higher than the target transmission quality, the method further includes:
detecting a target time interval for executing statistical operation on message attribute information stored in the target information set;
Under the condition that the target time interval is larger than or equal to a set threshold value, counting the message attribute information stored in the target information set to obtain reference statistical information;
And generating a reference notification message carrying the reference statistical information and sending the reference notification message to the target processor, wherein the target processor is used for controlling the flow of the target service flow according to the reference notification message.
According to another embodiment of the present application, there is also provided a device for reporting service flow information, including:
The acquisition module is used for acquiring a target message which appears in the transmission process of a target data stream on the network switching equipment, wherein the target message is a message which is discarded due to the fact that the target message cannot be buffered in a target buffer space, and the target buffer space is used for temporarily storing a message which exceeds a port transmission bandwidth part and is included in the data stream to be transmitted under the condition that the bandwidth of the data stream to be transmitted is larger than the port transmission bandwidth of a data stream output port of the network switching equipment;
the updating module is used for updating the initial packet loss information of the target data stream by using the target message to obtain target packet loss information, wherein the initial packet loss information records the packet loss condition of each service stream in a plurality of service streams included in the target data stream;
The sending module is configured to send a target notification message to a target processor according to the target packet loss information when the target packet loss information is used to indicate that the data transmission quality of the target traffic flow is lower than the target transmission quality, where the target traffic flow is a traffic flow to which the target packet included in the plurality of traffic flows belongs, and the target processor is configured to respond to the target notification message to perform flow control on the traffic flow in a packet loss state in the transmission process of the target data flow.
According to still another aspect of the embodiments of the present application, there is further provided a computer readable storage medium having a computer program stored therein, where the computer program is configured to execute the above-mentioned method for reporting traffic flow information when running.
According to still another aspect of the embodiment of the present application, there is further provided an electronic device including a memory, a processor, and a computer program stored in the memory and capable of running on the processor, where the processor executes the method for reporting the traffic flow information by using the computer program.
In the embodiment of the application, a target message which appears in the transmission process of a target data stream on network switching equipment is acquired, wherein the target message is a message which is discarded after failing to be cached in a target cache space, and the target cache space is used for temporarily storing a message which exceeds a port transmission bandwidth part and is included in the data stream to be transmitted under the condition that the bandwidth of the data stream to be transmitted is larger than the port transmission bandwidth of a data stream output port of the network switching equipment; updating initial packet loss information of the target data stream by using the target message to obtain target packet loss information, wherein the initial packet loss information records packet loss conditions of each service stream in a plurality of service streams included in the target data stream; and then, under the condition that the target packet loss information is used for indicating that the data transmission quality of the target service flow is lower than the target transmission quality, sending a target notification message to a target processor according to the target packet loss information, wherein the target service flow is the service flow to which a target message included in a plurality of service flows belongs, and the target processor is used for responding to the target notification message to perform flow control on the service flow in a packet loss state in the transmission process of the target data flow. The initial packet loss information of each service flow packet loss condition in a plurality of service flows included in the target data flow is updated by using the acquired packet which is not buffered to the target buffer space and discarded, after the target packet information is obtained, a target notification message is sent to the target processor according to the updated target packet loss information when the data transmission quality of the target service flow is lower than the target transmission quality, so that the packet loss information of the service flow is fed back to the target processor according to the influence condition of the packet loss information on the data transmission quality of the target service flow, the problem of packet loss in the service flow transmission process can be accurately and timely known by the processor, and the processor is helped to more effectively realize the flow management of the service flow. By adopting the technical scheme, the problems of low monitoring efficiency of the processor on the service flow transmission process and the like in the related technology are solved, and the technical effect of improving the monitoring efficiency of the processor on the service flow transmission process is realized.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the application and together with the description, serve to explain the principles of the application.
In order to more clearly illustrate the embodiments of the application or the technical solutions of the prior art, the drawings which are used in the description of the embodiments or the prior art will be briefly described, and it will be obvious to a person skilled in the art that other drawings can be obtained from these drawings without inventive effort.
Fig. 1 is a schematic diagram of a hardware environment of a method for reporting service flow information according to an embodiment of the present application;
fig. 2 is a flowchart of a method for reporting traffic flow information according to an embodiment of the present application;
FIG. 3 is a schematic diagram of a traffic drop scenario according to an embodiment of the present application;
Fig. 4 is a schematic diagram of a method for reporting service flow information according to an embodiment of the present application;
FIG. 5 is a schematic diagram of a process for discarding a message according to an embodiment of the present application;
Fig. 6 is a schematic diagram of a method for reporting traffic flow information according to an embodiment of the present application;
Fig. 7 is a block diagram of a service flow information reporting apparatus according to an embodiment of the present application.
Detailed Description
In order that those skilled in the art will better understand the present application, a technical solution in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in which it is apparent that the described embodiments are only some embodiments of the present application, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the present application without making any inventive effort, shall fall within the scope of the present application.
It should be noted that the terms "first," "second," and the like in the description and the claims of the present application and the above figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate such that the embodiments of the application described herein may be implemented in sequences other than those illustrated or otherwise described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
The method embodiments provided by the embodiments of the present application may be performed in a computer terminal, a device terminal, or a similar computing apparatus. Taking a computer terminal as an example, fig. 1 is a schematic diagram of a hardware environment of a method for reporting service flow information according to an embodiment of the present application. As shown in fig. 1, the computer terminal may include one or more (only one is shown in fig. 1) processors 102 (the processor 102 may include, but is not limited to, a microprocessor MCU or a processing device such as a programmable logic device FPGA) and a memory 104 for storing data, and in one exemplary embodiment, may also include a transmission device 106 for communication functions and an input-output device 108. It will be appreciated by those skilled in the art that the configuration shown in fig. 1 is merely illustrative and is not intended to limit the configuration of the computer terminal described above. For example, a computer terminal may also include more or fewer components than shown in FIG. 1, or have a different configuration than the equivalent functions shown in FIG. 1 or more than the functions shown in FIG. 1.
The memory 104 may be used to store a computer program, for example, a software program of application software and a module, such as a computer program corresponding to a method for sending message push in an embodiment of the present invention, and the processor 102 executes the computer program stored in the memory 104, thereby performing various functional applications and data processing, that is, implementing the method described above. Memory 104 may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 104 may further include memory remotely located relative to the processor 102, which may be connected to the computer terminal via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The transmission device 106 is used to receive or transmit data via a network. Specific examples of the network described above may include a wireless network provided by a communication provider of a computer terminal. In one example, the transmission device 106 includes a network adapter (Network Interface Controller, simply referred to as a NIC) that can connect to other network devices through a base station to communicate with the internet. In one example, the transmission device 106 may be a Radio Frequency (RF) module, which is configured to communicate with the internet wirelessly.
In this embodiment, a method for reporting service flow information is provided and applied to the computer terminal, and fig. 2 is a flowchart of a method for reporting service flow information according to an embodiment of the present application, where the flowchart includes the following steps:
Step S202, obtaining a target message which appears in the transmission process of a target data stream on a network switching device, wherein the target message is a message discarded due to the fact that the target message cannot be buffered in a target buffer space, and the target buffer space is used for temporarily storing a message which is included in the data stream to be transmitted and exceeds a port transmission bandwidth part of a data stream output port of the network switching device under the condition that the bandwidth of the data stream to be transmitted is larger than the port transmission bandwidth of the data stream output port of the network switching device;
Step S204, updating initial packet loss information of the target data stream by using the target message to obtain target packet loss information, wherein the initial packet loss information records packet loss conditions of each service stream in a plurality of service streams included in the target data stream;
step S206, when the target packet loss information is used to indicate that the data transmission quality of the target traffic flow is lower than the target transmission quality, a target notification message is sent to a target processor according to the target packet loss information, where the target traffic flow is a traffic flow to which the target packet included in the plurality of traffic flows belongs, and the target processor is used to respond to the target notification message to perform flow control on the traffic flow in a packet loss state in the transmission process of the target data flow.
Through the steps, the initial packet loss information of each service flow packet loss condition in a plurality of service flows included in the target data flow is updated by using the acquired packet which is not buffered in the target buffer space and is discarded, after the target packet information is obtained, a target notification message is sent to the target processor according to the updated target packet loss information under the condition that the data transmission quality of the target service flow is lower than the target transmission quality, so that the packet loss information of the service flow is fed back to the target processor according to the influence condition of the packet loss information on the data transmission quality of the target service flow, the problem of packet loss in the service flow transmission process can be accurately and timely known by the processor, and the processor is helped to more effectively realize the flow management of the service flow. By adopting the technical scheme, the problems of low monitoring efficiency of the processor on the service flow transmission process and the like in the related technology are solved, and the technical effect of improving the monitoring efficiency of the processor on the service flow transmission process is realized.
In the technical solution provided in step S202, the target message may be, but is not limited to, acquired by: acquiring the capacity of a target cache space, detecting the relation among the data flow size of the input target cache space, the data flow size of the output target cache space and the capacity size of the target cache space, and starting to acquire the data flow ready for inputting the target cache space as a target message under the condition that the data flow size of the input target cache space is equal to the data flow size of the output target cache space and the capacity size of the target cache space, or detecting the residual available capacity size of the target cache space, and starting to acquire the data flow ready for inputting the target cache space as a target message under the condition that the residual available capacity size is lower than a preset threshold value.
Alternatively, in an embodiment of the present application, the data stream is a set of ordered, byte data sequences having a start point and an end point, and the target data stream may be, but is not limited to, composed of one or more service streams, each for transmitting corresponding service data.
Optionally, in the embodiment of the present application, when a full packet is stored in the target buffer space, if the received packet data to be transmitted is received, the received packet data may be selected to be the packet data to be discarded, or a packet already stored in the target buffer space may be discarded according to a target discard policy, so as to provide a storage space for a subsequently received packet to be transmitted, where the target discard policy may be discarding according to a sequence of packet storage, and discarding according to a service to which the packet belongs.
Optionally, in this embodiment, a plurality of data flows are carried in the existing network environment, when the data flows exceed the capability of the forwarding device (such as a network switch) for forwarding the egress, the messages exceeding the capability of forwarding the egress need to be temporarily cached by using the queue cache resources of the switch, and then forwarded when the egress is idle. However, the queue buffer resources of the switch are limited, and once the queue buffer resources are full, the situation of packet loss due to message congestion occurs. The existing service is interrupted when the packet loss is serious due to the packet loss caused by congestion of the data packet in the current network environment. Fig. 3 is a schematic diagram of a traffic drop scenario according to an embodiment of the present application. As shown in fig. 3, assuming that the physical bandwidths of the ports 1 to 4 are all 1Gbps, and the flows A, B, C are all 500Mbps, if the flows A, B, C are simultaneously transmitted according to the forwarding condition shown in the drawing, it is obvious that the size (1.5 Gbps) of the flows received by the ports 1 to 3 exceeds the forwarding capability (1 Gbps) of the port 4, the flows exceeding the port forwarding capability are temporarily stored in the port queue buffer, the buffer capability of the switching device is limited, and when the queue buffer is full, the later flows are discarded (virtual boxes in the drawing). At present, the CPU can poll and read the occupation condition of the queue cache resources of the output port of the chip, and when the queue cache resources are occupied, the situation of packet loss is considered to be monitored. However, the method has two disadvantages, on one hand, the granularity of the CPU polling is generally large, if the traffic is discarded due to subtle burst, the CPU is likely to be unable to monitor, on the other hand, even if the CPU monitors that the queue buffer resource is full, the packet loss condition is considered to occur, the CPU cannot accurately perform the flow positioning, and further cannot determine which traffic is discarded due to congestion. For another monitoring mode of packet loss, the CPU participates in the switch to discard the flow analysis, the chip sends all the discarded messages due to congestion to the CPU, and the CPU analyzes the discarded messages one by one to determine the specific service flow. However, this monitoring method is very dependent on the processing capability of the CPU, and once there are multiple services and packet loss occurs at the same time, this analysis method may cause a significant overhead to the controller, and may affect the processing of other services when serious.
By adopting the scheme of the application, when the exchange chip transmits data, the discarded messages are collected in real time, the situation that the packet loss situation cannot be identified and the discarded messages are ignored due to large time granularity is avoided, and then the packet loss situation of the service flow in the packet loss state in the data flow is determined by analyzing the messages, so that the packet loss situation is fed back to the CPU, the specific relevant situation of the packet loss can be known under the condition that the processing capacity of the CPU is not excessively depended, and the CPU can accurately know the packet loss problem in the service flow transmission process and timely perform relevant flow management.
In the technical solution provided in step S204, the initial packet loss information may include, but is not limited to, a packet characteristic of the packet discarded in each service flow (for indicating a packet type, such as a packet entry Port Index, ipDa, ipSa, ip Protocol, L4 Srcport, L4 Destport), a packet number, a packet length, a timestamp of the packet entering the switching device, and so on.
Optionally, in the embodiment of the present application, the packet loss conditions of different service flows in the target data flow are classified and stored in the initial packet loss information, and then, after the target message exists, the packet loss conditions of the service flows in the initial packet loss information and the target message are updated according to the characteristics of the target message, so that the packet loss conditions of each service flow in the target data flow are accurately counted.
In the technical solution provided in step S206, the data transmission quality may be determined by the total amount of dropped messages in the service flow or the importance level of information carried by the dropped messages in the service flow, for example, when the number of dropped messages in the target service flow is greater than a preset threshold, it is determined that the data transmission quality of the target service flow is lower than the target transmission quality, or when the importance level of information carried by the dropped messages in the target service flow is higher than the preset level, it is determined that the data transmission quality of the target service flow is lower than the target transmission quality.
Optionally, in the embodiment of the present application, the target packet loss information may, but is not limited to, carry packet loss situations of each service flow included in the target data flow.
Optionally, fig. 4 is a schematic diagram of a method for reporting service flow information according to an embodiment of the present application. As shown in fig. 4, a message enters a memory management unit (MMU, memory Management Unit) of the switch chip from an Ethernet Port, a large amount of queue buffer resources of the switch chip are occupied to cause the message to be discarded, the discarded message is reprocessed, the message is classified in flow and information is counted, and the flow information and the message counted information are reported to the CPU.
As an optional embodiment, the updating the initial packet loss information of the network switching device with the target packet to obtain the target packet loss information includes:
acquiring target attribute information of the target message;
Screening a target information set corresponding to the target message from a plurality of initial information sets, wherein the target information set is used for storing attribute information of the discarded message in a target service flow, and the initial packet loss information comprises the plurality of initial information sets;
and storing the target attribute information into the target information set.
Optionally, in the embodiment of the present application, the target attribute information may be, but is not limited to, obtained by analyzing information carried by a header of a message.
Optionally, in the embodiment of the present application, the target attribute information of the target packet includes, but is not limited to, a packet entry Port Index of the target packet, a destination IP address IpDa, a source IP address IpSa, an IP Protocol, a transport layer source Port L4 Srcport, a transport layer destination Port L4 Destport, a packet length, a timestamp of a packet entering the switching device, traffic flow information corresponding to the packet, and the like.
Through the steps, the information set corresponding to each service flow is obtained through the equipment, and then the target attribute information of the target message is obtained and stored into the target information set configured for the target service flow to which the target message belongs, so that the classified storage of the packet loss information of different service flows is realized, and the accuracy of the packet loss information statistics is improved.
Optionally, in this embodiment, fig. 5 is a schematic diagram of a process for discarding a packet according to an embodiment of the present application. As shown in fig. 5, the processing of the discarded packet includes: copying a discarded message to distinguish normal forwarding messages, and carrying out flow classification and message information statistics on the copied message. Wherein,
Flow classification: in order to make the CPU determine the traffic flow and reduce unnecessary overhead, enough message features are needed to facilitate the CPU to determine the specific traffic, such as IP messages, according to the message entry Port Index, destination IP address IpDa, source IP address IpSa, IP Protocol, transport layer source Port L4 Srcport, and transport layer destination Port L4 Destport, which are cached in the specific chip Memory as traffic classification basis.
And (3) message statistics: the statistics information includes, but is not limited to, packet Count, packet length PACKET LENGTH, timestamp INGRESS TIMESTAMP of the Packet entering the switching device, etc., and meanwhile, the statistics information needs to be bound with the traffic, so that additional overhead caused by the reintegration of the CPU after the information is sent is avoided.
As an alternative embodiment, before said storing said target attribute information into said target information set, said method further comprises:
Detecting a reference service flow to which the stored message attribute information in the target information set belongs;
Reporting the target attribute information to the target processor under the condition that the reference service flow and the target service flow are inconsistent;
And receiving a candidate information set allocated by the target processor in response to the target attribute information, and storing the target attribute information into the candidate information set.
Optionally, in the embodiment of the present application, the detecting the reference service flow to which the message attribute information already stored in the target information set belongs includes, but is not limited to, detecting a field indicating a service flow type in the message attribute information, or detecting a port mode of inputting a message stored in the message attribute information on a network transmission device (the network transmission device allocates a corresponding port for each message of the service flows).
Through the steps, the reference service flow to which the message attribute information stored in the target information set belongs is detected, the reference service flow is compared with the target service flow, the target attribute information is reported and stored in the candidate information set under the condition that the comparison is inconsistent, which is equivalent to the condition that the corresponding service flow stored in the target information set and the corresponding service flow stored in the target information set information is checked before the target attribute information is stored, and under the condition that the Memory conflict occurs under the inconsistent condition, the target attribute information to be stored is timely reported to the target processor and the corresponding storage position is replaced, so that the condition that the processor is affected by the disorder of the information storage order caused by the mixed storage of a plurality of service flow information is effectively avoided, and the traffic management efficiency of the processor on the service flow is improved.
As an optional embodiment, the sending, according to the target packet loss information, a target notification message to a target processor includes:
Screening a target information set from a plurality of initial information sets included in the target packet loss information, wherein the target information set is used for storing message attribute information of discarded messages in a target service flow;
counting the message attribute information stored in the target information set to obtain target statistical information of the target service flow, wherein the target statistical information is used for representing the packet loss condition of the target service flow in the transmission process;
and generating the target notification message carrying the target statistical information and sending the target notification message to the target processor.
Optionally, in the embodiment of the present application, the statistics of the message attribute information stored in the target information set is performed to obtain the target statistics of the target service flow, where the target statistics include, but are not limited to, directly determining all the message attribute information stored in the target information set as the target statistics of the target service flow, or determining part of the message attribute information in the target information set as the target statistics according to the condition of triggering the reporting action, for example, when the reporting of the message information is triggered due to the Memory conflict, part of the message attribute information in the target information set, such as a timestamp of a message entering the switching device, may be deleted, and the rest of the message attribute information is determined as the target statistics of the target service flow.
As an optional embodiment, after updating the initial packet loss information of the target data stream by using the target packet to obtain target packet loss information, the method further includes:
Screening a target information set from a plurality of initial information sets included in the target packet loss information, wherein the target information set is used for storing message attribute information of discarded messages in a target service flow;
And determining the data transmission quality of the target service flow according to the message attribute information stored in the target information set.
Optionally, in the embodiment of the present application, determining the data transmission quality of the target service flow according to the message attribute information stored in the target information set includes, but is not limited to, determining the data transmission quality of the target service flow according to the number of messages that have been lost currently and recorded in the message attribute information, or determining the data transmission quality of the target service flow according to the importance level of the lost messages and recorded in the message attribute information, for example, detecting all the message attribute information recorded in the target information set, and if an occurrence of one message attribute information indicates that the importance level of the lost message is high, determining that the data transmission quality of the target service flow is poor.
As an optional embodiment, determining the data transmission quality of the target service flow according to the message attribute information stored in the target information set includes:
determining the number of discarded message targets in the target service flow according to the message attribute information stored in the target information set;
Under the condition that the target number is larger than or equal to the preset message number, determining that the data transmission quality of the target service flow is lower than the target transmission quality;
And under the condition that the target number is smaller than the preset message number, determining that the data transmission quality of the target service flow is higher than the target transmission quality.
As an alternative embodiment, after said determining that the data transmission quality of the target traffic flow is higher than the target transmission quality, the method further comprises:
detecting a target time interval for executing statistical operation on message attribute information stored in the target information set;
Under the condition that the target time interval is larger than or equal to a set threshold value, counting the message attribute information stored in the target information set to obtain reference statistical information;
And generating a reference notification message carrying the reference statistical information and sending the reference notification message to the target processor, wherein the target processor is used for controlling the flow of the target service flow according to the reference notification message.
Alternatively, in this embodiment, the set threshold may be set manually, or may be determined by the processor according to the importance level of the current transmission information, which is not limited in this scheme.
Alternatively, in this embodiment, the set threshold may be constant, or the processor may be constantly changed according to the condition of the data transmission quality, for example, the quality transmission quality may be set, and in the case where the data transmission quality is higher than the target transmission quality but lower than the quality transmission quality, the set threshold may be appropriately reduced.
Optionally, in this embodiment, a manner of reporting the CPU includes: the method I is a common uploading method, and the chip uploads flow classification and statistical information at regular time; the second mode is to report the CPU in time aiming at the special event, if the number of the statistical messages exceeds the minimum expected value; in the third mode, when two different service flow information are cached to the same chip Memory, the CPU needs to be reported immediately, and the CPU determines the Memory for caching the conflict service flow information.
In order to better understand the above process, the following description of the above process is provided with reference to an alternative embodiment, but is not limited to the technical solution of the embodiment of the present application.
In this embodiment, a method for reporting service flow information is provided, and fig. 6 is a schematic diagram of a method for reporting service flow information according to an embodiment of the present application, as shown in fig. 6, mainly including the following steps:
Step S601: the Drop message is copied in one copy, and S602 is performed.
Step S602: and collecting message characteristic information according to the message type, classifying the flow, storing the information to a specific chip Memory, and executing S603.
Step S603: judging whether Memory conflict exists in the S602 process, and executing S604 if the Memory conflict does not exist; if there is a Memory conflict, S605 is executed.
Step S604: and counting message information, updating the information such as the number of messages, the length of messages, the time stamp of the messages and the like, and executing S606.
Step S605: the Memory conflict reports the message characteristic information to the CPU, and S607 is executed.
Step S606: and judging whether the number of the messages exceeds a preset value, if so, executing S608, otherwise, executing S609.
Step S607: the CPU determines the specific traffic flow, allocates an idle Memory for the traffic information buffer, and re-executes the collision traffic S602.
Step S608: and (3) meeting the reporting CPU condition, and uploading the message characteristics and information to the CPU, wherein the CPU determines the discarded service flow caused by blocking and the number of discarded messages of the service flow.
Step S609: whether the timing reporting interval is satisfied is judged, if yes, S608 is executed, otherwise S604 is executed.
From the description of the above embodiments, it will be clear to a person skilled in the art that the method according to the above embodiments may be implemented by means of software and a necessary general hardware platform, but of course also by means of hardware, but in many cases the former is a preferred embodiment. Based on such understanding, the technical solution of the present application may be embodied essentially or in a part contributing to the prior art in the form of a software product stored in a storage medium (e.g. ROM/RAM, magnetic disk, optical disk) comprising several instructions for causing a terminal device (which may be a mobile phone, a computer, a server, or a network device, etc.) to perform the method of the various embodiments of the present application.
Fig. 7 is a block diagram of a service flow information reporting apparatus according to an embodiment of the present application; as shown in fig. 7, includes:
The acquisition module is used for acquiring a target message which appears in the transmission process of a target data stream on the network switching equipment, wherein the target message is a message which is discarded due to the fact that the target message cannot be buffered in a target buffer space, and the target buffer space is used for temporarily storing a message which exceeds a port transmission bandwidth part and is included in the data stream to be transmitted under the condition that the bandwidth of the data stream to be transmitted is larger than the port transmission bandwidth of a data stream output port of the network switching equipment;
the updating module is used for updating the initial packet loss information of the target data stream by using the target message to obtain target packet loss information, wherein the initial packet loss information records the packet loss condition of each service stream in a plurality of service streams included in the target data stream;
The sending module is configured to send a target notification message to a target processor according to the target packet loss information when the target packet loss information is used to indicate that the data transmission quality of the target traffic flow is lower than the target transmission quality, where the target traffic flow is a traffic flow to which the target packet included in the plurality of traffic flows belongs, and the target processor is configured to respond to the target notification message to perform flow control on the traffic flow in a packet loss state in the transmission process of the target data flow.
Through the above embodiment, the obtained packet which is not buffered in the target buffer space and discarded is used to update the initial packet loss information recording the packet loss condition of each service flow in the plurality of service flows included in the target data flow, after the target packet information is obtained, the target notification message is sent to the target processor according to the updated target packet loss information when the data transmission quality of the target service flow is lower than the target transmission quality, so that the packet loss information of the service flow is fed back to the target processor according to the influence condition of the packet loss information on the data transmission quality of the target service flow, the processor can accurately and timely learn the packet loss problem in the service flow transmission process, and the processor is helped to more effectively realize the flow management of the service flow. By adopting the technical scheme, the problems of low monitoring efficiency of the processor on the service flow transmission process and the like in the related technology are solved, and the technical effect of improving the monitoring efficiency of the processor on the service flow transmission process is realized.
In one exemplary embodiment, the update module includes:
the acquisition unit is used for acquiring the target attribute information of the target message;
A first screening unit, configured to screen a target information set corresponding to the target packet from a plurality of initial information sets, where the target information set is used to store attribute information of a packet that has been discarded in a target service flow, and the initial packet loss information includes the plurality of initial information sets;
and the storage unit is used for storing the target attribute information into the target information set.
Optionally, the updating module further includes:
The first detection unit is used for detecting the reference service flow to which the stored message attribute information in the target information set belongs;
The reporting unit is used for reporting the target attribute information to the target processor under the condition that the reference service flow is inconsistent with the target service flow;
And the receiving unit is used for receiving the candidate information set allocated by the target processor in response to the target attribute information and storing the target attribute information into the candidate information set.
In an exemplary embodiment, the transmitting module includes:
A second screening unit, configured to screen a target information set from a plurality of initial information sets included in the target packet loss information, where the target information set is used to store message attribute information of a discarded message in a target service flow;
The first statistics unit is used for counting the message attribute information stored in the target information set to obtain target statistics information of the target service flow, wherein the target statistics information is used for representing packet loss situations of the target service flow in the transmission process;
and the generating unit is used for generating the target notification message carrying the target statistical information and sending the target notification message to the target processor.
Optionally, the device for reporting service flow information further includes:
the screening module is used for screening a target information set from a plurality of initial information sets included in the target packet loss information, wherein the target information set is used for storing message attribute information of discarded messages in a target service flow;
and the determining module is used for determining the data transmission quality of the target service flow according to the message attribute information stored in the target information set.
Optionally, the determining module includes:
A first determining unit, configured to determine, according to the message attribute information stored in the target information set, a target number of messages that have been discarded in the target service flow;
a second determining unit, configured to determine that, when the target number is greater than or equal to a preset number of packets, the data transmission quality of the target service flow is lower than the target transmission quality;
And a third determining unit, configured to determine that the data transmission quality of the target service flow is higher than the target transmission quality when the target number is less than a preset number of packets.
Optionally, the determining module further includes:
The second detection unit is used for detecting a target time interval for executing statistical operation on the message attribute information stored in the target information set;
the second statistical unit is used for counting the message attribute information stored in the target information set to obtain reference statistical information under the condition that the target time interval is greater than or equal to a set threshold value;
And the sending unit is used for generating a reference notification message carrying the reference statistical information and sending the reference notification message to the target processor, wherein the target processor is used for controlling the flow of the target service flow according to the reference notification message.
The embodiment of the application also provides a storage medium, which comprises a stored program, wherein the program executes the method for reporting any business flow information.
Alternatively, in the present embodiment, the above-described storage medium may be configured to store program code for performing the steps of:
S1, acquiring a target message which appears in the transmission process of a target data stream on network switching equipment, wherein the target message is a message which is discarded due to the fact that the target message cannot be buffered in a target buffer space, and the target buffer space is used for temporarily storing a message which is included in the data stream to be transmitted and exceeds a port transmission bandwidth part of a data stream output port of the network switching equipment under the condition that the bandwidth of the data stream to be transmitted is larger than the port transmission bandwidth of the data stream output port of the network switching equipment;
S2, updating initial packet loss information of the target data stream by using the target message to obtain target packet loss information, wherein the initial packet loss information records packet loss conditions of each service stream in a plurality of service streams included in the target data stream;
S3, under the condition that the target packet loss information is used for indicating that the data transmission quality of the target service flow is lower than the target transmission quality, sending a target notification message to a target processor according to the target packet loss information, wherein the target service flow is the service flow to which the target message included in the plurality of service flows belongs, and the target processor is used for responding to the target notification message to perform flow control on the service flow in a packet loss state in the transmission process of the target data flow.
The embodiment of the application also provides an electronic device, which comprises a memory and a processor, wherein the memory stores a computer program, and the processor is configured to run the computer program to execute the steps in the embodiment of the method for reporting the service flow information.
Optionally, the electronic apparatus may further include a transmission device and an input/output device, where the transmission device is connected to the processor, and the input/output device is connected to the processor.
Alternatively, in the present embodiment, the above-described processor may be configured to execute the following steps by a computer program:
S1, acquiring a target message which appears in the transmission process of a target data stream on network switching equipment, wherein the target message is a message which is discarded due to the fact that the target message cannot be buffered in a target buffer space, and the target buffer space is used for temporarily storing a message which is included in the data stream to be transmitted and exceeds a port transmission bandwidth part of a data stream output port of the network switching equipment under the condition that the bandwidth of the data stream to be transmitted is larger than the port transmission bandwidth of the data stream output port of the network switching equipment;
S2, updating initial packet loss information of the target data stream by using the target message to obtain target packet loss information, wherein the initial packet loss information records packet loss conditions of each service stream in a plurality of service streams included in the target data stream;
S3, under the condition that the target packet loss information is used for indicating that the data transmission quality of the target service flow is lower than the target transmission quality, sending a target notification message to a target processor according to the target packet loss information, wherein the target service flow is the service flow to which the target message included in the plurality of service flows belongs, and the target processor is used for responding to the target notification message to perform flow control on the service flow in a packet loss state in the transmission process of the target data flow.
Alternatively, in the present embodiment, the storage medium may include, but is not limited to: a U-disk, a Read-Only Memory (ROM), a random access Memory (Random Access Memory RAM), a removable hard disk, a magnetic disk, or an optical disk, etc., which can store program codes.
Alternatively, specific examples in this embodiment may refer to examples described in the foregoing embodiments and optional implementations, and this embodiment is not described herein.
It will be appreciated by those skilled in the art that the modules or steps of the application described above may be implemented in a general purpose computing device, they may be concentrated on a single computing device, or distributed across a network of computing devices, they may alternatively be implemented in program code executable by computing devices, so that they may be stored in a memory device for execution by computing devices, and in some cases, the steps shown or described may be performed in a different order than that shown or described, or they may be separately fabricated into individual integrated circuit modules, or multiple modules or steps within them may be fabricated into a single integrated circuit module for implementation. Thus, the present application is not limited to any specific combination of hardware and software.
The foregoing is merely a preferred embodiment of the present application and it should be noted that modifications and adaptations to those skilled in the art may be made without departing from the principles of the present application, which are intended to be comprehended within the scope of the present application.

Claims (10)

1. The method for reporting the service flow information is characterized by comprising the following steps:
Acquiring a target message which appears in the transmission process of a target data stream on network switching equipment, wherein the target message is a message which is discarded due to the fact that the target message cannot be buffered to a target buffer space, and the target buffer space is used for temporarily storing a message which is included in the data stream to be transmitted and exceeds a port transmission bandwidth part of a data stream output port of the network switching equipment under the condition that the bandwidth of the data stream to be transmitted is larger than the port transmission bandwidth of the data stream output port of the network switching equipment;
Updating initial packet loss information of the target data stream by using the target message to obtain target packet loss information, wherein the initial packet loss information records packet loss conditions of each service stream in a plurality of service streams included in the target data stream;
And under the condition that the target packet loss information is used for indicating that the data transmission quality of the target service flow is lower than the target transmission quality, sending a target notification message to a target processor according to the target packet loss information, wherein the target service flow is the service flow to which the target message included in the plurality of service flows belongs, and the target processor is used for responding to the target notification message to perform flow control on the service flow in a packet loss state in the transmission process of the target data flow.
2. The method of claim 1, wherein updating the initial packet loss information of the network switching device with the target packet to obtain the target packet loss information includes:
acquiring target attribute information of the target message;
Screening a target information set corresponding to the target message from a plurality of initial information sets, wherein the target information set is used for storing attribute information of the discarded message in a target service flow, and the initial packet loss information comprises the plurality of initial information sets;
and storing the target attribute information into the target information set.
3. The method of claim 2, wherein prior to said storing said target attribute information into said target information set, said method further comprises:
Detecting a reference service flow to which the stored message attribute information in the target information set belongs;
Reporting the target attribute information to the target processor under the condition that the reference service flow and the target service flow are inconsistent;
And receiving a candidate information set allocated by the target processor in response to the target attribute information, and storing the target attribute information into the candidate information set.
4. The method of claim 1, wherein the sending the destination notification message to the destination processor according to the destination packet loss information comprises:
Screening a target information set from a plurality of initial information sets included in the target packet loss information, wherein the target information set is used for storing message attribute information of discarded messages in a target service flow;
counting the message attribute information stored in the target information set to obtain target statistical information of the target service flow, wherein the target statistical information is used for representing the packet loss condition of the target service flow in the transmission process;
and generating the target notification message carrying the target statistical information and sending the target notification message to the target processor.
5. The method of claim 1, wherein after updating the initial packet loss information of the target data stream using the target packet to obtain target packet loss information, the method further comprises:
Screening a target information set from a plurality of initial information sets included in the target packet loss information, wherein the target information set is used for storing message attribute information of discarded messages in a target service flow;
And determining the data transmission quality of the target service flow according to the message attribute information stored in the target information set.
6. The method of claim 5, wherein determining the data transmission quality of the target traffic stream based on the message attribute information stored in the target information set comprises:
determining the number of discarded message targets in the target service flow according to the message attribute information stored in the target information set;
Under the condition that the target number is larger than or equal to the preset message number, determining that the data transmission quality of the target service flow is lower than the target transmission quality;
And under the condition that the target number is smaller than the preset message number, determining that the data transmission quality of the target service flow is higher than the target transmission quality.
7. The method of claim 6, wherein after said determining that the data transmission quality of the target traffic stream is higher than the target transmission quality, the method further comprises:
detecting a target time interval for executing statistical operation on message attribute information stored in the target information set;
Under the condition that the target time interval is larger than or equal to a set threshold value, counting the message attribute information stored in the target information set to obtain reference statistical information;
And generating a reference notification message carrying the reference statistical information and sending the reference notification message to the target processor, wherein the target processor is used for controlling the flow of the target service flow according to the reference notification message.
8. The utility model provides a reporting device of service flow information which is characterized in that the device comprises:
The acquisition module is used for acquiring a target message which appears in the transmission process of a target data stream on the network switching equipment, wherein the target message is a message which is discarded due to the fact that the target message cannot be buffered in a target buffer space, and the target buffer space is used for temporarily storing a message which exceeds a port transmission bandwidth part and is included in the data stream to be transmitted under the condition that the bandwidth of the data stream to be transmitted is larger than the port transmission bandwidth of a data stream output port of the network switching equipment;
the updating module is used for updating the initial packet loss information of the target data stream by using the target message to obtain target packet loss information, wherein the initial packet loss information records the packet loss condition of each service stream in a plurality of service streams included in the target data stream;
The sending module is configured to send a target notification message to a target processor according to the target packet loss information when the target packet loss information is used to indicate that the data transmission quality of the target traffic flow is lower than the target transmission quality, where the target traffic flow is a traffic flow to which the target packet included in the plurality of traffic flows belongs, and the target processor is configured to respond to the target notification message to perform flow control on the traffic flow in a packet loss state in the transmission process of the target data flow.
9. A computer-readable storage medium, characterized in that the computer-readable storage medium comprises a stored program, wherein the program when run performs the method of any one of claims 1 to 7.
10. An electronic device comprising a memory and a processor, characterized in that the memory has stored therein a computer program, the processor being arranged to execute the method according to any of claims 1 to 7 by means of the computer program.
CN202410328922.9A 2024-03-21 2024-03-21 Method and device for reporting service flow information, storage medium and electronic device Pending CN118250229A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202410328922.9A CN118250229A (en) 2024-03-21 2024-03-21 Method and device for reporting service flow information, storage medium and electronic device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202410328922.9A CN118250229A (en) 2024-03-21 2024-03-21 Method and device for reporting service flow information, storage medium and electronic device

Publications (1)

Publication Number Publication Date
CN118250229A true CN118250229A (en) 2024-06-25

Family

ID=91560113

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202410328922.9A Pending CN118250229A (en) 2024-03-21 2024-03-21 Method and device for reporting service flow information, storage medium and electronic device

Country Status (1)

Country Link
CN (1) CN118250229A (en)

Similar Documents

Publication Publication Date Title
US8989002B2 (en) System and method for controlling threshold testing within a network
JP4798285B2 (en) Packet transmission quality measurement method and packet reception measurement device
US10924374B2 (en) Telemetry event aggregation
US20220045972A1 (en) Flow-based management of shared buffer resources
CN108667898B (en) Network element and method for providing a snapshot of buffer content in a network element
CN111314179B (en) Network quality detection method, device, equipment and storage medium
CN113328902B (en) Network performance detection method and device and network equipment
US7719990B2 (en) Communications network traffic monitor system
WO2020244422A1 (en) Queue congestion control method, apparatus, device and storage medium
US8619589B2 (en) System and method for removing test packets
CN109005126B (en) Data stream processing method, device and computer readable storage medium
US20160212034A1 (en) Communication management apparatus, communication system and storage medium
CN110831061A (en) Method and device for acquiring scheduling throughput, base station and storage medium
CN112104564A (en) Load sharing method and equipment
US20120213133A1 (en) Method and system for identifying media type transmitted over an atm network
CN110972199B (en) Flow congestion monitoring method and device
WO2023134574A1 (en) Method for flow statistics, device, and system
US10826784B2 (en) High definition, scalable network monitoring and debugging in real-time
CN118250229A (en) Method and device for reporting service flow information, storage medium and electronic device
EP4181479A1 (en) Method for identifying flow, and apparatus
WO2022152230A1 (en) Information flow identification method, network chip, and network device
CN114270788A (en) Traffic monitoring in a network node
CN114422309A (en) Method for analyzing service message transmission effect based on abstract feedback comparison mode
CN113453024B (en) Method, device and system for monitoring service
CN107547298B (en) Link bandwidth testing method and device

Legal Events

Date Code Title Description
PB01 Publication