WO2022001917A1 - 一种数据流统计方法、设备及存储介质 - Google Patents
一种数据流统计方法、设备及存储介质 Download PDFInfo
- Publication number
- WO2022001917A1 WO2022001917A1 PCT/CN2021/102624 CN2021102624W WO2022001917A1 WO 2022001917 A1 WO2022001917 A1 WO 2022001917A1 CN 2021102624 W CN2021102624 W CN 2021102624W WO 2022001917 A1 WO2022001917 A1 WO 2022001917A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- statistical
- target data
- data stream
- storage component
- record
- Prior art date
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/24—Querying
- G06F16/245—Query processing
- G06F16/2455—Query execution
- G06F16/24568—Data stream processing; Continuous queries
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L43/00—Arrangements for monitoring or testing data switching networks
- H04L43/08—Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L43/00—Arrangements for monitoring or testing data switching networks
- H04L43/08—Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
- H04L43/0876—Network utilisation, e.g. volume of load or congestion level
- H04L43/0894—Packet rate
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L43/00—Arrangements for monitoring or testing data switching networks
- H04L43/10—Active monitoring, e.g. heartbeat, ping or trace-route
- H04L43/106—Active monitoring, e.g. heartbeat, ping or trace-route using time related information in packets, e.g. by adding timestamps
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L43/00—Arrangements for monitoring or testing data switching networks
- H04L43/02—Capturing of monitoring data
- H04L43/026—Capturing of monitoring data using flow identification
Definitions
- the present application relates to the field of network technologies, and in particular, to a data flow statistics method, device and storage medium.
- Various aspects of the present application provide a data flow statistics method, device and storage medium, so as to improve the statistical performance of data flow.
- the embodiment of the present application provides a data flow statistics method, including:
- the flow of the target data stream satisfies the first preset condition, maintain a first statistical record corresponding to the target data stream in the first storage component, so as to perform a statistical analysis on the target data stream based on the first statistical record statistics;
- the access speed of the first storage component is higher than that of the second storage component.
- Embodiments of the present application further provide a computing device, including a first storage component, a second storage component, and a processor, where the processor is coupled to the first storage component and the second storage component, and the first storage component The access speed of the component is higher than that of the second storage component;
- the processor is configured to monitor the flow of the target data flow; if the flow of the target data flow satisfies the first preset condition, maintain a first statistical record corresponding to the target data flow in the first storage component, to Perform statistics on the target data stream based on the first statistical record; update a second statistical record corresponding to the target data stream according to the first statistical record, where the second statistical record is configured in the second storage component;
- the first storage component configured to store the first statistical record corresponding to the target data stream
- the second storage component is configured to store the second statistical record corresponding to the target data stream.
- Embodiments of the present application further provide a computer-readable storage medium storing computer instructions, and when the computer instructions are executed by one or more processors, cause the one or more processors to execute the foregoing data flow statistics method.
- the first storage component and the second storage component are used to perform data flow statistics, and for data flows whose traffic meets preset conditions, the statistical work of such data flows can be adaptively moved to the first storage component in execution.
- part of the processing pressure of the second storage component can be relieved;
- the high-speed access capability of the first storage component can be fully utilized, so that such data flows can be counted more quickly and accurately.
- the high-speed access capability of the first storage component can be fully utilized, thereby effectively reducing the number of accesses to the second storage component during the data flow statistics process, thereby greatly improving the data flow statistics performance.
- FIG. 1 is a schematic structural diagram of a computing device according to an exemplary embodiment of the present application
- FIG. 2 is a schematic logical diagram of a data flow statistics solution provided by an exemplary embodiment of the present application
- FIG. 3 is a schematic diagram of a logic for adaptively selecting statistics on a target data stream by using a first storage component or a second storage component according to an exemplary embodiment of the present application;
- FIG. 4 is a schematic flowchart of a data flow statistics method provided by an exemplary embodiment of the present application.
- the first storage component and the second storage component are used to perform data flow statistics. Dynamically move to the first storage component for execution. In this way, on the one hand, part of the processing pressure of the second storage component can be relieved; on the other hand, the high-speed access capability of the first storage component can be fully utilized, so that such data flows can be counted more quickly and accurately. Accordingly, in this embodiment, the high-speed access capability of the first storage component can be fully utilized, thereby effectively reducing the number of accesses to the second storage component during the data flow statistics process, thereby greatly improving the data flow statistics performance.
- FIG. 1 is a schematic structural diagram of a computing device according to an exemplary embodiment of the present application.
- FIG. 2 is a schematic logical diagram of a data flow statistics solution provided by an exemplary embodiment of the present application.
- the computing device includes: a first storage component 20 , a second storage component 30 and a processor 10 , and the processor 10 is coupled with the first storage component 20 and the second storage component 30 .
- the computing device provided in this embodiment can be applied to various scenarios where statistics on data streams are required. For example, application scenarios such as traffic monitoring, network billing, access control, network security monitoring and prevention, and network resource optimization and construction.
- application scenarios such as traffic monitoring, network billing, access control, network security monitoring and prevention, and network resource optimization and construction.
- the computing device provided in this embodiment can be deployed in various gateway products such as network cards, routers, and switches to provide a data flow statistics function. Of course, this embodiment is not limited to this.
- the access speed of the first storage component 20 is higher than the access speed of the second storage component 30 .
- the first storage component 20 can use an internal storage component, such as a memory, cache or hard disk, etc.
- the second storage component 30 can use an external storage component, such as DDR, etc.
- the internal storage components and external storage components here are defined from the dimension of storage speed, not from the dimension of physical structure. From the perspective of physical structure, both the internal storage component and the external storage component may be located inside the computing device, or both may be located outside the computing device, or the internal storage component may be located inside the computing device and the external storage component may be located outside the computing device, and so on.
- the component forms of the first storage component 20 and the second storage component 30 in this embodiment are not limited to this, and the two access components are only distinguished from the access speed.
- the first storage component 20 is used to assist the second storage component 30 to perform statistics on the data flow, which can effectively improve the statistical efficiency and accuracy of the data flow.
- the function of the processor 10 can be realized based on an FPGA (field programmable gate array, field programmable gate array).
- the second storage component 30 can be a DDR (Double Data Rate, Double-rate synchronous dynamic random access memory)
- the first storage component 20 may be RAM (random access memory, random access memory).
- this embodiment is not limited to this, and the functions of the processor 10 can also be implemented based on technologies such as a single-chip microcomputer, a CPU, and the like.
- the first storage component 20 can support the parallel processing function, that is, the processor 10 can initiate parallel access operations to the first storage component 20, so the access speed is higher; In terms of the access bandwidth and access form of the storage component 30, the access speed of the processor 10 to the second storage component 30 is relatively slow.
- the data flow can be counted based on the computing device. Since the statistical schemes for different data streams are similar, for ease of description, the target data stream will be used as an example to describe the statistical scheme, but it should be understood that the statistical scheme provided in this embodiment is applicable to the statistics required by the computing device. All data streams.
- the processor 10 can monitor the traffic of the target data stream; if the traffic of the target data stream satisfies the first preset condition, then maintain the first statistical record corresponding to the target data stream in the first storage component 20, so as to compare the data based on the first statistical record. The target data flow is counted.
- the first statistical record includes but is not limited to statistical items such as the number of forwarded packets pass-packets, the number of forwarded bytes pass-bytes, the number of dropped packets drop-packets, the number of dropped bytes drop-bytes and so on.
- the processor 10 when any one of the statistical items changes, the statistical record needs to be updated once. For example, in the process of forwarding the target data flow by the gateway device, each time a data packet is forwarded, the processor 10 needs to access the statistical record corresponding to the target data flow once, and analyze the number of forwarded packets in the statistical record under the statistical item of the number of forwarded packets. Statistical values are accumulated.
- a first preset condition may be preconfigured, and the first preset condition may be used as an identification condition for a data flow of a specific type. Therefore, based on the first preset condition, a specific type of data flow can be identified, and statistics of the specific type of data flow can be performed in the first storage component 20 .
- the processor 10 may maintain the first statistics record corresponding to the target data stream in the first storage component 20, so as to use the first storage component 20 to perform statistics on the target data stream.
- the first storage component 20 can support the parallel processing function. Therefore, the processor 10 can perform parallel access to the first statistical records in the first storage component 20, and update the first statistical records in a timely and accurate manner. This can effectively improve the statistical efficiency and accuracy of the target data stream, and avoid the problem of missing or misremembered.
- a first statistics table may be configured in the first storage component 20, and the first statistics table may include several statistics records.
- the processor 10 can dynamically increase or decrease the statistical records in the first statistical table. Therefore, the processor 10 can preferentially configure the aforementioned statistical records of a specific type of data flow into the first statistical table to preferentially utilize the first storage component. 20 Make statistics on a specific class of data flow.
- statistical records corresponding to all data streams may be stored in the second storage component 30, which may include second statistical records corresponding to the target data streams. Based on this, the processor 10 can update the second statistical record in the second storage component 30 according to the first statistical record in the first storage component 20 .
- the processor 10 in the process of collecting statistics on the target data stream based on the first statistical record, the processor 10 does not need to access the second statistical record in the second storage component 30, which can load a part of the second storage component 30 The data is offloaded to the first storage component 20 ; and the first storage component 20 can update the statistical result of the target data stream to the second storage component 30 . In this way, the number of accesses to the second storage component 30 can be greatly reduced in the process of collecting statistics on the target data stream.
- the processor 10 may perform 50 accesses to the first storage component 20 to update the pass-vols in the first statistical record to 50, and after that, the The second statistical record is updated according to the first statistical record. During this process, the processor 10 accesses the first storage component 20 50 times, and only accesses the second storage component 30 once.
- the first storage component 20 and the second storage component 30 are used to perform data flow statistics, and for data flows whose flow meets preset conditions, the statistical work of such data flows can be dynamically moved to the first storage Component 20 executes.
- part of the processing pressure of the second storage component 30 can be unloaded; on the other hand, the high-speed access capability of the first storage component 20 can be fully utilized, so that such data flows can be counted more quickly and accurately.
- the high-speed access capability of the first storage component 20 can be fully utilized, thereby effectively reducing the number of accesses to the second storage component 30 during the data flow statistics process, thereby greatly improving the data flow statistics performance.
- FIG. 3 is a schematic diagram of a logic for adaptively selecting statistics on a target data stream by using the first storage component 20 or the second storage component 30 according to an exemplary embodiment of the present application.
- the storage space of the first storage component 20 is limited, and therefore, the statistical threshold under each statistical item in the first statistical record is relatively low.
- the statistical threshold under the pass-packets statistic may only reach 1000.
- the processor 10 may update the second statistical record corresponding to the target data stream according to the first statistical record when the first statistical record overflows.
- the overflow may mean that the statistic value under any statistic item reaches the statistic threshold under the statistic item.
- the statistical thresholds under each statistical item can be set as required.
- the execution timing of updating the second statistical record according to the first statistical record may be various.
- the operation of updating the second statistical record according to the first statistical record can also be performed periodically or when the threshold of the number of accesses to the first statistical record is reached. The present embodiment is not limited to this.
- the processor 10 may accumulate each statistical value contained in the first statistical record to the corresponding statistical value in the second statistical record; The value is cleared to zero, and the statistics of the target data stream are continued based on the first statistical record.
- the processor 10 may transfer the statistical results of the statistics on the target data stream by the first storage component 20 to the second storage component 30 in stages, so as to ensure that the first storage component 20 can perform the statistics on the target data stream.
- Accurate statistics of data streams can avoid problems such as missing or wrong records due to the limitation of the storage space of the first storage component 20, and can be used for the next stage to continue to use the first storage component 20 to perform statistics on target data streams. Storage space basics.
- the processor 10 may adopt various implementation manners to determine whether the traffic of the target data stream satisfies the first preset condition.
- the processor 10 may calculate the forwarding rate of the target data stream according to the traffic of the target data stream; if the forwarding rate exceeds the first threshold, it is determined that the traffic of the target data stream satisfies the first preset condition.
- the first preset condition is configured such that the forwarding rate exceeds the first threshold. Based on this, the processor 10 can identify a specific type of data flow whose forwarding rate exceeds the first threshold from the plurality of data flows required to be counted.
- the processor 10 may maintain a record content for the target data stream, and the record content includes the timestamp and the accumulated forwarding amount under the timestamp;
- the interval or cumulative forwarding amount increment is used as a trigger condition to update the record content.
- the recorded content may be represented as (timestamp, packets).
- the processor 10 may obtain the cumulative forwarding amount from the recorded content corresponding to the target data stream, as the traffic of the target data stream.
- the processor 10 can set a number of time stamps within the time period in which the target data stream is processed, and when any time stamp is reached, according to the time stamp and the time stamp under the time stamp Accumulate the forwarding amount and update the record content corresponding to the target data stream.
- the record content corresponding to the target data stream may include the last time stamp before the current time and the accumulated forwarding amount under the time stamp.
- the recorded content may also include other time stamps and cumulative forwarding amounts under the time stamps, which are not limited here.
- the processor 10 may increase the cumulative forwarding amount to reach the preset increment when the increment of the cumulative forwarding amount corresponding to the target data stream reaches the preset increment threshold
- the time of the threshold is used as a time stamp, and the record content corresponding to the target data stream is updated according to the time stamp and the accumulated forwarding amount under the time stamp.
- the processor 10 can calculate the forwarding rate of the target data stream according to the current timestamp and the accumulated forwarding amount under the current timestamp, and the timestamp in the recorded content and the accumulated forwarding amount under the timestamp.
- the operation of calculating the forwarding rate of the target data stream can be performed.
- the current timestamp can be the preset timestamp interval or the cumulative forwarding amount increment. moment.
- the timing for calculating the forwarding rate of the target data stream may be the 200th ms (where the preset time stamp interval is 100 ms), and the time stamp at this time is 200ms, the cumulative forwarding amount is 180K.
- the record content of the target data stream can also be updated according to the current timestamp and the accumulated forwarding amount under the current timestamp.
- the timing for calculating the forwarding rate of the target data stream can also be used as the timing for judging whether the traffic of the target data stream satisfies the first preset condition, that is, as the timing for determining whether to count the target data stream in the internal processor 10. judgment time.
- the execution timing of each operation may not be exactly the same, and this embodiment is not limited to this.
- a statistic item may be added to the statistic record to carry the aforementioned record content.
- the record content corresponding to the target data stream can be configured in the first statistical record or in the second statistical record.
- the recorded content can also be arranged in a storage location accessible by other processors 10 without necessarily being arranged in the statistical recording, which is not limited here.
- the first storage component 20 may also be determined whether to use the first storage component according to other indicators such as the ratio of the target data stream to the network bandwidth and other indicators 20. Perform statistics on the target data stream, which is not limited in this embodiment.
- the processor 10 may also monitor the forwarding request for the target data stream. For example, the processor 10 may listen to the interface in the gateway device for receiving the forwarding request to listen for the forwarding request for the target data stream.
- the processor 10 may query the first statistical table in the first storage component 20 .
- the first statistical table is not full and the first statistical table does not contain a statistical record corresponding to the target data stream, a statistical record corresponding to the target data stream is created in the first statistical table, and based on the statistical record created in the first statistical table Statistical records, statistics on the target data stream;
- the first statistical table If the first statistical table is full, create a statistical record corresponding to the target data stream in the second statistical table in the second storage component 30; and perform statistics on the target data stream based on the statistical record created in the second statistical table .
- the processor 10 when a forwarding request for the target data stream is monitored, the processor 10 preferentially creates a statistical record for the target data stream in the first storage component 20 .
- the processor 10 can store in the second storage A second statistical table in component 30 creates statistical records for the target data stream.
- the first creation position of the statistical record corresponding to the target data stream is not necessarily the processing position of the statistical work, but the processor 10 can dynamically adjust the processing position of the statistical work according to the flow change of the target data stream. That is, the processor 10 can dynamically select to use the first storage component 20 or the second storage component 30 to collect statistics on the target data flow according to the flow change of the target data flow.
- the processor 10 can determine whether the traffic of the target data stream satisfies the first preset condition by monitoring the traffic of the target data stream.
- the processor 10 may query the first statistical table in the first storage component 20; if the target data stream corresponding to the target data stream is queried in the first statistical table If the statistic record corresponding to the target data stream is not queried in the first statistic table, the first statistic record is created in the first statistic table.
- the statistical record corresponding to the target data stream is queried in the first statistical table, which indicates that the processor 10 used the first storage component 20 to perform statistics on the target data stream.
- the processor 10 can keep using the The first storage component 20 collects statistics on the target data stream; but the statistics record corresponding to the target data stream is not queried in the first statistics table, which means that the processor 10 used the second storage component 30 to perform statistics on the target data stream before.
- the processor 10 may stop using the second storage component 30 to perform statistics, and switch to using the first storage component 20 to perform statistics on the target data stream.
- the processor 10 may determine whether the first statistical table is full. If it is not full, a first statistical record can be created in the first statistical table. If the first statistical table is full, determine the forwarding rate corresponding to each data flow in the first statistical table; select the target statistical record corresponding to a data flow whose forwarding rate is lower than the second threshold; delete the target statistics from the first statistical table record, and accumulate the target statistical record to the statistical record corresponding to the selected data stream in the second storage component 30; create a first statistical record in the first statistical table.
- the process of determining the forwarding rate corresponding to each data stream in the first statistical table may refer to the description in the foregoing embodiment, and the process of accumulating the target statistical record to the statistical record corresponding to the selected data stream in the second storage component 30 is also Reference may be made to the process of updating the second statistical record according to the first statistical record in the foregoing embodiment, which will not be repeated here.
- the processor 10 may perform statistics on the target data stream based on the first statistical record. Accordingly, if the traffic of the target data stream satisfies the first preset condition, the processor 10 can use the first storage component 20 to perform statistics on the target data stream, so as to offload the processing pressure of the second storage component 30 and improve the accuracy of the target data stream. statistical efficiency.
- the processor 10 may determine whether the traffic of the target data stream satisfies the second preset condition; if the traffic of the target data stream satisfies the second preset condition If the conditions are set, the processor 10 can query the first statistical table in the first storage component 20; if the first statistical record corresponding to the target data stream is found in the first statistical table, the second statistical record is updated according to the first statistical record record, and stop collecting statistics on the target data based on the first statistical record; collect statistics on the target data stream based on the second statistical record, and continue to perform the operation of judging whether the traffic of the target data stream satisfies the first preset condition.
- the first statistical record corresponding to the target data stream is queried in the first statistical table, which indicates that the processor 10 used the first storage component 20 to perform statistics on the target data stream.
- the processor 10 It is possible to stop using the first storage component 20 to perform statistics, and switch to using the second storage component 30 to perform statistics on the target data stream.
- the statistical record corresponding to the target data stream is not queried in the first statistical table, it can indicate that the processor 10 used the second storage component 30 to perform statistics on the target data stream. In this case, the processor 10 can keep using the The second storage component 30 performs statistics on the target data stream.
- the processor 10 may also calculate the forwarding rate of the target data stream according to the traffic of the target data stream; if the forwarding rate is lower than the second threshold, it is determined that the traffic of the target data stream satisfies the second preset condition.
- the second threshold may be smaller than the first threshold in the foregoing embodiments.
- the processor 10 may continue to determine whether the target data stream satisfies the second preset condition when the flow rate of the target data stream does not satisfy the first preset condition, and if the target data stream satisfies the second preset condition, then The second storage component 30 may be used to perform statistics on the target data stream, so as to release the storage space in the first storage component 20 . This can age the statistical records corresponding to the data streams that meet the second preset condition in the internal storage space in time to make room for other data streams that meet the first preset condition, so as to ensure that the first storage component 20 is used to prioritize the data streams that meet the first preset condition. Statistics are performed on data streams with preset conditions.
- the network traffic model usually follows these 28 rules, that is: 20% of the data flow occupies 80% of the network bandwidth.
- 20% of the data flow occupies 80% of the network bandwidth.
- 80 % of the data flow occupies 20% of the network bandwidth, for the convenience of description, we can call this type of data flow as long tail flow.
- An FPGA chip can be used to implement a statistical function, for example, a statistical function that can be provided by a statistical module such as STAT, and the FPGA chip can be used as a processor in the statistical solution provided in this embodiment.
- a statistical function for example, a statistical function that can be provided by a statistical module such as STAT
- the FPGA chip can be used as a processor in the statistical solution provided in this embodiment.
- the second storage component DDR and the first storage component RAM are configured for the FPGA chip.
- the RAM supports the parallel access function, but the storage space is limited, and the DDR is limited by the access bandwidth. And the access form, the access speed is relatively slow, but the storage space is large.
- a first statistical table can be built in RAM, and the first statistical table can be adaptively changed;
- a second statistical table can be built in DDR, and the second statistical table can cover the required Statistics of all data streams.
- the intention record content timestamp, packets
- the record content is used to record the cumulative forwarding amount of the data stream under different time stamps.
- the FPGA chip and the first storage component and the second storage component configured for it may be deployed on a gateway device or other devices that need to perform data flow statistics.
- processing requests of data streams received by these devices can be monitored. For example, if a processing request for data stream A is monitored, a statistical record for data stream A can be preferentially created in the first statistical table. If the first statistical table is full, a statistical record may also be created for the data stream A in the second statistical table.
- the flow of the data flow A can be monitored based on the aforementioned recorded content, and the forwarding rate corresponding to the data flow A can be calculated by using a preset time stamp interval or a cumulative forwarding amount increment as a trigger condition.
- the forwarding rate of the data flow A exceeds the first threshold, it can be determined that the data flow A is an elephant flow. However, if the turnaround rate of the data stream A is lower than the second threshold, it can be determined that the data stream A is a long wake stream. Accordingly, the elephant flow can be effectively identified.
- the first storage component may be preferentially used to perform statistics on elephant flows
- the second storage component may be preferentially used to perform statistics on long wake flows.
- the first statistical table can be designed as large as possible to accommodate more elephant flows, and when an elephant flow is identified, the first storage component can be used to perform statistics on the elephant flow.
- the first storage component collects statistics on the elephant flow, it is no longer necessary to access the second storage component, which can offload a part of the processing pressure of the second storage component, and the access speed of the first storage component is faster. Therefore, It can improve the statistical efficiency of elephant flow.
- the statistical records in the first statistical table are aged in time. Identify the long wake in the first statistical table in time, and transfer the statistical records corresponding to the long wake to the second statistical table, and then use the second storage component to perform statistics on the long wake, so that the first Free up storage space for other elephant flows in the statistics table.
- the elephant flow can be effectively identified, and the unloading ratio of the elephant flow in the second storage component can be effectively increased. Therefore, the parallel processing capability of the FPGA chip can be fully utilized, and the statistical efficiency of the elephant flow can be effectively improved.
- the traffic of the data stream usually has certain burst characteristics, and the duration of a large data stream is often relatively short, such as uploading and downloading webpage data, when the space of the first statistical table is limited, and the first statistical table is aged and recycled in time. resources, which can effectively improve the probability of using the first storage component to collect statistics on the elephant flow, thereby further improving the statistical performance.
- the storage component performs statistics, that is, keeps the previous processing position unchanged. Instead, methods such as elimination at the end can be used.
- any long wake flow is selected from the first statistical table, and the corresponding long wake flow is selected.
- Statistical records are moved to the second storage component to free up storage space for the elephant flow. In this way, the first storage component can be used to a great extent to perform the statistical work of the data flow, thereby further improving the statistical performance.
- FIG. 4 is a schematic flowchart of a data flow statistics method provided by an exemplary embodiment of the present application.
- the data flow statistics method provided in this embodiment may be executed by a data flow statistics apparatus, which may be implemented as software or a combination of software and hardware, and may be integrated in a computing device. As shown in Figure 3, the method includes:
- Step 400 monitor the flow of the target data stream
- Step 401 If the flow of the target data stream satisfies the first preset condition, maintain a first statistical record corresponding to the target data stream in the first storage component, so as to perform statistics on the target data stream based on the first statistical record;
- Step 402 Update the second statistical record corresponding to the target data stream according to the first statistical record, where the second statistical record is configured in the second storage component;
- the access speed of the first storage component is higher than that of the second storage component.
- the step of updating the second statistical record corresponding to the target data stream according to the first statistical record includes:
- the second statistical record corresponding to the target data stream is updated according to the first statistical record.
- the step updates the second statistical record corresponding to the target data stream according to the first statistical record, including:
- the method further includes:
- the forwarding rate exceeds the first threshold, it is determined that the traffic of the target data stream satisfies the first preset condition.
- the method further includes:
- Monitor the traffic of target data streams including:
- the cumulative forwarding amount is obtained as the flow.
- the recorded content is configured in the first statistical record or in the second statistical record.
- the step calculates the forwarding rate to the target data stream according to the traffic of the target data stream, including:
- the flow of the target data flow satisfies the first preset condition, maintaining the first statistical record corresponding to the target data flow in the first storage component, including:
- the queried statistical record is used as the first statistical record
- the step of creating a first statistical record in the first statistical table includes:
- a first statistical record is created in the first statistical table.
- the method further includes:
- the first statistical table in the first storage component is queried; if the first statistical record corresponding to the target data stream is queried in the first statistical table, the Record and update the second statistical record, and stop performing statistics on the target data based on the first statistical record;
- Statistics are performed on the target data stream based on the second statistical record, and the operation of determining whether the traffic of the target data stream satisfies the first preset condition is continued.
- the method further includes:
- the forwarding rate is lower than the second threshold, it is determined that the traffic of the target data stream satisfies the second preset condition.
- the step before monitoring the flow of the target data stream, the step further includes:
- the first statistical table in the first storage component In the case of listening to the forwarding request for the target data stream, if the first statistical table in the first storage component is not full and the first statistical table does not contain statistical records corresponding to the target data stream, the first statistical table Create a statistical record corresponding to the target data stream in , and perform statistics on the target data stream based on the statistical record created in the first statistical table;
- the first statistical table If the first statistical table is full, create a statistical record corresponding to the target data stream in a second statistical table in the second storage component; and perform statistics on the target data stream based on the statistical record created in the second statistical table.
- the first storage component adopts a memory, a cache or a hard disk
- the second storage component adopts a double-rate synchronous dynamic random access memory (DDR).
- DDR double-rate synchronous dynamic random access memory
- the execution subject of each step of the method provided in the above-mentioned embodiments may be the same device, or the method may also be executed by different devices.
- the execution subject of steps 301 to 302 may be device A; for another example, the execution subject of steps 301 and 302 may be device A, and the execution subject of step 300 may be device B; and so on.
- the embodiments of the present application further provide a computer-readable storage medium storing a computer program, and when the computer program is executed, each step that can be executed by a computing device in the foregoing method embodiments can be implemented.
- the embodiments of the present application may be provided as a method, a system, or a computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) having computer-usable program code embodied therein.
- computer-usable storage media including, but not limited to, disk storage, CD-ROM, optical storage, etc.
- These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory result in an article of manufacture comprising instruction means, the instructions
- the apparatus implements the functions specified in the flow or flow of the flowcharts and/or the block or blocks of the block diagrams.
- a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
- processors CPUs
- input/output interfaces network interfaces
- memory volatile and non-volatile memory
- Memory may include forms of non-persistent memory, random access memory (RAM) and/or non-volatile memory in computer readable media, such as read only memory (ROM) or flash memory (flash RAM). Memory is an example of a computer-readable medium.
- RAM random access memory
- ROM read only memory
- flash RAM flash memory
- Computer-readable media includes both persistent and non-permanent, removable and non-removable media, and storage of information may be implemented by any method or technology.
- Information may be computer readable instructions, data structures, modules of programs, or other data.
- Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read only memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), Flash Memory or other memory technology, Compact Disc Read Only Memory (CD-ROM), Digital Versatile Disc (DVD) or other optical storage, Magnetic tape cassettes, magnetic tape magnetic disk storage or other magnetic storage devices or any other non-transmission medium that can be used to store information that can be accessed by a computing device.
- computer-readable media does not include transitory computer-readable media, such as modulated data signals and carrier waves.
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Environmental & Geological Engineering (AREA)
- Theoretical Computer Science (AREA)
- Databases & Information Systems (AREA)
- Data Mining & Analysis (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Computational Linguistics (AREA)
- Health & Medical Sciences (AREA)
- Cardiology (AREA)
- General Health & Medical Sciences (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
本申请实施例提供一种数据流统计方法、设备及存储介质。在本申请实施例中,利用第一存储组件和第二存储组件进行数据流统计,对于流量满足预设条件的数据流,可将这类数据流的统计工作自适应地搬移至第一存储组件中执行。这样,一方面可卸载掉第二存储组件的一部分处理压力;另一方面,可充分利用第一存储组件的高速存取能力,从而更加快速、更加准确地对这类数据流进行统计。据此,本实施例中,可充分利用第一存储组件的高速存取能力,从而有效减少数据流统计过程中对第二存储组件的访问次数,进而大幅提升对数据流的统计性能。
Description
本申请要求2020年07月01日递交的申请号为202010626672.9、发明名称为“一种数据流统计方法、设备及存储介质”中国专利申请的优先权,其全部内容通过引用结合在本申请中。
本申请涉及网络技术领域,尤其涉及一种数据流统计方法、设备及存储介质。
在网络通信过程中,经常需要对数据流进行统计,数据流统计的结果,可广泛应用于流量监控、访问控制等多方面。
随着互联网技术的发展,网络通信过程中的数据流量激增,传统的数据流统计方案已经无法满足日益提高的统计要求。
因此,如何提升对数据流的统计性能成为亟待解决的问题。
发明内容
本申请的多个方面提供一种数据流统计方法、设备及存储介质,用以提升对数据流的统计性能。
本申请实施例提供一种数据流统计方法,包括:
监控目标数据流的流量;
若所述目标数据流的流量满足第一预设条件,则在第一存储组件中维护所述目标数据流对应的第一统计记录,以基于所述第一统计记录对所述目标数据流进行统计;
根据所述第一统计记录更新所述目标数据流对应的第二统计记录,所述第二统计记录配置于第二存储组件中;
其中,所述第一存储组件的存取速度高于所述第二存储组件。
本申请实施例还提供一种计算设备,包括第一存储组件、第二存储组件和处理器,所述处理器与所述第一存储组件和所述第二存储组件耦合,所述第一存储组件的存取速度高于所述第二存储组件;
所述处理器,用于监控目标数据流的流量;若所述目标数据流的流量满足第一预设条件,则在第一存储组件中维护所述目标数据流对应的第一统计记录,以基于所述第一统计记录对所述目标数据流进行 统计;根据所述第一统计记录更新所述目标数据流对应的第二统计记录,所述第二统计记录配置于第二存储组件中;
所述第一存储组件,用于存储所述目标数据流对应的第一统计记录;
所述第二存储组件,用于存储所述目标数据流对应的第二统计记录。
本申请实施例还提供一种存储计算机指令的计算机可读存储介质,当所述计算机指令被一个或多个处理器执行时,致使所述一个或多个处理器执行前述的数据流统计方法。
在本申请实施例中,利用第一存储组件和第二存储组件进行数据流统计,对于流量满足预设条件的数据流,可将这类数据流的统计工作自适应地搬移至第一存储组件中执行。这样,一方面可卸载掉第二存储组件的一部分处理压力;另一方面,可充分利用第一存储组件的高速存取能力,从而更加快速、更加准确地对这类数据流进行统计。据此,本实施例中,可充分利用第一存储组件的高速存取能力,从而有效减少数据流统计过程中对第二存储组件的访问次数,进而大幅提升对数据流的统计性能。
此处所说明的附图用来提供对本申请的进一步理解,构成本申请的一部分,本申请的示意性实施例及其说明用于解释本申请,并不构成对本申请的不当限定。在附图中:
图1为本申请一示例性实施例提供的一种计算设备的结构示意图;
图2为本申请一示例性实施例提供的一种数据流统计方案的逻辑示意图;
图3为本申请一示例性实施例提供的一种自适应选择利用第一存储组件或第二存储组件对目标数据流进行统计的逻辑示意图;
图4为本申请一示例性实施例提供的一种数据流统计方法的流程示意图。
为使本申请的目的、技术方案和优点更加清楚,下面将结合本申请具体实施例及相应的附图对本申请技术方案进行清楚、完整地描述。显 然,所描述的实施例仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。
目前,传统的数据流统计方案已经无法满足日益提高的统计要求。为改善该技术问题,本申请实施例的一些实施例中:利用第一存储组件和第二存储组件进行数据流统计,对于流量满足预设条件的数据流,可将这类数据流的统计工作动态搬移至第一存储组件中执行。这样,一方面可卸载掉第二存储组件的一部分处理压力;另一方面,可充分利用第一存储组件的高速存取能力,从而更加快速、更加准确地对这类数据流进行统计。据此,本实施例中,可充分利用第一存储组件的高速存取能力,从而有效减少数据流统计过程中对第二存储组件的访问次数,进而大幅提升对数据流的统计性能。
以下结合附图,详细说明本申请各实施例提供的技术方案。
图1为本申请一示例性实施例提供的一种计算设备的结构示意图。图2为本申请一示例性实施例提供的一种数据流统计方案的逻辑示意图。如图1所示,该计算设备包括:第一存储组件20、第二存储组件30和处理器10,处理器10与第一存储组件20和第二存储组件30耦合。
本实施例提供的计算设备可应用于各种需要对数据流进行统计的场景中。例如,流量监控、网络计费、访问控制、网络安全监控与防范、网络资源优化建设等应用场景。在产品应用方面,本实施例提供的计算设备可布设在网卡、路由器、交换机等各类网关产品中,以提供数据流统计功能,当然,本实施例并不限于此。
本实施例中,第一存储组件20的存取速度高于第二存储组件30的存取速度。其中,第一存储组件20可采用内部存储组件,例如,内存、缓存或硬盘等,第二存储组件30则可采用外部存储组件,例如,DDR等。这里的内部存储组件和外部存储组件是从存储速度的维度进行定义的,而非从物理结构的维度进行定义。从物理结构维度来看,内部存储组件和外部存储组件可均位于计算设备内部,也可均位于计算设备外部,或者内部存储组件位于计算设备内部而外部存储组件位于计算设备外部等等。
另外,值得说明的是,本实施例中的第一存储组件20和第二存储组件30的组件形式并不限于此,只是从存取速度上区分了两个存取组件。本实施例中,利用第一存储组件20辅助第二存储组件30对数据流进行 统计,可有效提高数据流的统计效率和准确度。
在技术实现上,本实施例中,可基于FPGA(field programmable gate array,现场可编程门阵列)实现处理器10的功能,这种情况下,第二存储组件30可以是DDR(Double Data Rate,双倍速率同步动态随机存储器),第一存储组件20则可以是RAM(random access memory,随机存取存储器)。当然,本实施例并不限于此,还可基于单片机、CPU等技术实现处理器10的功能。以FPGA技术为例,其第一存储组件20可支持并行处理功能,也即是,处理器10可对第一存储组件20发起并行访问操作,因此,访问速度更高;而受限于第二存储组件30的访问带宽及访问形式,处理器10对第二存储组件30的访问速度则较慢。
在上述设备结构的基础上,本实施例中,可基于计算设备对数据流进行统计。由于对不同数据流的统计方案类似,为便于描述,本文中将以目标数据流为例进行统计方案的说明,但应当理解的是,本实施例提供的统计方案适用于计算设备所需统计的所有数据流。
处理器10可监控目标数据流的流量;若目标数据流的流量满足第一预设条件,则在第一存储组件20中维护目标数据流对应的第一统计记录,以基于第一统计记录对目标数据流进行统计。
其中,第一统计记录中包括但不限于已转发包数pass-packets、已转发字节数pass-bytes、已丢包数drop-packets、已丢字节数drop-bytes等统计项。对于处理器10来说,在任意一种统计项发生变化的情况,就需要更新一次统计记录。例如,网关设备对目标数据流进行转发的过程中,每转发一个数据包packet,处理器10需要访问一次目标数据流对应的统计记录,并对统计记录中的已转发包数这一统计项下的统计值执行累加操作。
参考图2,在这种统计方式下,本实施例中,可预先配置第一预设条件,第一预设条件可作为特定类数据流的识别条件。因此,基于第一预设条件,可识别出特定类数据流,并在第一存储组件20中对特定类数据流进行统计。
若目标数据流的流量满足第一预设条件,处理器10可在第一存储组件20中维护目标数据流对应的第一统计记录,以利用第一存储组件20对目标数据流进行统计。正如前文提及的,第一存储组件20可支持并行处理功能,因此,处理器10可对第一存储组件20中的第一统计记录进行并行访问,以及时、准确地更新第一统计记录中的各统计项,这可有 效提高对目标数据流的统计效率和准确率,避免漏记或错记问题。
实际应用中,可在第一存储组件20中配置一第一统计表,第一统计表中可包含若干统计记录。处理器10可对第一统计表中的统计记录进行动态增减,因此,处理器10可将前述的特定类数据流的统计记录优先配置到第一统计表中,以优先利用第一存储组件20对特定类数据流进行统计。
本实施例中,可在第二存储组件30存储全部数据流对应的统计记录,这其中可包含目标数据流对应的第二统计记录。基于此,处理器10可根据第一存储组件20中的第一统计记录更新第二存储组件30中的第二统计记录。
本实施例中,在基于第一统计记录对目标数据流进行统计的过程中,处理器10无需再访问第二存储组件30中的第二统计记录,这可将第二存储组件30的一部分负载卸载至第一存储组件20上;而第一存储组件20则可将其对目标数据流的统计结果更新至第二存储组件30。这样,在对目标数据流进行统计的过程中,可大幅降低对第二存储组件30的访问次数。
例如,网关设备对目标数据流中的50个数据包进行转发,处理器10可对第一存储组件20执行50次访问,以将第一统计记录中的pass-pakets更新为50,之后,可根据第一统计记录更新第二统计记录。这个过程中,处理器10对第一存储组件20访问50次,而仅对第二存储组件30访问1次。
据此,本实施例中,利用第一存储组件20和第二存储组件30进行数据流统计,对于流量满足预设条件的数据流,可将这类数据流的统计工作动态搬移至第一存储组件20中执行。这样,一方面可卸载掉第二存储组件30的一部分处理压力;另一方面,可充分利用第一存储组件20的高速存取能力,从而更加快速、更加准确地对这类数据流进行统计。据此,本实施例中,可充分利用第一存储组件20的高速存取能力,从而有效减少数据流统计过程中对第二存储组件30的访问次数,进而大幅提升对数据流的统计性能。
图3为本申请一示例性实施例提供的一种自适应选择利用第一存储组件20或第二存储组件30对目标数据流进行统计的逻辑示意图。
参考图3,在上述或下述实施例中,第一存储组件20的存储空间有限,因此,第一统计记录中各统计项下的统计门限较低。例如,pass-packets 这一统计项下的统计门限可能只能达到1000。
为此,本实施例中,处理器10可在第一统计记录发生溢出的情况下,根据第一统计记录更新目标数据流对应的第二统计记录。其中,溢出可以是指任一统计项下的统计值达到该统计项下的统计门限。实际应用中,可按需设定各统计项下的统计门限。
当然,本实施例中,根据第一统计记录更新第二统计记录的执行时机可以是多种多样的。除了可将第一统计记录发生溢出作为执行时机外,还可周期地或者在达到对第一统计记录的访问次数阈值的情况下,执行根据第一统计记录更新第二统计记录的操作,等。本实施例并不限于此。
处理器10在根据第一统计记录更新第二统计记录的过程中,可将第一统计记录包含的各统计值累加至第二统计记录中相应的统计值;对第一统计记录包含的各统计值进行清零,并继续基于第一统计记录对目标数据流进行统计。
例如,第一统计记录包括:pass-packets=1000、pass-bytes=956378、drop-packets=20、drop-bytes=2530。第二统计记录包括:pass-packets=52361、pass-bytes=6953332、drop-packets=562、drop-bytes=6325。则执行根据第一统计记录更新第二统计记录操作后,第一统计记录包括:pass-packets=0、pass-bytes=0、drop-packets=0、drop-bytes=0,第二统计记录包括:pass-packets=53361、pass-bytes=7909710、drop-packets=582、drop-bytes=8855。之后,在第一统计记录中各统计项下,从0开始计数,以继续对目标数据流进行统计。
据此,本实施例中,处理器10可将利用第一存储组件20对目标数据流进行统计的统计结果,阶段性地搬运至第二存储组件30中,以保证第一存储组件20对目标数据流的准确统计,避免因第一存储组件20的存储空间的局限性而导致漏记或错记等问题,并可为下一阶段继续利用第一存储组件20对目标数据流进行统计而提供存储空间基础。
在上述或下述实施例中,处理器10可采用多种实现方式确定目标数据流的流量是否满足第一预设条件。
在一种可选地实现方式中,处理器10可根据目标数据流的流量,计算对目标数据流的转发速率;若转发速率超过第一阈值,则确定目标数据流的流量满足第一预设条件。
在该实现方式中,第一预设条件配置为转发速率超过第一阈值。基于此,处理器10可从所需统计的多个数据流中,识别出转发速率超过第 一阈值的特定类数据流。
为了计算出对目标数据流的转发速率,在该实现方式中,处理器10可为目标数据流维护一记录内容,记录内容包括时间戳以及时间戳下的累积转发量;以预设的时间戳间隔或累计转发量增量作为触发条件,更新记录内容。例如,记录内容可表示为(timestamp,packets)。其中,处理器10可从目标数据流对应的记录内容中,获取累积转发量,作为目标数据流的流量。
其中,若以时间戳间隔作为触发条件,则处理器10可在目标数据流被处理的时段内,设定若干时间戳,并在达到任意时间戳时,根据该时间戳和该时间戳下的累积转发量,更新目标数据流对应的记录内容。这样,从当前时刻来看,目标数据流对应的记录内容中包含的可以是当前时刻之前的最后一个时间戳及该时间戳下的累积转发量。当然,记录内容中,还可包含其它时间戳及时间戳下的累积转发量,在此不做限定。
其中,若以累积转发量增量作为触发条件,则处理器10可在目标数据流对应的累积转发量的增量达到预设增量门限时,将累积转发量的增量达到预设增量门限的时刻作为时间戳,根据该时间戳和该时间戳下的累积转发量,更新目标数据流对应的记录内容。
基于此,处理器10可根据当前时间戳及当前时间戳下的累积转发量和记录内容中的时间戳以及时间戳下的累积转发量,计算对目标数据流的转发速率。
实际应用中,可在目标数据流的记录内容发生更新的情况下,执行计算对目标数据流的转发速率的操作,这样,当前时间戳可以是达到预设的时间戳间隔或累计转发量增量的时刻。
例如,目标数据流的记录内容C0=(第100ms,100K),则计算目标数据流的转发速率的时机可以是第200ms(其中,预设的时间戳间隔为100ms),此时的时间戳为200ms,累积转发量为180K。则目标数据流的转发速率PPS可记为:(180K-100K)/(200ms-100ms)=800Kpps,也即,每秒转发800K个数据包。
又例如,计算目标数据流的转发速率的时机也可以是第300ms(第300ms时,累积转发量为200K,达到预设增量门限100K)。则目标数据流的转发速率PPS可记为:(200K-100K)/(300ms-100ms)=500Kpps,也即,每秒转发500K个数据包。
在计算出目标数据流的转发速率的同时,还可根据当前时间戳及当 前时间戳下的累积转发量更新目标数据流的记录内容。
承接上例,可将C1=(第200ms,180K)更新至记录内容,或者将C1=(第300ms,200K)更新至记录内容。
相应地,计算目标数据流的转发速率的时机,还可作为判断目标数据流的流量是否满足第一预设条件的时机,也即,作为确定是否在内部处理器10中对目标数据流进行统计的判断时机。当然,各操作的执行时机也可不完全相同,本实施例并不限于此。
另外,在该实现方式中,可在统计记录中增加一统计项,以承载前述的记录内容。基于此,目标数据流对应的记录内容可配置于第一统计记录中,也可配置于第二统计记录中。当然,也可将记录内容配置于其它处理器10可访问的存储位置而不必须配置到统计记录中,在此不做限定。
除了可根据转发速率确定是否利用第一存储组件20对目标数据流进行统计外,在其它实现方式中,还可根据目标数据流对网络带宽的占比等其它指标来确定是否利用第一存储组件20对目标数据流进行统计,本实施例并不限于此。
据此,本实施例中,可及时地发现目标数据流的流量是否满足第一预设条件,从而可在目标数据流的流量满足第一预设条件的情况下,尽早地利用第一存储组件20度目标数据流进行统计,进而有效提高数据流的统计性能。
在上述或下述实施例中,处理器10还可监听针对目标数据流的转发请求。例如,处理器10可监听网关设备中用于接收转发请求的接口,以监听针对目标数据流的转发请求。
在监听到针对目标数据流的转发请求的情况下,处理器10可查询第一存储组件20中的第一统计表。
若第一统计表未满且第一统计表中未包含与目标数据流对应的统计记录,则在第一统计表中创建目标数据流对应的统计记录,并基于在第一统计表中创建的统计记录,对目标数据流进行统计;
若第一统计表已满,则在第二存储组件30中的第二统计表中创建目标数据流对应的统计记录;并基于在第二统计表中创建的统计记录,对目标数据流进行统计。
本实施例中,在监听到针对目标数据流的转发请求的情况下,处理器10优先在第一存储组件20中为目标数据流创建统计记录。但由于第 一存储组件20中所能容纳的统计记录的数量有限,有可能出现第一存储组件20中的第一统计表已满的情况,这种情况下,处理器10可在第二存储组件30中的第二统计表中为目标数据流创建统计记录。
但是,上述目标数据流对应的统计记录的首次创建位置,并不一定会作为统计工作的处理位置,而是可由处理器10根据目标数据流的流量变化情况,动态地调整统计工作的处理位置。也即是,处理器10可根据目标数据流的流量变化情况,动态地选择利用第一存储组件20或第二存储组件30对目标数据流进行统计。
参考图3,处理器10可通过监控目标数据流的流量,判断目标数据流的流量是否满足第一预设条件。
在一种情况下,若目标数据流的流量满足第一预设条件,则处理器10可查询第一存储组件20中的第一统计表;若在第一统计表中查询到目标数据流对应的统计记录,则将查询到的统计记录作为第一统计记录;若在第一统计表中未查询到目标数据流对应的统计记录,则在第一统计表中创建第一统计记录。
其中,在第一统计表中查询到目标数据流对应的统计记录,则可表征此前处理器10是利用第一存储组件20对目标数据流进行统计,这种情况下,处理器10可保持利用第一存储组件20对目标数据流进行统计;而在第一统计表中未查询到目标数据流对应的统计记录,则可表征此前处理器10是利用第二存储组件30对目标数据流进行统计,在这种情况下,处理器10可停止利用第二存储组件30进行统计,而切换至利用第一存储组件20对目标数据流进行统计。
另外,处理器10在第一统计表中创建第一统计记录的过程中,可判断第一统计表是否已满。若未满,则可在第一统计表中创建第一统计记录。若第一统计表已满,则确定第一统计表中各数据流对应的转发速率;选择转发速率低于第二阈值的一数据流对应的目标统计记录;从第一统计表中删除目标统计记录,并将目标统计记录累加至第二存储组件30中选择出的数据流对应的统计记录;在第一统计表中创建第一统计记录。其中,确定第一统计表中各数据流对应的转发速率的过程可参考前述实施例中的描述,将目标统计记录累加至第二存储组件30中选择出的数据流对应的统计记录的过程也可参考前述实施例中根据第一统计记录更新第二统计记录的过程,在此不再赘述。
在此基础上,处理器10可基于第一统计记录对目标数据流进行统计。 据此,若目标数据流的流量满足第一预设条件,处理器10可利用第一存储组件20对目标数据流进行统计,以卸载第二存储组件30的处理压力,并提高对目标数据流的统计效率。
在另一种情况下,若目标数据流的流量不满足第一预设条件,则处理器10可判断目标数据流的流量是否满足第二预设条件;若目标数据流的流量满足第二预设条件,则处理器10可查询第一存储组件20中的第一统计表;若在第一统计表中查询到目标数据流对应的第一统计记录,则根据第一统计记录更新第二统计记录,并停止基于第一统计记录对目标数据了进行统计;基于第二统计记录对目标数据流进行统计,并继续执行判断目标数据流的流量是否满足第一预设条件的操作。
其中,在第一统计表中查询到目标数据流对应的第一统计记录,则可表征此前处理器10是利用第一存储组件20对目标数据流进行统计,在这种情况下,处理器10可停止利用第一存储组件20进行统计,而切换至利用第二存储组件30对目标数据流进行统计。而在第一统计表中未查询到目标数据流对应的统计记录,则可表征此前处理器10是利用第二存储组件30对目标数据流进行统计,这种情况下,处理器10可保持利用第二存储组件30对目标数据流进行统计。
另外,处理器10还可根据目标数据流的流量,计算对目标数据流的转发速率;若转发速率低于第二阈值,则确定目标数据流的流量满足第二预设条件。其中,第二阈值可小于前述实施例中的第一阈值。计算对目标数据流的转发速率的过程可参考前述实施例中的描述,在此不再赘述。
在这种情况下,处理器10可在目标数据流的流量不满足第一预设条件时,继续判断目标数据流是否满足第二预设条件,若目标数据流满足第二预设条件,则可利用第二存储组件30对目标数据流进行统计,以释放第一存储组件20中的存储空间。这可及时老化内部存储空间中满足第二预设条件的数据流对应的统计记录,为满足第一预设条件的其它数据流腾出空间,从而保证利用第一存储组件20优先对满足第一预设条件的数据流进行统计。
以下,以对数据流A的统计过程为例,进行技术方案的详细说明。
发明人在研究过程中发现,网络流量模型通常遵循这28法则,也就是:20%的数据流占用80%的网络带宽,为便于描述,我们可将这类数据流称为大象流;80%的数据流占用20%的网络带宽,为便于描述,我 们可将这类数据流称为长尾流。
本实施例提出了一种自适应地统计方案。可采用FPGA芯片实现统计功能,例如,STAT等统计模块可提供的统计功能,FPGA芯片可作为本实施例提供的统计方案中的处理器。与传统的统计方案不同的是,本实施例中,为FPGA芯片配置了第二存储组件DDR和第一存储组件RAM,其中,RAM支持并行访问功能,但存储空间有限,DDR受限于访问带宽及访问形式,访问速度比较慢,但存储空间较大。基于DDR和RAM,本实施例中,可在RAM中构建以第一统计表,该第一统计表为自适应变化的;在DDR中构建第二统计表,该第二统计表可覆盖所需统计的全部数据流。另外,与传统的统计方案不同的还有,额外增加了意向记录内容(timestamp,packets),记录内容用于记录数据流在不同时间戳下的累积转发量。
其中,FPGA芯片及为其配置的第一存储组件和第二存储组件,可部署在网关设备或其它需要进行数据流统计的设备上。
在此基础上,可监听这些设备接收到的数据流的处理请求,例如,若监听到针对数据流A的处理请求,则可优先在第一统计表中为数据流A创建统计记录。若第一统计表已满,也可在第二统计表中为数据流A创建统计记录。
之后,可基于前述的记录内容,监控数据流A的流量,并可以预设的时间戳间隔或累积转发量增量作为触发条件,计算数据流A对应的转发速率。
若数据流A的转发速率超过第一阈值,则可确定数据流A为大象流。而若数据流A的赚翻速率低于第二阈值,则可确定数据流A为长尾流。据此,可有效地识别出大象流。
本实施例中,可优先利用第一存储组件对大象流进行统计,优先利用第二存储组件对长尾流进行统计。
为此,一方面,可尽可能设计大的第一统计表,以容纳更多的大象流,并可在识别到大象流时,利用第一存储组件对大象流进行统计,在利用第一存储组件对大象流进行统计的过程中,不再需要对第二存储组件进行访问,这可卸载第二存储组件的一部分处理压力,而且第一存储组件的访问速度更快,因此,可提高对大象流的统计效率。另一方面,对于第一统计表中的统计记录进行及时老化。及时地识别出第一统计表中的长尾流,并将长尾流对应的统计记录搬运至第二统计表中,之后可 利用第二存储组件对长尾流进行统计,从而可在第一统计表中为其它大象流腾出存储空间。
通过这两方面,可有效识别出大象流,并可有效提高第二存储组件中大象流的卸载比例,因此,可充分利用FPGA芯片的并行处理能力,有效提高对大象流的统计效率。数据流的流量通常有一定的突发特性,往往一个大的数据流的存续时间比较短,比如网页数据的上传下载,第一统计表的空间有限的情况下,及时地老化回收第一统计表的资源,可有效提升利用第一存储组件对大象流进行统计的概率,从而可进一步提升统计性能。
另外,为了减少利用第一统计表对第二统计表的更新次数,对于转发速率低于第二阈值或者高于第二阈值但低于第一阈值的数据流,也可不主动切换至利用第二存储组件进行统计,也即保存此前的处理位置不变。而是可采用末尾淘汰等方式,在识别到大象流且第一统计表已满的情况下,在从第一统计表中选择任一长尾流,并将选出的长尾流对应的统计记录搬运至第二存储组件中,从而为大象流腾出存储空间。这样,可极大程度地利用第一存储组件执行数据流的统计工作,进一步提高统计性能。
图4为本申请一示例性实施例提供的一种数据流统计方法的流程示意图。本实施例提供的数据流统计方法可以由一数据流统计装置来执行,该数据流统计装置可以实现为软件或实现为软件和硬件的组合,该数据流统计装置可集成设置在计算设备中。如图3所示,该方法包括:
步骤400、监控目标数据流的流量;
步骤401、若目标数据流的流量满足第一预设条件,则在第一存储组件中维护目标数据流对应的第一统计记录,以基于第一统计记录对目标数据流进行统计;
步骤402、根据第一统计记录更新目标数据流对应的第二统计记录,第二统计记录配置于第二存储组件中;
其中,第一存储组件的存取速度高于第二存储组件。
在一可选实施例中,步骤根据第一统计记录更新目标数据流对应的第二统计记录,包括:
在第一统计记录发生溢出的情况下,根据第一统计记录更新目标数据流对应的第二统计记录。
在一可选实施例中,步骤根据第一统计记录更新目标数据流对应 的第二统计记录,包括:
将第一统计记录包含的各统计值累加至第二统计记录中相应的统计值;
对第一统计记录包含的各统计值进行清零,并继续基于第一统计记录对目标数据流进行统计。
在一可选实施例中,该方法还包括:
根据目标数据流的流量,计算对目标数据流的转发速率;
若转发速率超过第一阈值,则确定目标数据流的流量满足第一预设条件。
在一可选实施例中,该方法还包括:
为目标数据流维护一记录内容,记录内容包括时间戳以及时间戳下的累积转发量;
以预设的时间戳间隔或累计转发量增量作为触发条件,更新记录内容;
监控目标数据流的流量,包括:
从目标数据流对应的记录内容中,获取累积转发量,作为流量。
在一可选实施例中,记录内容配置于第一统计记录中或第二统计记录中。
在一可选实施例中,步骤根据目标数据流的流量,计算对目标数据流的转发速率,包括:
根据当前时间戳及当前时间戳下的累积转发量和记录内容中的时间戳以及时间戳下的累积转发量,计算对目标数据流的转发速率。
在一可选实施例中,步骤若目标数据流的流量满足第一预设条件,则在第一存储组件中维护目标数据流对应的第一统计记录,包括:
若目标数据流的流量满足第一预设条件,则查询第一存储组件中的第一统计表;
若在第一统计表中查询到目标数据流对应的统计记录,则将查询到的统计记录作为第一统计记录;
若在第一统计表中未查询到目标数据流对应的统计记录,则在第一统计表中创建第一统计记录。
在一可选实施例中,步骤在第一统计表中创建第一统计记录,包括:
若第一统计表已满,则确定第一统计表中各数据流对应的转发速 率;
选择转发速率低于第二阈值的一数据流对应的目标统计记录;
从第一统计表中删除目标统计记录,并将目标统计记录累加至第二存储组件中选择出的数据流对应的统计记录;
在第一统计表中创建第一统计记录。
在一可选实施例中,该方法还包括:
若目标数据流的流量不满足第一预设条件,判断目标数据流的流量是否满足第二预设条件;
若目标数据流的流量满足第二预设条件,则查询第一存储组件中的第一统计表;若在第一统计表中查询到目标数据流对应的第一统计记录,则根据第一统计记录更新第二统计记录,并停止基于第一统计记录对目标数据了进行统计;
基于第二统计记录对目标数据流进行统计,并继续执行判断目标数据流的流量是否满足第一预设条件的操作。
在一可选实施例中,该方法还包括:
根据目标数据流的流量,计算对目标数据流的转发速率;
若转发速率低于第二阈值,则确定目标数据流的流量满足第二预设条件。
在一可选实施例中,步骤在监控目标数据流的流量之前,还包括:
在监听到针对目标数据流的转发请求的情况下,若第一存储组件中的第一统计表未满且第一统计表中未包含与目标数据流对应的统计记录,则在第一统计表中创建目标数据流对应的统计记录,并基于在第一统计表中创建的统计记录,对目标数据流进行统计;
若第一统计表已满,则在第二存储组件中的第二统计表中创建目标数据流对应的统计记录;并基于在第二统计表中创建的统计记录,对目标数据流进行统计。
在一可选实施例中,第一存储组件采用内存、缓存或硬盘,第二存储组件采用双倍速率同步动态随机存储器DDR。
值得说明的是,上述关于数据流统计方法的各实施例中的技术细节可参考前述计算设备的各实施例中的相关描述,为节省篇幅,在此不再赘述,但这不应造成本申请保护范围的损失。
另外,上述实施例所提供方法的各步骤的执行主体均可以是同一设备,或者,该方法也由不同设备作为执行主体。比如,步骤301至步骤 302的执行主体可以为设备A;又比如,步骤301和302的执行主体可以为设备A,步骤300的执行主体可以为设备B;等等。而且,在上述实施例及附图中的描述的一些流程中,包含了按照特定顺序出现的多个操作,但是应该清楚了解,这些操作可以不按照其在本文中出现的顺序来执行或并行执行,操作的序号如301、302等,仅仅是用于区分开各个不同的操作,序号本身不代表任何的执行顺序。另外,这些流程可以包括更多或更少的操作,并且这些操作可以按顺序执行或并行执行。需要说明的是,本文中的“第一”、“第二”等描述,是用于区分不同的统计记录、阈值、模块等,不代表先后顺序,也不限定“第一”和“第二”是不同的类型。
相应地,本申请实施例还提供一种存储有计算机程序的计算机可读存储介质,计算机程序被执行时能够实现上述方法实施例中可由计算设备执行的各步骤。
本领域内的技术人员应明白,本申请的实施例可提供为方法、系统、或计算机程序产品。因此,本申请可采用完全硬件实施例、完全软件实施例、或结合软件和硬件方面的实施例的形式。而且,本申请可采用在一个或多个其中包含有计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器、CD-ROM、光学存储器等)上实施的计算机程序产品的形式。
本申请是参照根据本申请实施例的方法、设备(系统)、和计算机程序产品的流程图和/或方框图来描述的。应理解可由计算机程序指令实现流程图和/或方框图中的每一流程和/或方框、以及流程图和/或方框图中的流程和/或方框的结合。可提供这些计算机程序指令到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理设备的处理器执行的指令产生用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的装置。
这些计算机程序指令也可存储在能引导计算机或其他可编程数据处理设备以特定方式工作的计算机可读存储器中,使得存储在该计算机可读存储器中的指令产生包括指令装置的制造品,该指令装置实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能。
这些计算机程序指令也可装载到计算机或其他可编程数据处理设备上,使得在计算机或其他可编程设备上执行一系列操作步骤以产生计算 机实现的处理,从而在计算机或其他可编程设备上执行的指令提供用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的步骤。
在一个典型的配置中,计算设备包括一个或多个处理器(CPU)、输入/输出接口、网络接口和内存。
内存可能包括计算机可读介质中的非永久性存储器,随机存取存储器(RAM)和/或非易失性内存等形式,如只读存储器(ROM)或闪存(flash RAM)。内存是计算机可读介质的示例。
计算机可读介质包括永久性和非永久性、可移动和非可移动媒体可以由任何方法或技术来实现信息存储。信息可以是计算机可读指令、数据结构、程序的模块或其他数据。计算机的存储介质的例子包括,但不限于相变内存(PRAM)、静态随机存取存储器(SRAM)、动态随机存取存储器(DRAM)、其他类型的随机存取存储器(RAM)、只读存储器(ROM)、电可擦除可编程只读存储器(EEPROM)、快闪记忆体或其他内存技术、只读光盘只读存储器(CD-ROM)、数字多功能光盘(DVD)或其他光学存储、磁盒式磁带,磁带磁磁盘存储或其他磁性存储设备或任何其他非传输介质,可用于存储可以被计算设备访问的信息。按照本文中的界定,计算机可读介质不包括暂存电脑可读媒体(transitory media),如调制的数据信号和载波。
还需要说明的是,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、商品或者设备不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、商品或者设备所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括所述要素的过程、方法、商品或者设备中还存在另外的相同要素。
以上所述仅为本申请的实施例而已,并不用于限制本申请。对于本领域技术人员来说,本申请可以有各种更改和变化。凡在本申请的精神和原理之内所作的任何修改、等同替换、改进等,均应包含在本申请的权利要求范围之内。
Claims (27)
- 一种数据流统计方法,其特征在于,包括:监控目标数据流的流量;若所述目标数据流的流量满足第一预设条件,则在第一存储组件中维护所述目标数据流对应的第一统计记录,以基于所述第一统计记录对所述目标数据流进行统计;根据所述第一统计记录更新所述目标数据流对应的第二统计记录,所述第二统计记录配置于第二存储组件中;其中,所述第一存储组件的存取速度高于所述第二存储组件。
- 根据权利要求1所述的方法,其特征在于,所述根据所述第一统计记录更新所述目标数据流对应的第二统计记录,包括:在所述第一统计记录发生溢出的情况下,根据所述第一统计记录更新所述目标数据流对应的第二统计记录。
- 根据权利要求2所述的方法,其特征在于,所述根据所述第一统计记录更新所述目标数据流对应的第二统计记录,包括:将所述第一统计记录包含的各统计值累加至所述第二统计记录中相应的统计值;对所述第一统计记录包含的各统计值进行清零,并继续基于所述第一统计记录对所述目标数据流进行统计。
- 根据权利要求1所述的方法,其特征在于,还包括:根据所述目标数据流的流量,计算对所述目标数据流的转发速率;若所述转发速率超过第一阈值,则确定所述目标数据流的流量满足第一预设条件。
- 根据权利要求4所述的方法,其特征在于,还包括:为所述目标数据流维护一记录内容,所述记录内容包括时间戳以及所述时间戳下的累积转发量;以预设的时间戳间隔或累计转发量增量作为触发条件,更新所述记录内容;所述监控目标数据流的流量,包括:从所述目标数据流对应的记录内容中,获取所述累积转发量,作为所述流量。
- 根据权利要求5所述的方法,其特征在于,所述记录内容配置于所述第一统计记录中或所述第二统计记录中。
- 根据权利要求5所述的方法,其特征在于,所述根据所述目标 数据流的流量,计算对所述目标数据流的转发速率,包括:根据当前时间戳及当前时间戳下的累积转发量和所述记录内容中的时间戳以及所述时间戳下的累积转发量,计算对所述目标数据流的转发速率。
- 根据权利要求1所述的方法,其特征在于,所述若所述目标数据流的流量满足第一预设条件,则在第一存储组件中维护所述目标数据流对应的第一统计记录,包括:若所述目标数据流的流量满足第一预设条件,则查询所述第一存储组件中的第一统计表;若在所述第一统计表中查询到所述目标数据流对应的统计记录,则将查询到的统计记录作为所述第一统计记录;若在所述第一统计表中未查询到所述目标数据流对应的统计记录,则在所述第一统计表中创建所述第一统计记录。
- 根据权利要求8所述的方法,其特征在于,所述在所述第一统计表中创建所述第一统计记录,包括:若所述第一统计表已满,则确定所述第一统计表中各数据流对应的转发速率;选择转发速率低于第二阈值的一数据流对应的目标统计记录;从所述第一统计表中删除所述目标统计记录,并将所述目标统计记录累加至所述第二存储组件中所述选择出的数据流对应的统计记录;在所述第一统计表中创建所述第一统计记录。
- 根据权利要求1所述的方法,其特征在于,还包括:若所述目标数据流的流量不满足所述第一预设条件,判断所述目标数据流的流量是否满足第二预设条件;若所述目标数据流的流量满足所述第二预设条件,则查询所述第一存储组件中的第一统计表;若在第一统计表中查询到目标数据流对应的第一统计记录,则根据所述第一统计记录更新所述第二统计记录,并停止基于所述第一统计记录对所述目标数据了进行统计;基于所述第二统计记录对所述目标数据流进行统计,并继续执行所述判断所述目标数据流的流量是否满足所述第一预设条件的操作。
- 根据权利要求10所述的方法,其特征在于,还包括:根据所述目标数据流的流量,计算对所述目标数据流的转发速率;若所述转发速率低于第二阈值,则确定所述目标数据流的流量满 足所述第二预设条件。
- 根据权利要求1所述的方法,其特征在于,在监控目标数据流的流量之前,还包括:在监听到针对目标数据流的转发请求的情况下,若所述第一存储组件中的第一统计表未满且所述第一统计表中未包含与所述目标数据流对应的统计记录,则在所述第一统计表中创建所述目标数据流对应的统计记录,并基于在所述第一统计表中创建的所述统计记录,对所述目标数据流进行统计;若所述第一统计表已满,则在所述第二存储组件中的第二统计表中创建所述目标数据流对应的统计记录;并基于在所述第二统计表中创建的所述统计记录,对所述目标数据流进行统计。
- 根据权利要求1所述的方法,其特征在于,所述第一存储组件采用内存、缓存或硬盘,所述第二存储组件采用双倍速率同步动态随机存储器DDR。
- 一种计算设备,其特征在于,包括第一存储组件、第二存储组件和处理器,所述处理器与所述第一存储组件和所述第二存储组件耦合,所述第一存储组件的存取速度高于所述第二存储组件;所述处理器,用于监控目标数据流的流量;若所述目标数据流的流量满足第一预设条件,则在第一存储组件中维护所述目标数据流对应的第一统计记录,以基于所述第一统计记录对所述目标数据流进行统计;根据所述第一统计记录更新所述目标数据流对应的第二统计记录,所述第二统计记录配置于第二存储组件中;所述第一存储组件,用于存储所述目标数据流对应的第一统计记录;所述第二存储组件,用于存储所述目标数据流对应的第二统计记录。
- 根据权利要求14所述的设备,其特征在于,所述处理器在根据所述第一统计记录更新所述目标数据流对应的第二统计记录时,用于:在所述第一统计记录发生溢出的情况下,根据所述第一统计记录更新所述目标数据流对应的第二统计记录。
- 根据权利要求15所述的设备,其特征在于,所述处理器在根据所述第一统计记录更新所述目标数据流对应的第二统计记录时,用于:将所述第一统计记录包含的各统计值累加至所述第二统计记录中相应的统计值;对所述第一统计记录包含的各统计值进行清零,并继续基于所述第一统计记录对所述目标数据流进行统计。
- 根据权利要求14所述的设备,其特征在于,所述处理器还用于:根据所述目标数据流的流量,计算对所述目标数据流的转发速率;若所述转发速率超过第一阈值,则确定所述目标数据流的流量满足第一预设条件。
- 根据权利要求17所述的设备,其特征在于,所述处理器还用于:为所述目标数据流维护一记录内容,所述记录内容包括时间戳以及所述时间戳下的累积转发量;以预设的时间戳间隔或累计转发量增量作为触发条件,更新所述记录内容;所述监控目标数据流的流量时,用于:从所述目标数据流对应的记录内容中,获取所述累积转发量,作为所述流量。
- 根据权利要求18所述的设备,其特征在于,所述记录内容配置于所述第一统计记录中或所述第二统计记录中。
- 根据权利要求18所述的设备,其特征在于,所述处理器在根据所述目标数据流的流量,计算对所述目标数据流的转发速率时,用于:根据当前时间戳及当前时间戳下的累积转发量和所述记录内容中的时间戳以及所述时间戳下的累积转发量,计算对所述目标数据流的转发速率。
- 根据权利要求14所述的设备,其特征在于,若目标数据流的流量满足第一预设条件,则所述处理器在第一存储组件中维护所述目标数据流对应的第一统计记录时,用于:若目标数据流的流量满足第一预设条件,则查询所述第一存储组件中的第一统计表;若在所述第一统计表中查询到所述目标数据流对应的统计记录,则将查询到的统计记录作为所述第一统计记录;若在所述第一统计表中未查询到所述目标数据流对应的统计记 录,则在所述第一统计表中创建所述第一统计记录。
- 根据权利要求21所述的设备,其特征在于,所述处理器在所述第一统计表中创建所述第一统计记录时,用于:若所述第一统计表已满,则确定所述第一统计表中各数据流对应的转发速率;选择转发速率低于第二阈值的一数据流对应的目标统计记录;从所述第一统计表中删除所述目标统计记录,并将所述目标统计记录累加至所述第二存储组件中所述选择出的数据流对应的统计记录;在所述第一统计表中创建所述第一统计记录。
- 根据权利要求14所述的设备,其特征在于,所述处理器还用于:若所述目标数据流的流量不满足所述第一预设条件,判断所述目标数据流的流量是否满足第二预设条件;若所述目标数据流的流量满足所述第二预设条件,则查询所述第一存储组件中的第一统计表;若在第一统计表中查询到目标数据流对应的第一统计记录,则根据所述第一统计记录更新所述第二统计记录,并停止基于所述第一统计记录对所述目标数据了进行统计;基于所述第二统计记录对所述目标数据流进行统计,并继续执行所述判断所述目标数据流的流量是否满足所述第一预设条件的操作。
- 根据权利要求23所述的设备,其特征在于,所述处理器还用于:根据所述目标数据流的流量,计算对所述目标数据流的转发速率;若所述转发速率低于第二阈值,则确定所述目标数据流的流量满足所述第二预设条件。
- 根据权利要求14所述的设备,其特征在于,在监控目标数据流的流量之前,所述处理器还用于:在监听到针对目标数据流的转发请求的情况下,若所述第一存储组件中的第一统计表未满且所述第一统计表中未包含与所述目标数据流对应的统计记录,则在所述第一统计表中创建所述目标数据流对应的统计记录,并基于在所述第一统计表中创建的所述统计记录,对所述目标数据流进行统计;若所述第一统计表已满,则在所述第二存储组件中的第二统计表中创建所述目标数据流对应的统计记录;并基于在所述第二统计表中 创建的所述统计记录,对所述目标数据流进行统计。
- 根据权利要求14所述的设备,其特征在于,所述第一存储组件采用内存、缓存或硬盘,所述第二存储组件采用双倍速率同步动态随机存储器DDR。
- 一种存储计算机指令的计算机可读存储介质,其特征在于,当所述计算机指令被一个或多个处理器执行时,致使所述一个或多个处理器执行权利要求1-13任一项所述的数据流统计方法。
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010626672.9 | 2020-07-01 | ||
CN202010626672.9A CN114095386B (zh) | 2020-07-01 | 2020-07-01 | 一种数据流统计方法、设备及存储介质 |
Publications (1)
Publication Number | Publication Date |
---|---|
WO2022001917A1 true WO2022001917A1 (zh) | 2022-01-06 |
Family
ID=79317438
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
PCT/CN2021/102624 WO2022001917A1 (zh) | 2020-07-01 | 2021-06-28 | 一种数据流统计方法、设备及存储介质 |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN114095386B (zh) |
WO (1) | WO2022001917A1 (zh) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN115396373A (zh) * | 2022-10-27 | 2022-11-25 | 阿里云计算有限公司 | 基于云服务器的信息处理方法、系统及电子设备 |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20100169280A1 (en) * | 2008-12-26 | 2010-07-01 | Huawei Technologies Co., Ltd. | Distributed network construction and storage method, apparatus and system |
CN104821887A (zh) * | 2014-01-30 | 2015-08-05 | 马维尔以色列(M.I.S.L.)有限公司 | 通过使用具有不同延迟的存储器来进行分组处理的设备和方法 |
CN106055606A (zh) * | 2016-05-25 | 2016-10-26 | 合网络技术(北京)有限公司 | 流数据处理方法和装置 |
CN106407636A (zh) * | 2015-07-31 | 2017-02-15 | 腾讯科技(深圳)有限公司 | 集成结果统计方法及装置 |
CN109614264A (zh) * | 2018-10-31 | 2019-04-12 | 华为技术有限公司 | 一种数据备份方法、装置及系统 |
CN110661824A (zh) * | 2018-06-28 | 2020-01-07 | 阿里巴巴集团控股有限公司 | 分布式集群中服务器的流量调控方法以及装置 |
Family Cites Families (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109428774B (zh) * | 2017-08-22 | 2020-12-22 | 网宿科技股份有限公司 | 一种dpi设备的数据处理方法及相关的dpi设备 |
US10476803B2 (en) * | 2017-12-18 | 2019-11-12 | Mellanox Technologies, Ltd. | Elephant flow detection in network access |
CN108809826A (zh) * | 2018-04-27 | 2018-11-13 | 广州西麦科技股份有限公司 | 一种大象数据流处理方法、装置、p4交换机及介质 |
CN110943883B (zh) * | 2019-11-13 | 2023-01-31 | 深圳市东进技术股份有限公司 | 网络流量统计方法、系统、网关及计算机可读存储介质 |
-
2020
- 2020-07-01 CN CN202010626672.9A patent/CN114095386B/zh active Active
-
2021
- 2021-06-28 WO PCT/CN2021/102624 patent/WO2022001917A1/zh active Application Filing
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20100169280A1 (en) * | 2008-12-26 | 2010-07-01 | Huawei Technologies Co., Ltd. | Distributed network construction and storage method, apparatus and system |
CN104821887A (zh) * | 2014-01-30 | 2015-08-05 | 马维尔以色列(M.I.S.L.)有限公司 | 通过使用具有不同延迟的存储器来进行分组处理的设备和方法 |
CN106407636A (zh) * | 2015-07-31 | 2017-02-15 | 腾讯科技(深圳)有限公司 | 集成结果统计方法及装置 |
CN106055606A (zh) * | 2016-05-25 | 2016-10-26 | 合网络技术(北京)有限公司 | 流数据处理方法和装置 |
CN110661824A (zh) * | 2018-06-28 | 2020-01-07 | 阿里巴巴集团控股有限公司 | 分布式集群中服务器的流量调控方法以及装置 |
CN109614264A (zh) * | 2018-10-31 | 2019-04-12 | 华为技术有限公司 | 一种数据备份方法、装置及系统 |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN115396373A (zh) * | 2022-10-27 | 2022-11-25 | 阿里云计算有限公司 | 基于云服务器的信息处理方法、系统及电子设备 |
Also Published As
Publication number | Publication date |
---|---|
CN114095386B (zh) | 2024-03-26 |
CN114095386A (zh) | 2022-02-25 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP7039685B2 (ja) | トラフィック測定方法、デバイス、およびシステム | |
JP6921069B2 (ja) | ネットワーク攻撃を識別するための方法及び装置 | |
EP3425524A1 (en) | Cloud platform-based client application data calculation method and device | |
US8145859B2 (en) | Method and system for spilling from a queue to a persistent store | |
US20140258375A1 (en) | System and method for large object cache management in a network | |
WO2017028696A1 (zh) | 分布式存储系统的负载监控方法及设备 | |
TWI738721B (zh) | 任務調度方法和裝置 | |
US10419370B2 (en) | Hierarchical packet buffer system | |
EP3282643B1 (en) | Method and apparatus of estimating conversation in a distributed netflow environment | |
TWI677210B (zh) | 一種企業物件的資訊加載方法和裝置 | |
WO2016141735A1 (zh) | 缓存数据的确定方法及装置 | |
CN112131005B (zh) | 一种资源调整策略确定方法和装置 | |
US11095674B2 (en) | DDoS attack detection method and device | |
WO2022001917A1 (zh) | 一种数据流统计方法、设备及存储介质 | |
WO2022022558A1 (zh) | 用于聚合链路的流量分配方法、装置、光线路终端及存储介质 | |
US20190155985A1 (en) | Communication protocols design verification through database systems for hardware-based emulation platforms | |
CN109521969B (zh) | 一种固态硬盘数据回收方法、装置和计算机可读存储介质 | |
WO2024169387A1 (zh) | 资源调度方法、装置、电子设备和存储介质 | |
US20150078388A1 (en) | Sequence number retrieval for voice data with redundancy | |
WO2017157164A1 (zh) | 数据聚合方法及装置 | |
CN104012056A (zh) | 减小归因于网络交换机处的聚播崩溃的tcp超时 | |
WO2022179294A1 (zh) | 数据预取的方法、设备及系统 | |
CN110727518B (zh) | 一种数据处理方法及相关设备 | |
CN107544760B (zh) | 一种分布式存储请求的下发方法、装置、设备及存储介质 | |
CN109413122B (zh) | 一种数据处理方法、网络处理器及计算机存储介质 |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
NENP | Non-entry into the national phase |
Ref country code: DE |
|
122 | Ep: pct application non-entry in european phase |
Ref document number: 21834153 Country of ref document: EP Kind code of ref document: A1 |