CN107171895A - A kind of communication network data flow-measuring method - Google Patents

A kind of communication network data flow-measuring method Download PDF

Info

Publication number
CN107171895A
CN107171895A CN201710528843.2A CN201710528843A CN107171895A CN 107171895 A CN107171895 A CN 107171895A CN 201710528843 A CN201710528843 A CN 201710528843A CN 107171895 A CN107171895 A CN 107171895A
Authority
CN
China
Prior art keywords
data
packet
communication network
data traffic
network
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201710528843.2A
Other languages
Chinese (zh)
Inventor
孙杰
陈婧
陈习权
韩海林
侯升平
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang Province Institute of Metrology
Original Assignee
Zhejiang Province Institute of Metrology
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhejiang Province Institute of Metrology filed Critical Zhejiang Province Institute of Metrology
Priority to CN201710528843.2A priority Critical patent/CN107171895A/en
Publication of CN107171895A publication Critical patent/CN107171895A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/08Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
    • H04L43/0876Network utilisation, e.g. volume of load or congestion level
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/06Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/22Parsing or analysis of headers
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W24/00Supervisory, monitoring or testing arrangements
    • H04W24/08Testing, supervising or monitoring using real traffic

Abstract

The invention discloses a kind of communication network data flow-measuring method, belong to metering method field.This method step is as follows:S1:Access communication network to be measured;S2:Carry out data transmission with destination server, by data traffic monitoring module embedded in network card driver in transmitting procedure, the packet in internet surfing data traffic measurement process is caught in data channel;S3:Parse the packet header captured;S4:According to type of data packet, feature and mark, the packet in destination layer is added up, internet surfing data traffic measurement data is obtained.It is of the invention that communication network data flow measuring data is directly obtained in data channel, with high accuracy and repeatability.

Description

