WO2023173766A1 - 端口流量采集方法、装置、存储介质及电子设备 - Google Patents

端口流量采集方法、装置、存储介质及电子设备 Download PDF

Info

Publication number
WO2023173766A1
WO2023173766A1 PCT/CN2022/130639 CN2022130639W WO2023173766A1 WO 2023173766 A1 WO2023173766 A1 WO 2023173766A1 CN 2022130639 W CN2022130639 W CN 2022130639W WO 2023173766 A1 WO2023173766 A1 WO 2023173766A1
Authority
WO
WIPO (PCT)
Prior art keywords
port
packet loss
queue
port traffic
traffic data
Prior art date
Application number
PCT/CN2022/130639
Other languages
English (en)
French (fr)
Other versions
WO2023173766A9 (zh
Inventor
何晓明
李嫚
朱明英
韦烜
黄君雅
Original Assignee
中国电信股份有限公司
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 中国电信股份有限公司 filed Critical 中国电信股份有限公司
Publication of WO2023173766A1 publication Critical patent/WO2023173766A1/zh
Publication of WO2023173766A9 publication Critical patent/WO2023173766A9/zh

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/08Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
    • H04L43/0876Network utilisation, e.g. volume of load or congestion level
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/08Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
    • H04L43/0876Network utilisation, e.g. volume of load or congestion level
    • H04L43/0888Throughput

Definitions

  • the present disclosure relates to the field of data communication technology, and in particular to a port traffic collection method, device, computer-readable storage medium and electronic equipment.
  • Microburst refers to a port receiving a very large amount of burst data in a very short period of time.
  • the duration of a typical microburst is usually between tens to hundreds of milliseconds, so that the instantaneous burst rate reaches Several times the average rate, even exceeding the port bandwidth.
  • Microburst phenomena have a serious impact on network performance and service experience. Real-time detection and avoidance of microburst traffic is a difficult problem faced by network operation and maintenance.
  • the present disclosure provides a port traffic collection method, device, computer-readable storage medium and electronic equipment.
  • a port traffic collection method is provided, which is applied to network equipment, including:
  • the port traffic data is read according to the subscription period
  • the port flow data is encapsulated and reported to the collection control platform, so that the collection control platform can process the port flow data in real time.
  • it also includes:
  • the subscription period is a traffic collection period for packet loss in the subscription port queue of the collection control platform.
  • the real-time detection of whether packets are lost in a port queue includes:
  • stopping reading port traffic data according to the subscription cycle includes:
  • the count value of the queue overflow packet loss counter stops increasing within a certain period of time, the count value of the queue overflow packet loss counter is cleared, and the reading of port traffic data according to the subscription cycle is stopped.
  • stopping reading port traffic data according to the subscription cycle includes:
  • the collection control platform determines that no packet loss occurs in the port queue based on the port traffic data, it issues the configuration of clearing the count value of the queue overflow packet loss counter to the network device, and the network device stops based on Read port traffic data during the subscription cycle.
  • it also includes:
  • the collection control platform performs visual real-time presentation of the port flow data in the form of charts and/or curves.
  • it also includes:
  • a port traffic collection device including:
  • the port packet loss detection module detects whether the port queue is losing packets in real time
  • the port traffic reading module if packet loss is detected in the port queue, reads the port traffic data according to the subscription period;
  • the traffic data processing module encapsulates the port traffic data and reports it to the collection control platform so that the collection control platform can process the port traffic data in real time.
  • an electronic device including: a processor; and a memory for storing executable instructions of the processor; wherein the processor is configured to execute the executable instructions via Instructions to execute any one of the above mentioned port traffic collection methods.
  • a computer-readable storage medium on which a computer program is stored.
  • the computer program When executed by a processor, it implements any one of the above port traffic collection methods.
  • Figure 1 shows a flow chart of a port traffic collection method in an embodiment of the present disclosure
  • Figure 2 is a flowchart of a method for visualizing port traffic data by a collection control platform in an embodiment of the present disclosure
  • Figure 3 is a flow chart of a method for ending port traffic collection in an embodiment of the present disclosure
  • Figure 4 is a flow chart of a method for determining the end of port traffic in an embodiment of the present disclosure
  • Figure 5 shows a schematic diagram of a port traffic collection device in an embodiment of the present disclosure
  • Figure 6 shows a flow chart of yet another port traffic collection method in an embodiment of the present disclosure
  • Figure 7 shows a flow chart of another method for ending port traffic collection in an embodiment of the present disclosure
  • Figure 8 shows a flow chart of yet another method for ending port traffic collection in an embodiment of the present disclosure
  • Figure 9 shows a schematic diagram of a port traffic collection system in an embodiment of the present disclosure.
  • Figure 10 shows a schematic diagram of visual real-time presentation of port traffic in an embodiment of the present disclosure.
  • Figure 11 shows a structural block diagram of an electronic device in an embodiment of the present disclosure.
  • Example embodiments will now be described more fully with reference to the accompanying drawings.
  • Example embodiments may, however, be embodied in various forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the concepts of the example embodiments. To those skilled in the art.
  • the described features, structures or characteristics may be combined in any suitable manner in one or more embodiments.
  • Microburst means that a port receives a large amount of burst data in a very short period of time.
  • Network telemetry uses subscription or publishing push mode (PUSH) to achieve millisecond-level data collection and submission.
  • PUSH subscription or publishing push mode
  • embodiments of the present disclosure provide a method for collecting port traffic, which detects whether packet loss in the port queue is detected in real time. If packet loss is detected in the port queue, the port traffic data is read according to the subscription period, and the port traffic data is encapsulated and reported to Collection control platform. The collection control platform visualizes port traffic in real time based on reported port traffic data. It is low cost and can better understand the characteristics of port traffic and accurately judge port micro-bursts. At least to a certain extent, it can overcome the problem of collection in related technologies. The problems of port micro-burst traffic are low accuracy and high cost. This exemplary implementation will be described in detail below with reference to the drawings and examples.
  • embodiments of the present disclosure provide a port traffic collection method, which can be executed by any electronic device with computing processing capabilities.
  • Figure 1 shows a flow chart of a port traffic collection method in an embodiment of the present disclosure.
  • the port traffic collection method provided in an embodiment of the present disclosure is applied to network equipment and includes the following steps:
  • the network device reads the count value of the queue overflow packet loss counter of the port in real time at the millisecond level based on a hardware chip.
  • the hardware chip may have a built-in microprocessor to improve the efficiency of reading the count value of the queue overflow packet loss counter of the port.
  • the queue overflow packet loss counter of the corresponding port will count the number of lost packets.
  • the initial value is generally zero. Therefore, when the queue overflow packet loss counter is greater than zero, then Read port traffic data according to the subscription period.
  • the subscription period is the traffic collection period when the port queue subscribed to by the collection control platform loses packets.
  • the hardware chip reads the port traffic data according to the subscription cycle.
  • the subscription period is set to 5 milliseconds to 10 milliseconds, which can collect port micro-burst traffic and reduce costs.
  • the subscription period is set to 1 millisecond to 2 milliseconds, which can efficiently collect port micro-burst traffic.
  • S106 Encapsulate the port traffic data and report it to the collection control platform so that the collection control platform can process the port traffic data in real time.
  • the collection control platform receives the encapsulated port traffic data, and visually presents the port traffic in the form of a chart or curve in real time.
  • the network device when packet loss in the port queue is detected, can be triggered to report port traffic data to the collection control platform according to the subscription cycle, and the collection control platform displays the port traffic based on the reported port traffic data to minimize resource occupation. Realize the collection and visualization of port micro-burst traffic, and combine the real-time detection of port traffic with the visual presentation of port traffic data to more clearly understand the characteristics of port traffic and accurately determine port micro-bursts.
  • Figure 2 is a flowchart of a method for visualizing port traffic data processing by a collection control platform in an embodiment of the disclosure. As shown in Figure 2, the method for visualizing port traffic data by a collection control platform provided in an embodiment of the disclosure includes the following steps :
  • S202 The hardware chip sends the port traffic data read according to the subscription cycle to the device processor.
  • the device processor includes the main control board or line card CPU of the network device.
  • the device processor encapsulates the port traffic data
  • S206 The device processor reports the encapsulated port traffic data to the collection control platform.
  • the device processor performs telemetry encapsulation on the port traffic data. Telemetry encapsulation can realize millisecond-level data collection and transmission, and can effectively capture port micro-burst traffic.
  • the device processor encapsulates one or more port traffic data and reports it to the collection control platform according to the subscription cycle, reducing the frequency of reporting, effectively increasing the processing rate and reducing costs.
  • the collection control platform receives the encapsulated port traffic data, processes the encapsulated port traffic data online in real time, and visually presents the port traffic in the form of charts or curves in real time.
  • the collection and control platform receives the encapsulated port traffic data, processes the encapsulated port traffic data online in real time, and performs visual real-time presentation.
  • the delay time of the visual presentation should be controlled within 1 second.
  • the hardware chip reports port traffic data to the collection control platform according to the subscription cycle.
  • the collection control platform visualizes the port traffic in real time based on the reported port traffic data, thereby minimizing resource occupation and realizing the collection and visualization of port traffic.
  • Figure 3 is a flow chart of a method for ending port traffic collection in an embodiment of the present disclosure. As shown in Figure 3, the method for ending port traffic collection provided in an embodiment of the present disclosure includes the following steps:
  • the network device reads the counting status of the port queue overflow packet loss counter in real time based on the hardware chip. When a certain port queue overflow packet loss counter is greater than zero, it is determined that the port traffic detection event is triggered.
  • S308 Encapsulate the port traffic data, and report the encapsulated port traffic data to the collection control platform.
  • the hardware chip reads the port traffic data of the port according to the subscription cycle, uploads it to the device processor, and the device processor encapsulates the port traffic data, and reports the encapsulated port traffic data to the collection control platform.
  • the collection control platform receives the encapsulated port traffic data, processes the encapsulated port traffic data online in real time, and visualizes the port traffic in the form of charts or curves in real time;
  • the count value of the queue overflow packet loss counter stops increasing within a certain period of time, it is determined that the port queue packet loss has ended, the count value of the queue overflow packet loss counter is cleared, and reading based on the subscription cycle is stopped. Port traffic data.
  • the hardware chip determines whether the count value of the queue overflow packet loss counter remains unchanged within a certain period of time. If so, clear the port queue overflow packet loss counter and stop traffic collection for the port.
  • the time to determine whether the queue overflow packet loss counter changes can be set according to user needs. Generally, it can be set to 200ms, that is, the hardware chip detects the queue overflow packet loss counter in real time. When the queue overflows the packet loss counter, If the count value does not increase within 200ms, the port queue overflow packet loss counter will be cleared, and traffic collection for the port will be stopped.
  • the real-time detection of port traffic and the visual presentation of port traffic data are combined to have a clearer understanding of port traffic characteristics, accurately determine port micro-bursts, and when it is determined that packet loss in the port queue has ended, stop based on subscription Periodically reading port traffic data can improve port traffic detection efficiency and reduce costs.
  • Figure 4 shows a flow chart of a method for determining the end of port traffic in an embodiment of the present disclosure.
  • the method for determining the end of port traffic provided in an embodiment of the present disclosure includes the following steps:
  • S402 The collection and control platform determines that no packet loss occurs in the port queue based on the port traffic data reported by real-time monitoring.
  • the port traffic data includes but is not limited to the port traffic rate. This embodiment uses the port traffic rate as an example for introduction. Based on the port traffic data reported in real-time monitoring, the collection and control platform determines that no packet loss occurs in the port queue if the port traffic rate is less than or equal to 80% within a certain period of time.
  • the time to determine whether the port traffic rate changes is set according to user needs, which is generally less than 1 second. That is, the port traffic data reported by the collection control platform based on real-time monitoring, within 1 second, the port traffic rate is less than or equal to 80%. Make sure that no packet loss occurs in the port queue.
  • embodiments of the present disclosure also provide a port traffic collection device, as shown in the following embodiments. Since the problem-solving principle of this device embodiment is similar to that of the above-mentioned method embodiment, the implementation of this device embodiment can refer to the implementation of the above-mentioned method embodiment, and repeated details will not be repeated.
  • Figure 5 shows a schematic diagram of a port traffic collection device in an embodiment of the present disclosure.
  • the port traffic collection device 5 includes: a port packet loss detection module 501, a port traffic reading module 502 and a traffic data processing module 503 ;
  • the port packet loss detection module 501 is connected to the input end of the port traffic reading module 502, and the output end of the port traffic reading module 502 is connected to the input end of the traffic data processing module 503.
  • the port packet loss detection module detects whether the port queue is losing packets in real time
  • the port traffic reading module if packet loss is detected in the port queue, reads the port traffic data according to the subscription period;
  • the traffic data processing module encapsulates the port traffic data and reports it to the collection control platform so that the collection control platform can process the port traffic data in real time.
  • the network device when packet loss in the port queue is detected, can be triggered to report port traffic data to the collection control platform according to the subscription cycle.
  • the collection control platform can visualize the port traffic in real time based on the reported port traffic data, and convert the port traffic into The combination of real-time detection and visual presentation of port traffic data can provide a clearer understanding of port traffic characteristics and accurately determine port micro-bursts.
  • Figure 6 shows a flow chart of another port traffic collection method in an embodiment of the present disclosure.
  • the port traffic collection method provided in an embodiment of the present disclosure is applied to network equipment and includes the following steps:
  • the hardware chip reads the count value of the queue overflow packet loss counter of each port of the network device in real time
  • the queue overflow packet loss counter of the corresponding port will count the number of packets lost. At this time, the queue overflow packet loss counter is greater than zero, and the queue overflow packet loss counter of the port is judged to be The packet counter value is abnormal.
  • the collection control platform subscribes to the traffic collection period when packets are lost on each port on the network device; the subscription period is the traffic collection period when the collection control platform subscribes to the port queue when packets are lost.
  • the hardware chip sends the read port traffic data to the device processor, so that the device processor can encapsulate the port traffic data.
  • the device processor includes: a main control board or a line card CPU of the network device.
  • the device processor performs telemetry encapsulation of port traffic data.
  • Telemetry uses subscription or publishing push mode to collect and send data. Telemetry encapsulation can achieve millisecond-level data collection and sending, and can effectively capture port micro-burst traffic.
  • S608 The device processor reports the encapsulated port traffic data to the collection control platform.
  • the device processor reports the encapsulated port traffic data to the collection control platform in real time.
  • the collection and control platform receives the encapsulated port traffic data, processes the encapsulated port traffic data online in real time, and visualizes the port traffic in the form of charts or curves in real time.
  • the collection control platform subscribes to the traffic collection cycle when packet loss occurs on a port due to queue overflow.
  • the network device reads the counting status of the port queue overflow packet loss counter in real time based on the hardware chip, and triggers the port traffic collection and reporting conditions.
  • Port traffic data is periodically reported to the collection and control platform.
  • the collection and control platform performs a visual and real-time presentation of port traffic based on the reported port traffic data. Combining real-time detection of port traffic and visual presentation of port traffic data can provide a clearer understanding of port traffic characteristics. Accurately determine port micro-bursts.
  • Figure 7 shows a flow chart of another port traffic collection end method in an embodiment of the present disclosure.
  • the port traffic collection end method provided in the embodiment of the present disclosure is applied to network equipment and includes the following steps S702 to S714. .
  • the collection control platform subscribes to the traffic collection cycle when packet loss occurs on the port due to queue overflow.
  • the network device reads the count of the port queue overflow packet loss counter in real time based on the hardware chip, and determines whether the port traffic detection event is triggered.
  • the hardware chip reads the port traffic data of the port according to the subscription cycle and reports it to the device processor, otherwise, continue to repeat this step.
  • the device processor encapsulates the port traffic data collected and reported by the hardware chip, and reports the encapsulated port traffic data to the collection control platform.
  • the collection and control platform receives the encapsulated port traffic data, processes the encapsulated port traffic data online in real time, and visualizes the port traffic in the form of charts or curves in real time.
  • S712 The hardware chip determines whether the count value of the queue overflow packet loss counter remains unchanged within a certain period of time.
  • the real-time detection of port traffic and the visual presentation of port traffic data are combined to have a clearer understanding of port traffic characteristics, accurately determine port micro-bursts, and when it is determined that packet loss in the port queue has ended, stop based on subscription Periodically reading port traffic data can improve port traffic detection efficiency and reduce costs.
  • Figure 8 shows a flow chart of yet another method for ending port traffic collection in the embodiment of the present disclosure.
  • the method for ending port traffic collection provided in the embodiment of the present disclosure is applied to network equipment and includes the following steps S802 to S816. .
  • the collection control platform subscribes to the traffic collection cycle when packet loss occurs on the port due to queue overflow.
  • the network device reads the counting status of the port queue overflow packet loss counter in real time based on the hardware chip, and determines whether the port traffic detection event is triggered.
  • the hardware chip reads the port traffic data of the port according to the subscription cycle and reports it to the device processor.
  • the device processor encapsulates the port traffic data collected and reported by the hardware chip, and reports the encapsulated port traffic data to the collection control platform.
  • the collection and control platform receives the encapsulated port traffic data, processes the encapsulated port traffic data online in real time, and visualizes the port traffic in the form of charts or curves in real time.
  • S812 The collection and control platform determines that no packet loss occurs in the port queue based on the port traffic data reported by real-time monitoring.
  • the port traffic rate is less than or equal to 80% within a certain period of time, it is determined that no packet loss occurs in the port queue.
  • the time is set according to user needs, and is generally less than 1 second.
  • the collection control platform issues the configuration of clearing the queue overflow packet loss counter to the port.
  • the real-time detection of port traffic and the visual presentation of port traffic data are combined to have a clearer understanding of port traffic characteristics, accurately determine port micro-bursts, and when it is determined that packet loss in the port queue has ended, stop based on subscription Periodically reading port traffic data can improve port traffic detection efficiency and reduce costs.
  • Figure 9 shows a schematic diagram of a port traffic collection system in an embodiment of the present disclosure.
  • the port traffic collection system provided in an embodiment of the present disclosure includes: a network device 90 and a collection control platform 91; the network device 90 includes : Several queue overflow packet loss counters 9000, hardware chips 9001, device processors 9002, and several port traffic counters 9003.
  • the hardware chip 9001 reads the counting status of the queue overflow packet loss counter 9000 of each port of the network device 90 in real time at millisecond intervals; when a certain port loses packets due to queue overflow, the corresponding port queue overflow packet loss counter 9000 will match the packet loss. The number of packets is counted.
  • the queue overflow packet loss counter 9000 is greater than zero, which immediately triggers the hardware chip 9001 to start reading the port traffic data through the port traffic counter 9003 according to the subscription cycle parameters, and reports it to the device processor 9002; the device processor 9002
  • the hardware chip 9001 collects and reports the port traffic data for telemetry encapsulation, and reports it to the collection control platform 91 according to the subscription cycle requirements.
  • the collection control platform 91 processes the reported port traffic telemetry data online in real time, and analyzes the port traffic in the form of charts or curves. Perform visual real-time presentation.
  • the collection control platform 91 subscribes to the traffic collection cycle when packet loss occurs on a port due to queue overflow.
  • the network device reads the counting status of the port queue overflow packet loss counter 9000 in real time based on the hardware chip 9001, and triggers the port traffic collection and reporting conditions. , report the port flow data to the collection control platform 91 according to the subscription period, and the collection control platform 91 visually presents the port flow in real time based on the reported port flow data. Combining the real-time detection of the port flow and the visual presentation of the port flow data can make it clearer Understand port traffic characteristics and accurately determine port micro-bursts.
  • Figure 10 shows a schematic diagram of a visual real-time presentation of port traffic in an embodiment of the present disclosure.
  • a queue overflow packet loss counter is greater than zero
  • the port is due to a micro burst.
  • Transient congestion caused by traffic It can be seen from the traffic curve that the traffic rate of this port is above 95%.
  • the medium used by the network to provide a communication link between the network device and the server may be a wired network or a wireless network.
  • the above-mentioned wireless network or wired network uses standard communication technologies and/or protocols.
  • the network is usually the Internet, but can also be any network, including but not limited to Local Area Network (LAN), Metropolitan Area Network (MAN), Wide Area Network (Wide Area Network, WAN), mobile, wired or wireless network, private network, or virtual private network).
  • data exchanged over the network is represented using technologies and/or formats including HyperText Mark-up Language (HTML), Extensible Markup Language (XML), etc.
  • HTML HyperText Mark-up Language
  • XML Extensible Markup Language
  • you can also use things such as Secure Socket Layer (Secure Socket Layer, SSL), Transport Layer Security (Transport Layer Security, TLS), Virtual Private Network (Virtual Private Network, VPN), Internet Protocol Security (Internet Protocol Security, IPsec), etc.
  • SSL Secure Socket Layer
  • TLS Transport Layer Security
  • VPN Virtual Private Network
  • Internet Protocol Security Internet Protocol Security
  • IPsec Internet Protocol Security
  • the clients of the application installed in different network devices are the same, or the clients of the same type of application are based on different operating systems.
  • the specific form of the application client can also be different.
  • the application client can be a mobile phone client, a PC client, etc.
  • the server may be a server that provides various services, such as a background management server that provides support for devices operated by users using network equipment.
  • the background management server can analyze and process the received request and other data, and feed the processing results back to the network device.
  • the server can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or it can provide cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, Cloud communications, middleware services, domain name services, security services, CDN (Content Delivery Network, content distribution network), and cloud servers for basic cloud computing services such as big data and artificial intelligence platforms.
  • Network terminals and servers can be connected directly or indirectly through wired or wireless communication methods, which is not limited in this application.
  • FIG. 11 An electronic device 1100 according to this embodiment of the present disclosure is described below with reference to FIG. 11 .
  • the electronic device 1100 shown in FIG. 11 is only an example and should not bring any limitations to the functions and scope of use of the embodiments of the present disclosure.
  • electronic device 1100 is embodied in the form of a general computing device.
  • the components of the electronic device 1100 may include, but are not limited to: the above-mentioned at least one processing unit 1110, the above-mentioned at least one storage unit 1120, and a bus 1130 connecting different system components (including the storage unit 1120 and the processing unit 1110).
  • the storage unit stores program code, and the program code can be executed by the processing unit 1110, so that the processing unit 1110 performs various exemplary methods according to the present disclosure described in the "Example Method" section of this specification.
  • Implementation steps For example, the processing unit 1110 can perform the following steps of the above method embodiment: read the count value of the queue overflow packet loss counter of the port in real time; when the count value of the queue overflow packet loss counter is greater than zero, read the port according to the subscription period Traffic data; encapsulate the port traffic data and report it to the collection and control platform so that the collection and control platform can process the port traffic data in real time.
  • the processing unit 1110 may perform the following steps of the above method embodiment:
  • the collection control platform subscribes to the traffic collection cycle when the port loses packets due to queue overflow; the network device reads the count of the port queue overflow packet loss counter in real time based on the hardware chip, and determines whether the port traffic detection event is triggered; if so, the hardware chip reads the count of the port queue overflow packet loss counter in real time; if so, the hardware chip uses the subscription Periodically read the port traffic data of the port and report it to the device processor; the device processor encapsulates the port traffic data collected and reported by the hardware chip, and reports the encapsulated port traffic data to the collection control platform; the collection control platform receives the encapsulation
  • the encapsulated port traffic data is processed online in real time, and the port traffic is visualized and presented in real time in the form of charts or curves; when it is determined that the port queue packet loss has ended, the queue overflow packet loss counter counts The value is cleared to zero and stops reading port traffic data based on the subscription period.
  • the processing unit 1110 may perform the following steps of the above method embodiment:
  • the value of the queue overflow packet loss counter stops increasing within a certain period of time, the value of the queue overflow packet loss counter is cleared and the reading of port traffic data based on the subscription period is stopped.
  • the processing unit 1110 may perform the following steps of the above method embodiment:
  • the collection control platform determines whether the burst traffic is over based on the port traffic data reported in real-time monitoring; if so, it issues the configuration of clearing the queue overflow packet loss counter to the port; when the hardware chip senses that the port queue overflow packet loss counter is zero, it stops processing This port collects traffic.
  • the processing unit 1110 may perform the following steps of the above method embodiment:
  • the hardware chip reads the queue overflow packet loss counter of each port of the network device in real time at millisecond intervals; when a port loses packets due to queue overflow, the corresponding port queue overflow packet loss counter will count the number of packets lost. , at this time, the queue overflow packet loss counter is greater than zero, which immediately triggers the hardware chip to start reading the port traffic data according to the subscription cycle parameters, and reports it to the device processor; the device processor performs telemetry encapsulation on the port traffic data collected and reported by the hardware chip. It is reported to the collection control platform according to the subscription cycle requirements. The collection control platform processes the reported port traffic telemetry data online in real time, and visually presents the port traffic in the form of charts or curves in real time.
  • the storage unit 1120 may include a readable medium in the form of a volatile storage unit, such as a random access storage unit (RAM) 11201 and/or a cache storage unit 11202, and may further include a read-only storage unit (ROM) 11203.
  • RAM random access storage unit
  • ROM read-only storage unit
  • Storage unit 1120 may also include a program/utility 11204 having a set of (at least one) program modules 11205 including, but not limited to: an operating system, one or more application programs, other program modules, and program data, Each of these examples, or some combination, may include the implementation of a network environment.
  • program/utility 11204 having a set of (at least one) program modules 11205 including, but not limited to: an operating system, one or more application programs, other program modules, and program data, Each of these examples, or some combination, may include the implementation of a network environment.
  • Bus 1130 may be a local area representing one or more of several types of bus structures, including a memory unit bus or memory unit controller, a peripheral bus, a graphics acceleration port, a processing unit, or using any of a variety of bus structures. bus.
  • Electronic device 1100 may also communicate with one or more external devices 1140 (e.g., keyboard, pointing device, Bluetooth device, etc.), may also communicate with one or more devices that enable a user to interact with electronic device 1100, and/or with Any device (eg, router, modem, etc.) that enables the electronic device 1100 to communicate with one or more other computing devices. This communication may occur through an input/output (I/O) interface 1150.
  • the electronic device 1100 may also communicate with one or more networks (eg, a local area network (LAN), a wide area network (WAN), and/or a public network, such as the Internet) through the network adapter 1160 . As shown, network adapter 1160 communicates with other modules of electronic device 1100 via bus 1130 .
  • network adapter 1160 communicates with other modules of electronic device 1100 via bus 1130 .
  • the example embodiments described here can be implemented by software, or can be implemented by software combined with necessary hardware. Therefore, the technical solution according to the embodiment of the present disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, U disk, mobile hard disk, etc.) or on the network , including several instructions to cause a computing device (which may be a personal computer, a server, a terminal device, a network device, etc.) to execute a method according to an embodiment of the present disclosure.
  • a computing device which may be a personal computer, a server, a terminal device, a network device, etc.
  • a computer-readable storage medium is also provided, and the computer-readable storage medium may be a readable signal medium or a readable storage medium.
  • Program products capable of implementing the above methods of the present disclosure are stored thereon.
  • various aspects of the present disclosure can also be implemented in the form of a program product, which includes program code.
  • the program code is used to cause the The terminal device performs the steps according to various exemplary embodiments of the present disclosure described in the above "Example Method" section of this specification.
  • Computer-readable storage media in this disclosure may include, but are not limited to: electrical connections having one or more wires, portable computer disks, hard drives, random access memory (RAM), read only memory (ROM), Erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination of the above.
  • RAM random access memory
  • ROM read only memory
  • EPROM or flash memory Erasable programmable read-only memory
  • CD-ROM portable compact disk read-only memory
  • magnetic storage device or any suitable combination of the above.
  • a computer-readable storage medium may include a data signal propagated in baseband or as part of a carrier wave carrying readable program code therein. Such propagated data signals may take many forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above.
  • a readable signal medium may also be any readable medium other than a readable storage medium that can send, propagate, or transport the program for use by or in connection with an instruction execution system, apparatus, or device.
  • program code embodied on a computer-readable storage medium may be transmitted using any suitable medium, including but not limited to wireless, wired, optical cable, RF, etc., or any suitable combination of the above.
  • program code for performing operations of the present disclosure may be written in any combination of one or more programming languages, including object-oriented programming languages such as Java, C++, etc., and Includes conventional procedural programming languages—such as "C” or similar programming languages.
  • the program code may execute entirely on the user's computing device, partly on the user's device, as a stand-alone software package, partly on the user's computing device and partly on a remote computing device, or entirely on the remote computing device or server execute on.
  • the remote computing device may be connected to the user computing device through any kind of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computing device, such as provided by an Internet service. (business comes via Internet connection).
  • LAN local area network
  • WAN wide area network
  • the technical solution according to the embodiment of the present disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, U disk, mobile hard disk, etc.) or on the network , including several instructions to cause a computing device (which may be a personal computer, a server, a mobile terminal, a network device, etc.) to execute a method according to an embodiment of the present disclosure.
  • a computing device which may be a personal computer, a server, a mobile terminal, a network device, etc.

