CN106161052B - Network line selection method and network speed-measuring method - Google Patents
Network line selection method and network speed-measuring method Download PDFInfo
- Publication number
- CN106161052B CN106161052B CN201510148197.8A CN201510148197A CN106161052B CN 106161052 B CN106161052 B CN 106161052B CN 201510148197 A CN201510148197 A CN 201510148197A CN 106161052 B CN106161052 B CN 106161052B
- Authority
- CN
- China
- Prior art keywords
- speed
- network
- tests
- network line
- tool
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L41/00—Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
- H04L41/12—Discovery or management of network topologies
-
- 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
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Environmental & Geological Engineering (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
The invention discloses a kind of network line selection method and network speed-measuring methods.The network line selection method includes: to test the speed to carry out network more than once on every network line of the tool in a plurality of network line between the client and server-side of network application and test the speed using first, and more than one first average value for testing the speed value measured using the first tool of testing the speed is tested the speed result as the first of this network line;If first of any two network lines in a plurality of network line the difference to test the speed between result is greater than the first predetermined threshold, a network line for then selecting the network speed measured in a plurality of network line using the first tool of testing the speed most fast is as the network line actually used between client and server-side, and a network line for otherwise selecting the network speed measured in a plurality of network line using the second tool of testing the speed most fast is as the network line actually used between client and server-side.
Description
Technical field
The present invention relates to computer field, relate more specifically to a kind of network line selection method and network speed-measuring method.
Background technique
In general, the network application of such as online game, instant messaging tools, information publishing platform etc includes for running
Client (that is, client-side program) on the subscriber terminal and for running server-side on the server (that is, server journey
Sequence) two parts.When the client of network application is communicated with server-side, since the performance by user terminal, network operator set
The influence of the reasons such as standby performance and server load, sometimes network speed can be very slow, seriously affects user experience.
Requirement with user to the fluency of network application is growing day by day, and many application providers start network application
Server-side be arranged in the server with a plurality of network line so that the client of network application can pass through a plurality of net
Any one in winding thread road communicates with the server-side of network application.Specifically, when the client request of network application and network
When the server-side of application is communicated, the client of network application can pass through appointing in following two network line selection scheme
Selected in a plurality of network line between a kind of client and server-side from network application of anticipating a network line as with net
The network line that the server-side of network application actually uses when being communicated: 1) by original mechanism that tests the speed in network application to net
A plurality of network line between the client and server-side of network application tests the speed, to select Network status preferably one;
And 2) tested the speed by the Ping mechanism that tests the speed to a plurality of network line between the client and server-side of network application, thus
Select Network status preferably one.
But the above two mechanism of testing the speed have the following deficiencies: in 1) network application it is original test the speed mechanism due to by
The influence of the logical process of the process of network application can not accurately reflect current network quality;Meanwhile it is original in network application
The mechanism that tests the speed depends on the server-side of network application, thus network resistance occurs between the client and server-side of network application
When the abnormal conditions such as plug, broken string, the detection of network connectivty and delay can not be carried out, analysis appearance is above-mentioned different so as to cause being difficult
Normal reason;2) although the Ping mechanism of testing the speed is a kind of scheme that tests the speed of more bottom, it can accurately reflect Network status,
Ping test the speed mechanism generally only have 60%-70% success rate.
Summary of the invention
In view of above-described one or more problems, the present invention provides a kind of novel network line selection method and
Network speed-measuring method.
Network line selection method according to an embodiment of the present invention, for between the client and server-side of network application
A plurality of network line in select a network line as the network line actually used between client and server-side, the party
Method includes: to carry out network more than once on every network line in a plurality of network line using first tool that tests the speed and test the speed,
And more than one first average value for testing the speed value measured using the first tool of testing the speed is surveyed as the first of this network line
Fast result;If first of any two articles of network lines in a plurality of network line the difference to test the speed between result is greater than the
One predetermined threshold then selects the grid line that the network speed measured in a plurality of network line using the first tool of testing the speed is most fast
Otherwise road selects to utilize second in a plurality of network line as the network line actually used between client and server-side
A most fast network line of the network speed that the tool of testing the speed measures is as the network line actually used between client and server-side.
Network speed-measuring method according to an embodiment of the present invention, comprising: using first test the speed tool network application client
It holds and carries out network more than once on the network line that actually uses between server-side and test the speed, and will test the speed tool survey using first
More than one first average value for testing the speed value test the speed result as the first of the network line;If first tests the speed result not
Greater than the second predetermined threshold, then result is tested the speed as the network speed of the network line using the first of the network line and characterized, otherwise will
The second of the network line measured using the second tool of testing the speed tests the speed result as the network speed of network line characterization.
The present invention by the way that a variety of tools of testing the speed are combined, using it is a variety of test the speed tool the advantages of in high complicated network feelings
Network connectivty and delay when providing the various states of network application under condition, so as to provide in complex situations accurately
Server delays data, and then promote the network fluency of the server of network application.
Detailed description of the invention
Fig. 1 is a plurality of between the client and server-side from network application shown according to example embodiment of the present invention
Stream of the network line as the method for the network line actually used between client and server-side is selected in network line
Cheng Tu;
Fig. 2 is shown between the client and server-side from network application of another example embodiment according to the present invention
Method of the network line as the network line actually used between client and server-side is selected in a plurality of network line
Flow chart;
Fig. 3 be show according to example embodiment of the present invention in network application during normal operation to the visitor of network application
The flow chart for the method that the network line actually used between family end and server-side tests the speed;And
Fig. 4 be show another example embodiment according to the present invention between the client and server-side of network application
The method that network connection tests the speed to the network line actually used between the client and server-side of network application when disconnecting
Flow chart.
Specific embodiment
The feature and exemplary embodiment of various aspects of the invention is described more fully below.In following detailed description
In, many details are proposed, in order to provide complete understanding of the present invention.But to those skilled in the art
It will be apparent that the present invention can be implemented in the case where not needing some details in these details.Below to implementation
The description of example is used for the purpose of providing by showing example of the invention and better understanding of the invention.The present invention never limits
In any concrete configuration set forth below and algorithm, but cover under the premise of without departing from the spirit of the present invention element,
Any modification, replacement and the improvement of component and algorithm.In the the accompanying drawings and the following description, well known structure and skill is not shown
Art is unnecessary fuzzy to avoid causing the present invention.
In order to more accurately know current network quality while increase the probability of success that network tests the speed, propose here in this way
A kind of design: building Ping in the server side of network application and test the speed server, server and network application so that Ping tests the speed
Server share a plurality of network line and being capable of visitor by any one in a plurality of network line with network application
The communication of family end;It builds TCP (transmission control protocol) in the server side of network application to test the speed server, so that the TCP service of testing the speed
Device and the server of network application share a plurality of network line and can by any one in a plurality of network line with
The client communication of network application;Ping tests the speed server and TCP tests the speed, and server is more network interface card multiple internet agreements (IP)
The server of address, and it is provided which network speed measuring function;Preferably, TCP tests the speed server in addition to network speed measuring function
In addition, while having the function of abnormality processing and log recording;Preferably, the tool of testing the speed is built in network application, and in net
Network tests the speed message package using the interior uplink and downlink of addition respectively, and server-side and the client that network application is carried in message package are current
Timestamp, obtains uplink and downlink delay at time difference when by timestamp and receiving message respectively.
It should be understood that in order to improve the reliability that network tests the speed, usually build simultaneously two Ping test the speed server,
And two TCP test the speed server, wherein two Ping server that tests the speed includes that a main Ping tests the speed server and one
Backup Ping tests the speed server, and two TCP server that tests the speed includes that a main TCP tests the speed server and a backup
TCP tests the speed server.
Below with reference to Fig. 1 and Fig. 2, network line selection method according to an embodiment of the present invention is described in detail.
Fig. 1 is a plurality of between the client and server-side from network application shown according to example embodiment of the present invention
Stream of the network line as the method for the network line actually used between client and server-side is selected in network line
Cheng Tu.As shown in Figure 1, this method comprises:
At 102a, network application user via network application client logging in network apply server-side it
Before, tool (that is, first test the speed tool) is tested the speed to a plurality of network between the client and server-side of network application using Ping
Every network line in route carries out (no more than 10 times) network more than once and tests the speed, and the tool that will be tested the speed using Ping
The test the speed average value of value (that is, first test the speed value) of more than one Ping measured tests the speed result as the Ping of this network line
(that is, first test the speed result).
A plurality of grid line at 102b, between client and server-side of the tool to network application that tested the speed using Ping
Road carries out network while test the speed, and tests the speed tool (that is, second test the speed tool) in the client and servo of network application using TCP
Network more than once is carried out on every network line in a plurality of network line between end to test the speed, and will be tested the speed work using second
Have the test the speed average value of value (that is, second test the speed value) of more than one TCP for measuring to test the speed knot as the second of this network line
Fruit.
At 104, any two nets in a plurality of network line between the client of network application and server-side are judged
Whether the Ping on the winding thread road difference between result that tests the speed is greater than the first predetermined threshold.If it is, proceeding at 106, otherwise
It proceeds at 108.In addition, when there is no a grid line in a plurality of network line between the client and server-side of network application
The Ping on the road result that tests the speed is acquired then, is also gone at 108.
At 106, select to test the speed in a plurality of network line between the client of network application and server-side using Ping
A most fast network line of the network speed that tool measures is as the net actually used between the client and server-side of network application
Winding thread road.
At 108, when any two networks in a plurality of network line between the client and server-side of network application
The Ping of route tests the speed the difference between result when being not more than the first predetermined threshold, selects the client and servo of network application
A most fast network line of the network speed measured in a plurality of network line between end using the TCP tool of testing the speed is as network application
Client and server-side between the network line that actually uses.
In the following, the application example of network line selection method shown in FIG. 1 is described in detail.
In the first example, exist between the client and server-side of network application includes first network route and the second net
Two network lines including winding thread road, the first predetermined threshold are 5 milliseconds (ms).Tool is tested the speed in first network line using Ping
Road carries out 10 networks and tests the speed, and the Ping for obtaining first network route tests the speed result as 49ms;Existed using the Ping tool that tests the speed
It carries out 10 networks on second network line to test the speed, the Ping for obtaining the second network line tests the speed result as 56ms;It is surveyed using TCP
Fast tool carries out 8 networks on first network route and tests the speed, and the TCP for obtaining first network route tests the speed result as 49ms;Make
8 networks are carried out on the second network line being tested the speed, the TCP result that tests the speed for obtaining the second network line is with the TCP tool that tests the speed
55ms.In this example, the test the speed Ping of result and the second network line of the Ping of first network route tests the speed between result
Difference (7ms) is greater than the first predetermined threshold, therefore being tested the speed tool in first network route and the second network line using Ping
The faster network line (that is, first network route) of the network speed measured is as between the client and server-side of network application
The network line of actual use.
In the second example, exist between the client and server-side of network application includes first network route and the second net
Two network lines including winding thread road, the first predetermined threshold are 5ms.It is enterprising in first network route using the Ping tool that tests the speed
10 networks of row test the speed, and the Ping for obtaining first network route tests the speed result as 51ms;Tool is tested the speed in the second net using Ping
Winding thread road carries out 10 networks and tests the speed, and the Ping for obtaining the second network line tests the speed result as 49ms;It is tested the speed tool using TCP
It carries out 10 networks on first network route to test the speed, the TCP for obtaining first network route tests the speed result as 49ms;Use TCP
The tool that tests the speed carries out 10 networks on the second network line and tests the speed, and the TCP for obtaining the second network line tests the speed result as 53ms.
In this example, the Ping of first network route tests the speed the difference that the Ping of result and the second network line tests the speed between result
(2ms) selects testing the speed tool survey in first network route and the second network line using TCP less than the first predetermined threshold
The faster network line (that is, first network route) of network speed obtained is as real between the client and server-side of network application
The network line that border uses.
Exist in third example, between the client and server-side of network application includes first network route, the second net
Three network lines including winding thread road and third network line, the first predetermined threshold are 5ms.It is tested the speed tool using Ping
It carries out 8 networks on first network route to test the speed, the Ping for obtaining first network route tests the speed result as 56ms;Use Ping
The tool that tests the speed carries out 8 networks on the second network line and tests the speed, and the Ping for obtaining the second network line tests the speed result as 50ms;
8 networks are carried out on third network line testing the speed, the Ping for obtaining third network line tests the speed knot using the Ping tool that tests the speed
Fruit is 49ms;7 networks are carried out on first network route test the speed, obtain the TCP of first network route using the TCP tool that tests the speed
The result that tests the speed is 52ms;7 networks are carried out on the second network line test the speed, obtain the second grid line using the TCP tool that tests the speed
The TCP on road tests the speed result as 56ms;7 networks are carried out on third network line test the speed, obtain third using the TCP tool that tests the speed
The TCP of network line tests the speed result as 49ms.In this example, the Ping of first network route tests the speed result and third grid line
The Ping on the road difference (7ms) between result that tests the speed is greater than the first predetermined threshold, therefore selects first network route, the second network
A most fast network line of the network speed measured using the Ping tool of testing the speed in route and third network line is (that is, third
Network line) as the network line actually used between the client and server-side of network application.
In the fourth example, exist between the client and server-side of network application includes first network route, the second net
Three network lines including winding thread road and third network line, the first predetermined threshold are 5ms.It is tested the speed tool using Ping
It carries out 8 networks on first network route to test the speed, the Ping for obtaining first network route tests the speed result as 53ms;Use Ping
The tool that tests the speed carries out 8 networks on the second network line and tests the speed, and the Ping for obtaining the second network line tests the speed result as 54ms;
8 networks are carried out on third network line testing the speed, the Ping for obtaining third network line tests the speed knot using the Ping tool that tests the speed
Fruit is 51ms;7 networks are carried out on first network route test the speed, obtain the TCP of first network route using the TCP tool that tests the speed
The result that tests the speed is 52ms;7 networks are carried out on the second network line test the speed, obtain the second grid line using the TCP tool that tests the speed
The TCP on road tests the speed result as 56ms;7 networks are carried out on third network line test the speed, obtain third using the TCP tool that tests the speed
The TCP of network line tests the speed result as 49ms.In this example, the Ping of first network route tests the speed result and the second grid line
The Ping on road test the speed difference (1ms) between result, first network route Ping test the speed result and third network line
Ping test the speed difference (2ms) between result, the second network line the test the speed Ping of result and third network line of Ping survey
Difference (3ms) between fast result no more than the first predetermined threshold, therefore select first network route, the second network line,
And the most fast network line of the network speed measured using the TCP tool of testing the speed in third network line is (that is, third grid line
Road) as the network line actually used between the client and server-side of network application.
Fig. 2 is shown between the client and server-side from network application of another example embodiment according to the present invention
Method of the network line as the network line actually used between client and server-side is selected in a plurality of network line
Flow chart.As shown in Fig. 2, this method comprises:
At 202, network application user via network application client logging in network apply server-side before,
Tool is tested the speed to every network line in a plurality of network line between the client and server-side of network application using Ping
It carries out (no more than 10 times) network more than once to test the speed, and more than one Ping measured using the Ping tool of testing the speed is surveyed
The average value of fast value tests the speed result as the Ping of this network line.
At 204, any two nets in a plurality of network line between the client of network application and server-side are judged
Whether the Ping on the winding thread road difference between result that tests the speed is greater than the first predetermined threshold.If so, proceed at 206, otherwise before
It enters at 208.In addition, when there is no a network line in a plurality of network line between the client and server-side of network application
The Ping result that tests the speed be acquired then, also go at 208.
At 206, surveying in a plurality of network line between the client of network application and server-side using Ping is selected
A most fast network line of the network speed that fast tool measures between the client and server-side of network application as actually using
Network line.
At 208, tool is tested the speed in a plurality of network line between the client and server-side of network application using TCP
Every network line on carry out network more than once and test the speed, and more than one TCP measured using the TCP tool of testing the speed is tested the speed
The average value of value tests the speed result as the second of this network line.
At 210, select to test the speed work in a plurality of network line between the client of network application and server-side using TCP
Has a most fast network line of the network speed measured as the network actually used between the client and server-side of network application
Route.
In the following, the application example of network line selection method shown in Fig. 2 is described in detail.
In the first example, exist between the client and server-side of network application includes first network route and the second net
Two network lines including winding thread road, the first predetermined threshold are 5ms.It is enterprising in first network route using the Ping tool that tests the speed
10 networks of row test the speed, and the Ping for obtaining first network route tests the speed result as 49ms;Tool is tested the speed in the second net using Ping
Winding thread road carries out 10 networks and tests the speed, and the Ping for obtaining the second network line tests the speed result as 56ms.In this example, first
The Ping of network line tests the speed, and to be greater than first predetermined for the difference (7ms) that tests the speed between result of Ping of result and the second network line
Threshold value, therefore select the network speed faster one measured using the Ping tool of testing the speed in first network route and the second network line
Network line (that is, first network route) is as the grid line actually used between the client and server-side of network application
Road.
In the second example, exist between the client and server-side of network application includes first network route and the second net
Two network lines including winding thread road, the first predetermined threshold are 5ms.It is enterprising in first network route using the Ping tool that tests the speed
8 networks of row test the speed, and the Ping for obtaining first network route tests the speed result as 49ms;Tool is tested the speed in the second network using Ping
It carries out 8 networks on route to test the speed, the Ping for obtaining the second network line tests the speed result as 51ms;Due to first network route
Ping test the speed result and the second network line the difference (2ms) that tests the speed between result of Ping less than the first predetermined threshold, therefore
It continues to use the TCP tool that tests the speed to carry out 10 networks respectively on first network route and the second network line and test the speed, obtains
The TCP of one network line test the speed result be 49ms, the TCP of the second network line result that tests the speed is 53ms.In this example, it selects
In first network route and the second network line the faster network line of the network speed measured using the TCP tool of testing the speed (that is,
First network route) as the network line actually used between the client and server-side of network application.
Exist in third example, between the client and server-side of network application includes first network route, the second net
Three network lines including winding thread road and third network line, the first predetermined threshold are 5ms.It is tested the speed tool using Ping
It carries out 8 networks on first network route to test the speed, the Ping for obtaining first network route tests the speed result as 56ms;Use Ping
The tool that tests the speed carries out 8 networks on the second network line and tests the speed, and the Ping for obtaining the second network line tests the speed result as 50ms;
8 networks are carried out on third network line testing the speed, the Ping for obtaining third network line tests the speed knot using the Ping tool that tests the speed
Fruit is 49ms.In this example, the Ping of first network route test the speed result and third network line Ping test the speed result it
Between difference (7ms) be greater than the first predetermined threshold, therefore select first network route, the second network line and third network
The most fast network line (that is, third network line) of the network speed measured using the Ping tool of testing the speed in route is as network
The network line actually used between the client and server-side of application.
In the fourth example, exist between the client and server-side of network application includes first network route, the second net
Three network lines including winding thread road and third network line, the first predetermined threshold are 5ms.It is tested the speed tool using Ping
It carries out 8 networks on first network route to test the speed, the Ping for obtaining first network route tests the speed result as 53ms;Use Ping
The tool that tests the speed carries out 8 networks on the second network line and tests the speed, and the Ping for obtaining the second network line tests the speed result as 54ms;
8 networks are carried out on third network line testing the speed, the Ping for obtaining third network line tests the speed knot using the Ping tool that tests the speed
Fruit is 51ms;Since the Ping of first network route tests the speed the difference that the Ping of result and the second network line tests the speed between result
The Ping of (1ms), first network route test the speed result and third network line Ping test the speed difference (2ms) between result,
The Ping of second network line test the speed result and third network line the difference (3ms) that tests the speed between result of Ping no more than
First predetermined threshold, therefore continue to use TCP and test the speed tool respectively in first network route, the second network line and third
It carries out 7 networks on network line testing the speed, the TCP result that tests the speed for obtaining first network route is 52ms, the second network line
TCP test the speed result be 56ms, the TCP of the third network line result that tests the speed is 49ms.In this example, first network line is selected
A most fast grid line of the network speed measured using the TCP tool of testing the speed in road, the second network line and third network line
Road (that is, third network line) is as the network line actually used between the client and server-side of network application.
Fig. 3 be show according to example embodiment of the present invention in network application during normal operation to the visitor of network application
The flow chart for the method that the network line actually used between family end and server-side tests the speed.As shown in figure 3, this method packet
It includes:
At 302a, periodically actually made between the client of network application and server-side using the Ping tool that tests the speed
Network line carries out network more than once and tests the speed (for example, testing the speed tool to the client of network application using Ping every 1s
The network line actually used between end and server-side carries out network more than once and tests the speed), and the tool survey that will be tested the speed using Ping
The test the speed average value of value of more than one Ping test the speed result as the Ping of this network line.
At 302b, in the tool that tested the speed using Ping periodically to practical between the client of network application and server-side
While the network line that uses carries out network and tests the speed, using TCP test the speed tool periodically to the client of network application and
The network line that actually uses between server-side is carried out network more than once and tested the speed (for example, being tested the speed tool pair every 1s using TCP
The network line actually used between the client and server-side of network application carries out network more than once and tests the speed), and will utilize
The test the speed average value of value of more than one TCP that the TCP tool of testing the speed measures tests the speed result as the TCP of this network line.
At 302c, while carrying out the operation at 102a and at 102b, testing the speed tool week in network application is utilized
Network more than once is carried out to the network line that actually uses between the client and server-side of network application to phase property to test the speed (example
Such as, the network line actually used between the client and server-side every 1s to network application carries out network more than once and surveys
Speed), and using more than one apply in test the speed value average value as testing the speed result in applying.
At 304, judge that the Ping of the network line actually used between the client of network application and server-side tests the speed
As a result whether it is greater than the second predetermined threshold.If it is not, then illustrating that the network speed that the Ping tool of testing the speed measures can receive
In the range of, it proceeds at 306;If it is, the network speed for illustrating that the Ping tool of testing the speed measures is excessively slow, proceed at 308.
In addition, when the Ping of network line actually used between the client and server-side of network application the result that tests the speed can not obtain
When, it also goes at 308.
At 306, Ping is tested the speed into result as the network actually used between the client of network application and server-side
The network speed of route characterizes.
At 308, TCP is tested the speed into result as the grid line actually used between the client of network application and server-side
The network speed on road characterizes.
At 310, result is tested the speed using Ping or TCP tests the speed and tests the speed as a result, i.e. by calculating Ping in result and application
The result that tests the speed or TCP test the speed the difference to test the speed between result in result and application, and the logic for obtaining the server-side of network application is prolonged
Late.
In the following, the application example of method shown in Fig. 3 is described in detail.
In the first example, the second predetermined threshold is 100ms.Using Ping test the speed tool network application client and
10 networks are carried out on the network line actually used between server-side to test the speed, and are obtained Ping and are tested the speed result as 49ms;Use TCP
It tests the speed and carries out 10 networks on the network line that tool actually uses between the client and server-side of network application and test the speed, obtain
Result is tested the speed to TCP as 55ms;Since Ping tests the speed result less than the second predetermined threshold, Ping is tested the speed into result as this
The network speed of network line characterizes;The result that tests the speed in the application obtained using the tool of testing the speed in network application is 11ms;It calculates
Ping tests the speed the difference to test the speed between result in result and application, and the logical delay for obtaining the server-side of network application is 38ms.
In the second example, the second predetermined threshold is 100ms.Using Ping test the speed tool network application client and
10 networks are carried out on the network line actually used between server-side to test the speed, and are obtained Ping and are tested the speed result as 105ms;It uses
TCP, which tests the speed, to carry out 10 networks on the network line that tool actually uses between the client and server-side of network application and surveys
Speed obtains TCP and tests the speed result as 60ms;Since Ping tests the speed result greater than the second predetermined threshold, the TCP result that tests the speed is made
It is characterized for the network speed of the network line;The result that tests the speed in the application obtained using the tool of testing the speed inside network application is 11ms;Meter
It calculates TCP to test the speed the difference to test the speed between result in result and application, the logical delay for obtaining the server-side of network application is 49ms.
Fig. 4 be show another example embodiment according to the present invention between the client and server-side of network application
The method that network connection tests the speed to the network line actually used between the client and server-side of network application when disconnecting
Flow chart.As shown in figure 4, this method comprises:
At 402, periodically actually made between the client of network application and server-side using the Ping tool that tests the speed
Network line carries out network more than once and tests the speed (for example, testing the speed tool to the client of network application using Ping every 1s
The network line actually used between end and server-side carries out network more than once and tests the speed), and the tool survey that will be tested the speed using Ping
The test the speed average value of value of more than one Ping test the speed result as the Ping of this network line.
At 404, judge that the Ping of the network line actually used between the client of network application and server-side tests the speed
As a result whether it is greater than the second predetermined threshold.If it is not, proceeding at 406;If so, proceeding at 408.In addition, working as network
The Ping of the network line actually used between the client and server-side of application tests the speed result when can not obtain, and also goes to
At 408.
At 406, net is re-established on the network line that actually uses between the client and server-side of network application
Network connection.
At 408, periodically actually used between the client of network application and server-side using the TCP tool that tests the speed
Network line carry out network more than once test the speed (for example, every 1s using TCP test the speed tool to the client of network application with
The network line actually used between server-side carries out network more than once and tests the speed), and one will measured using the TCP tool of testing the speed
The test the speed average value of value of a above TCP tests the speed result as the TCP of this network line.
At 410, judge that the TCP of the network line actually used between the client of network application and server-side tests the speed knot
Whether fruit is greater than third predetermined threshold.If it is, back to continue at 402 Ping test the speed tool network application visitor
Network is carried out on the network line actually used between family end and server-side to test the speed, and otherwise proceeds to 406.
Here it is possible to which the client in network application increases speed measuring module, which is provided with Ping and tests the speed interface
It tests the speed with TCP and interface and the above route selection in conjunction with Fig. 1 to Fig. 4 description and/or the process that tests the speed is realized by individual thread.
In conclusion the present invention (is mutually tied by combining a variety of tools of testing the speed for example, Ping is tested the speed to test the speed with TCP
Close, or Ping tested the speed, TCP tests the speed and network application in test the speed combine), using it is a variety of test the speed tool the advantages of
(for example, low disappearing of testing the speed of high stability and independence or Ping that the low consumption tested the speed of Ping and high-precision and TCP test the speed
The logical coherence to test the speed in the high stability and independence and network application that consumption tests the speed with high-precision, TCP) high complicated
Network condition under network connectivty when providing the various states of network application and delay, so as to mention in complex situations
For accurately server delays data, and then promote the network fluency of the server of network application.
It will be understood by those skilled in the art that there is also can be used for realizing the embodiment of the present invention more optional embodiments and
Improved procedure, and above embodiment and example are only the explanations of one or more embodiments.Therefore, the scope of the present invention is only
It is limited by the appended claims.
Claims (8)
1. a kind of network line selection method, for from a plurality of network line between the client and server-side of network application
Select a network line as the network line actually used between the client and the server-side, the method packet
It includes:
Using first tool that tests the speed network more than once carried out on every network line in a plurality of network line test the speed,
And using measured using first tool of testing the speed more than one first test the speed value average value as the of this article of network line
One tests the speed result;
If first of any two network lines in a plurality of network line the difference to test the speed between result is greater than first
Predetermined threshold,
A network line for then selecting the network speed measured in a plurality of network line using first tool of testing the speed most fast
As the network line actually used between the client and the server-side,
Otherwise a network line for selecting the network speed measured in a plurality of network line using the second tool of testing the speed most fast is made
The network line actually used between the client and the server-side,
First tool of testing the speed is that Ping tests the speed tool, and second tool of testing the speed is that TCP tests the speed tool;
It builds Ping in the servo end side of network application to test the speed server, so that the Ping tests the speed, server is answered with the network
Server-side shares a plurality of network line and by any one and the network application in a plurality of network line
Client communication;
It builds TCP in the servo end side of network application to test the speed server, server and the network application so that the TCP tests the speed
Server-side share a plurality of network line and by any one in a plurality of network line and the network application
Client communication;
Wherein, the Ping tests the speed server and the TCP server that tests the speed is more network interface card multiple internet Protocol IP address
Server, and it is provided which network speed measuring function.
2. network line selection method according to claim 1, which is characterized in that further include:
Network more than once is carried out on every network line in a plurality of network line using described second tool that tests the speed
Test the speed, and using measured using second tool of testing the speed more than one second test the speed value average value as this network line
Second test the speed result.
3. network line selection method according to claim 1, which is characterized in that
Tool is tested the speed using described first simultaneously and described second tool that tests the speed carries out network survey on a plurality of network line
Speed, or
Network is carried out on a plurality of network line test the speed, recycle described second to test the speed first with described first tool that tests the speed
Tool carries out network on a plurality of network line and tests the speed.
4. a kind of network speed-measuring method, comprising:
It tests the speed using first and carries out one on the network line that tool actually uses between the client and server-side of network application
The secondary above network tests the speed, and using measured using first tool of testing the speed more than one first test the speed value average value as institute
The first of network line is stated to test the speed result;
If described first tests the speed result no more than the second predetermined threshold,
Then result is tested the speed as the network speed of the network line for the first of the network line to characterize,
Otherwise result is tested the speed as the network line using the second of the network line measured using the second tool of testing the speed
Network speed characterization,
It carries out network on the network line using the tool that tests the speed in the network application to test the speed, to obtain the grid line
The third on road test the speed as a result,
Using the first of the network line test the speed result or second test the speed result and the network line third test the speed knot
Fruit obtains the logical delay of the network application,
First tool of testing the speed is that Ping tests the speed tool, and second tool of testing the speed is that TCP tests the speed tool;
It builds Ping in the servo end side of network application to test the speed server, so that the Ping tests the speed, server is answered with the network
Server-side shares a plurality of network line and by any one and the network application in a plurality of network line
Client communication;
It builds TCP in the servo end side of network application to test the speed server, server and the network application so that the TCP tests the speed
Server-side share a plurality of network line and by any one in a plurality of network line and the network application
Client communication;
Wherein, the Ping tests the speed server and the TCP server that tests the speed is more network interface card multiple internet Protocol IP address
Server, and it is provided which network speed measuring function.
5. network speed-measuring method according to claim 4, which is characterized in that further include:
Network more than once is carried out on the network line test the speed, and will utilize described second using described second tool that tests the speed
More than one second average value for testing the speed value that the tool of testing the speed measures tests the speed result as the second of the network line.
6. network speed-measuring method according to claim 4, which is characterized in that while testing the speed tool and institute using described first
Second tool that tests the speed is stated to carry out network on the network line and test the speed or test the speed tool in the net first with described first
Winding thread road, which carries out network, tests the speed described second tool that tests the speed is recycled to carry out network on the network line and test the speed.
7. a kind of client of network application, including the function mould for realizing method described in any one of claims 1 to 6
Block.
8. a kind of computer readable storage medium for being stored with computer executable instructions, the computer executable instructions are in quilt
It can be operated when execution to realize method described in any one of claims 1 to 6.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510148197.8A CN106161052B (en) | 2015-03-31 | 2015-03-31 | Network line selection method and network speed-measuring method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510148197.8A CN106161052B (en) | 2015-03-31 | 2015-03-31 | Network line selection method and network speed-measuring method |
Publications (2)
Publication Number | Publication Date |
---|---|
CN106161052A CN106161052A (en) | 2016-11-23 |
CN106161052B true CN106161052B (en) | 2019-10-08 |
Family
ID=57337894
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201510148197.8A Active CN106161052B (en) | 2015-03-31 | 2015-03-31 | Network line selection method and network speed-measuring method |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106161052B (en) |
Families Citing this family (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106953805A (en) * | 2017-03-17 | 2017-07-14 | 广州爱九游信息技术有限公司 | Network line control method, device and service terminal |
CN109379247B (en) * | 2018-09-27 | 2022-02-15 | 腾讯科技(深圳)有限公司 | Method and device for detecting network delay of application program |
CN109474497A (en) * | 2018-12-19 | 2019-03-15 | 四川艾贝斯科技发展有限公司 | A kind of reliable network maintenance terminal deep learning algorithm |
CN115499346B (en) * | 2022-09-15 | 2024-04-26 | 巨擎网络科技(济南)有限公司 | Speed measuring method, device, equipment and medium for multiple network cards |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101075924A (en) * | 2006-09-21 | 2007-11-21 | 腾讯科技(深圳)有限公司 | Method for accessing server by customer end |
CN103533016A (en) * | 2013-01-24 | 2014-01-22 | 中国联合网络通信有限公司重庆市分公司 | Broadband network speed measuring and intelligent analyzing system |
CN103763156A (en) * | 2014-01-28 | 2014-04-30 | 中国移动(深圳)有限公司 | Network speed measurement method and system |
-
2015
- 2015-03-31 CN CN201510148197.8A patent/CN106161052B/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101075924A (en) * | 2006-09-21 | 2007-11-21 | 腾讯科技(深圳)有限公司 | Method for accessing server by customer end |
CN103533016A (en) * | 2013-01-24 | 2014-01-22 | 中国联合网络通信有限公司重庆市分公司 | Broadband network speed measuring and intelligent analyzing system |
CN103763156A (en) * | 2014-01-28 | 2014-04-30 | 中国移动(深圳)有限公司 | Network speed measurement method and system |
Also Published As
Publication number | Publication date |
---|---|
CN106161052A (en) | 2016-11-23 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106161052B (en) | Network line selection method and network speed-measuring method | |
CN102449957B (en) | Ip network fault locating method, apparatus, and system | |
CN103259696B (en) | Network bandwidth detection method, device and the network equipment | |
EP3022874B1 (en) | Triangle loopback | |
EP2266254A2 (en) | Available bandwidth estimation in a packet-switched communication network | |
US9935832B2 (en) | Automated placement of measurement endpoint nodes in a network | |
CN105763394B (en) | A kind of network link detection method, device and system | |
CN104717670B (en) | A kind of measure of the quality of service method, apparatus and system | |
CN105656662B (en) | A kind of Fault Locating Method and device | |
CN104734907A (en) | Method for actively measuring end-to-end path performance of OpenFlow network and system adopted by the same | |
CN106302016A (en) | The method and system of low discharge quick obtaining network physical bandwidth | |
CN116264558A (en) | Cloud private line quality monitoring method, device, equipment and computer storage medium | |
EP2512066A1 (en) | Testing shaped TCP traffic | |
Vondrouš et al. | Testing methodology for performance evaluation of communication systems for Smart Grid | |
Mustafa et al. | EFFECTOR: DASH QoE and QoS evaluation framework for EnCrypTed videO tRaffic | |
CN109218140A (en) | A kind of method of software definition deployment NFV network measuring system | |
US9992073B2 (en) | Network status measuring system and a method for measuring status of a network | |
CN104980352A (en) | Routing method and device for multiline computer room | |
US11372744B1 (en) | System for identifying issues during testing of applications | |
CN104601255B (en) | The method of testing and device of line card | |
Vondrous et al. | Simulation of the application layer in narrowband networks with conditional data injection XML scheme based on universal data generator | |
US11743164B2 (en) | Quality measuring device, quality measuring method, and quality measuring program | |
CN105515894B (en) | A kind of test method and test device that can judgement surf the Internet | |
Tan et al. | Abshoot: A reliable and efficient scheme for end-to-end available bandwidth measurement | |
JP2000069121A (en) | Delay and throughput evaluation method and network management device |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |