CN117376206A - A method and device for detecting network status, electronic equipment, and storage media - Google Patents
A method and device for detecting network status, electronic equipment, and storage media Download PDFInfo
- Publication number
- CN117376206A CN117376206A CN202210771501.4A CN202210771501A CN117376206A CN 117376206 A CN117376206 A CN 117376206A CN 202210771501 A CN202210771501 A CN 202210771501A CN 117376206 A CN117376206 A CN 117376206A
- Authority
- CN
- China
- Prior art keywords
- trip delay
- round
- network
- kurtosis
- data packet
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Classifications
-
- 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/0852—Delays
- H04L43/0864—Round trip delays
-
- 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/04—Processing captured monitoring data, e.g. for logfile generation
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Environmental & Geological Engineering (AREA)
- Data Mining & Analysis (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
The invention provides a method and a device for detecting network state, electronic equipment and a storage medium, wherein the method for detecting network state comprises the following steps: recording the sending time of the sending data packet; receiving feedback information for receiving the sending data packet, analyzing the receiving feedback information, and obtaining the receiving time recorded when a receiving client receives the sending data packet through a network; acquiring the round trip delay of the transmitted data packet according to the transmission time and the receiving time, and storing the round trip delay sequence to a preset length; acquiring the skewness and kurtosis of the round-trip delay sequence based on the round-trip delay stored in the round-trip delay sequence; based on the skewness and kurtosis, a network state of the network is determined. The network bandwidth utilization may be improved.
Description
Technical Field
The present invention relates to the field of network detection technologies, and in particular, to a method and apparatus for detecting a network state, an electronic device, and a storage medium.
Background
The internet provides a carrier for the transmission of mass data, but in the process of transmitting data through the internet, the condition of network jitter state mutation is often encountered due to the environmental change of the internet. For example, on a train, since a control management protocol of a base station periodically negotiates a Round Trip Time (RTT) threshold with a mobile device through a network, a client performs a data retransmission process based on a data transmission delay and the negotiated threshold. However, in the method, in the case of abrupt network jitter (train coasting or traveling in mountainous areas), the mobile device cannot acquire the information of the base limit in time through the network. Therefore, for the algorithm that the delay change is adopted in the mobile device to estimate the limitation of the network, the data transmission and retransmission processing is performed according to the base limit negotiated before the sudden change of the jitter state of the network, and erroneous judgment may be generated, for example, network congestion or congestion relief may be confirmed, so that the estimation of the available bandwidth is wrong, and thus the utilization rate of the network bandwidth is insufficient and is lower.
Disclosure of Invention
In view of the above, the present invention is directed to a method and apparatus for detecting a network status, an electronic device, and a storage medium, so as to improve the network bandwidth utilization.
In a first aspect, an embodiment of the present invention provides a method for detecting a network state, including:
recording the sending time of the sending data packet;
receiving feedback information for receiving the sending data packet, analyzing the receiving feedback information, and obtaining the receiving time recorded when a receiving client receives the sending data packet through a network;
acquiring the round trip delay of the transmitted data packet according to the transmission time and the receiving time, and storing the round trip delay sequence to a preset length;
acquiring the skewness and kurtosis of the round-trip delay sequence based on the round-trip delay stored in the round-trip delay sequence;
based on the skewness and kurtosis, a network state of the network is determined.
With reference to the first aspect, an embodiment of the present invention provides a first possible implementation manner of the first aspect, where the determining, based on the skewness and kurtosis, a network state of the network includes:
obtaining a standard deviation error and a standard kurtosis error;
calculating the skewness quotient of the skewness and the standard deviation of the skewness and the kurtosis quotient of the kurtosis and the kurtosis marking error;
and if the skewness quotient is smaller than or equal to a preset skewness threshold value and the kurtosis quotient is smaller than or equal to a preset kurtosis threshold value, determining that the network state of the network is a stable state.
With reference to the first possible implementation manner of the first aspect, the embodiment of the present invention provides a second possible implementation manner of the first aspect, where the method further includes:
if the skewness quotient is greater than the skewness threshold, or the kurtosis quotient is greater than the kurtosis threshold, calculating an autocorrelation coefficient of the round trip delay sequence;
and if the autocorrelation coefficient is smaller than or equal to a preset autocorrelation threshold, determining that the network state of the network is a stable state, and if the autocorrelation coefficient is larger than the autocorrelation threshold, determining that the network state of the network is a non-stable state.
With reference to the first aspect, the first possible implementation manner or the second possible implementation manner of the first aspect, the embodiment of the present invention provides a third possible implementation manner of the first aspect, wherein the obtaining, based on the round trip delay stored in the round trip delay sequence, the skewness and kurtosis of the round trip delay sequence includes:
acquiring a delay average value of each round trip delay in the round trip delay sequence;
calculating the delay difference value between each round trip delay and the delay average value;
calculating the cube sum average value of the cube sum of each time delay difference value;
calculating the square sum of the delay difference values, obtaining the delay number difference value of the round trip delay number minus 1, calculating the quotient of the square sum and the delay number difference value to obtain a first average value of the square sum, and calculating the third power of the first average value of the square sum to obtain a square center difference;
calculating the quotient of the cubic sum mean value and the square center difference to obtain the skewness of the round trip delay sequence;
calculating the fourth power sum mean value of the fourth power sum of the time delay differences;
calculating the square sum of the delay difference values, obtaining the delay number difference value of the round trip delay number minus 1, and calculating the quotient of the square sum and the round trip delay number to obtain a second average value of the square sum;
and calculating the quotient of the square of the fourth-order sum mean value and the square of the square sum second mean value, and subtracting 3 to obtain the kurtosis of the round-trip delay sequence.
With reference to the first aspect, the first possible implementation manner or the second possible implementation manner of the first aspect, the embodiment of the present invention provides a fourth possible implementation manner of the first aspect, where the method further includes:
if the receiving feedback information for receiving the sending data packet is not received within the preset receiving time threshold, setting the receiving time of the sending data packet as the current time.
With reference to the first aspect, the first possible implementation manner or the second possible implementation manner of the first aspect, the embodiment of the present invention provides a fifth possible implementation manner of the first aspect, where the obtaining the round trip delay of the sent data packet, and storing the round trip delay sequence to a preset length, includes:
inquiring whether the round-trip delay sequence is full, if so, deleting the first stored round-trip delay according to a first-in first-out strategy, sequentially advancing the stored round-trip delay, and storing the round-trip delay of the sent data packet to the last of the round-trip delay sequence; if not, the round trip delay of the sent data packet is stored to the back of the last round trip delay stored in the round trip delay sequence.
With reference to the first aspect, the first possible implementation manner or the second possible implementation manner of the first aspect, the embodiment of the present invention provides a sixth possible implementation manner of the first aspect, where before recording a transmission time of a transmission data packet, the method further includes:
and the sending client determines whether the received network signal strength is lower than a preset signal strength threshold, if yes, the step of recording the sending time of the sending data packet is executed, if not, the step of waiting for the next period and the step of determining whether the received network signal strength is lower than the preset signal strength threshold is executed.
In a second aspect, an embodiment of the present invention further provides an apparatus for detecting a network state, including:
the recording module is used for recording the sending time of the sending data packet;
the analysis module is used for receiving the receiving feedback information for receiving the sending data packet, analyzing the receiving feedback information and obtaining the receiving time recorded when the receiving client receives the sending data packet through a network;
the time delay calculation module is used for acquiring the round trip time delay of the transmitted data packet according to the transmitting time and the receiving time and storing the round trip time delay sequence to a preset length;
the kurtosis calculation module is used for acquiring the kurtosis and the skewness of the round-trip delay sequence based on the round-trip delay stored in the round-trip delay sequence;
and the state detection module is used for determining the network state of the network based on the skewness and kurtosis.
In a third aspect, embodiments of the present application provide a computer device including a memory, a processor, and a computer program stored on the memory and executable on the processor, the processor implementing the steps of the above method when executing the computer program.
In a fourth aspect, embodiments of the present application provide a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of the method described above.
The embodiment of the invention provides a method and a device for detecting network state, electronic equipment and a storage medium, wherein the sending time of a sending data packet is recorded; receiving feedback information for receiving the sending data packet, analyzing the receiving feedback information, and obtaining the receiving time recorded when a receiving client receives the sending data packet through a network; acquiring the round trip delay of the transmitted data packet according to the transmission time and the receiving time, and storing the round trip delay sequence to a preset length; acquiring the skewness and kurtosis of the round-trip delay sequence based on the round-trip delay stored in the round-trip delay sequence; based on the skewness and kurtosis, a network state of the network is determined. Therefore, network state detection is carried out according to the round trip delay, and whether the network is in a stable state can be rapidly judged without obtaining information of a base limit through negotiation, so that accurate estimation of available bandwidth is realized, and the utilization rate of network bandwidth is improved.
In order to make the above objects, features and advantages of the present invention more comprehensible, preferred embodiments accompanied with figures are described in detail below.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings that are needed in the embodiments will be briefly described below, it being understood that the following drawings only illustrate some embodiments of the present invention and therefore should not be considered as limiting the scope, and other related drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 is a flowchart of a method for detecting a network state according to an embodiment of the present invention;
fig. 2 is a schematic structural diagram of an apparatus for detecting a network state according to an embodiment of the present invention;
fig. 3 is a schematic structural diagram of a computer device 300 according to an embodiment of the present application.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the embodiments of the present invention more apparent, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention, and it is apparent that the described embodiments are only some embodiments of the present invention, not all embodiments. The components of the embodiments of the present invention generally described and illustrated in the figures herein may be arranged and designed in a wide variety of different configurations. Thus, the following detailed description of the embodiments of the invention, as presented in the figures, is not intended to limit the scope of the invention, as claimed, but is merely representative of selected embodiments of the invention. All other embodiments, which can be made by a person skilled in the art without making any inventive effort, are intended to be within the scope of the present invention.
The embodiment of the invention provides a method and a device for detecting network state, electronic equipment and a storage medium, and the method and the device are described in the following embodiments.
Fig. 1 is a flowchart of a method for detecting a network state according to an embodiment of the present invention.
As shown in fig. 1, the method includes:
step 101, recording the sending time of a sending data packet;
in the embodiment of the invention, when a sending client sends data packets to a receiving client through a network, the time (sending time) when each sending data packet leaves the sending client is recorded.
In the embodiment of the present invention, as an optional embodiment, the sending client includes, but is not limited to: mobile phones, personal digital assistants, notebook computers, fixed terminals, servers, routers, switches, devices in virtual local area networks (VLAN, virtual Local Area Network), devices in a given network.
In an embodiment of the present invention, as an optional embodiment, before recording a transmission time of the transmission data packet, the method further includes:
and the sending client determines whether the received network signal strength is lower than a preset signal strength threshold, if yes, the step of recording the sending time of the sending data packet is executed, if not, the step of waiting for the next period and the step of determining whether the received network signal strength is lower than the preset signal strength threshold is executed.
In the embodiment of the invention, the strength of the network signal received by the sending client can be changed within a period of time before the sudden change of the network jitter state, so that the sending time of the sending data packet is triggered and recorded after the strength of the network signal is lower than the signal strength threshold value, and the data volume to be recorded can be reduced. As another alternative embodiment, the step of recording the transmission time of the transmission data packet may be triggered to be performed after the transmission client enters a preset area (e.g., a longer bridge hole, a tunnel, a multi-mountain area).
Step 102, receiving the receiving feedback information for receiving the sending data packet, analyzing the receiving feedback information, and obtaining the receiving time recorded when the receiving client receives the sending data packet through the network;
in the embodiment of the invention, when receiving the sending data packet transmitted by the sending client through the network, the receiving client records the time of receiving the sending data packet, carries the receiving time in the receiving feedback information and feeds back the receiving time to the sending client.
In the embodiment of the present invention, when the network state changes sharply, the sending client may not receive the feedback information received by the receiving client through the network for a longer time, so as an optional embodiment, the method further includes:
if the receiving feedback information for receiving the sending data packet is not received within the preset receiving time threshold, setting the receiving time of the sending data packet as the current time.
Step 103, according to the sending time and the receiving time, acquiring the round trip delay of the sending data packet, and storing the round trip delay sequence to a preset length;
in the embodiment of the present invention, as an optional embodiment, the acquiring the round trip delay of the sent data packet and storing the round trip delay sequence to a preset length includes:
inquiring whether the round-trip delay sequence is full, if so, deleting the first stored round-trip delay according to a first-in first-out strategy, sequentially advancing the stored round-trip delay, and storing the round-trip delay of the sent data packet to the last of the round-trip delay sequence; if not, the round trip delay of the sent data packet is stored to the back of the last round trip delay stored in the round trip delay sequence.
In the embodiment of the invention, the length of the round trip delay sequence is used for guaranteeing the statistical requirements in the subsequent statistics of skewness and kurtosis on one hand, and is used for judging the network state in time on the other hand. As an alternative embodiment, the length of the round trip delay sequence is greater than or equal to a predetermined statistical minimum requirement. In the embodiment of the present invention, the length may be set to 30 statistics, that is, the number of stored round trip delays is 30, or may be set to 50 statistics, where a specific value may be determined according to an application scenario in which a sending client and a receiving client perform network communication.
104, acquiring the skewness and kurtosis of the round-trip delay sequence based on the round-trip delay stored in the round-trip delay sequence;
in the embodiment of the present invention, as an optional embodiment, obtaining the skewness and kurtosis of the round-trip delay sequence based on the round-trip delay stored in the round-trip delay sequence includes:
acquiring a delay average value of each round trip delay in the round trip delay sequence;
calculating the delay difference value between each round trip delay and the delay average value;
calculating the cube sum average value of the cube sum of each time delay difference value;
calculating the square sum of the delay difference values, obtaining the delay number difference value of the round trip delay number minus 1, calculating the quotient of the square sum and the delay number difference value to obtain a first average value of the square sum, and calculating the third power of the first average value of the square sum to obtain a square center difference;
calculating the quotient of the cubic sum mean value and the square center difference to obtain the skewness of the round trip delay sequence;
calculating the fourth power sum mean value of the fourth power sum of the time delay differences;
calculating the square sum of the delay difference values, obtaining the delay number difference value of the round trip delay number minus 1, and calculating the quotient of the square sum and the round trip delay number to obtain a second average value of the square sum;
and calculating the quotient of the square of the fourth-order sum mean value and the square of the square sum second mean value, and subtracting 3 to obtain the kurtosis of the round-trip delay sequence.
In an embodiment of the present invention, as an alternative embodiment, the skewness and kurtosis are calculated using the following formulas:
in the method, in the process of the invention,
p is the skewness, n is the number of round trip delays contained in the round trip delay sequence;
x i is round trip delay, x' is delay mean value;
f is kurtosis.
Step 105, determining a network state of the network based on the skewness and kurtosis.
In an embodiment of the present invention, as an optional embodiment, determining a network state of the network based on the skewness and kurtosis includes:
obtaining a standard deviation error and a standard kurtosis error;
calculating the skewness quotient of the skewness and the standard deviation of the skewness and the kurtosis quotient of the kurtosis and the kurtosis marking error;
and if the skewness quotient is smaller than or equal to a preset skewness threshold value and the kurtosis quotient is smaller than or equal to a preset kurtosis threshold value, determining that the network state of the network is a stable state.
In the embodiment of the present invention, as an alternative embodiment, the skewness standard error and the kurtosis standard error are calculated using the following formulas:
in the method, in the process of the invention,
p' is the standard deviation error of the skewness;
f' is the kurtosis standard error.
In the embodiment of the present invention, as an alternative embodiment, the skewness threshold is set to 1.96, and the kurtosis threshold is set to 1.96.
In an embodiment of the present invention, as another optional embodiment, the method further includes:
if the skewness quotient is greater than the skewness threshold, or the kurtosis quotient is greater than the kurtosis threshold, calculating an autocorrelation coefficient of the round trip delay sequence;
and if the autocorrelation coefficient is smaller than or equal to a preset autocorrelation threshold, determining that the network state of the network is a stable state, and if the autocorrelation coefficient is larger than the autocorrelation threshold, determining that the network state of the network is a non-stable state.
In an embodiment of the present invention, as an alternative embodiment, the autocorrelation coefficients are calculated using the following formula:
ρ(i,s)=E((x i -x′)(x s -x′))
in the method, in the process of the invention,
gamma is the autocorrelation coefficient;
ρ (i, s) is the auto-covariance coefficient;
i, s is the sequence number of the round trip delay, E is the mathematical expectation, and D is the variance.
In the embodiment of the present invention, as an alternative embodiment, the autocorrelation threshold is set to 0.2.
In the embodiment of the invention, by calculating the RTT of each sent data packet, when the calculated RTT number exceeds 30 meeting the minimum requirement of statistics, the skewness, kurtosis standard error and skewness standard error of a round trip delay sequence formed by RTT are calculated. If the standard deviation of the deviation divided by the deviation is smaller than or equal to 1.96 and the standard deviation of the kurtosis divided by the kurtosis is smaller than or equal to 1.96, the network is considered to be in a stable state, and the kurtosis and the deviation of the network transmission are calculated in an iterative mode after a new round trip delay is received. If the deviation divided by the standard deviation is greater than 1.96, or the kurtosis divided by the standard deviation of kurtosis is greater than 1.96, calculating an autocorrelation coefficient of 30 RTTs, if the autocorrelation coefficient is less than or equal to 0.2, considering that the network is still in a stable state, if the autocorrelation coefficient is greater than 0.2, considering that the network state is in a change, adopting a corresponding sending strategy, for example, reducing the sending rate or adopting a diversity transmission mode, and then carrying out iterative calculation after receiving a new round trip delay. Therefore, under the condition of sudden change of the network jitter state, network state detection can be timely carried out, a data packet sending strategy is adjusted according to the network state detection result, abnormal network state assessment caused by RTT noise can be effectively eliminated without consulting to obtain basic limit information, whether the network is in a stable state can be rapidly judged, and therefore a network limited algorithm is guided to accelerate bandwidth recovery, accurate estimation of available bandwidth is achieved, and network bandwidth utilization rate is improved.
Fig. 2 is a schematic diagram of an apparatus for detecting a network state according to an embodiment of the present invention. As shown in fig. 2, the apparatus includes:
a recording module 201, configured to record a transmission time of a transmission data packet;
the parsing module 202 is configured to receive the receiving feedback information for receiving the sending data packet, parse the receiving feedback information, and obtain a receiving time recorded when the receiving client receives the sending data packet through a network;
the delay calculation module 203 is configured to obtain a round trip delay of the sent data packet according to the sending time and the receiving time, and store the round trip delay sequence to a preset length;
in this embodiment of the present invention, as an optional embodiment, the delay calculation module 203 is specifically configured to:
inquiring whether the round-trip delay sequence is full or not according to the sending time and the receiving time, if yes, deleting the first stored round-trip delay according to a first-in first-out strategy, sequentially advancing the stored round-trip delay, and storing the round-trip delay of the sending data packet to the last of the round-trip delay sequence; if not, the round trip delay of the sent data packet is stored to the back of the last round trip delay stored in the round trip delay sequence.
A kurtosis calculation module 204, configured to obtain a kurtosis and a kurtosis of the round-trip delay sequence based on the round-trip delay stored in the round-trip delay sequence;
in an embodiment of the present invention, as an optional embodiment, the kurtosis calculation module 204 includes:
a delay difference calculating unit (not shown in the figure) for obtaining a delay average value of each round trip delay in the round trip delay sequence; calculating the delay difference value between each round trip delay and the delay average value;
the deviation calculating unit is used for calculating the cube sum average value of the cube sum of the time delay differences; calculating the square sum of the delay difference values, obtaining the delay number difference value of the round trip delay number minus 1, calculating the quotient of the square sum and the delay number difference value to obtain a first average value of the square sum, and calculating the third power of the first average value of the square sum to obtain a square center difference; calculating the quotient of the cubic sum mean value and the square center difference to obtain the skewness of the round trip delay sequence;
the kurtosis calculation unit is used for calculating the fourth power sum mean value of the fourth power sum of the time delay differences; calculating the square sum of the delay difference values, obtaining the delay number difference value of the round trip delay number minus 1, and calculating the quotient of the square sum and the round trip delay number to obtain a second average value of the square sum; and calculating the quotient of the square of the fourth-order sum mean value and the square of the square sum second mean value, and subtracting 3 to obtain the kurtosis of the round-trip delay sequence.
A state detection module 205, configured to determine a network state of the network based on the skewness and kurtosis.
In an embodiment of the present invention, as an optional embodiment, the state detection module 205 includes:
a standard error calculation unit (not shown in the figure) for acquiring a skewness standard error and a kurtosis standard error;
the quotient calculation unit is used for calculating the skewness quotient of the skewness and the standard deviation of the skewness and the kurtosis quotient of the kurtosis and the kurtosis marking error;
and the state judging first unit is used for determining that the network state of the network is a stable state if the skewness quotient is smaller than or equal to a preset skewness threshold value and the kurtosis quotient is smaller than or equal to a preset kurtosis threshold value.
In an embodiment of the present invention, as another alternative embodiment, the state detection module 205 further includes:
an autocorrelation coefficient calculation unit for calculating the autocorrelation coefficient of the round-trip delay sequence if the skewness quotient is greater than the skewness threshold or the kurtosis quotient is greater than the kurtosis threshold;
and the state judging second unit is used for determining that the network state of the network is in a stable state if the autocorrelation coefficient is smaller than or equal to a preset autocorrelation threshold value, and determining that the network state of the network is in a non-stable state if the autocorrelation coefficient is larger than the autocorrelation threshold value.
In an embodiment of the present invention, as an optional embodiment, the apparatus further includes:
a receiving processing module (not shown in the figure) sets the receiving time of the sending data packet as the current time if the receiving feedback information for receiving the sending data packet is not received within a preset receiving time threshold.
In an embodiment of the present invention, as another optional embodiment, the apparatus further includes:
and the signal strength comparison module is used for determining whether the received network signal strength is lower than a preset signal strength threshold value, if so, executing the step of recording the transmission time of the transmitted data packet, and if not, waiting for the next period, and executing the step of determining whether the received network signal strength is lower than the preset signal strength threshold value.
As shown in fig. 3, an embodiment of the present application provides a computer device 300 for executing the method for detecting a network state in fig. 1, where the device includes a memory 301, a processor 302 connected to the memory 301 through a bus, and a computer program stored on the memory 301 and capable of running on the processor 302, where the steps of the method for detecting a network state are implemented when the processor 302 executes the computer program.
Specifically, the above-mentioned memory 301 and the processor 302 can be general-purpose memories and processors, and are not particularly limited herein, and the above-mentioned method of detecting a network state can be performed when the processor 302 runs a computer program stored in the memory 301.
Corresponding to the method for detecting a network state in fig. 1, the embodiment of the present application further provides a computer readable storage medium, on which a computer program is stored, which when being executed by a processor, performs the steps of the method for detecting a network state described above.
In particular, the storage medium can be a general-purpose storage medium, such as a removable disk, a hard disk, etc., on which the computer program is executed, capable of performing the above-described method of detecting a network state.
In the embodiments provided herein, it should be understood that the disclosed systems and methods may be implemented in other ways. The system embodiments described above are merely illustrative, e.g., the division of the elements is merely a logical functional division, and there may be additional divisions in actual implementation, and e.g., multiple elements or components may be combined or integrated into another system, or some features may be omitted, or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed with each other may be through some communication interface, system or unit indirect coupling or communication connection, which may be in electrical, mechanical or other form.
The units described as separate units may or may not be physically separate, and units shown as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
In addition, each functional unit in the embodiments provided in the present application may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a computer-readable storage medium. Based on such understanding, the technical solution of the present application may be embodied essentially or in a part contributing to the prior art or in a part of the technical solution, in the form of a software product stored in a storage medium, including several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods described in the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (Random Access Memory, RAM), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
It should be noted that: like reference numerals and letters in the following figures denote like items, and thus once an item is defined in one figure, no further definition or explanation of it is required in the following figures, and furthermore, the terms "first," "second," "third," etc. are used merely to distinguish one description from another and are not to be construed as indicating or implying relative importance.
Finally, it should be noted that: the foregoing examples are merely specific embodiments of the present application, and are not intended to limit the scope of the present application, but the present application is not limited thereto, and those skilled in the art will appreciate that while the foregoing examples are described in detail, the present application is not limited thereto. Any person skilled in the art may modify or easily conceive of the technical solution described in the foregoing embodiments, or make equivalent substitutions for some of the technical features within the technical scope of the disclosure of the present application; such modifications, changes or substitutions do not depart from the spirit and scope of the corresponding technical solutions. Are intended to be encompassed within the scope of this application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.
Claims (10)
1. A method of detecting a network condition, comprising:
recording the sending time of the sending data packet;
receiving feedback information for receiving the sending data packet, analyzing the receiving feedback information, and obtaining the receiving time recorded when a receiving client receives the sending data packet through a network;
acquiring the round trip delay of the transmitted data packet according to the transmission time and the receiving time, and storing the round trip delay sequence to a preset length;
acquiring the skewness and kurtosis of the round-trip delay sequence based on the round-trip delay stored in the round-trip delay sequence;
based on the skewness and kurtosis, a network state of the network is determined.
2. The method of claim 1, wherein the determining the network state of the network based on the skewness and kurtosis comprises:
obtaining a standard deviation error and a standard kurtosis error;
calculating the skewness quotient of the skewness and the standard deviation of the skewness and the kurtosis quotient of the kurtosis and the kurtosis marking error;
and if the skewness quotient is not greater than the preset skewness threshold, and the kurtosis quotient is not greater than the preset kurtosis threshold, determining that the network state of the network is a stable state.
3. The method according to claim 2, wherein the method further comprises:
if the skewness quotient is greater than the skewness threshold, or the kurtosis quotient is greater than the kurtosis threshold, calculating an autocorrelation coefficient of the round trip delay sequence;
if the autocorrelation coefficient is smaller than or equal to a preset autocorrelation threshold, determining that the network state of the network is a stable state;
and if the autocorrelation coefficient is greater than the autocorrelation threshold, determining that the network state of the network is a non-stationary state.
4. A method according to any one of claims 1 to 3, wherein said obtaining the skewness and kurtosis of the round trip delay sequence based on the round trip delays stored in the round trip delay sequence comprises:
acquiring a delay average value of each round trip delay in the round trip delay sequence;
calculating the delay difference value between each round trip delay and the delay average value;
calculating the cube sum average value of the cube sum of each time delay difference value;
calculating the square sum of the delay difference values, obtaining the delay number difference value of the round trip delay number minus 1, calculating the quotient of the square sum and the delay number difference value to obtain a first average value of the square sum, and calculating the third power of the first average value of the square sum to obtain a square center difference;
calculating the quotient of the cubic sum mean value and the square center difference to obtain the skewness of the round trip delay sequence;
calculating the fourth power sum mean value of the fourth power sum of the time delay differences;
calculating the square sum of the delay difference values, obtaining the delay number difference value of the round trip delay number minus 1, and calculating the quotient of the square sum and the round trip delay number to obtain a second average value of the square sum;
and calculating the quotient of the square of the fourth-order sum mean value and the square of the square sum second mean value, and subtracting 3 to obtain the kurtosis of the round-trip delay sequence.
5. A method according to any one of claims 1 to 3, further comprising:
if the receiving feedback information for receiving the sending data packet is not received within the preset receiving time threshold, setting the receiving time of the sending data packet as the current time.
6. A method according to any one of claims 1 to 3, wherein said obtaining the round trip delay of the transmitted data packet, storing the round trip delay sequence to a predetermined length, comprises:
inquiring whether the round-trip delay sequence is full, if so, deleting the first stored round-trip delay according to a first-in first-out strategy, sequentially advancing the stored round-trip delay, and storing the round-trip delay of the sent data packet to the last of the round-trip delay sequence; if not, the round trip delay of the sent data packet is stored to the back of the last round trip delay stored in the round trip delay sequence.
7. A method according to any one of claims 1 to 3, characterized in that before recording the transmission time of the transmitted data packet, the method further comprises:
and the sending client determines whether the received network signal strength is lower than a preset signal strength threshold, if yes, the step of recording the sending time of the sending data packet is executed, if not, the step of waiting for the next period and the step of determining whether the received network signal strength is lower than the preset signal strength threshold is executed.
8. An apparatus for detecting a network condition, comprising:
the recording module is used for recording the sending time of the sending data packet;
the analysis module is used for receiving the receiving feedback information for receiving the sending data packet, analyzing the receiving feedback information and obtaining the receiving time recorded when the receiving client receives the sending data packet through a network;
the time delay calculation module is used for acquiring the round trip time delay of the transmitted data packet according to the transmitting time and the receiving time and storing the round trip time delay sequence to a preset length;
the kurtosis calculation module is used for acquiring the kurtosis and the skewness of the round-trip delay sequence based on the round-trip delay stored in the round-trip delay sequence;
and the state detection module is used for determining the network state of the network based on the skewness and kurtosis.
9. A computer device, comprising: a processor, a memory and a bus, said memory storing machine readable instructions executable by said processor, said processor and said memory communicating over the bus when the computer device is running, said machine readable instructions when executed by said processor performing the steps of the method of detecting a network state as claimed in any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that it has stored thereon a computer program which, when executed by a processor, performs the steps of the method of detecting a network state according to any of claims 1 to 7.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202210771501.4A CN117376206A (en) | 2022-06-30 | 2022-06-30 | A method and device for detecting network status, electronic equipment, and storage media |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202210771501.4A CN117376206A (en) | 2022-06-30 | 2022-06-30 | A method and device for detecting network status, electronic equipment, and storage media |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| CN117376206A true CN117376206A (en) | 2024-01-09 |
Family
ID=89398948
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN202210771501.4A Pending CN117376206A (en) | 2022-06-30 | 2022-06-30 | A method and device for detecting network status, electronic equipment, and storage media |
Country Status (1)
| Country | Link |
|---|---|
| CN (1) | CN117376206A (en) |
-
2022
- 2022-06-30 CN CN202210771501.4A patent/CN117376206A/en active Pending
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| EP3832953B1 (en) | System, method, and apparatus for evaluating round-trip time | |
| US8073945B2 (en) | Method and apparatus for providing a measurement of performance for a network | |
| CN111817977B (en) | A network congestion control method and device | |
| US8593947B2 (en) | Congestion detection method, congestion detection apparatus, and recording medium storing congestion detection program recorded thereon | |
| JP4348124B2 (en) | Method and communication device for estimating QoS | |
| EP3468132B1 (en) | Method and device for transmitting speech data | |
| CN101606355A (en) | Measuring network performance with benchmark packet probes | |
| US9667547B2 (en) | Congestion management and latency prediction in CSMA media | |
| Smirnov et al. | Formal reliability analysis of switched ethernet automotive networks under transient transmission errors | |
| US7689686B2 (en) | Active probing for sustainable capacity estimation of networked dataflows | |
| TWI658715B (en) | Communication device, available bandwidth calculation system, available bandwidth calculation method, and program | |
| CN111343135B (en) | Network security situation detection method | |
| US9674726B1 (en) | Methods and systems for improved bandwidth estimation | |
| Kulkarni et al. | Analysis of TCP performance in data center networks | |
| CN117376206A (en) | A method and device for detecting network status, electronic equipment, and storage media | |
| CN114124754B (en) | Method for processing media data packets in a multimedia network and related products | |
| CN106453635B (en) | Message push method and device | |
| US9900207B2 (en) | Network control protocol | |
| CN112637055B (en) | Multi-link aggregation method, system and storage medium based on VPN tunnel | |
| CN118842756A (en) | Data transmission method, device, electronic equipment and computer readable storage medium | |
| WO2022222693A1 (en) | Message processing method and apparatus, electronic device, and computer-readable storage medium | |
| CN113542215A (en) | Method for improving streaming media transmission performance and related device | |
| US20140237136A1 (en) | Communication system, communication controller, communication control method, and medium | |
| CN116248172B (en) | Data transmission method, device and storage medium based on TCP/IP protocol and CCSDS protocol | |
| JP2004172706A (en) | Packet loss rate measurement method and system |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| PB01 | Publication | ||
| PB01 | Publication | ||
| WD01 | Invention patent application deemed withdrawn after publication | ||
| WD01 | Invention patent application deemed withdrawn after publication |
Application publication date: 20240109 |