Landscapes

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

Abstract

一种端口流量采集方法、装置、计算机可读存储介质及电子设备,涉及数据通信技术领域。方法包括:实时检测端口队列是否丢包;若检测到端口队列丢包,则根据订阅周期读取端口流量数据;将端口流量数据封装后上报至采集控制平台,采集控制平台基于上报的端口流量数据对端口流量进行可视化实时呈现。通过在检测到端口队列丢包时,触发网络设备将端口流量数据上传至采集控制平台进行处理并显示,以最小化资源占用实现端口微突发流量的采集和可视化。

Description

端口流量采集方法、装置、存储介质及电子设备
本公开基于申请号为202210272397.4、申请日为2022年3月18日、发明名称为《端口流量采集方法、装置、存储介质及电子设备》的中国专利申请提出,并要求该中国专利申请的优先权,该中国专利申请的全部内容在此引入本公开作为参考。
技术领域
本公开涉及数据通信技术领域,尤其涉及一种端口流量采集方法、装置、计算机可读存储介质及电子设备。
背景技术
微突发(Microburst)是指端口在非常短的时间内收到非常多的突发数据,典型的微突发的持续时间通常在几十至几百毫秒之间,以至于瞬时突发速率达到平均速率的数倍,甚至超过端口带宽的现象。微突发现象对网络性能和业务体验产生严重影响,实时检测并规避微突发流量是网络运维面临的难题。
需要说明的是,在上述背景技术部分公开的信息仅用于加强对本公开的背景的理解,因此可以包括不构成对本领域普通技术人员已知的现有技术的信息。
发明内容
本公开提供一种端口流量采集方法、装置、计算机可读存储介质及电子设备。
本公开的其他特性和优点将通过下面的详细描述变得显然,或部分地通过本公开的实践而习得。
根据本公开的一个方面,提供了一种端口流量采集方法,应用于网络设备,包括:
实时检测端口队列是否丢包;
若检测到端口队列丢包,则根据订阅周期读取端口流量数据;
将所述端口流量数据封装后上报至采集控制平台,以便所述采集控制平台对所述端口流量数据进行实时处理。
在本公开的一个实施例中,还包括:
在确定端口队列丢包结束的情况下,停止根据订阅周期读取端口流量数据。
在本公开的一个实施例中,所述订阅周期为所述采集控制平台订阅端口队列丢包的流量采集周期。
在本公开的一个实施例中,所述实时检测端口队列是否丢包,包括:
实时读取端口的队列溢出丢包计数器的计数值;
当队列溢出丢包计数器的计数值大于零时,则确定端口队列丢包。
在本公开的一个实施例中,所述当确定端口队列丢包结束的情况下,停止根据订阅周期读取端口流量数据包括:
在所述队列溢出丢包计数器的计数值在一定时间内停止增加的情况下,将所述队列溢出丢包计数器的计数值清零,并停止根据订阅周期读取端口流量数据。
在本公开的一个实施例中,所述当确定端口队列丢包结束的情况下,停止根据订阅周期读取端口流量数据包括:
在所述采集控制平台根据所述端口流量数据确定端口队列没有发生丢包的情况下,向所述网络设备下发所述队列溢出丢包计数器的计数值清零配置,所述网络设备停止根据订阅周期读取端口流量数据。
在本公开的一个实施例中,还包括:
所述采集控制平台以图表和/或曲线形式对所述端口流量数据进行可视化实时呈现。
在本公开的一个实施例中,还包括:
对读取的一个端口的多个流量数据进行封装,并根据所述订阅周期将封装后的所述多个流量数据上报至所述采集控制平台。
根据本公开的另一个方面,还提供了一种端口流量采集装置,包括:
端口丢包检测模块,实时检测端口队列是否丢包;
端口流量读取模块,若检测到端口队列丢包,则根据订阅周期读取 端口流量数据;
流量数据处理模块,将所述端口流量数据封装后上报至采集控制平台,以便所述采集控制平台对所述端口流量数据进行实时处理。
根据本公开的另一个方面,还提供了一种电子设备,包括:处理器;以及存储器,用于存储所述处理器的可执行指令;其中,所述处理器配置为经由执行所述可执行指令来执行上述任意一项所述端口流量采集方法。
根据本公开的另一个方面,还提供了一种计算机可读存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时实现上述任意一项所述的端口流量采集方法。
应当理解的是,以上的一般描述和后文的细节描述仅是示例性和解释性的,并不能限制本公开。
附图说明
此处的附图被并入说明书中并构成本说明书的一部分,示出了符合本公开的实施例,并与说明书一起用于解释本公开的原理。显而易见地,下面描述中的附图仅仅是本公开的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1示出本公开实施例中一种端口流量采集方法流程图;
图2出本公开实施例中一种采集控制平台对所述端口流量数据可视化处理方法流程图;
图3出本公开实施例中一种端口流量采集结束方法流程图;
图4出本公开实施例中一种确定端口流量结束方法流程图;
图5示出本公开实施例中一种端口流量采集装置示意图;
图6示出本公开实施例中又一种端口流量采集方法流程图;
图7示出本公开实施例中又一种端口流量采集结束方法流程图;
图8示出本公开实施例中再一种端口流量采集结束方法流程图;
图9示出本公开实施例中一种端口流量采集系统示意图;
图10示出本公开实施例中一种端口流量的可视化实时呈现示意图; 和
图11示出本公开实施例中一种电子设备的结构框图。
具体实施方式
现在将参考附图更全面地描述示例实施方式。然而,示例实施方式能够以多种形式实施,且不应被理解为限于在此阐述的范例;相反,提供这些实施方式使得本公开将更加全面和完整,并将示例实施方式的构思全面地传达给本领域的技术人员。所描述的特征、结构或特性可以以任何合适的方式结合在一个或更多实施方式中。
此外,附图仅为本公开的示意性图解,并非一定是按比例绘制。图中相同的附图标记表示相同或类似的部分,因而将省略对它们的重复描述。附图中所示的一些方框图是功能实体,不一定必须与物理或逻辑上独立的实体相对应。可以采用软件形式来实现这些功能实体,或在一个或多个硬件模块或集成电路中实现这些功能实体,或在不同网络和/或处理器装置和/或微控制器装置中实现这些功能实体。
为了便于理解,下面首先对本公开涉及到的几个名词进行解释如下:
微突发(Microburst)是指端口在非常短的时间内收到非常多的突发数据。
网络遥测(telemetry)采用订阅或发布的推模式(PUSH)可以实现毫秒级的数据采集上送。
目前,可通过人工方式登录设备上查看端口丢包情况,或通过主控卡上的CPU对各端口丢包情况进行查询,但这种方法难以实现毫秒级的时间周期实时监控端口的丢包发生,并且在检测到端口丢包发生时,需要即刻向网管或采集控制平台上报,运维人员需要进一步了解端口微突发流量趋势。基于简单网络管理协议(SNMP)方式的流量统计曲线,在处理时会面临由于采集频率低,每个采集数据仅反映采样周期内的平均流量,不能反应更细时间粒度的实时网络流量情况的困境。而网络遥测(telemetry)采用订阅或发布的推模式(PUSH)可以实现毫秒级的数据采集上送,能够有效捕获端口微突发流量,但是持续进行毫秒级的数据 采集对资源消耗巨大。
因此,本公开实施例中提供了一种端口流量采集方法,实时检测端口队列是否丢包,若检测到端口队列丢包,则根据订阅周期读取端口流量数据,将端口流量数据封装后上报至采集控制平台,采集控制平台基于上报的端口流量数据对端口流量进行可视化实时呈现,成本低,且能够更清楚了解端口流量特征,精准判断端口微突发,至少在一定程度上克服相关技术中采集端口微突发流量精准度低、成本高的问题。下面结合附图及实施例对本示例实施方式进行详细说明。
首先,本公开实施例中提供了一种端口流量采集方法,该方法可以由任意具备计算处理能力的电子设备执行。
图1示出本公开实施例中一种端口流量采集方法流程图,如图1所示,本公开实施例中提供的端口流量采集方法,应用于网络设备,包括如下步骤:
S102,实时检测端口队列是否丢包。
在一个实施例中,网络设备基于硬件芯片以毫秒级实时读取端口的队列溢出丢包计数器的计数值。
在一个实施例中,硬件芯片可内置微处理器,提高读取端口的队列溢出丢包计数器的计数值的效率。
S104,当检测到端口队列丢包时,根据订阅周期读取端口流量数据。
需要说明的是,当某一端口因队列溢出发生丢包时,对应端口的队列溢出丢包计数器将对丢包数量进行计数,初始值一般为零,因此当队列溢出丢包计数器大于零,则根据订阅周期读取端口流量数据。
需要说明的是,订阅周期为采集控制平台订阅的端口队列丢包时的流量采集周期。
在一个实施例中,当队列溢出丢包计数器的计数值大于零时,硬件芯片根据订阅周期读取端口流量数据。
在一个实施例中,订阅周期设置为5毫秒至10毫秒,可以采集端口微突发流量、降低成本。
在一个实施例中,订阅周期设置为1毫秒至2毫秒,可以高效采集端 口微突发流量。
S106,将端口流量数据封装后上报至采集控制平台,以便采集控制平台对端口流量数据进行实时处理。
在一个实施例中,采集控制平台接收封装后的端口流量数据,并以图表或曲线形式对端口流量进行可视化实时呈现。
上述实施例中,能够在检测到端口队列丢包时,触发网络设备根据订阅周期向采集控制平台上报端口流量数据,采集控制平台基于上报的端口流量数据对端口流量进行显示,以最小化资源占用实现端口微突发流量的采集和可视化,将端口流量的实时检测和端口流量数据可视化呈现相结合,能够更清楚了解端口流量特征,精准判断端口微突发。
图2出本公开实施例中一种采集控制平台对端口流量数据可视化处理方法流程图,如图2所示,本公开实施例中提供的采集控制平台对端口流量数据可视化处理方法,包括如下步骤:
S202,硬件芯片将根据订阅周期读取的端口流量数据发送至设备处理器。
需要说明的是,设备处理器包括网络设备的主控板或线卡CPU。
S204,设备处理器对端口流量数据进行封装处理;
S206,设备处理器将封装后的端口流量数据上报至采集控制平台。
需要说明的是,设备处理器对端口流量数据进行telemetry封装,telemetry封装可以实现毫秒级的数据采集上送,能够有效捕获端口微突发流量。
在一个实施例中,设备处理器对一个或多个端口流量数据进行封装,根据订阅周期上报至采集控制平台,减少上报的频次,有效提高处理速率且降低成本。
S208,采集控制平台接收封装后的端口流量数据,对封装后的端口流量数据进行在线实时处理,并以图表或曲线形式对端口流量进行可视化实时呈现。
需要说明的是,采集控制平台接收封装后的端口流量数据,对封装后的端口流量数据进行在线实时处理,并进行可视化实时呈现,可视化呈现的延时时间应控制在1秒以内。
上述实施例中,硬件芯片根据订阅周期向采集控制平台上报端口流量数据,采集控制平台基于上报的端口流量数据对端口流量进行可视化实时呈现,以最小化资源占用实现端口流量的采集和可视化。
图3出本公开实施例中一种端口流量采集结束方法流程图,如图3所示,本公开实施例中提供的端口流量采集结束方法,包括如下步骤:
S302,采集控制平台订阅端口因队列溢出发生丢包时的流量采集周期;
S304,判断端口流量检测事件是否被触发。
在一个实施例中,网络设备基于硬件芯片实时读取端口队列溢出丢包计数器的计数情况,当某一端口队列溢出丢包计数器大于零时,则确定端口流量检测事件被触发。
S306,若是,根据订阅周期读取该端口的端口流量数据;
S308,将端口流量数据进行封装,将封装后的端口流量数据上报至采集控制平台。
在一个实施例中,硬件芯片根据订阅周期读取该端口的端口流量数据,上传至设备处理器,设备处理器对端口流量数据进行封装,将封装后的端口流量数据上报至采集控制平台。
S310,采集控制平台接收封装后的端口流量数据,对封装后的端口流量数据进行在线实时处理,并以图表或曲线形式对端口流量进行可视化实时呈现;
S312,当确定端口队列丢包结束的情况下,停止根据订阅周期读取端口流量数据。
在一个实施例中,当队列溢出丢包计数器的计数值在一定时间内停止增加的情况下,确定端口队列丢包结束,队列溢出丢包计数器的计数值清零,并停止根据订阅周期读取端口流量数据。
需要说明的是,硬件芯片判断队列溢出丢包计数器的计数值是否在一定时间内保持不变。若是,则将此端口队列溢出丢包计数器清零,同时停止对该端口进行流量采集。
需要说明的是,可以根据用户需求设置判断队列溢出丢包计数器的计数值是否变化的时间,一般可设置为200ms,即硬件芯片实时检测队 列溢出丢包计数器的计数值,当队列溢出丢包计数器的计数值在200ms内不增加时,则将此端口队列溢出丢包计数器清零,同时停止对该端口进行流量采集。
上述实施例中,将端口流量的实时检测和端口流量数据可视化呈现相结合,能够更清楚了解端口流量特征,精准判断端口微突发,且在确定端口队列丢包结束的情况下,停止根据订阅周期读取端口流量数据,可提高端口流量检测效率及降低成本。
图4出本公开实施例中一种确定端口流量结束方法流程图,如图4所示,本公开实施例中提供的确定端口流量结束方法,包括如下步骤:
S402,采集控制平台根据实时监控上报的端口流量数据确定端口队列没有发生丢包。
在一个实施例中,端口流量数据包括但不限于端口流量速率,本实施例以端口流量速率为例进行介绍。采集控制平台根据实时监控上报的端口流量数据,在一定时间内端口流量速率小于或等于80%,确定端口队列没有发生丢包。
需要说明的是,根据用户需求设置确定端口流量速率是否变化的时间,一般小于1秒,即采集控制平台根据实时监控上报的端口流量数据,在1秒内,端口流量速率小于或等于80%,确定端口队列没有发生丢包。
S404,向端口下发队列溢出丢包计数器清零的配置;
S406,当硬件芯片感知端口队列溢出丢包计数器为零,停止对该端口进行流量采集。
上述实施例中,在确定端口队列丢包结束的情况下,停止根据订阅周期读取端口流量数据,可提高端口流量检测效率及降低成本。
基于同一发明构思,本公开实施例中还提供了一种端口流量采集装置,如下面的实施例。由于该装置实施例解决问题的原理与上述方法实施例相似,因此该装置实施例的实施可以参见上述方法实施例的实施,重复之处不再赘述。
图5示出本公开实施例中一种端口流量采集装置示意图,如图5所示,该端口流量采集装置5包括:端口丢包检测模块501、端口流量读取 模块502及流量数据处理模块503;其中,端口丢包检测模块501连接端口流量读取模块502的输入端,端口流量读取模块502的输出端连接流量数据处理模块503的输入端。
端口丢包检测模块,实时检测端口队列是否丢包;
端口流量读取模块,若检测到端口队列丢包,则根据订阅周期读取端口流量数据;
流量数据处理模块,将所述端口流量数据封装后上报至采集控制平台,以便采集控制平台对所述端口流量数据进行实时处理。
上述实施例中,能够在检测到端口队列丢包时,触发网络设备根据订阅周期向采集控制平台上报端口流量数据,采集控制平台基于上报的端口流量数据对端口流量进行可视化实时呈现,将端口流量的实时检测和端口流量数据可视化呈现相结合,能够更清楚了解端口流量特征,精准判断端口微突发。
图6示出本公开实施例中又一种端口流量采集方法流程图,如图6所示,本公开实施例中提供的端口流量采集方法,应用于网络设备,包括如下步骤:
S602,硬件芯片实时读取网络设备各端口的队列溢出丢包计数器的计数值;
S604,当某一端口的队列溢出丢包计数器的计数值异常时,硬件芯片根据订阅周期读取端口流量数据。
需要说明的是,当某一端口因队列溢出发生丢包时,对应端口队列溢出丢包计数器将对丢包数量进行计数,此时队列溢出丢包计数器大于零,则判断该端口的队列溢出丢包计数器的计数数值异常。
需要说明的是,采集控制平台订阅网络设备上各端口丢包时的流量采集周期;订阅周期为采集控制平台订阅端口队列丢包时的流量采集周期。
S606,硬件芯片将读取的端口流量数据发送至设备处理器,以便设备处理器对端口流量数据进行封装处理。
在一个实施例中,设备处理器包括:网络设备的主控板或线卡CPU。
需要说明的是,设备处理器对端口流量数据进行telemetry封装。
需要说明的是,telemetry(网络遥测)采用订阅或发布的推模式采集上送数据,telemetry封装可以实现毫秒级的数据采集上送,能够有效捕获端口微突发流量。
S608,设备处理器将封装后的端口流量数据上报至采集控制平台。
在一个实施例中,设备处理器将封装后的端口流量数据实时上报至采集控制平台。
S610,采集控制平台接收封装后的端口流量数据,对封装后的端口流量数据进行在线实时处理,并以图表或曲线形式对端口流量进行可视化实时呈现。
上述实施例中,采集控制平台订阅端口因队列溢出发生丢包时的流量采集周期,网络设备基于硬件芯片实时读取端口队列溢出丢包计数器的计数情况,并触发端口流量采集上报条件,根据订阅周期向采集控制平台上报端口流量数据,采集控制平台基于上报的端口流量数据对端口流量进行可视化实时呈现,将端口流量的实时检测和端口流量数据可视化呈现相结合,能够更清楚了解端口流量特征,精准判断端口微突发。
图7示出本公开实施例中又一种端口流量采集结束方法流程图,如图7所示,本公开实施例中提供的端口流量采集结束方法,应用于网络设备,包括如下步骤S702至S714。
S702,采集控制平台订阅端口因队列溢出发生丢包时的流量采集周期。
S704,网络设备基于硬件芯片实时读取端口队列溢出丢包计数器的计数情况,判断端口流量检测事件是否被触发。
在一个实施例中,当某一端口队列溢出丢包计数器大于零时,则确定端口流量检测事件被触发。
S706,若是,硬件芯片根据订阅周期读取该端口的端口流量数据,并向设备处理器上报,否则继续重复此步骤。
S708,设备处理器对硬件芯片采集上报的端口流量数据进行封装,将封装后的端口流量数据上报至采集控制平台。
S710,采集控制平台接收封装后的端口流量数据,对封装后的端口 流量数据进行在线实时处理,并以图表或曲线形式对端口流量进行可视化实时呈现。
S712,硬件芯片判断队列溢出丢包计数器的计数值是否在一定时间内保持不变。
S714,若是,则将此端口队列溢出丢包计数器清零,同时停止对该端口进行流量采集;若否,则返回至S706。
上述实施例中,将端口流量的实时检测和端口流量数据可视化呈现相结合,能够更清楚了解端口流量特征,精准判断端口微突发,且在确定端口队列丢包结束的情况下,停止根据订阅周期读取端口流量数据,可提高端口流量检测效率及降低成本。
图8示出本公开实施例中再一种端口流量采集结束方法流程图,如图8所示,本公开实施例中提供的端口流量采集结束方法,应用于网络设备,包括如下步骤S802至S816。
S802,采集控制平台订阅端口因队列溢出发生丢包时的流量采集周期。
S804,网络设备基于硬件芯片实时读取端口队列溢出丢包计数器的计数情况,判断端口流量检测事件是否被触发。
在一个实施例中,当某一端口队列溢出丢包计数器大于零时,则确定端口流量检测事件被触发。
S806,若是,硬件芯片根据订阅周期读取该端口的端口流量数据,并向设备处理器上报。
S808,设备处理器对硬件芯片采集上报的端口流量数据进行封装,将封装后的端口流量数据上报至采集控制平台。
S810,采集控制平台接收封装后的端口流量数据,对封装后的端口流量数据进行在线实时处理,并以图表或曲线形式对端口流量进行可视化实时呈现。
S812,采集控制平台根据实时监控上报的端口流量数据判断端口队列没有发生丢包。
在一个实施例中,在一定时间内,端口流量速率小于或等于到80%,则判断该端口队列没有发生丢包,时间根据用户需求进行设置, 一般小于1秒。
S814,若是,则采集控制平台向端口下发队列溢出丢包计数器清零的配置。
S816,当硬件芯片感知端口队列溢出丢包计数器为零,停止对该端口进行流量采集。
上述实施例中,将端口流量的实时检测和端口流量数据可视化呈现相结合,能够更清楚了解端口流量特征,精准判断端口微突发,且在确定端口队列丢包结束的情况下,停止根据订阅周期读取端口流量数据,可提高端口流量检测效率及降低成本。
图9示出本公开实施例中一种端口流量采集系统示意图,如图9所示,本公开实施例中提供的端口流量采集系统,包括:网络设备90及采集控制平台91;网络设备90包括:若干队列溢出丢包计数器9000、硬件芯片9001、设备处理器9002、若干端口流量计数器9003。硬件芯片9001以毫秒级的间隔实时读取网络设备90各端口的队列溢出丢包计数器9000的计数情况;当某一端口因队列溢出发生丢包时,对应端口队列溢出丢包计数器9000将对丢包数量进行计数,此时队列溢出丢包计数器9000大于零,即刻触发硬件芯片9001开始根据订阅周期参数通过端口流量计数器9003读取端口流量数据,并向设备处理器9002上报;设备处理器9002对硬件芯片9001采集上报的端口流量数据进行telemetry封装,可按照订阅周期要求上报到采集控制平台91,采集控制平台91对上报的端口流量telemetry数据进行在线实时处理,并以图表或曲线形式对端口流量进行可视化实时呈现。
上述实施例中,采集控制平台91订阅端口因队列溢出发生丢包时的流量采集周期,网络设备基于硬件芯片9001实时读取端口队列溢出丢包计数器9000的计数情况,并触发端口流量采集上报条件,根据订阅周期向采集控制平台91上报端口流量数据,采集控制平台91基于上报的端口流量数据对端口流量进行可视化实时呈现,将端口流量的实时检测和端口流量数据可视化呈现相结合,能够更清楚了解端口流量特征,精准判断端口微突发。
图10示出本公开实施例中一种端口流量的可视化实时呈现示意图, 如图10所示,当某端口发生队列溢出时,通过实时检测队列溢出丢包计数器大于零,可以判断端口因微突发流量产生的瞬时拥塞。从流量曲线可以看出该端口的流量速率在95%以上。
在一个实施例中,网络用以在网络设备和服务器之间提供通信链路的介质,可以是有线网络,也可以是无线网络。
可选地,上述的无线网络或有线网络使用标准通信技术和/或协议。网络通常为因特网、但也可以是任何网络,包括但不限于局域网(Local Area Network,LAN)、城域网(Metropolitan Area Network,MAN)、广域网(Wide Area Network,WAN)、移动、有线或者无线网络、专用网络或者虚拟专用网络的任何组合)。在一些实施例中,使用包括超文本标记语言(Hyper Text Mark-up Language,HTML)、可扩展标记语言(Extensible MarkupLanguage,XML)等的技术和/或格式来代表通过网络交换的数据。此外还可以使用诸如安全套接字层(Secure Socket Layer,SSL)、传输层安全(Transport Layer Security,TLS)、虚拟专用网络(Virtual Private Network,VPN)、网际协议安全(Internet ProtocolSecurity,IPsec)等常规加密技术来加密所有或者一些链路。在另一些实施例中,还可以使用定制和/或专用数据通信技术取代或者补充上述数据通信技术。
可选地,不同的网络设备中安装的应用程序的客户端是相同的,或基于不同操作系统的同一类型应用程序的客户端。基于终端平台的不同,该应用程序的客户端的具体形态也可以不同,比如,该应用程序客户端可以是手机客户端、PC客户端等。
服务器可以是提供各种服务的服务器,例如对用户利用网络设备、、所进行操作的装置提供支持的后台管理服务器。后台管理服务器可以对接收到的请求等数据进行分析等处理,并将处理结果反馈给网络设备。
可选地,服务器可以是独立的物理服务器,也可以是多个物理服务器构成的服务器集群或者分布式系统,还可以是提供云服务、云数据库、云计算、云函数、云存储、网络服务、云通信、中间件服务、域名服务、安全服务、CDN(Content Delivery Network,内容分发网络)、以及大数据和人工智能平台等基础云计算服务的云服务器。网络终端以及 服务器可以通过有线或无线通信方式进行直接或间接地连接,本申请在此不做限制。
本领域技术人员可以知晓,网络设备、网络和服务器的数量仅仅是示意性的,根据实际需要,可以具有任意数目的网络设备、网络和服务器。本公开实施例对此不作限定。
所属技术领域的技术人员能够理解,本公开的各个方面可以实现为系统、方法或程序产品。因此,本公开的各个方面可以具体实现为以下形式,即:完全的硬件实施方式、完全的软件实施方式(包括固件、微代码等),或硬件和软件方面结合的实施方式,这里可以统称为“电路”、“模块”或“系统”。
下面参照图11来描述根据本公开的这种实施方式的电子设备1100。图11显示的电子设备1100仅仅是一个示例,不应对本公开实施例的功能和使用范围带来任何限制。
如图11所示,电子设备1100以通用计算设备的形式表现。电子设备1100的组件可以包括但不限于:上述至少一个处理单元1110、上述至少一个存储单元1120、连接不同系统组件(包括存储单元1120和处理单元1110)的总线1130。
其中,所述存储单元存储有程序代码,所述程序代码可以被所述处理单元1110执行,使得所述处理单元1110执行本说明书上述“示例性方法”部分中描述的根据本公开各种示例性实施方式的步骤。例如,所述处理单元1110可以执行上述方法实施例的如下步骤:实时读取端口的队列溢出丢包计数器的计数值;当队列溢出丢包计数器的计数值大于零时,根据订阅周期读取端口流量数据;将端口流量数据封装后上报至采集控制平台,以便采集控制平台对端口流量数据进行实时处理。
所述处理单元1110可以执行上述方法实施例的如下步骤:
采集控制平台订阅端口因队列溢出发生丢包时的流量采集周期;网络设备基于硬件芯片实时读取端口队列溢出丢包计数器的计数情况,判断端口流量检测事件是否被触发;若是,硬件芯片根据订阅周期读取该端口的端口流量数据,并向设备处理器上报;设备处理器对硬件芯片采集上报的端口流量数据进行封装,将封装后的端口流量数据上报至采集 控制平台;采集控制平台接收封装后的端口流量数据,对封装后的端口流量数据进行在线实时处理,并以图表或曲线形式对端口流量进行可视化实时呈现;当确定端口队列丢包结束的情况下,队列溢出丢包计数器的计数值清零,并停止根据订阅周期读取端口流量数据。
所述处理单元1110可以执行上述方法实施例的如下步骤:
当队列溢出丢包计数器的计数值在一定时间内停止增加的情况下,队列溢出丢包计数器的计数值清零,并停止根据订阅周期读取端口流量数据。
所述处理单元1110可以执行上述方法实施例的如下步骤:
采集控制平台根据实时监控上报的端口流量数据判断突发流量是否结束;若是,则向端口下发队列溢出丢包计数器清零的配置;当硬件芯片感知端口队列溢出丢包计数器为零,停止对该端口进行流量采集。
所述处理单元1110可以执行上述方法实施例的如下步骤:
硬件芯片以毫秒级的间隔实时读取网络设备各端口的队列溢出丢包计数器的计数情况;当某一端口因队列溢出发生丢包时,对应端口队列溢出丢包计数器将对丢包数量进行计数,此时队列溢出丢包计数器大于零,即刻触发硬件芯片开始根据订阅周期参数读取端口流量数据,并向设备处理器上报;设备处理器对硬件芯片采集上报的端口流量数据进行telemetry封装,可按照订阅周期要求上报到采集控制平台,采集控制平台对上报的端口流量telemetry数据进行在线实时处理,并以图表或曲线形式对端口流量进行可视化实时呈现。
存储单元1120可以包括易失性存储单元形式的可读介质,例如随机存取存储单元(RAM)11201和/或高速缓存存储单元11202,还可以进一步包括只读存储单元(ROM)11203。
存储单元1120还可以包括具有一组(至少一个)程序模块11205的程序/实用工具11204,这样的程序模块11205包括但不限于:操作系统、一个或者多个应用程序、其它程序模块以及程序数据,这些示例中的每一个或某种组合中可能包括网络环境的实现。
总线1130可以为表示几类总线结构中的一种或多种,包括存储单元总线或者存储单元控制器、外围总线、图形加速端口、处理单元或者使 用多种总线结构中的任意总线结构的局域总线。
电子设备1100也可以与一个或多个外部设备1140(例如键盘、指向设备、蓝牙设备等)通信,还可与一个或者多个使得用户能与该电子设备1100交互的设备通信,和/或与使得该电子设备1100能与一个或多个其它计算设备进行通信的任何设备(例如路由器、调制解调器等等)通信。这种通信可以通过输入/输出(I/O)接口1150进行。并且,电子设备1100还可以通过网络适配器1160与一个或者多个网络(例如局域网(LAN),广域网(WAN)和/或公共网络,例如因特网)通信。如图所示,网络适配器1160通过总线1130与电子设备1100的其它模块通信。应当明白,尽管图中未示出,可以结合电子设备1100使用其它硬件和/或软件模块,包括但不限于:微代码、设备驱动器、冗余处理单元、外部磁盘驱动阵列、RAID系统、磁带驱动器以及数据备份存储系统等。
通过以上的实施方式的描述,本领域的技术人员易于理解,这里描述的示例实施方式可以通过软件实现,也可以通过软件结合必要的硬件的方式来实现。因此,根据本公开实施方式的技术方案可以以软件产品的形式体现出来,该软件产品可以存储在一个非易失性存储介质(可以是CD-ROM,U盘,移动硬盘等)中或网络上,包括若干指令以使得一台计算设备(可以是个人计算机、服务器、终端装置、或者网络设备等)执行根据本公开实施方式的方法。
在本公开的示例性实施例中,还提供了一种计算机可读存储介质,该计算机可读存储介质可以是可读信号介质或者可读存储介质。其上存储有能够实现本公开上述方法的程序产品。在一些可能的实施方式中,本公开的各个方面还可以实现为一种程序产品的形式,其包括程序代码,当所述程序产品在终端设备上运行时,所述程序代码用于使所述终端设备执行本说明书上述“示例性方法”部分中描述的根据本公开各种示例性实施方式的步骤。
本公开中的计算机可读存储介质的更具体的例子可以包括但不限于:具有一个或多个导线的电连接、便携式计算机磁盘、硬盘、随机访问存储器(RAM)、只读存储器(ROM)、可擦式可编程只读存储器(EPROM或闪存)、光纤、便携式紧凑磁盘只读存储器(CD-ROM)、 光存储器件、磁存储器件、或者上述的任意合适的组合。
在本公开中,计算机可读存储介质可以包括在基带中或者作为载波一部分传播的数据信号,其中承载了可读程序代码。这种传播的数据信号可以采用多种形式,包括但不限于电磁信号、光信号或上述的任意合适的组合。可读信号介质还可以是可读存储介质以外的任何可读介质,该可读介质可以发送、传播或者传输用于由指令执行系统、装置或者器件使用或者与其结合使用的程序。
可选地,计算机可读存储介质上包含的程序代码可以用任何适当的介质传输,包括但不限于无线、有线、光缆、RF等等,或者上述的任意合适的组合。
在具体实施时,可以以一种或多种程序设计语言的任意组合来编写用于执行本公开操作的程序代码,所述程序设计语言包括面向对象的程序设计语言—诸如Java、C++等,还包括常规的过程式程序设计语言—诸如“C”语言或类似的程序设计语言。程序代码可以完全地在用户计算设备上执行、部分地在用户设备上执行、作为一个独立的软件包执行、部分在用户计算设备上部分在远程计算设备上执行、或者完全在远程计算设备或服务器上执行。在涉及远程计算设备的情形中,远程计算设备可以通过任意种类的网络,包括局域网(LAN)或广域网(WAN),连接到用户计算设备,或者,可以连接到外部计算设备(例如利用因特网服务提供商来通过因特网连接)。
应当注意,尽管在上文详细描述中提及了用于动作执行的设备的若干模块或者单元,但是这种划分并非强制性的。实际上,根据本公开的实施方式,上文描述的两个或更多模块或者单元的特征和功能可以在一个模块或者单元中具体化。反之,上文描述的一个模块或者单元的特征和功能可以进一步划分为由多个模块或者单元来具体化。
此外,尽管在附图中以特定顺序描述了本公开中方法的各个步骤,但是,这并非要求或者暗示必须按照该特定顺序来执行这些步骤,或是必须执行全部所示的步骤才能实现期望的结果。附加的或备选的,可以省略某些步骤,将多个步骤合并为一个步骤执行,以及/或者将一个步骤分解为多个步骤执行等。
通过以上实施方式的描述,本领域的技术人员易于理解,这里描述的示例实施方式可以通过软件实现,也可以通过软件结合必要的硬件的方式来实现。因此,根据本公开实施方式的技术方案可以以软件产品的形式体现出来,该软件产品可以存储在一个非易失性存储介质(可以是CD-ROM,U盘,移动硬盘等)中或网络上,包括若干指令以使得一台计算设备(可以是个人计算机、服务器、移动终端、或者网络设备等)执行根据本公开实施方式的方法。
本领域技术人员在考虑说明书及实践这里公开的发明后,将容易想到本公开的其它实施方案。本公开旨在涵盖本公开的任何变型、用途或者适应性变化,这些变型、用途或者适应性变化遵循本公开的一般性原理并包括本公开未公开的本技术领域中的公知常识或惯用技术手段。说明书和实施例仅被视为示例性的,本公开的真正范围和精神由所附的权利要求指出。