A kind of communication network data flow-measuring method
Technical field
The invention belongs to metering method field, and in particular to a kind of communication network data flow-measuring method.
Background technology
As domestic mobile communications network develops, based on 2G (GPRS, CDMA), 3G (WCDMA, CDMA2000 and TD- SCDMA), 4G (TD-LTE, FDD-LTE) and WIFI mobile data services are used widely, mobile communication carrier's charge It is that the size of the internet surfing data traffic produced using in mobile communication process is used as foundation, the data flow gauge of mobile communication carrier Calculation system and charge system belong to trade settlement equipment scope.According to《Measurement Law》Regulation, trade settlement equipment should be included in pressure Measures range.Simultaneously as the number of users using mobile communication network business is continuously increased, mobile communications network online The accurate measurement sex chromosome mosaicism of data traffic also turns into the focus of public concern.
But lack the device measured to mobile communication carrier's internet surfing data traffic at present, and therefore, quality inspection metering System can not effectively be supervised to mobile communication carrier's internet surfing data traffic metering.
Current user is commonly used in the wireless terminals such as mobile phone and carries out Internet data using internet surfing data traffic Survey Software Flow measurement.Such software is the interface function that provides using system to obtain internet surfing data traffic, due to exist system other Software interference, data-bag lost and retransmit the problems such as, cause measurement internet surfing data traffic and mobile communication carrier place measurement Result error is very big.
In the prior art, relevant programme is as follows:
Chinese invention patent 201210105349.2 discloses a kind of adaptive terminal network flow correction method, the party Method accounts for the proportion of total flow to calculate total flow correspondence according to dynamic adjustment application program weights and local application flow Calibrated fluxes, reach measurement result gap problems of too at result terminal measurements and mobile communication carrier.The program Have the disadvantage to need the weights from high in the clouds acquisition and more new application in trimming process, and timed maintenance updates the application program Weights, weights size directly affects measurement result, if weights are unreasonable, can increase poor with measurement result at mobile communication carrier Away from.It is monthly to calculate to produce after mobile communication carrier's inquiry real traffic that weights, which are obtained, can only monthly update once, lack Real-time.Trimming process can produce excessive data flow.
Chinese invention patent 201410024704.2 discloses a kind of data traffic measuring method of network terminal, this method Have the disadvantages that:(1) network packet that this method filters out wide area network transmission using screening module is united for statistical module Flow is counted, data need to be packaged packing before wide area network transmission is entered according to procotol, and encapsulation packing process can add Upper each layer network agreement packet header, the packet that encapsulation packing is finished is made up of user data and each procotol packet header.It is mobile Common carrier data traffic charging gateway carries out procotol point according to data traffic charging specification to the packet received Layer parsing, is resolved to progress data flow measurement charging after a certain network protocol layer, i.e., the remaining network for not parsing part is assisted View packet header and user data carry out data traffic measurement charging in the lump.This method does not consider which layer to carry out data flow measurement at Amount, causing data traffic to measure bore and mobile communication carrier, to measure bore inconsistent, thus causes measurement result and movement Common carrier measurement result gap.(2) this method in diverter module according to data sample characteristic information by volume of data Sample is divided into some bursts of data flows, and is once maintained operation several times to each burst of data flow and once terminated to operate, and is System can produce overhead, and the excessive data flow that can induce one in operation, bring unpredictalbe data traffic to measure Error.(3) this method calculates the flow deviation value of data flow by the characteristic information of data flow, to correct initial data flow, The algorithm is difficult to ensure that data traffic test result and mobile communication carrier's data traffic measurement result are more close.(4) should Method purpose is to enable users to accurately understand data traffic service condition from terminal, reduces and is inquired about to mobile communication network operator Trouble.This method is difficult to reappear same data traffic test scene, it is impossible to meet repeatability and the stability requirement of metering.
In general, there are the following problems in current state of the art:
(1) mobile communications network internet surfing data traffic measurement data can not be directly obtained, to make measurement result close to fortune Business's measurement result is sought, it is necessary to calculate final flow rate measurement result using weighting algorithm and correction algorithm, the calculating process can draw Enter error, cause measurement result and mobile communication carrier's measurement result gap further to expand.
(2) do not consider which network protocol layer to carry out data traffic measurement at, cause data traffic to measure bore and movement Common carrier measurement bore is inconsistent, thus causes measurement result and mobile communication carrier's measurement result to have larger gap.
(3) it is difficult to reappear same data traffic test scene, it is impossible to which the repeatability and stability requirement for meeting metering can not There is provided stable test, it is impossible to repeatedly reproduce test result.
(4) method is only limited to theory, is not achieved on actual hardware.
The content of the invention
It is an object of the invention to solve problems of the prior art, and provide a kind of communication network data flow to survey Amount method, the device can complete 2G (GPRS, CDMA), 3G (WCDMA, CDMA2000 and TD-SCDMA) and 4G (TD-LTE, FDD-LTE) mobile communications network and the measurement of WIFI internet surfing data traffics under standard.
Concrete technical scheme of the present invention is as follows:
Communication network data flow-measuring method, step is as follows:
S1:Access communication network to be measured;
S2:Carry out data transmission with destination server, drive data traffic monitoring module embedded in network card in transmitting procedure In program, the packet in internet surfing data traffic measurement process is caught in data channel;
S3:Parse the packet header captured;
S4:According to type of data packet, feature and mark, the packet in destination layer is added up, Internet data is obtained Flow measuring data.
In the present invention, data channel refers under the path that data packet stream is passed through in data transmission procedure, such as PPP patterns Socket standards under Linux device file standard interface Read (), Write (), ioctl (), USB interface WIFI module API.The packet caught in data channel in internet surfing data traffic measurement process refers to catch in measurement process by number According to all packets of channel transfer.
Preferably, described data traffic monitoring module is the hook program for monitoring data flow.
Preferably, described data transfer uses data downloading mode.
Preferably, in data transmission procedure, using repeatedly downloading onesize file.
Another object of the present invention is to provide a kind of communication network data flow metering method, step is as follows:By logical Communication network access communications data operator, then download normal data APMB package from server;This article is downloaded in measurement as stated above The flow that part is produced, then the data traffic with the measurement of communication data operator fee collecting system be compared, obtain both Between data deviation, the accuracy of charge system is judged according to deviation size.
A further object of the present invention is to provide a kind of communication network data flow measurement device, including
AM access module:The communication network to be measured for accessing;
Monitoring module:For carrying out data transmission with destination server, data traffic is monitored into hook journey in transmitting procedure In sequence embedded in network card driver, the packet in internet surfing data traffic measurement process is caught in data channel;
Parsing module:For parsing the packet header captured;
Statistical module:For according to type of data packet, feature and mark, being added up to the packet in destination layer, being obtained To internet surfing data traffic measurement data.
Preferably, described parsing module and statistical module is run in linux system.
Based on foregoing communication network data flow-measuring method, the present invention for different communication network species there is provided Three kinds of preferred implementations, it is specific as follows:
The first communication network data flow-measuring method, it is adaptable to which communication network is 2G, 3G or PPP pattern 4G networks; Its step is:
Initializing signal informing mechanism and shared drive mechanism, load the first hook journey for monitoring network interface card working condition Sequence, loading starts in kernel and the second hook program for monitoring data traffic in NIC driver, monitoring data passage All-network operation, while calling AT instruction initialization dialing parameters, module messaging parameter and network type parameters and loading Configuration, calls serial ports workbench process, into networked mode;Using the second hook program being embedded in NIC driver, During carrying out data transmission with destination server, the data in internet surfing data traffic measurement process are caught in data channel Bag;The packet header captured is parsed, according to type of data packet, feature and mark, the packet in destination layer is tired out Meter, obtains internet surfing data traffic measurement data.
Second of communication network data flow-measuring method, it is adaptable to which communication network is the TD-LTE 4G nets under USB interface Network or FDD-LTE 4G networks;Its step is:
Signal informing mechanism and shared drive mechanism under Initialize installation TD-LTE or FDD-LTE flow rate mode, loading Hook program for monitoring 4G flows, calls IFCONFIG orders loading initialization network card equipment, is registered to NET Device List, while calling AT instruction initialization dialing parameters, module messaging parameter and network type parameters and loading configuration, calls string Mouth workbench process;Using the hook program being embedded in NIC driver, carried out data transmission with destination server Cheng Zhong, catches the packet in internet surfing data traffic measurement process in data channel;Parse the packet header captured, root According to type of data packet, feature and mark, the packet in destination layer is added up, internet surfing data traffic measurement data is obtained.
The third communication network data flow-measuring method, it is adaptable to which communication network is USB interface WIFI network;Its step For:
Signal informing mechanism and shared drive mechanism under Initialize installation WIFI flow rate modes, are loaded for monitoring WIFI The hook program of flow, calls IFCONFIG orders loading initialization network card equipment, is registered to NET Device lists;Utilize hook Subprogram, during carrying out data transmission with destination server, catches internet surfing data traffic measurement process in data channel In packet;The packet header captured is parsed, according to type of data packet, feature and mark, to the data in destination layer Bag is added up, and obtains internet surfing data traffic measurement data.
The present invention in terms of existing technologies, has the advantages that:
1st, the present invention can obtain communication network data flow measuring data directly in data channel, without being weighted Or correction algorithm.
2nd, the present invention is embedded in driver using by data traffic monitoring hook program, the real-time capture in data channel Packet in internet surfing data traffic measurement process, and parse the packet header that captures, judge type of data packet, feature and Mark, according to judged result, rejects the packet for being not belonging to scope of statistics, and the mobile communications network for belonging to scope of statistics is surfed the Net The progress of data traffic packet is real-time accumulated, obtains internet surfing data traffic measurement data measurement result, as a result need not be added Power is corrected, and significantly improves internet surfing data traffic measurement data measurement accuracy.
3rd, the present invention can count IP layers of upstream data flow measuring data, IP layers of downlink data flow measurement number respectively According to, TCP layer upstream data flow measuring data and TCP layer downlink data flow measuring data, user can obtain individually up With descending measurement data, TCP layer and IP layers of measurement data can also be obtained respectively.
4th, the mobile communications network internet surfing data traffic measurement data and operator that the present invention is obtained are consistent.The present invention The mobile communications network internet surfing data traffic measuring method of use, due to using data traffic monitoring hook program insertion driving journey The method of sequence and the packet in data channel in real-time capture internet surfing data traffic measurement process, test result and operator Keep high consistency, it is ensured that the accuracy and fairness of measurement result.
5th, the present invention can reappear same data traffic test scene, meet repeatability and the stability requirement of metering.Meter Amount requires that test device and method have good stability and repeatability, the method used using the present invention, can be in difference Time, different location carried out same data traffic test, and test has repdocutbility, with fine repeatability and stability, completely symbol Total amount requirement.
Brief description of the drawings
Fig. 1 is the flow chart of communication network data flow-measuring method;
Fig. 2 is the structural representation of communication network data flow measurement device in embodiment;
Fig. 3 is the flow chart of communication network data flow-measuring method in an embodiment;
Fig. 4 is the flow chart of communication network data flow-measuring method in an embodiment;
Fig. 5 is the flow chart of communication network data flow-measuring method in an embodiment;
Fig. 6 is the flow chart that the network terminal obtains packet;
Fig. 7 is the flow chart of communication network data flow metering method.
Embodiment
The present invention is further elaborated and illustrated with reference to the accompanying drawings and detailed description.Each in the present invention is implemented The technical characteristic of mode can carry out respective combination on the premise of not colliding with each other.
Communication network data flow-measuring method proposed by the present invention, basic step is as shown in Figure 1:
S1:By the network terminal (mobile device, PC or other be integrated with the network equipment of functional module) access is to be measured The communication network of amount, communication network includes 2G, 3G, 4G, 5G, WIFI network, WiMax, cable network or Ethernet.
S2:(upstream or downstream are preferably downloaded) is carried out data transmission with destination server by the communication network again, passed One is used in the hook program embedded in network card driver of monitoring data flow during defeated, is caught in data channel Packet during network data flow measurement;
S3:Parse the packet header captured;
S4:According to the analysis result (including type, feature and mark) of packet, packet can be sorted out to corresponding Layer, is then added up to the packet in destination layer, obtains this layer of internet surfing data traffic measurement data.
The above method can be measured according to user's needs to the internet surfing data traffic of different layers.Destination layer can be Application layer, transport layer in any one layer in procotol, such as layer models of TCP/IP tetra-, Interconnection Network Layer, network interface Layer;Physical layer, data link layer, Internet, transport layer, session layer, expression layer, application layer in OSI seven layer models;2G networks In Internet, GTP layers, TCP/UDP layers, IP layers, data link layer, physical layer.
To take multiple measurements, in data transmission procedure, the packet of transmission can be set as the standard of fixed size File, to improve checking repeatability.Each step of this method can be realized by disparate modules in embedded systems.By Had differences in the network of different systems, thus the above method be applied to heterogeneous networks in when also to be changed accordingly.Under Face is for the most commonly seen network formats of three classes, to introduce the present invention's exemplified by the embedded system for carrying (SuSE) Linux OS Implementation.
When communication network is 2G, 3G or PPP pattern 4G networks, above-mentioned flow-measuring method step is:
As shown in figure 3, system initialization sets signal informing mechanism and shared drive mechanism under PPP patterns, call PPPD-2.4.4 processes are simultaneously run in back way, load the first hook journey for monitoring PPPD-2.4.4 process works states Sequence, loading starts kernel PPP drivings, loads the second hook program for monitoring data traffic in PPPD-2.4.4 drivings, prison Linux device file standard interface Read (), Write (), ioctl () all operations are controlled, while calling AT instructions initial Change dialing parameters, module messaging parameter and network type parameters and these configurations will be loaded, call serial ports workbench process, enter Networked mode carries out the transmission of packet.During carrying out data transmission with destination server, using being embedded in trawl performance The second hook program in program, catches the packet in internet surfing data traffic measurement process in data channel;Parsing is caught The packet header arrived, according to type of data packet, feature and mark, is added up to the packet in destination layer, is surfed the Net Data traffic measurement data.
When communication network is TD-LTE 4G networks or FDD-LTE 4G networks under USB interface, above-mentioned flow measurement side Method step is:
As shown in figure 4, during linux system startup, the signal under Initialize installation TD-LTE or FDD-LTE flow rate mode leads to Know mechanism and shared drive mechanism, load the hook program for monitoring 4G flows, call IFCONFIG orders loading initialization Network card equipment, is registered to NET Device lists, while calling AT instruction initialization dialing parameters, module messaging parameter and network Type parameter simultaneously loads configuration, calls serial ports workbench process;Using the hook program being embedded in NIC driver, with During destination server carries out data transmission, the packet in internet surfing data traffic measurement process is caught in data channel; The packet header captured is parsed, according to type of data packet, feature and mark, the packet in destination layer is added up, Obtain internet surfing data traffic measurement data.
When communication network is USB interface WIFI network, above-mentioned flow-measuring method step is:
As shown in figure 5, during linux system startup, signal informing mechanism under Initialize installation WIFI flow rate modes and altogether Memory mechanism is enjoyed, the hook program for monitoring WIFI flows is loaded, IFCONFIG orders loading initialization network card equipment is called, It is registered to NET Device lists;Using hook program, during carrying out data transmission with destination server, in data channel The upper packet caught in internet surfing data traffic measurement process;The packet header captured is parsed, according to type of data packet, spy Seek peace mark, the packet in destination layer is added up, internet surfing data traffic measurement data is obtained.
Above are only the step of realizing under three class network formats, but those skilled in the art it should be appreciated that the present invention not Only limit and this, can also be measured such as WiMax, 5G, cable network or Ethernet using the method for the present invention.
Further, since in data transmission procedure, the process of other in system can also produce data traffic in activity, therefore In order to reduce the interference of other processes, method of the invention is preferably run in linux system.
Based on above-mentioned data traffic measuring method, a kind of communication network data flow measurement side can also be further provided for Method, step is as follows:
The network terminal by Radio Link access mobile communication operator, then by wire link from server download standard File data bag, as shown in Figure 6.Again as shown in fig. 7, measuring the flow that the network terminal downloads this document generation by preceding method, Then the data traffic with the measurement of communication data operator fee collecting system is compared, and obtains data deviation between the two, The accuracy of carrier billing systems is judged according to deviation size.
With reference to a specific embodiment, the present invention is further elaborated, enables those skilled in the art Enough more fully understand the implementation of the present invention.
Embodiment 1
A set of special mobile communications network internet surfing data traffic measurement is devised in the present invention, the present embodiment in order to realize Device, the hardware configuration of the device as shown in Fig. 2 be connected by CPU and with CPU memory cell DDR ram memory cells, NANDFLASH, wireless networking communication module, capacitance touch screen, WLAN unit, gps clock unit, audio input output unit, MSATA hard-disk interfaces, SD interface, local ethernet interface, USB Host interfaces, PMU composition.
CPU uses Freescale i.MX6 ARM Cortex-A9 processors, dominant frequency 1GHz;DDR ram memory cells are used DDR3 internal memories, 1GB capacity;NAND FLASH use INAND Flash, the 8GByte capacity of high speed EMMC interfaces, support INAND Start;Wireless networking communication module using mini-PCIE interfaces 3G module (support WCDMA, CDMA2000 and TD-SCDMA, to Lower compatible 2G (GPRS, CDMA)) and 4G modules (TD-LTE, FDD-LTE), instruction set is supported, can be configured as needed, antenna is External SMA interfaces, support China Mobile, China Telecom and CHINAUNICOM three to run greatly;Capacitance touch screen is using LVDS interface electricity Appearance formula multiple point touching display screen;WLAN unit uses WiFi module, supports 802.11b/g/n;Gps clock unit uses GPS moulds Block, antenna is external SMA interfaces;Audio input output unit provides audio coding and decoding interface;MSATA hard-disk interfaces are provided SATA interface, maximum supports 4T mSATA hard disks;SD interface provides a standard SD card interface;Local ethernet interface provides one Individual 10/100/1000Mbps BASE-T Ethernet interfaces;USB Host interfaces support 4 USB HOST interfaces, and a USB OTG;PMU uses 10000 MAH 7.2V lithium battery and external power supply.
Each hardware capability is as follows in mobile communications network internet surfing data traffic measurement apparatus:
CPU:Hardware unit core, carries (SuSE) Linux OS, for process instruction, performs operation, control time, place Manage data etc..
DDR ram memory cells:Volatile storage devices, ephemeral data during for interim storage operation for embedded system.
NAND FLASH:Non-volatile memory device, for storage device embedded system program and data.
Wireless networking communication module:Device upstream data is sent to wireless air chain after being modulated through wireless networking communication module Road;Device is sent to after receiving downlink data and demodulation from wireless air-link.
Capacitance touch screen:Man-machine interaction shows that system receives control command, display arrange parameter and measurement result.
WLAN unit:Connect WIFI hot spot.
Gps clock unit:System time synchronization.
Audio input output unit:The input and output of audio signal.
MSATA hard-disk interfaces:There is provided memory space for expanding hard disk.
SD interface:External SD card is supported, for copying data flow measurement.
Local ethernet interface:Connect LAN.
USB Host interfaces:Circumscribed USB equipment is supported, for copying data flow measurement.
PMU:Power supply supply is provided for device.
After system starts, hardware initialization is carried out to wireless networking communication module, storage system and display system first, it is complete After, in capacitance touch screen display current system hardware information, and user test is waited to instruct.User is in capacitance touch screen After input test instruction, system receives user and sets operation, and device dials up on the telephone, and starts internet surfing data traffic measurement.System is adjusted Internet surfing data traffic measurement process is monitored with flow measurement instruction set and linux system kernel support module and IP data are measured Bag, shows internet surfing data traffic measurement data and is stored in system physical memory space in real time on capacitance touch screen.System is led to Cross gps clock unit and realize system time synchronization.Mobile communications network internet surfing data traffic is measured based on the device Specific method step is as follows:
(1) WCDMA 3G modules, are selected as the wireless networking communication module of measurement.
(2), by embedded program writing station NAND FLASH.
(3), external power supply is accessed by installation's power source administrative unit to power to device.
(4) CHINAUNICOM's online SIM card, is put into device neck.
(5), mobile communications network internet surfing data traffic measurement apparatus is started shooting.
(6), hardware initialization, hardware initialization is carried out to wireless networking communication module, storage system and display system, complete After, current system information is shown in device capacitance touch screen.
(7) linux system, is started
System initialization sets signal informing mechanism and shared drive mechanism under PPP patterns, calls PPPD-2.4.4 to enter Journey is simultaneously run in back way, loads the first hook program for monitoring PPPD-2.4.4 process works states, and loading starts Kernel PPP drives, and loads the second hook program for monitoring data traffic in PPPD-2.4.4 drivings, monitors Linux equipment File standard interface Read (), Write (), ioctl () all operations, at the same call AT instruction initialization dialing parameters, Module messaging parameter and network type parameters simultaneously will load these configurations, call serial ports workbench process, enter into networked mode The transmission of row packet.
(8), user clicks on set of time in device capacitance touch screen, and device gps clock unit carries out time synchronized, completes Apparatus system set of time
(9), user is in device capacitance touch screen arrange parameter:Test-types are selected for " dialing circulates HTTP " and " downloaded File ", download file IP address are 218.75.126.173, and port is 80 ports, and cycle-index is set 10 times, and dialing parameters are set It is set to and " is waited 0 second before dialing;Waited 0 second before downloading;Waited 10 seconds after broken string ".
(10), after setting completed, START button is clicked in device capacitance touch screen.Start test.
(11), device dials up on the telephone, and device is by embedded program from address http://218.75.126.173:Under 80 Load file size is 10MB normative documents, and file is temporarily stored in NAND FLASH in downloading process.In downloading process, utilize The second hook program being embedded in NIC driver catches the number in internet surfing data traffic measurement process in data channel According to bag, the packet header captured is parsed, according to type of data packet, feature and mark, the data of IP layers and TCP layer are identified Bag, rejects remainder data bag, the packet in IP layers and TCP layer is added up respectively, internet surfing data traffic in each layer is obtained Measurement data.
(12) after the completion of, device is once downloaded, PPP connections are disconnected, this is downloaded in device capacitance touch screen display To data traffic measurement result.IP layers of downlink traffic in data traffic measurement result, IP layers of uplink traffic, IP layers of uplink and downlink Total flow, TCP downlink traffics, TCP uplink traffics, TCP uplink and downlink total flows.
In the present embodiment, after the completion of downloading for the first time, test data is as follows:
Table 1 first time data traffic measurement result
(13), device is downloaded after completion once, after broken string is waited 10 seconds, is dialled up on the telephone again, repeated downloads file size For 10MB normative documents 9 times.10 groups of following data are obtained after being completed.
20 data flow measurements of table
(14), test is completed, and disconnects PPP connections, test result is saved in into NANDFLASH with TXT file formats.
(15) USB flash disk, is inserted into USB Host interfaces, TXT file formats are copied to USB flash disk.
(16) mobile communication carrier website, is logged in, inquiry surfing flow is detailed, by mobile communication carrier's surfing flow The data traffic measurement data that the data traffic measurement data of charge system measurement is measured with the present apparatus is compared, and obtains data Flow measuring data deviation.
30 data flow measurements of table compare situation with carrier data
Sequence number IP layers of up-downgoing total flow (byte) of device Operator IP layers of up-downgoing total flow (byte) Absolute value of the bias
1 11087414 11087466 0.00047%
2 11086166 11086218 0.00047%
3 11089650 11089650 0.00000%
4 11088974 11089130 0.0014%
5 11090638 11090794 0.0014%
6 11086946 11087102 0.0014%
7 11088558 11088558 0.00000%
8 11088090 11088090 0.00000%
9 11087518 11087518 0.00000%
10 11088870 11088922 0.00047%
As can be seen here, the present invention has high measurement accuracy, the data traffic that actual measured value is provided with operator Absolute value of the bias between value is controlled within 0.0014%.
Embodiment described above is a kind of preferably scheme of the present invention, and so it is not intended to limiting the invention.Have The those of ordinary skill for closing technical field, without departing from the spirit and scope of the present invention, can also make various changes Change and modification.Therefore the technical scheme that all modes for taking equivalent substitution or equivalent transformation are obtained, all falls within the guarantor of the present invention In the range of shield.

