Summary of the invention
Of the invention provides a kind of method and system of test router, and its object is to can be in the steady of test router
When qualitative, can in many test envelopes efficiently and rapidly positioning failure problem.
Technical solution provided by the invention is as follows:
A kind of method of test router, including server, an at least test machine and at least a router to be measured, institute
State test machine respectively with the server and router communication connection to be measured;Comprising steps of
Test machine described in S300 obtains the test assignment stored in advance, tests an at least router to be measured;
Server described in S400 receives url access request, judges current test data whether in normal range (NR), if executing
Step S500;It is no to then follow the steps S600;
It is normal that server described in S500 exports the current test data;It is pre- to judge whether the current length of testing speech meets
If length of testing speech, if execute step S700;Otherwise return step S400;
It is abnormal that server described in S600 exports current test data;Judge whether to terminate currently to test, if executing step
S700;Otherwise return step S400;
The control of server described in S700 terminates current test, and the current test data is saved to the server count
According in library.
In the present invention, the test script saved in the available server of test machine tests router to be measured, will
The result of test is saved into server, and by selecting any test machine connecting with server network, inputting url both can be with
Server is accessed, when outputing test data abnormal, warning information is issued, tester is prompted to check, confirms abnormal number
According to and judge whether to terminate currently to test.The state of current test router to be measured can be obtained at any time through the invention, no
It needs to send on special messenger to the test machine for being located at different location and check respectively, it is time saving and energy saving.
Further, the step S300 comprising steps of
Test machine described in S310 and any router wired connection to be measured;Obtain the first test in the server
Script, acquires the router memory related data to be measured in the first preset duration, and by the router memory phase to be measured
Data are closed to save into server database;And/or
Test machine described in S320 and any router to be measured are wirelessly connected;Obtain the second test in the server
Script, acquires the router performance related data to be measured in the second preset duration, and by the router performance phase to be measured
Data are closed to save into server database;
Wherein, first preset duration is greater than second preset duration.
In the present invention, it is only necessary to control test machine and router to be measured is carried out wired or is wirelessly connected, so that it may carry out
Different tests wired connection can only test router memory related data to be measured on a test machine;It can also be one
It is wirelessly connected on platform test machine and only tests router performance related data to be measured;It can also be respectively on two or more test machines
One or more test machine wired connection is set and tests router memory related data to be measured, the test machine of setting one or more without
Line connecting test router performance related data to be measured.It here, can as long as the first preset duration is greater than the second preset duration
Test router memory related data and performance-related data to be measured to synchronize;Router memory to be measured can also first be tested
Related data, re-test router performance related data to be measured.
Further, the step S310 comprising steps of
Test machine described in S311 and any router wired connection to be measured;Obtain the first test in the server
Script;
Test machine described in S312 obtains the router residue cpu data to be measured according to the first predeterminated frequency, and saves extremely
In the server database;And/or
Test machine described in S313 obtains the router free memory data to be measured according to first predeterminated frequency, and
It saves into the server database;And/or
Test machine described in S314 obtains the router main steps state to be measured according to first predeterminated frequency, and
It saves into the server database;And/or
Test machine described in S315 obtains the router device runing time to be measured according to first predeterminated frequency, and
It saves into the server database;
The step S320 comprising steps of
Test machine described in S321 and any router to be measured are wirelessly connected;Obtain the second test in the server
Script;
Test machine described in S322 obtains the packet loss and time delay of ping gateway according to the second predeterminated frequency, and saves to institute
It states in server database;And/or
S323 obtains the packet loss and time delay of ping outer net according to second predeterminated frequency, and saves to the service
In device database;And/or
S324 obtains the transmission rate and receiving velocity of network interface card connection according to second predeterminated frequency, and saves to institute
It states in server database;And/or
S325 obtains the signal strength of network interface card connection according to second predeterminated frequency, and saves to the server count
According in library;And/or
S326 obtains network interface card upstream data flow and downlink data flow according to second predeterminated frequency, and saves extremely
In the server database.
In the present invention, remaining cpu data, free memory data, the main steps shape for testing router to be measured can choose
One or more of state, operation hours test item, also can choose test ping gateway packet loss and time delay,
In signal strength that the transmission rate that the packet loss of ping outer net is connected with time delay, network interface card is connected with receiving velocity, network interface card, network interface card
One or more of row data traffic and downlink data flow test item.
Further, the step S400 comprising steps of
S410 inputs url on any test machine connecting with the server, requests access to the clothes by the url
Business device;
Server described in S420 judges the current test data whether in normal range (NR), if executing step S500;It is no
Then follow the steps S600.
In the present invention, test man only needs to select any test machine connecting with server network, and input url both can be with
Access server, so that it may carry out testing router to be measured, not need to send on special messenger to the test machine for being located at different location respectively
It is checked, it is time saving and energy saving.
Further, it is further comprised the steps of: before the step S300
S100 controls the test machine according to default building plan, and the router to be measured connects same with the server
Network;
First test script and second test script is arranged in test machine described in S200, according to the test script
Select test assignment and test time started;
Wherein, first test script tests the router memory related data to be measured;Second test script
Test the router performance related data to be measured.
The present invention also provides a kind of system of test router, including server, an at least test machine and at least one
Router to be measured, the test machine respectively with the server and router communication connection to be measured;
Wherein, the test machine includes: test module;The server includes storage module, judgment module and control mould
Block;The storage module communication connection of the test module of the test machine and the server;The judgment module of the server point
Not with the storage module of the server and control module communication connection;
The test module of the test machine obtains the test assignment stored in advance in the storage module, at least one
Platform router to be measured is tested;
Whether the judgment module of the server receives url access request, judges current test data in normal range (NR);
The control module of the server, when the judgment module of the server exports current test data in normal range (NR)
When, it is normal to export the current test data;
The judgment module of the server, also when export the current test data it is normal after, judge the current test
Whether duration meets preset length of testing speech;
The control module of the server, also when the current length of testing speech meets preset length of testing speech, control knot
Shu Dangqian test, and the current test data is saved into the storage module of the server;
The judgment module of the server then continues also when the current length of testing speech is unsatisfactory for preset length of testing speech
Judge current test data whether in normal range (NR);
The control module of the server does not exist when the judgment module of the server exports the current test data also
When normal range (NR), it is abnormal to export the current test data;
The judgment module of the server, also when export the current test data it is normal after, judge whether to terminate current
Test;
The control module of the server, after judgement terminates the current test, control terminates current test, and will work as
Preceding test data is saved into the storage module of the server;
The judgment module of the server continues to judge currently to test number also after judgement does not terminate the current test
According to whether in normal range (NR).
In the present invention, the test script saved in the available server of test machine tests router to be measured,
The result of test is saved into server, by selecting any test machine connecting with server network, input url both may be used
To access server, obtains the state of current test router to be measured and judged and controlled, do not need to send special messenger in place
It is time saving and energy saving in being checked respectively on the test machine of different location.
Further, the test module of the test machine and any router wired connection to be measured;Obtain the clothes
The first test script being engaged in the storage module of device, acquires the router memory dependency number to be measured in the first preset duration
According to, and the router memory related data to be measured is saved into the storage module of the server;And/or
The test module of the test machine and any router to be measured are wirelessly connected;Obtain the storage of the server
The second test script in module acquires the router performance related data to be measured in the second preset duration, and will be described
Router performance related data to be measured is saved into the storage module of the server;
Wherein, first preset duration is greater than second preset duration.
In the present invention, it is only necessary to control test machine and router to be measured is carried out wired or is wirelessly connected, so that it may carry out
Different tests wired connection can only test router memory related data to be measured on a test machine;It can also be one
It is wirelessly connected on platform test machine and only tests router performance related data to be measured;It can also be respectively on two or more test machines
One or more test machine wired connection is set and tests router memory related data to be measured, the test machine of setting one or more without
Line connecting test router performance related data to be measured.It here, can as long as the first preset duration is greater than the second preset duration
Test router memory related data and performance-related data to be measured to synchronize;Router memory to be measured can also first be tested
Related data, re-test router performance related data to be measured.
Further, the test module of the test machine includes:
Acquisition submodule obtains the first test script in the storage module of the server;And/or obtain the clothes
The second test script being engaged in the storage module of device;
Residue CPU submodule is tested, according to the first predeterminated frequency, obtains the router residue cpu data to be measured, and protect
It deposits into the storage module of the server;And/or
Free memory submodule is tested, according to first predeterminated frequency, obtains the router free memory number to be measured
According to, and save into the storage module of the server;And/or
Main steps submodule is tested, according to first predeterminated frequency, obtains the router main steps shape to be measured
State, and save into the storage module of the server;And/or
Test run time submodule, according to first predeterminated frequency, when obtaining the router device to be measured operation
Between, and save into the storage module of the server;And/or
Test Network sub-module obtains the packet loss and time delay of ping gateway according to the second predeterminated frequency, and saves to institute
It states in the storage module of server;And/or
Outer net submodule is tested, according to second predeterminated frequency, obtains the packet loss and time delay of ping outer net, and save
Into the storage module of the server;And/or
Connection speed submodule is tested, according to second predeterminated frequency, obtains the transmission rate and network interface card of network interface card connection
The receiving velocity of connection, and save into the storage module of the server;
Signal strength submodule is tested, according to second predeterminated frequency, obtains the signal strength of network interface card connection, and save
Into the storage module of the server;And/or
Uplink/downlink flow submodule is tested, according to second predeterminated frequency, obtains network interface card upstream data flow and network interface card
Downlink data flow, and save into the storage module of the server.
In the present invention, remaining cpu data, free memory data, the main steps shape for testing router to be measured can choose
One or more of state, operation hours test item, also can choose test ping gateway packet loss and time delay,
In signal strength that the transmission rate that the packet loss of ping outer net is connected with time delay, network interface card is connected with receiving velocity, network interface card, network interface card
One or more of row data traffic and downlink data flow test item.
Further, the test machine further include: setup module, access modules;The setup module of the test machine and institute
State the storage module communication connection of server;The storage module communication connection of the access modules of the test machine and the server
First test script and second test script is arranged, according to described in the setup module of the test machine
Test script selects test assignment and test time started;
The access modules of the test machine input url on any test machine connecting with the server;By described
Url requests access to the server;Wherein,
First test script tests the router memory related data to be measured;Second test script tests institute
State router performance related data to be measured.
In the present invention, tester can according to need carries out editor's test script on a testing machine, according to the survey of editor
Training originally carries out selection test assignment, and after starting test, tester wants to check the state for testing router to be measured, it is only necessary to
Any test machine connecting with server network is selected, inputs url both accessible servers, so that it may test to be measured
Router is not needed to send on special messenger to the test machine for being located at different location and be checked respectively, time saving and energy saving.
Further, according to default building plan test system building, and the test machine is controlled, the router to be measured
Consolidated network is connected with the server.
Compared with prior art, the present invention provides a kind of method and system of test router, at least brings following one kind
Technical effect:
1, the test item of at least one router to be measured is tested, can need to repeat to build test to avoid Test Engineer
Environment improves work efficiency, time saving and energy saving.
2, the normal or abnormal efficiently quick positioning failure problem that outputs test data can be passed through.
3, the router performance that can carry out different models in batches is tested, the test router performance of high-efficient automatic,
Save the time for carrying out test one by one and not stopping variation test environment.
Specific embodiment
In order to more clearly explain the embodiment of the invention or the technical proposal in the existing technology, Detailed description of the invention will be compareed below
A specific embodiment of the invention.It should be evident that drawings in the following description are only some embodiments of the invention, for
For those of ordinary skill in the art, without creative efforts, it can also be obtained according to these attached drawings other
Attached drawing, and obtain other embodiments.
To make simplified form, part related to the present invention is only schematically shown in each figure, they are not represented
Its practical structures as product.In addition, there is identical structure or function in some figures so that simplified form is easy to understand
Component only symbolically depicts one of those, or has only marked one of those.Herein, "one" is not only indicated
" only this ", can also indicate the situation of " more than one ".
Shown in referring to Fig.1, the present invention provides one embodiment of a kind of method of test router, including server, until
A few test machine and an at least router to be measured, the test machine connect with the server and router to be measured communication respectively
It connects;The embodiment comprising steps of
Test machine described in S300 obtains the test assignment stored in advance, tests an at least router to be measured;
Server described in S400 receives url access request, judges current test data whether in normal range (NR), if executing
Step S500;It is no to then follow the steps S600;
It is normal that server described in S500 exports the current test data;It is pre- to judge whether the current length of testing speech meets
If length of testing speech, if execute step S700;Otherwise return step S400;
It is abnormal that server described in S600 exports current test data;Judge whether to terminate currently to test, if executing step
S700;Otherwise return step S400;
The control of server described in S700 terminates current test, and the current test data is saved to the server count
According in library.
In the embodiment of the present invention, router to be measured can be placed in test envelope (Test Bed), Test Bed is exactly to survey
The specific software environment of examination, hardware environment may include software, hardware and network structure.For example, Arena browser can
Using as test CSS, the Test Bed of html code.Server connect consolidated network with test envelope, selects any connection net
The test machine of network can access the Visualizing Test System of server by url, and be capable of the beginning testing time of nominative testing machine,
And the data information of all test machine test routers is arrived in test during the test;Wherein, test machine includes PC, notebook
Deng.Stability of the embodiment of the present invention using test machine for router is tested, and obtains a series of test data, is tested
Machine, which executes different test scripts, can test the performance of a router to be measured, can also be performed simultaneously not by more test machines
Same test script tests the performance of more each model routers to be measured, obtains the test number of each test item of router to be measured
According to, and the test data of each test item and server are subjected to information exchange, by the database of test data typing server
In.In this way, the test item of at least one router to be measured of test, can need to repeat to build test wrapper to avoid Test Engineer
Border improves work efficiency, time saving and energy saving;It can also enough normal or abnormal efficiently quickly fixed by outputing test data
Position failure problems prompt tester's data test abnormal, can be tester and rapidly find exception by warning information
Point.
Referring to shown in Fig. 2, relative to upper one embodiment, details are not described herein for identical part.The present invention provides one kind
Another embodiment of the method for test router, the embodiment comprising steps of
S100 controls the test machine according to default building plan, and the router to be measured connects same with the server
Network;
First test script and second test script is arranged in test machine described in S200, according to the test script
Select test assignment and test time started;
S310 test machine and any router wired connection to be measured;Obtain the first test foot in the server
This, acquires the router memory related data to be measured, and the router memory to be measured is related in the first preset duration
Data are saved into the server database;And/or
S320 test machine and any router to be measured are wirelessly connected;Obtain the second test foot in the server
This, acquires the router performance related data to be measured, and the router performance to be measured is related in the second preset duration
Data are saved into the server database;
S410 inputs url on any test machine connecting with the server, requests access to the clothes by the url
Business device;
Server described in S420 judges the current test data whether in normal range (NR), if executing step S500;It is no
Then follow the steps S600.
Wherein, first preset duration is greater than second preset duration.
Wherein, first test script tests the router memory related data to be measured;Second test script
Test the router performance related data to be measured.
In the embodiment of the present invention, tester can arbitrarily select the test machine connecting with server, in the test
Url is inputted on machine browser, server is requested access to by the url, is surveyed according to the pre-set test time started
Examination.Here it can be set and only test router memory related data to be measured, can also only test router performance dependency number to be measured
According to or router memory related data to be measured and router performance related data to be measured all test.Here it can be set wired
The test for testing the test assignment and wireless test router performance related data to be measured of router memory related data to be measured is appointed
Business starts simultaneously at progress;Also the test assignment that wired test router memory related data to be measured can be set first starts to test,
The test assignment of wireless test router performance related data to be measured then begins to test;Also wireless test road to be measured can be set
By the test assignment of device performance-related data first test, the test assignment of wired test router memory related data to be measured
It then begins to test.Generally in order to save the time, router memory related data to be measured, re-test routing to be measured are first tested in setting
Device performance-related data.
Wherein, by choosing at random the test machine connecting with server, url is inputted on the test machine browser,
Server is requested access to by the url, the stability Visualizing Test System of server, real time access test system can be passed through
System obtains current test data.Selection setting can also be carried out by test machine, thought in this way, user can according to need selection
Script to be tested can also select to think project to be tested by the script of selection.Even, user can also be as needed
The test item etc. for wanting progress is added again.
The test of general router includes at least two test machines, and a test machine executes the first test script, for surveying
Try the remaining CPU of router to be measured, free memory, the test items such as currently running main steps and operation hours;
An other test machine executes the second test script, is mainly used for the test of the network parameter of router, such as ping latency,
Ping packet loss, the test items such as network interface card connection speed, network interface card connection signal intensity and network interface card flow, test machine execute each
The test data of each test item got from script, can all be sent to server, be stored in inside the database of server.
Whether server judges current test data in normal range (NR), and then test machine shows that data are normal if normal, meets length of testing speech
After terminate the secondary test, and by test data typing server database, be convenient for subsequent query.If current test data does not exist
Normal range (NR), then system prompt warning information, artificially reviews and validate abnormal data and judges whether to terminate the secondary test, if
Then terminate to test, and by this test data typing historical data, if otherwise whether system rejudges current data normal
Range.When these test datas are checked in user's access, then server loads basis in test page after receiving instruction first
Static html webpage control and javascript script language files etc., many dynamics and the stronger effect of interactivity can be made
Fruit, and the test data for each test item for calling each test machine test to obtain from server database, and according to each
Each test item of a test machine draws a test chart.The data that the present embodiment generates test are managed, real
The visualization for having showed data makes tester more effectively observe the properties variation of router by resolution chart.This
Sample tests the test item of at least one router to be measured, can need to repeat to build test environment to avoid Test Engineer, mention
High working efficiency is time saving and energy saving;It can also enough pass through the normal or abnormal efficiently quick positioning failure that outputs test data
Problem;Furthermore it is also possible to which batch carries out the router performance test of different models, the test router of high-efficient automatic
Can, the time for testing and not stopping variation test environment one by one is saved, time saving and energy saving, user's test experience greatly increases.
Referring to shown in Fig. 3, relative to upper one embodiment, details are not described herein for identical part.The present invention provides one kind
Another embodiment of the method for test router, the embodiment comprising steps of
Test machine described in S311 and any router wired connection to be measured;Obtain the first test in the server
Script;
Test machine described in S312 obtains the router residue cpu data to be measured according to the first predeterminated frequency, and saves extremely
In the server database;And/or
Test machine described in S313 obtains the router free memory data to be measured according to first predeterminated frequency, and
It saves into the server database;And/or
Test machine described in S314 obtains the router main steps state to be measured according to first predeterminated frequency, and
It saves into the server database;And/or
Test machine described in S315 obtains the router device runing time to be measured according to first predeterminated frequency, and
It saves into the server database;
The step S320 comprising steps of
Test machine described in S321 and any router to be measured are wirelessly connected;Obtain the second test in the server
Script;
Test machine described in S322 obtains the packet loss and time delay of ping gateway according to the second predeterminated frequency, and saves to institute
It states in server database;And/or
S323 obtains the packet loss and time delay of ping outer net according to second predeterminated frequency, and saves to the service
In device database;And/or
S324 obtains the transmission rate and receiving velocity of network interface card connection according to second predeterminated frequency, and saves to institute
It states in server database;And/or
S325 obtains the signal strength of network interface card connection according to second predeterminated frequency, and saves to the server count
According in library;And/or
S326 obtains network interface card upstream data flow and downlink data flow according to second predeterminated frequency, and saves extremely
In the server database.
In the embodiment of the present invention, tester can request access to server by url, be opened according to pre-set test
Time beginning is tested, and generally in order to save the time, router memory related data to be measured, re-test road to be measured are first tested in setting
By device performance-related data.The test of general router includes at least two test machines, and a test machine executes the first test foot
This tests the remaining CPU and/or free memory and/or currently running main of router to be measured according to the first predeterminated frequency
The test items such as process and/or operation hours;An other test machine executes the second test script, default according to first
Frequency, ping gateway time delay, ping gateway packet loss and/or ping outer net time delay, the ping outer net for testing router to be measured are lost
Packet rate and/or network interface card connection speed (transmission rate and receiving velocity including network interface card connection), network interface card connection signal intensity, and/
Or the test items such as network interface card flow (including network interface card upstream data flow and network interface card downlink data flow), test machine execute respective foot
Originally the test data of each test item got can all be sent to server, be stored in inside the database of server.This reality
Applying example is to illustrate to test all main test item, tester can according to need only test one therein or
Person is several any.When these test datas are checked in user's access, then server is after receiving instruction, and from server database
The test data of the middle each test item for calling each test machine test to obtain, can make in the page of test machine and much show
The result figure of test data.The present embodiment thinks project to be tested to that can carry out selection according to the demand of tester, then
The test result of test item is saved in the database of server, when tester wants the related data of detection router
When, any selection one connects the test machine of consolidated network with server altogether, may have access in the input of test machine input url
Server calls the test result of database currently tested, and server counts test result, and defeated by test machine
It shows out, the data for testing generation are managed, and the visualization of data is realized, and by resolution chart, make tester more
The properties variation for effectively observing router, meanwhile, it is capable to which efficiently and rapidly position stability is asked in many test envelopes
Topic, to find and solving the problems, such as to provide efficient and convenient approach, improves testing efficiency and accuracy.
Referring to shown in Fig. 4, the present invention provides a kind of one embodiment of the system of test router, including server
1000, an at least test machine 2000 and at least a router 3000 to be measured, test machine 2000 described in the embodiment respectively with
3000 communication connection of the server 1000 and router to be measured;
Wherein, the test machine 2000 includes: test module 2200;The server 1000 include storage module 1100,
Judgment module 1200 and control module 1300;The test module 2200 of the test machine 2000 and the storage of the server 1000
1100 communication connection of module;The judgment module 1200 of the server 1000 storage module with the server 1000 respectively
1100 and 1300 communication connection of control module;
The test module 2200 of the test machine 2000, the test stored in advance obtained in the storage module 1100 are appointed
Business, tests at least one router 3000 to be measured;
Whether the judgment module 1200 of the server 1000 receives url access request, judges current test data just
Normal range;
The control module 1300 of the server 1000, when the judgment module 1200 of the server 1000 exports current survey
Data are tried in normal range (NR), it is normal to export the current test data;
The judgment module 1200 of the server 1000, also when export the current test data it is normal after, described in judgement
Whether current length of testing speech meets preset length of testing speech;
The control module 1300 of the server 1000, also when the current length of testing speech meets preset length of testing speech
When, control terminates current test, and the current test data is saved into the storage module 1100 of the server 1000;
The judgment module 1200 of the server 1000, also when the current length of testing speech is unsatisfactory for preset test
It is long, then continue to judge current test data whether in normal range (NR);
The control module 1300 of the server 1000, also when the judgment module 1200 of the server 1000 export it is described
It is abnormal to export the current test data not in normal range (NR) for current test data;
The judgment module 1200 of the server 1000, also when export the current test data it is normal after, judge whether
Terminate current test;
The control module 1300 of the server 1000, after judgement terminates the current test, control terminates current survey
Examination, and current test data is saved into the storage module 1100 of the server 1000;
The judgment module 1200 of the server 1000 continues judgement and works as also after judgement does not terminate the current test
Whether preceding test data is in normal range (NR).
In the embodiment of the present invention, wherein server 1000 connect consolidated network with router 3000 to be measured, selects any company
Lead to the test machine 2000 of the network, the Visualizing Test System of server 1000 can be accessed by input url, and survey can be specified
The beginning testing time of test-run a machine 2000, and test to all test machines 2000 test router 3000 to be measured during the test
Test data information.Stability of the present invention using test machine 2000 for router is tested, and obtains a series of test
Data can execute the performance that different test scripts tests a router 3000 to be measured by a test machine 2000, obtain
The test data of each test item of router 3000 to be measured, and the test data of each test item and server 1000 are subjected to letter
Breath interaction, will be in the database of test data typing server 1000.In this way, the survey of at least one router 3000 to be measured of test
Examination project can be needed to repeat to build test environment to avoid Test Engineer, be improved work efficiency, time saving and energy saving;Moreover, also
Tester can be prompted by warning information by the normal or abnormal efficiently quick positioning failure problem that outputs test data
Data test is abnormal, can be tester and rapidly finds abnormal point.
Referring to Figure 5, relative to upper one embodiment, details are not described herein for identical part.The present invention provides one kind
Another embodiment of the system of test router,
The test machine 2000 further include: setup module 2100, access modules 2300;The setting mould of the test machine 2000
1100 communication connection of storage module of block 2100 and the server 1000;The access modules 2300 of the test machine 2000 and institute
State 1100 communication connection of storage module of server 1000;
First test script and second test script is arranged in the setup module 2100 of the test machine 2000,
Test assignment and test time started are selected according to the test script;
The access modules of the test machine 2000 input on any test machine 2000 connecting with the server 1000
url;The server 1000 is requested access to by the url;Wherein,
First test script tests the 3000 memory related data of router to be measured;Second test script is surveyed
Try 3000 performance-related data of router to be measured.
The test module 2200 of the test machine 2000 includes:
Acquisition submodule 2205 obtains the first test script in the storage module 1100 of the server 1000;With/
Or, obtaining the second test script in the storage module 1100 of the server 1000;
Residue CPU submodule 2210 is tested, according to the first predeterminated frequency, obtains the 3000 residue CPU of router to be measured
Data, and save into the storage module 1100 of the server 1000;And/or
Free memory submodule 2220 is tested, according to first predeterminated frequency, it is surplus to obtain the router 3000 to be measured
Remaining internal storage data, and save into the storage module 1100 of the server 1000;And/or
Main steps submodule 2230 is tested, according to first predeterminated frequency, it is main to obtain the router 3000 to be measured
Process status is wanted, and is saved into the storage module 1100 of the server 1000;And/or
Test run time submodule 2240 obtains the router 3000 to be measured and sets according to first predeterminated frequency
Standby runing time, and save into the storage module 1100 of the server 1000;And/or
Test Network sub-module 2250 obtains the packet loss and time delay of ping gateway according to the second predeterminated frequency, and saves
Into the storage module 1100 of the server 1000;And/or
Outer net submodule 2260 is tested, according to second predeterminated frequency, obtains the packet loss and time delay of ping outer net, and
It saves into the storage module 1100 of the server 1000;And/or
Test connection speed submodule 2270, according to second predeterminated frequency, obtain network interface card connection transmission rate and
The receiving velocity of network interface card connection, and save into the storage module 1100 of the server 1000;
Signal strength submodule 2280 is tested, according to second predeterminated frequency, obtains the signal strength of network interface card connection, and
It saves into the storage module 1100 of the server 1000;And/or
Test uplink/downlink flow submodule 2290, according to second predeterminated frequency, obtain network interface card upstream data flow and
Network interface card downlink data flow, and save into the storage module 1100 of the server 1000.
In the embodiment of the present invention, the test machine 2000, the router to be measured are controlled according to default building plan first
3000 and the server 1000 connect consolidated network.First test script tests the 3000 memory phase of router to be measured
Close data;Second test script tests 3000 performance-related data of router to be measured.Tester can pass through url
Server 1000 is requested access to, is tested according to the pre-set test time started, generally in order to save the time, setting is first
Test 3000 memory related data of router to be measured, re-test 3000 performance-related data of router to be measured.General router
Test includes at least two test machines 2000, and a test machine 2000 executes the first test script, according to the first predeterminated frequency, surveys
Try the remaining CPU of router 3000 to be measured, free memory, the test items such as currently running main steps and operation hours
Mesh;An other test machine 2000 executes the second test script and tests router 3000 to be measured according to the first predeterminated frequency
Ping gateway time delay, ping gateway packet loss, ping outer net time delay, ping outer net packet loss, network interface card connection speed (including network interface card
The transmission rate and receiving velocity of connection), network interface card connection signal intensity and network interface card flow (including network interface card upstream data flow
With network interface card downlink data flow) etc. test items, test machine 2000 execute the test for each test item that respective script is got
Data can all be sent to server 1000, be stored in inside the database of server 1000.When these tests are checked in user's access
When data, then server 1000 calls each test machine 2000 to test after receiving instruction, and from 1000 database of server
The test data of each test item obtained can make the result for much showing test data in the page of test machine 2000
Figure.The present embodiment thinks project to be tested to that can carry out selection according to the demand of tester, then by the survey of test item
Test result is saved in the database of server 1000, any to select when tester wants the related data of detection router
The test machine 2000 for connecting consolidated network altogether with server 1000 is selected, inputs url in the input of the test machine 2000
Server 1000 is accessed, the test result of database currently tested is called, server 1000 counts test result, and
It exports and shows by test machine 2000, the data for testing generation are managed, realize the visualization of data, pass through test chart
Shape makes tester more effectively observe the properties variation of router, meanwhile, it is capable in many test envelopes efficiently quickly
Ground position stability problem improves testing efficiency and accuracy to find and solving the problems, such as to provide efficient and convenient approach.
Referring to shown in Fig. 6, relative to upper one embodiment, details are not described herein for identical part.The present invention provides one kind
The test module 2200 of another embodiment of the system of test router, the test machine 2000 includes:
The test module 2200 of the test machine 2000 and any 3000 wired connection of router to be measured;Described in acquisition
The first test script in the storage module 1100 of server 1000 acquires the router to be measured in the first preset duration
3000 memory related datas, and the 3000 memory related data of router to be measured is saved to the storage of the server 1000
In module 1100;And/or
The test module of the test machine 2000 and any router 3000 to be measured are wirelessly connected;Obtain the service
The second test script in the storage module 1100 of device 1000 acquires 3000 property of router to be measured in the second preset duration
Energy related data, and 3000 performance-related data of router to be measured is saved to the storage module of the server 1000
In 1100;
Wherein, first preset duration is greater than second preset duration.
In the embodiment of the present invention, it can be performed simultaneously different test scripts by more test machines 2000, tested respectively more
The performance of each model of platform router 3000 to be measured, wherein the dotted portion test machine 2000 in Fig. 6 and router 3000 to be measured
It is wirelessly connected, bold portion test machine 2000 and 3000 wired connection of router to be measured.Wherein, it is wirelessly connected partial dynamic distribution
IP address, wired connection part static allocation IP address.What is shown in figure is optimal test program, can be one in test
Above test machine 2000 and 3000 wired connection of router to be measured, one or more test machine 2000 and router 3000 to be measured
It is wirelessly connected, as long as the test machine 2000 for selecting any one to connect with server 1000, input url accesses server 1000,
The script for obtaining server 1000 carries out relevant test, such as obtains the first test script, according to the second predeterminated frequency, test
The remaining CPU of router 3000 to be measured, free memory, the test items such as currently running main steps and operation hours
Mesh;Alternatively, obtain the second test script, according to the first predeterminated frequency, test router 3000 to be measured ping gateway time delay,
Ping gateway packet loss, ping outer net time delay, ping outer net packet loss, network interface card connection speed (the transmission speed including network interface card connection
Rate and receiving velocity), network interface card connection signal intensity and network interface card flow (including line number under network interface card upstream data flow and network interface card
According to flow) etc. test items.Wherein, tester can make all routers to be measured 3000 can be wired with test machine 2000
It connects and is wirelessly connected, it is only necessary to a part of test machine 2000 is set in test and opens wired connection closing infinitely connection, and
The first test script is obtained, 3000 memory dependence test of router to be measured, setting one are just able to carry out according to the first test frequency
Partial test machine 2000 opens unlimited connection closed wired connection, and obtains the second test script, just according to the second test frequency
It is able to carry out 3000 performance dependence test of router to be measured.
Referring to shown in Fig. 7 (a), Fig. 7 (b) and Fig. 7 (c), the present invention provides a reality of a kind of method of test router
Example,
S1, the topological test system building of 7 (a) and Fig. 7 (b) is pressed;
S2, test essential information (such as the hardware version, software for opening stability Visualized Monitoring System setting test envelope
Version etc.) and the test time started
S3, testbed test start, and opening stability Visualized Monitoring System can real time inspection test data
Whether S4, system judge current test data in normal range (NR), and then system shows that data are normal if normal, meet and survey
Terminate the secondary test after examination duration and by test data typing historical data, is convenient for subsequent query.If current test data is not
In normal range (NR), then system prompt warning information, artificially reviews and validate abnormal data and judges whether to terminate the secondary test, if
It is to terminate to test, and by this test data typing historical data, if otherwise whether system rejudges current data just
Normal range.
Pc1~3 acquired following data every one minute by wireless connection dut:
1, every 1 minute ping gateway, packet loss and time delay, numerical value typing serverDB Ping-GW: are calculated.
2, every 1 minute ping outer net, packet loss and time delay, numerical value typing serverDB Ping-Internet: are calculated.
3, the transmission rate of network interface card connection, numerical value typing serverDB Linkrate-Tx: were obtained every one minute.
4, the receiving velocity of network interface card connection, numerical value typing serverDB Linkrate-Rx: were obtained every one minute.
5, the signal strength of network interface card connection, numerical value typing serverDB SignalStrength: were obtained every one minute.
6, Upstream: every one minute acquisition network interface card upstream data flow, numerical value typing serverDB.
7, Downstream: every one minute acquisition network interface card downlink data flow, numerical value typing serverDB.
Pc4 acquired following data every five minutes by wired connection dut:
1, remaining cpu data, numerical value typing serverDB DUT-CPU: are obtained every five minutes telnet equipment.
2, free memory data, numerical value typing serverDB DUT-MEM: are obtained every five minutes telnet equipment.
3, DUT-Process: main steps state is obtained every five minutes telnet equipment.One phase dominant query
Cathkpt process status, numerical value typing serverDB.Later period can inquire other states of a process, therefore database needs to reserve
List item is for recording other states of a process.
4, operation hours, numerical value typing serverDB DUT-Uptime: are obtained every five minutes telnet equipment.
In present example, server is connected to test envelope by laboratory network, any pc for being connected to laboratory network
Stability Visualized Monitoring System, the beginning testing time of nominative testing bed can be accessed by url, and monitored during the test
To the data information of all test envelopes.DUT, wireless router device referred to be measured.The present invention is using test envelope for wireless
The stability of router is tested, and obtains a series of test data.Multiple such test envelopes can carry out a variety of nothings simultaneously
The stability test of line router, and test data and server are interacted into information, by test data typing server
In database.In network between server and test envelope, any one end pc for being connected to the network can be accessed steady by url
Qualitative visualization monitoring system, the beginning testing time of nominative testing bed, and all test envelopes are monitored during the test
Data information.Here, telnet equipment refers to remote control terminal equipment.
In present example, by Zabbix DB (open source monitoring system) control S1-PC-01 perform script Scrit1 come
The test item for executing the 1-5 (or several any in 1-7) in Fig. 7 (b), controls S1-PC-02 perform script Scrit2 to hold
The test item of 8-12 (or several any in 8-14) in row Fig. 7 (b), controls S1-PC-03 perform script Scrit3 to hold
The test item of 15-19 (or several any in 15-21) in row Fig. 7 (b), control S4-PC-01 perform script Scrit4 come
The test item for executing the 22-26 in Fig. 7 (b) saves the data that test obtains into the database of Zabbix DB, according to
The instruction of tester calls test data to analyze.Server counts test result, and exports by test machine
It has been shown that, the data for testing generation are managed, realize the visualization of data, by resolution chart, there is tester more
The properties variation of effect ground observation router, meanwhile, it is capable to the efficiently and rapidly position stability problem in many test envelopes,
To find and solving the problems, such as to provide efficient and convenient approach, testing efficiency and accuracy are improved.
It should be noted that above-described embodiment can be freely combined as needed.The above is only of the invention preferred
Embodiment, it is noted that for those skilled in the art, in the premise for not departing from the principle of the invention
Under, several improvements and modifications can also be made, these modifications and embellishments should also be considered as the scope of protection of the present invention.