Claims (11)

  1. 一种端口流量采集方法,其中,应用于网络设备,包括:
    实时检测端口队列是否丢包;
    若检测到端口队列丢包,则根据订阅周期读取端口流量数据;
    将所述端口流量数据封装后上报至采集控制平台,以便所述采集控制平台对所述端口流量数据进行实时处理。
  2. 根据权利要求1所述的端口流量采集方法,其中,还包括:
    在确定端口队列丢包结束的情况下,停止根据订阅周期读取端口流量数据。
  3. 根据权利要求1所述的端口流量采集方法,其中,
    所述订阅周期为所述采集控制平台订阅端口队列丢包的流量采集周期。
  4. 根据权利要求1所述的端口流量采集方法,其中,所述实时检测端口队列是否丢包,包括:
    实时读取端口的队列溢出丢包计数器的计数值;
    当队列溢出丢包计数器的计数值大于零时,则确定端口队列丢包。
  5. 根据权利要求2所述的端口流量采集方法,其中,所述在确定端口队列丢包结束的情况下,停止根据订阅周期读取端口流量数据包括:
    在所述队列溢出丢包计数器的计数值在一定时间内停止增加的情况下,将所述队列溢出丢包计数器的计数值清零,并停止根据订阅周期读取端口流量数据。
  6. 根据权利要求1所述的端口流量采集方法,其中,所述在确定端口队列丢包结束的情况下,停止根据订阅周期读取端口流量数据包括:
    在所述采集控制平台根据所述端口流量数据确定端口队列没有发生丢包的情况下,向所述网络设备下发所述队列溢出丢包计数器的计数值清零配置,所述网络设备停止根据订阅周期读取端口流量数据。
  7. 根据权利要求1所述的端口流量采集方法,其中,还包括:
    所述采集控制平台以图表和/或曲线形式对所述端口流量数据进行可视化实时呈现。
  8. 根据权利要求1所述的端口流量采集方法,其中,还包括:
    对读取的一个端口的多个流量数据进行封装,并根据所述订阅周期将封装后的所述多个流量数据批量上报至所述采集控制平台。
  9. 一种端口流量采集装置,其中,包括:
    端口丢包检测模块,实时检测端口队列是否丢包;
    端口流量读取模块,若检测到端口队列丢包,则根据订阅周期读取端口流量数据;
    流量数据处理模块,将所述端口流量数据封装后上报至采集控制平台,以便所述采集控制平台对所述端口流量数据进行实时处理。
  10. 一种电子设备,其中,包括:
    处理器;以及
    存储器,用于存储所述处理器的可执行指令;
    其中,所述处理器配置为经由执行所述可执行指令来执行权利要求1~8中任意一项所述端口流量采集方法。
  11. 一种计算机可读存储介质,其上存储有计算机程序,其中,所述计算机程序被处理器执行时实现权利要求1~8中任意一项所述的端口流量采集方法。