Claims (10)

1. a kind of communication network data flow-measuring method, it is characterised in that step is as follows:
S1:Access communication network to be measured;
S2:Carry out data transmission with destination server, by data traffic monitoring module embedded in network card driver in transmitting procedure In, the packet in internet surfing data traffic measurement process is caught in data channel;
S3:Parse the packet header captured;
S4:According to type of data packet, feature and mark, the packet in destination layer is added up, internet surfing data traffic is obtained Measurement data.
2. communication network data flow-measuring method as claimed in claim 1, it is characterised in that described data traffic monitoring Module is the hook program for monitoring data flow.
3. communication network data flow-measuring method as claimed in claim 1, it is characterised in that described data transfer is used Data downloading mode.
4. communication network data flow-measuring method as claimed in claim 1, it is characterised in that in data transmission procedure, is passed Defeated packet is the normative document of fixed size.
5. a kind of communication network data flow measurement device, it is characterised in that including
AM access module:The communication network to be measured for accessing;
Monitoring module:It is in transmitting procedure that data traffic monitoring hook program is embedding for carrying out data transmission with destination server Enter in NIC driver, the packet in internet surfing data traffic measurement process is caught in data channel;
Parsing module:For parsing the packet header captured;
Statistical module:For according to type of data packet, feature and mark, being added up to the packet in destination layer, being obtained Network data flow measuring data.
6. communication network data flow measurement device as claimed in claim 5, it is characterised in that described parsing module and system Meter module is run in linux system.
7. a kind of communication network data flow-measuring method, described communication network is 2G, 3G or PPP pattern 4G networks;It is special Levy and be, initializing signal informing mechanism and shared drive mechanism load the first hook journey for monitoring network interface card working condition Sequence, loading starts in kernel and the second hook program for monitoring data traffic in NIC driver, monitoring data passage All-network operation, while calling AT instruction initialization dialing parameters, module messaging parameter and network type parameters and loading Configuration, calls serial ports workbench process, into networked mode;Using the second hook program being embedded in NIC driver, During carrying out data transmission with destination server, the data in internet surfing data traffic measurement process are caught in data channel Bag;The packet header captured is parsed, according to type of data packet, feature and mark, the packet in destination layer is tired out Meter, obtains internet surfing data traffic measurement data.
8. a kind of communication network data flow-measuring method, described communication network be TD-LTE 4G networks under USB interface or FDD-LTE 4G networks;Characterized in that,
Signal informing mechanism and shared drive mechanism under Initialize installation TD-LTE or FDD-LTE flow rate mode, loading is used for The hook program of 4G flows is monitored, IFCONFIG orders loading initialization network card equipment is called, is registered to NET Device lists, AT instruction initialization dialing parameters, module messaging parameter and network type parameters are called simultaneously and configuration is loaded, and call serial ports work Make platform process;Using the hook program being embedded in NIC driver, during carrying out data transmission with destination server, The packet in internet surfing data traffic measurement process is caught in data channel;The packet header captured is parsed, according to number According to Packet type, feature and mark, the packet in destination layer is added up, internet surfing data traffic measurement data is obtained.
9. a kind of communication network data flow-measuring method, described communication network is USB interface WIFI network;Its feature exists In step is as follows:
Signal informing mechanism and shared drive mechanism under Initialize installation WIFI flow rate modes, are loaded for monitoring WIFI flows Hook program, call IFCONFIG orders loading initialization network card equipment, be registered to NET Device lists;Utilize hook journey Sequence, during carrying out data transmission with destination server, catches in internet surfing data traffic measurement process in data channel Packet;The packet header captured is parsed, according to type of data packet, feature and mark, the packet in destination layer is entered Row is accumulative, obtains internet surfing data traffic measurement data.
10. a kind of communication network data flow metering method, it is characterised in that step is as follows:
Normal data APMB package is downloaded by communication network access communications data operator, then from server;By claim 1 institute State method measurement and download the flow that this document is produced, then with the data traffic of communication data operator fee collecting system measurement It is compared, obtains data deviation between the two, the accuracy of charge system is judged according to deviation size.
CN201710528843.2A 2017-07-01 2017-07-01 A kind of communication network data flow-measuring method Pending CN107171895A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710528843.2A CN107171895A (en) 2017-07-01 2017-07-01 A kind of communication network data flow-measuring method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710528843.2A CN107171895A (en) 2017-07-01 2017-07-01 A kind of communication network data flow-measuring method