PCT/CN2022/130639 2022-03-18 2022-11-08 端口流量采集方法、装置、存储介质及电子设备 WO2023173766A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202210272397.4 2022-03-18
CN202210272397.4A CN116800644A (zh) 2022-03-18 2022-03-18 端口流量采集方法、装置、存储介质及电子设备

Publications (2)

Publication Number Publication Date
WO2023173766A1 true WO2023173766A1 (zh) 2023-09-21
WO2023173766A9 WO2023173766A9 (zh) 2024-03-28

Family

ID=88022126

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/130639 WO2023173766A1 (zh) 2022-03-18 2022-11-08 端口流量采集方法、装置、存储介质及电子设备

Country Status (2)

Country Link
CN (1) CN116800644A (zh)
WO (1) WO2023173766A1 (zh)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060092845A1 (en) * 2004-10-29 2006-05-04 Broadcom Corporation Service aware flow control
CN105791008A (zh) * 2016-03-02 2016-07-20 华为技术有限公司 确定丢包位置和原因的方法和装置
CN114050983A (zh) * 2021-10-26 2022-02-15 中国电信股份有限公司 流量自适应采集方法及装置、存储介质及电子设备
CN114124643A (zh) * 2021-11-10 2022-03-01 中盈优创资讯科技有限公司 一种基于PaaS的网络设备流量采集方法及装置

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060092845A1 (en) * 2004-10-29 2006-05-04 Broadcom Corporation Service aware flow control
CN105791008A (zh) * 2016-03-02 2016-07-20 华为技术有限公司 确定丢包位置和原因的方法和装置
CN114050983A (zh) * 2021-10-26 2022-02-15 中国电信股份有限公司 流量自适应采集方法及装置、存储介质及电子设备
CN114124643A (zh) * 2021-11-10 2022-03-01 中盈优创资讯科技有限公司 一种基于PaaS的网络设备流量采集方法及装置

Also Published As

Publication number Publication date
CN116800644A (zh) 2023-09-22
WO2023173766A9 (zh) 2024-03-28

Similar Documents

Publication Publication Date Title
US20210042270A1 (en) Alarm log compression method, apparatus, and system, and storage medium
US8447851B1 (en) System for monitoring elastic cloud-based computing systems as a service
US8135827B2 (en) Distributed capture and aggregation of dynamic application usage information
CN107704387B (zh) 用于系统预警的方法、装置、电子设备及计算机可读介质
CN114050983B (zh) 流量自适应采集方法及装置、存储介质及电子设备
CN114039900A (zh) 一种高效网络数据包协议分析方法和系统
CN114338484B (zh) 光网络性能数据融合采集方法、装置、设备和存储介质
WO2023173766A1 (zh) 端口流量采集方法、装置、存储介质及电子设备
US20150120903A1 (en) System for monitoring XMPP-based communication services
KR20210131269A (ko) 교통량 모니터링 시스템의 테스트 방법, 장치 및 기기
CN115080363B (zh) 一种基于业务日志的系统容量评估方法及装置
WO2015070666A1 (zh) 一种调整目标系统性能的方法、设备及系统
CN117370053A (zh) 一种面向信息系统业务运行全景监测方法及系统
US10284435B2 (en) Method to visualize end user response time
CN114189480B (zh) 一种流量采样方法、装置、电子设备及介质
CN115202973A (zh) 应用运行状态的确定方法、装置、电子设备和介质
CN110852537A (zh) 服务质量检测方法和装置
CN113079055A (zh) 一种agv运行数据的动态采集方法和装置
CN113794719B (zh) 一种基于Elasticsearch技术网络异常流量分析方法、装置和电子设备
CN110995486A (zh) 一种基于物联网的智能硬件设备监控系统
CN103327071A (zh) 云计算网络智能监控模型数据处理分散分载方法及其系统
CN114697319B (zh) 一种公有云的租户业务管理方法及装置
CN117395135A (zh) 一种基于Spring Boot框架的服务器监控方法及系统
CN110995839B (zh) 广告系统性能的分析方法、装置和计算机存储介质
CN115242667A (zh) 5g云边端结合的数采分析系统及方法

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 22931779

Country of ref document: EP

Kind code of ref document: A1