Publications (1)

Publication Number Publication Date
CN107171895A true CN107171895A (en) 2017-09-15

Family

ID=59826753

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710528843.2A Pending CN107171895A (en) 2017-07-01 2017-07-01 A kind of communication network data flow-measuring method

Country Status (1)

Country Link
CN (1) CN107171895A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111263388A (en) * 2020-02-13 2020-06-09 上海复深蓝软件股份有限公司 Mobile network environment testing method and device, computer equipment and storage medium
CN113628358A (en) * 2021-07-27 2021-11-09 北京优奥创思科技发展有限公司 Conference sign-in hardware performance test method, system and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1633110A (en) * 2005-01-14 2005-06-29 中国科学院计算技术研究所 Flow analysis method based on Linux core
CN102711075A (en) * 2012-04-12 2012-10-03 深圳市中兴移动通信有限公司 Self-adaptive terminal network flow correction method
US20120250567A1 (en) * 2010-04-09 2012-10-04 Xingwei Zhou Method and device for dynamically changing port service configuration between application processor and communication module
CN103716211A (en) * 2014-01-20 2014-04-09 西安电子科技大学 Data traffic measuring method and system of network terminal
CN104092581A (en) * 2014-06-30 2014-10-08 国家电网公司 Quick message processing method in message recording and analyzing system of intelligent substation
CN104684003A (en) * 2015-02-12 2015-06-03 洛阳市质量技术监督检验测试中心 Flow measurement method for mobile network

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1633110A (en) * 2005-01-14 2005-06-29 中国科学院计算技术研究所 Flow analysis method based on Linux core
US20120250567A1 (en) * 2010-04-09 2012-10-04 Xingwei Zhou Method and device for dynamically changing port service configuration between application processor and communication module
CN102711075A (en) * 2012-04-12 2012-10-03 深圳市中兴移动通信有限公司 Self-adaptive terminal network flow correction method
CN103716211A (en) * 2014-01-20 2014-04-09 西安电子科技大学 Data traffic measuring method and system of network terminal
CN104092581A (en) * 2014-06-30 2014-10-08 国家电网公司 Quick message processing method in message recording and analyzing system of intelligent substation
CN104684003A (en) * 2015-02-12 2015-06-03 洛阳市质量技术监督检验测试中心 Flow measurement method for mobile network

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
浙江在线 钱江晚报: "实验证明不是运营商在偷流量", 《HTTPS://XW.QQ.COM/TECH/20151122012441》 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111263388A (en) * 2020-02-13 2020-06-09 上海复深蓝软件股份有限公司 Mobile network environment testing method and device, computer equipment and storage medium
CN113628358A (en) * 2021-07-27 2021-11-09 北京优奥创思科技发展有限公司 Conference sign-in hardware performance test method, system and storage medium

Similar Documents

Publication Publication Date Title
CN107148009A (en) Multi-standard mobile communications network internet surfing data traffic measurement apparatus and its method
CN100377523C (en) Data service information collecting device and charging method using same
CN103297282A (en) Network delay measuring device and method
JP5717862B2 (en) Content caching with remote billing services in wireless access networks
CN107623644A (en) A kind of bandwidth speed limiting method, apparatus and equipment
CN107171895A (en) A kind of communication network data flow-measuring method
CN106209325A (en) A kind of TCP ACK message processing method and device
CN108198286A (en) A kind of intelligent door lock system based on NB-IOT technologies
CN103096363A (en) Method and device for simulating weak wireless network
US20120102141A1 (en) Caching at the wireless tower with remote charging services
CN109617802B (en) Link aggregation implementation method and related product
CN105814930B (en) Charging controller, method and system
CN110248379A (en) The performance test methods and device of base station in WLAN
CN102315981B (en) Equipment and method for testing evolved packet core network equipment
US20070195801A1 (en) Context-based processing of data flows
WO2013007198A1 (en) Charging method and device
Zeng et al. Multi-attribute Aware Path Selection Approach for Efficient MPTCP-based Data Delivery.
CN207354632U (en) A kind of multi-standard mobile communications network internet surfing data traffic measuring device
CN104640158B (en) Terminal occupies Internet resources calculation method, device and Internet resources calculation server
CN104205887A (en) Billing method, access network device and gateway device
CN104380783B (en) A kind of method, apparatus and system of flow monitoring
CN102291206B (en) Test method, device and system of uploading and downloading speed of 3G interface
US20050137838A1 (en) Dial-up resource simulator
WO2021209058A1 (en) Antenna selection method and related device
CN107682234A (en) A kind of method of the network speed test based on WebSocket

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
WD01 Invention patent application deemed withdrawn after publication
WD01 Invention patent application deemed withdrawn after publication

Application publication date: 20170915