CN114070756B - Method for counting network traffic and related device - Google Patents

Method for counting network traffic and related device Download PDF

Info

Publication number
CN114070756B
CN114070756B CN202111118140.5A CN202111118140A CN114070756B CN 114070756 B CN114070756 B CN 114070756B CN 202111118140 A CN202111118140 A CN 202111118140A CN 114070756 B CN114070756 B CN 114070756B
Authority
CN
China
Prior art keywords
base station
internet surfing
module
target base
moment
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202111118140.5A
Other languages
Chinese (zh)
Other versions
CN114070756A (en
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.)
Shenzhen Neoway Technology Co Ltd
Original Assignee
Shenzhen Neoway Technology Co Ltd
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 Shenzhen Neoway Technology Co Ltd filed Critical Shenzhen Neoway Technology Co Ltd
Priority to CN202111118140.5A priority Critical patent/CN114070756B/en
Publication of CN114070756A publication Critical patent/CN114070756A/en
Application granted granted Critical
Publication of CN114070756B publication Critical patent/CN114070756B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

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
    • 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/0805Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters by checking availability
    • H04L43/0811Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters by checking availability by checking connectivity
    • 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
    • H04L43/0894Packet rate
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/10Active monitoring, e.g. heartbeat, ping or trace-route
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W64/00Locating users or terminals or network equipment for network management purposes, e.g. mobility management
    • H04W64/003Locating users or terminals or network equipment for network management purposes, e.g. mobility management locating network equipment
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Environmental & Geological Engineering (AREA)
  • Health & Medical Sciences (AREA)
  • Cardiology (AREA)
  • General Health & Medical Sciences (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The embodiment of the application discloses a method for counting network traffic and a related device, wherein the method comprises the following steps: the internet surfing module starts a network access service; the internet surfing module records internet surfing information, wherein the internet surfing information comprises information for counting network flow between the internet surfing module and a target base station, and the target base station is any base station connected with the internet surfing module. The embodiment of the application can improve the accuracy of counting the network traffic by recording the network traffic by using the internet surfing module for providing the network access service.

Description

Method for counting network traffic and related device
Technical Field
The present application relates to the field of communications technologies, and in particular, to a method and an apparatus for counting network traffic.
Background
With the development of communication technology and the proliferation of mobile office demands, a mode of surfing the internet by using a notebook computer gradually becomes a popular choice for mobile office of people, and accordingly, the user demands for checking network traffic at any time and any place are met.
Currently, a method for counting network traffic generally uses a background application program resident in a notebook computer to count network traffic, and when the background application program detects that the notebook computer uses a network, the background application program starts to acquire and count network traffic.
However, in the actual use process, under the condition that the burden of the notebook computer is large, the background application program may be closed, which results in lower accuracy of network traffic statistics.
Disclosure of Invention
The embodiment of the application provides a method and a related device for counting network traffic, which aim to improve the accuracy of counting the network traffic under the condition of larger load of a notebook computer.
In a first aspect, an embodiment of the present application provides a method for counting network traffic, where the method includes: the internet surfing module applied to providing network access service comprises:
the network access module starts the network access service;
the internet surfing module records internet surfing information, wherein the internet surfing information comprises information for counting network flow between the internet surfing module and a target base station, and the target base station is any base station connected with the internet surfing module.
It should be understood that the above-mentioned internet surfing module is one or more modules for providing network access service, and the above-mentioned internet surfing module may exist in various forms, for example, the above-mentioned internet surfing module may be a separate and removable physical component installed in the terminal device, a non-removable physical component embedded in the terminal device, or a program code downloaded to the terminal device through a network, etc.; the internet surfing information includes, but is not limited to, information for counting network traffic between the internet surfing module and a target base station, for example, the internet surfing information may also include information of a terminal device where the internet surfing module is located, and specifically, the internet surfing information may include a product identifier of the terminal device, information of an application program installed in the terminal device, and other information related to a network connected to the terminal device; the target base station is one or more base stations connected with the internet surfing module in the process of providing network access service.
In the embodiment of the application, the method records the internet information through the internet surfing module, and the internet surfing module has the function of providing network access service for the terminal equipment, so that the terminal equipment where the internet surfing module is located can not receive and send data through a network under the condition that the terminal equipment is more burdened or the internet surfing module can not be normally used due to other reasons, namely, network traffic can not be generated, thereby solving the problem of omission in the process of counting the network traffic and improving the accuracy of counting the network traffic.
In one possible implementation manner of the first aspect, the recording, by the internet surfing module, internet surfing information includes:
the internet surfing module records a first moment, a second moment, a flow accumulated value and target base station information; the first time is used for indicating the time when the internet surfing module is connected with the target base station, the second time is used for indicating the time when the internet surfing module is disconnected with the target base station, the flow accumulated value is used for indicating the magnitude of flow accumulated by the internet surfing module connected with the target base station, and the target base station information comprises the geographic position information of the target base station.
The information for counting the network traffic between the internet surfing module and the target base station includes: the first time, the second time, the traffic integrated value, and the target base station information.
It should be understood that the internet information will change during each connection or disconnection between the internet module and the target base station, and therefore, the internet information needs to be updated during the process of counting the network traffic.
In the method for counting network traffic provided by the embodiment of the application, when the internet surfing module establishes connection with the target base station, the internet surfing module starts to record the moment when the internet surfing module establishes connection with the target base station as the first moment, namely, the time point when the network traffic starts to be generated in the process of counting this time; when the internet surfing module is disconnected with the target base station, the internet surfing module starts to record the moment when the internet surfing module is disconnected with the target base station as a second moment, namely, the time point when the network traffic stops being generated in the counting process; and the internet surfing module further records the magnitude of the accumulated network flow generated between the internet surfing module and a target base station and information of any base station connected with the internet surfing module, namely the flow accumulated value and the target base station information, between the first moment and the second moment.
It can be understood that in the actual application process, the acquired accuracy levels of the first time and the second time may be preset according to the requirement, for example, the accuracy levels of the first time and the second time may be second level or millisecond level, etc., and in the time dimension, the statistical network flow may be more accurate; in addition, according to the recorded target base station information, the base station positioning technology can be adopted to acquire the information of the geographic position of the internet surfing module, for example, the longitude and latitude coordinates of the internet surfing module are acquired, the use place of the network traffic can be displayed in a friendly way, and the statistical use situation of the network traffic is more detailed.
In a possible implementation manner of the first aspect, the recording, by the internet surfing module, the first time, the second time, the traffic cumulative value, and the target base station information includes:
the internet surfing module determines the flow accumulated value according to the difference value of the network flow generated by the internet surfing module between the first moment and the second moment.
It should be understood that in the process of counting the network traffic, the network traffic accumulated by the internet surfing module is different up to different moments. In the embodiment of the present application, the manner of determining the traffic cumulative value may be to obtain the traffic cumulative value by respectively obtaining the network traffic value generated by the accumulation of the internet surfing module up to the first time and up to the second time, and obtaining the difference between the two values; the network traffic generated by the network access module from the first time to the second time may be accumulated by initializing the network traffic generated by the network access module from the first time to zero, and the traffic accumulation value may be determined according to the result of the accumulation. The network traffic obtained by statistics can be more visual by using a specific numerical value to explicitly represent the network traffic.
In a possible implementation manner of the first aspect, after the internet surfing module records internet surfing information, the method further includes:
and sending the internet surfing information to a server.
It can be appreciated that in the process of counting network traffic, the recorded internet surfing information generally needs to be dumped into other storage spaces, so as to reduce the burden of the internet surfing module. In the embodiment of the application, the internet surfing module dumps the internet surfing information to the server in a mode of sending the internet surfing information to the server, and the terminal equipment can access the internet surfing information through the server. The server has stronger data processing capability, and the internet surfing information is sent to the server, so that the network traffic speed obtained by statistics is improved while the burden of the internet surfing module is reduced.
In a second aspect, an embodiment of the present application provides a device for counting network traffic, which is applied to a network access module for providing a network access service, where the device includes:
the starting unit is used for starting the network access service;
the system comprises a recording unit, a network access module and a target base station, wherein the recording unit is used for recording network access information, the network access information comprises information for counting network flow between the network access module and the target base station, the network access module is a module for providing network access service, and the target base station is any base station connected with the network access module.
In a possible implementation manner of the second aspect, the recording unit is further configured to record the first time, the second time, the traffic cumulative value, and the target base station information; the first time is used for indicating the time when the internet surfing module is connected with the target base station, the second time is used for indicating the time when the internet surfing module is disconnected with the target base station, the flow accumulated value is used for indicating the magnitude of flow accumulated by the internet surfing module connected with the target base station, and the target base station information comprises the geographic position information of the target base station;
the information for counting the network traffic between the internet surfing module and the target base station includes: the first time, the second time, the traffic integrated value, and the target base station information.
In a possible implementation manner of the second aspect, the recording unit is further configured to determine the traffic cumulative value according to a difference between network traffic generated by the internet surfing module between the first time and the second time.
In a possible implementation manner of the second aspect, the recording unit is further configured to send the internet surfing information to a server.
In a third aspect, an embodiment of the present application provides an electronic device, including:
a memory for storing a program;
a processor for executing the program stored in the memory, wherein the processor performs the method according to the first aspect or any one of the possible implementation manners of the first aspect when the program is executed.
In a fourth aspect, an embodiment of the present application provides a computer readable storage medium having stored therein a computer program comprising program instructions which, when executed by a processor, perform a method as in any one of the possible implementations of the first aspect.
In a fifth aspect, embodiments of the present application provide a computer program product comprising: instructions or computer programs; the above instructions, or the above computer program, when executed, cause the method as in any one of the possible implementations of the first aspect to be implemented.
Drawings
In order to more clearly describe the technical solutions in the embodiments of the present application, the following will briefly describe the drawings that are required to be used in the embodiments of the present application.
Fig. 1 is a schematic diagram of an application scenario for counting network traffic according to an embodiment of the present application;
FIG. 2 is a flowchart of a method for counting network traffic according to an embodiment of the present application;
FIG. 3 is a flowchart of another method for counting network traffic according to an embodiment of the present application;
FIG. 4 is a flowchart of another method for counting network traffic according to an embodiment of the present application;
fig. 5 is a schematic diagram of another application scenario for counting network traffic according to an embodiment of the present application;
fig. 6 is a schematic structural diagram of a device for counting network traffic according to an embodiment of the present application;
fig. 7 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application.
The terms first and second and the like in the description, the claims and the drawings of the present application are used for distinguishing between different objects and not for describing a particular sequential order. Furthermore, the terms "comprising," "including," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion. Such as a process, method, system, article, or apparatus that comprises a list of steps or elements is not limited to the list of steps or elements but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
Reference herein to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment may be included in at least one embodiment of the application. The appearances of such phrases in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. Those of skill in the art will explicitly and implicitly understand that the embodiments described herein may be combined with other embodiments.
In the present application, "at least one (item)" means one or more, "a plurality" means two or more, "at least two (items)" means two or three and more, "and/or" for describing an association relationship of an association object, and three kinds of relationships may exist, for example, "a and/or B" may represent: only a, only B and both a and B are present, wherein a, B may be singular or plural. The character "/" generally indicates that the context-dependent object is an "or" relationship. "at least one of (a) or a similar expression thereof means any combination of these items. For example, at least one (one) of a, b or c may represent: a, b, c, "a and b", "a and c", "b and c", or "a and b and c".
In a specific implementation, in order to more clearly describe the scheme of the present application, the embodiments of the present application provide a method and a related device for counting network traffic, and the following description first describes some content related to the method for counting network traffic provided by the embodiments of the present application.
And (5) surfing the internet module: the internet access module is one or more modules for providing network access service, and can have various existing forms, and the internet access module can be an independent and removable physical entity component installed in or externally connected to the terminal equipment, such as a card type subscriber identity module (subscriber identity module, SIM) card, an irremovable physical entity component embedded in the terminal equipment, such as an embedded SIM card, a program code downloaded to the terminal equipment through a network, and the like.
At present, in many living scenes such as study or work of people, computers or mobile phones are usually used for surfing the internet, and real-time and accurate statistics of network traffic is an effective means for meeting the demands of people for checking the use condition of the network traffic at any time and any place. The current way to count network traffic is generally to count network traffic by using a background application program residing in a terminal device, and in particular, refer to fig. 1.
Fig. 1 is a schematic diagram of an application scenario for counting network traffic, as shown in fig. 1, when an application 101 in a terminal device sends a network request to a physical network card 102, the physical network card will forward the network request to a virtual network card 103, then the virtual network card forwards the network request to a background application 104, and the background application obtains usage information of the network traffic from the network request and counts the usage information, and then sends the network request to the physical network card 102, so that the physical network card sends the network request to a transmission medium outside the terminal device. However, in the actual use process, under the condition that the burden of the terminal device is large, the background application program may be closed, which results in lower accuracy of counting the network traffic.
In view of the problems in the foregoing method, an embodiment of the present application provides a method for counting network traffic, where the method may be applied to a network access module that provides network access services, as shown in fig. 2, and the method includes the following steps:
201. the internet surfing module starts a network access service.
The internet surfing module is directly or indirectly arranged in terminal equipment, and the terminal equipment can be a smart phone, a tablet computer, a notebook computer, a personal digital assistant, other wearable intelligent equipment and the like; the internet surfing module is controlled by the instruction of the terminal equipment operating system, receives the instruction of the terminal equipment operating system, then starts network access service, initializes and registers connection to the network, and provides internet surfing service for the terminal equipment.
202. The internet surfing module records internet surfing information.
The internet surfing information includes, but is not limited to, information for counting network traffic between the internet surfing module and a target base station, where the target base station is any base station connected with the internet surfing module, and the internet surfing information may also include information of a terminal device where the internet surfing module is located, for example, the internet surfing information may include a product identifier of the terminal device, information of an application program installed by the terminal device, and other information related to access of the terminal device to a network; after the network access service is started by the network access module, connection is established between the terminal equipment and the network, and the network access module starts recording network access information at the moment.
In some alternative embodiments, the step 202 of executing the internet surfing module may include recording the first time, the second time, the traffic accumulation value, and the target base station information.
The first time is used for indicating the time when the internet surfing module is connected with the target base station, namely, the time point when the network traffic starts to be generated in the counting process, the second time is used for indicating the time when the internet surfing module is disconnected with the target base station, the traffic accumulation value is used for indicating the magnitude of the traffic accumulated by the internet surfing module connected with the target base station, and the target base station information comprises the geographic position information of the target base station; it is understood that the internet surfing information includes, but is not limited to, the first time, the second time, the traffic integrated value, and the target base station information.
In some alternative embodiments, the step 202 performed by the internet surfing module may include determining the traffic cumulative value according to a difference between the network traffic generated by the internet surfing module between the first time and the second time. Specifically, there are various ways of determining the traffic cumulative value, for example, the traffic cumulative value may be obtained by respectively obtaining the network traffic value accumulated by the internet surfing module up to the first time and up to the second time, and taking the difference between the two values; the network traffic generated by the network access module from the first time to the second time may be accumulated by initializing the network traffic generated by the network access module from the first time to zero, and the traffic accumulation value may be determined according to the result of the accumulation.
In some optional embodiments, after executing step 202, the internet module may further send the internet information to a server, where it is understood that there may be various trigger conditions for sending the internet information to the server, for example, after the internet module is disconnected from the target base station, the internet module may send the internet information to the server when the network to which the terminal device where the internet module is located is connected is idle; the transmission frequency may be preset, and the internet surfing information may be transmitted in a fixed time in an exemplary manner; the internet information may be transmitted when the storage space occupied by the internet information stored in the internet module reaches the maximum storage space capacity of the internet module.
In order to more clearly describe the method for counting network traffic in the embodiment of the present application, another flowchart of the method for counting network traffic is provided in the embodiment of the present application, and refer to fig. 3.
As shown in fig. 3, the event listener 301 may be a function executor in the terminal device that listens to an instruction of the terminal device operating system and performs an action corresponding to the instruction.
302. And judging whether the terminal equipment starts the network or not.
Before executing step 201 in fig. 2, the event listener 301 executes step 302, and in the case that the terminal device enables the network, sends an instruction to open the network access service to the internet module; the terminal device may be a smart phone, a tablet computer, a notebook computer, a personal digital assistant, other wearable smart devices, etc.
303. And opening the network access service.
After the internet surfing module receives the instruction of opening the network access service, step 303 is executed, and the internet surfing module initializes and registers to connect to the network by establishing connection with the target base station, so as to provide the internet surfing service for the terminal equipment; the internet surfing module is controlled by an instruction of the terminal equipment operating system, and the target base station can be any base station connected with the internet surfing module.
304. And starting to record the internet surfing information.
After the internet surfing module executes step 303, the internet surfing module starts recording internet surfing information. Specifically, the internet surfing module may record a time point, i.e. a first moment, when the internet surfing module establishes connection with the target base station; the internet surfing module can record the flow quantity which is accumulated and generated by the internet surfing module and the target base station, namely a flow quantity accumulated value; the internet surfing module can record information of any base station connected with the internet surfing module, namely target base station information. The specific process of recording the internet information may refer to the corresponding process in step 202 in the foregoing method embodiment, which is not described herein.
305. And judging whether the terminal equipment is deactivated.
In the process of recording the internet information by the internet surfing module, the event monitor 301 executes step 305, and the disabling network may be that the terminal device is switched to another network, or that the terminal device is disconnected from the target base station due to a plurality of situations such as network connection interruption caused by a network signal difference, and in the case that the terminal device is disabled, an instruction for closing the network access service is sent to the internet surfing module.
306. Closing the network access service.
After receiving the instruction for closing the network access service, the internet surfing module executes step 306 to disconnect from the target base station and stop the internet surfing service.
307. And stopping recording the internet surfing information.
After the internet surfing module executes step 306, the internet surfing module may record a time point when the internet surfing module is disconnected from the target base station, that is, a second time, and then stop recording internet surfing information.
308. And judging whether the currently connected network is idle or not.
After the internet surfing module stops recording the internet surfing information, the internet surfing information is temporarily stored in a storage space of the internet surfing module, and the event monitoring program 301 judges whether a network currently connected with the terminal equipment is idle, and it should be understood that the network currently connected with the terminal equipment may be the same network as the deactivated network or another network connected with the terminal equipment, and thus the network currently connected with the terminal equipment is not excessively limited.
309. Uploading the internet information to the server.
And under the condition that the network to which the terminal equipment is currently connected is idle, the internet surfing module uploads the internet surfing information stored in the storage space to a server, wherein the server can be a website server, an application server or other types of servers capable of performing operations such as data storage, analysis or conversion. In order to describe the server analyzing and processing the internet surfing information in more detail, another method for counting network traffic is provided in the embodiment of the present application, and refer to fig. 4.
As shown in fig. 4, the process of the server parsing and processing the internet information may include: 401. analyzing the internet surfing information; 402. acquiring a first moment, a second moment, a flow accumulated value and target base station information; 403. determining the using time according to the first time and the second time; 404. determining the network flow according to the flow accumulation value; 405. determining longitude and latitude coordinates of the terminal equipment according to the target base station information; 406. and combining the first time, the second time, the using time, the network traffic size and longitude and latitude coordinates to form traffic using data points.
For the step 405, the target base station information may include geographic location information of the target base station, and may also include a base station identification number (identity document, ID), an angle of arrival (AOA) of the base station, and a time of arrival (TOA) of the base station; and determining the geographic position information, such as longitude and latitude coordinates, of the target base station according to the target base station information, and obtaining the geographic position information, such as longitude and latitude coordinates, of the terminal equipment according to the geographic position information of the target base station.
For the step 406, the server may integrate the data of the first time, the second time, the usage duration, the network traffic size, and the longitude and latitude coordinates to form traffic usage data points, so as to provide a unified data view, so that the server may open unified data interfaces for other terminal devices.
310. And deleting the uploaded internet information.
It will be appreciated that, during the process of waiting for uploading, multiple sets of internet information may be stored in the internet module, and after the internet module executes step 309, the internet module will delete the uploaded internet information in the storage space and retain the non-uploaded internet information.
311. And judging whether the terminal equipment is powered off or not.
The event monitor 301 determines whether the terminal device is powered off, and it is understood that the internet surfing module will stop working when the terminal device is powered off, which will not be described in detail.
Fig. 5 is another application scenario diagram of network traffic statistics provided by the embodiment of the present application, and as shown in fig. 5, the application scenario diagram may include a network surfing module 501, a terminal device 502, a network 503, a server 504, a network 505, a terminal device 506, and a terminal device 507.
The internet module 501 is included in the terminal device 502, and the internet module 501 may be an independent and removable physical component installed in the terminal device 502 or externally connected to the terminal device 502, or an irremovable physical component embedded in the terminal device 502, or a program code downloaded to the terminal device 502 through a network, or the like.
The networks 503 and 505 are transmission media providing communication links between terminal devices, between terminal devices and servers, and between servers, and may be wired networks using coaxial cables and twisted pair connections, optical fiber networks using optical fibers as transmission media, or wireless networks using electromagnetic waves as carriers.
The operating system of the terminal device 502 controls the internet surfing module 501 to start an internet surfing service and record internet surfing information, wherein the internet surfing information comprises information related to network traffic generated by the internet surfing of the terminal device 502. The data transmission is performed between the terminal device 502 and the server 504 through the network 503, and the server 504 may be a website server, an application server, or the like; the server 504 may perform operations such as analysis and conversion on the received data, and may also send data, commands, requests, etc. to other servers or terminal devices; the terminal device 502 sends the internet information to the server 504 via the network 503, and the internet module 501 deletes the transmitted internet information.
After receiving the internet surfing information sent by the terminal device 502, the server 504 may perform operations such as analysis or conversion on the internet surfing information to obtain information of each dimension of the network traffic, for example, generation time of the network traffic, size of the network traffic, and geographic location information of the internet surfing module 501 (or the terminal device 502) when the network traffic is generated.
In addition, server 504 may provide a data access interface, such as a hypertext transfer protocol (hyper text transfer protocol, HTTP) interface, and terminal device 506 and terminal device 507 may access data in server 504 via network 505 (or HTTP interface). Specifically, for example, an application running on the terminal device 506 or an application running on the terminal device 507 may access the server 504 by acquiring the identification number of the internet surfing module 501 and using the identification number as an identification code, so as to query or analyze the internet surfing information stored in the server 504; in particular, the terminal device 506 or the terminal device 507 may be further configured to receive a traffic alert message when the network traffic is excessive.
The process of counting network traffic will be described below in connection with the structure of the apparatus provided in the embodiments of the present application. Fig. 6 is a schematic diagram of an apparatus for counting network traffic, which is applied to a network access module for providing network access service according to an embodiment of the present application, and it can be understood that the apparatus may be the network access module in the foregoing description.
Specifically, as shown in fig. 6, the apparatus includes:
a starting unit 601, configured to start a network access service;
the recording unit 602 is configured to record internet information, where the internet information includes information for counting network traffic between an internet module and a target base station, the internet module is a module for providing a network access service, and the target base station is any base station connected to the internet module.
In some optional embodiments, the recording unit 602 may be further configured to record the first time, the second time, the traffic cumulative value, and the target base station information; the first time is used for indicating the time when the internet surfing module is connected with the target base station, the second time is used for indicating the time when the internet surfing module is disconnected with the target base station, the flow accumulated value is used for indicating the magnitude of flow accumulated by the internet surfing module connected with the target base station, and the target base station information comprises the geographic position information of the target base station; the internet information includes information for counting network traffic between the internet module and a target base station, including: the first time, the second time, the traffic integrated value, and the target base station information.
In some alternative embodiments, the recording unit 602 may be further configured to determine the flow cumulative value according to a difference between the flows generated by the internet surfing module between the first time and the second time.
In some alternative embodiments, the recording unit 602 is further configured to send the internet surfing information to a server.
It should be understood that the division of the units in the above apparatus is merely a division of a logic function, and may be fully or partially integrated into a physical entity or may be physically separated when actually implemented. For example, the above units may be processing elements set up separately, may be integrated in a certain chip of the terminal, may also be stored in a memory element of the controller in the form of program codes, and may be called by a certain processing element of the processor and perform the functions of the above units, where the processing element may be an integrated circuit chip with signal processing capability. Furthermore, the various units may be integrated together or may be implemented separately, in which case the steps of the method described above or the units of the apparatus described above may be implemented by means of integrated logic circuits in hardware or instructions in software form in a processor element, which may be a general-purpose processor or one or more integrated circuits configured to implement the method described above.
Fig. 7 is a schematic structural diagram of an electronic device according to an embodiment of the present application. As shown in fig. 7, the electronic device 700 may include: one or more processors 701, one or more memories 702, one or more communication interfaces 703, and a bus 704, the processors 701, memories 702, and communication interfaces 703 being connected by the bus 704. The electronic device may be the apparatus of the preceding description.
Wherein, the memory 702 is used for storing programs; the processor 701 is configured to execute the program stored in the memory, and when the program is executed, the processor 701 performs a method according to any one of possible embodiments of the method for counting network traffic.
It should be appreciated that in embodiments of the present application, the memory 702 includes, but is not limited to, random access memory (random access memory, RAM), read-only memory (ROM), erasable programmable read-only memory (erasable programmableread only memory, EPROM), or portable read-only memory (CDROM), and memory other than computer memory and processor cache, and that a portion of the memory 702 may include non-volatile random access memory, such as the memory 702 may also store device type information.
The processor 701 may be one or more central processing units (central processing unit, CPU), and in the case where the processor 701 is a CPU, the CPU may be a single-core CPU or a multi-core CPU; the processor 701 may also be other general purpose processors, digital signal processors (digital signal processor, DSP), application specific integrated circuits (application specific integrated circuit, ASIC), off-the-shelf programmable gate arrays (field-programmable gate array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, or the like. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The steps performed by the internet surfing module in the foregoing embodiment may be implemented based on the structure of the electronic device shown in fig. 7, and the processor 701 may perform the implementation described in any one of the optional embodiments of the method for counting network traffic provided in the embodiment of the present application; the implementation manner of the apparatus described in the embodiments of the present application may also be implemented, and in particular, the processor 701 may implement the functions of the starting unit 601 and the recording unit 602 in fig. 6.
In an embodiment of the present application, there is provided a computer-readable storage medium storing a computer program which, when executed by a processor, implements: starting the network access service; and recording internet surfing information, wherein the internet surfing information comprises information for counting network flow between the internet surfing module and a target base station, and the target base station is any base station connected with the internet surfing module.
It will be appreciated by those skilled in the art that embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, magnetic disk storage, optical disk read-only, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described in terms of flowchart illustrations and/or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While the application has been described with reference to certain preferred embodiments, it will be understood by those skilled in the art that various changes and substitutions of equivalents may be made and equivalents will be apparent to those skilled in the art without departing from the scope of the application. Therefore, the protection scope of the application is subject to the protection scope of the claims.

Claims (8)

1. The method for counting the network traffic is characterized by being applied to a network access module for providing network access service and comprising the following steps:
the internet surfing module starts the network access service;
the internet surfing module records the first moment, the second moment, the flow accumulated value and the target base station information; the first moment is used for indicating the moment when the internet surfing module is connected with a target base station, the target base station is any base station connected with the internet surfing module, the second moment is used for indicating the moment when the internet surfing module is disconnected with the target base station, the flow accumulation value is used for indicating the flow accumulated by the internet surfing module connected with the target base station, and the target base station information comprises geographic position information of the target base station.
2. The method of claim 1, wherein the logging module recording the first time, the second time, the traffic cumulative value, and the target base station information comprises:
and the internet surfing module determines the flow accumulated value according to the difference value of the network flow generated by the internet surfing module between the first moment and the second moment.
3. The method according to claim 1 or 2, wherein after the internet surfing module records internet surfing information, the method further comprises:
and sending the first moment, the second moment, the flow accumulated value and the target base station information to a server.
4. The utility model provides a device of statistics network flow which characterized in that is applied to the network module that provides network access service, includes:
the starting unit is used for starting the network access service;
the recording unit is used for recording the first moment, the second moment, the flow accumulated value and the target base station information; the first moment is used for representing the moment when the internet surfing module is connected with a target base station, the internet surfing module is a module for providing network access service, the target base station is any one base station connected with the internet surfing module, the second moment is used for representing the moment when the internet surfing module is disconnected with the target base station, the flow accumulation value is used for representing the flow accumulated by the internet surfing module connected with the target base station, and the target base station information comprises geographic position information of the target base station.
5. The apparatus of claim 4, wherein the device comprises a plurality of sensors,
the recording unit is further configured to determine the flow accumulation value according to a difference value of network flows generated by the internet surfing module between the first time and the second time.
6. The apparatus of claim 4 or 5, wherein the device comprises a plurality of sensors,
the recording unit is further configured to send the first time, the second time, the traffic cumulative value, and the target base station information to a server.
7. An electronic device, comprising:
a memory for storing a program;
a processor for executing the program stored in the memory, the processor performing the method of any one of claims 1 to 3 in the case where the program is executed.
8. A computer readable storage medium, characterized in that the computer readable storage medium has stored therein a computer program comprising program instructions which, when executed by a processor, perform the method of any of claims 1 to 3.
CN202111118140.5A 2021-09-23 2021-09-23 Method for counting network traffic and related device Active CN114070756B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111118140.5A CN114070756B (en) 2021-09-23 2021-09-23 Method for counting network traffic and related device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111118140.5A CN114070756B (en) 2021-09-23 2021-09-23 Method for counting network traffic and related device

Publications (2)

Publication Number Publication Date
CN114070756A CN114070756A (en) 2022-02-18
CN114070756B true CN114070756B (en) 2023-09-05

Family

ID=80233871

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111118140.5A Active CN114070756B (en) 2021-09-23 2021-09-23 Method for counting network traffic and related device

Country Status (1)

Country Link
CN (1) CN114070756B (en)

Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20110070389A (en) * 2009-12-18 2011-06-24 주식회사 케이티 Method and apparatus for providing vcc services between heterogeneity communication network based on ims
CN103905260A (en) * 2012-12-25 2014-07-02 北京新媒传信科技有限公司 Terminal device network traffic monitoring method and device
AU2014250620A1 (en) * 2009-08-25 2014-11-06 Interdigital Patent Holdings, Inc. Method and apparatus for managing group communications
CN104244203A (en) * 2014-09-25 2014-12-24 小米科技有限责任公司 Message pushing method and device
AU2015203574A1 (en) * 2009-08-12 2015-07-23 Interdigital Patent Holdings, Inc. Method and apparatus for contention-based uplink data transmission
US9247416B1 (en) * 2012-02-21 2016-01-26 Isaac S. Daniel Smart subscriber identification module system and method
CN106303953A (en) * 2016-07-29 2017-01-04 上海斐讯数据通信技术有限公司 A kind of people flow rate statistical system and method
CN107147584A (en) * 2017-05-12 2017-09-08 郑州云海信息技术有限公司 Method for controlling network flow, storage device and storage control
CN108012258A (en) * 2017-11-29 2018-05-08 北京小米移动软件有限公司 Data flux management method, device, terminal and the server of virtual SIM card
CN110087226A (en) * 2018-01-25 2019-08-02 中兴通讯股份有限公司 Flow statistical method, device, storage medium and electronic device
CN110446171A (en) * 2019-07-16 2019-11-12 深圳市奥克多普科技有限公司 A kind of flow managing method and system
CN110995764A (en) * 2019-12-27 2020-04-10 北京清华亚迅电子信息研究所 Fuzzy test system and method for data flow of application layer of mobile cellular network

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080080371A1 (en) * 2006-09-28 2008-04-03 Chunmei Liu Macro-spatial network multiplexing
WO2009111522A1 (en) * 2008-03-04 2009-09-11 Alcatel-Lucent Usa Inc. System and method for securing a base station using sim cards

Patent Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
AU2015203574A1 (en) * 2009-08-12 2015-07-23 Interdigital Patent Holdings, Inc. Method and apparatus for contention-based uplink data transmission
AU2014250620A1 (en) * 2009-08-25 2014-11-06 Interdigital Patent Holdings, Inc. Method and apparatus for managing group communications
KR20110070389A (en) * 2009-12-18 2011-06-24 주식회사 케이티 Method and apparatus for providing vcc services between heterogeneity communication network based on ims
US9247416B1 (en) * 2012-02-21 2016-01-26 Isaac S. Daniel Smart subscriber identification module system and method
CN103905260A (en) * 2012-12-25 2014-07-02 北京新媒传信科技有限公司 Terminal device network traffic monitoring method and device
CN104244203A (en) * 2014-09-25 2014-12-24 小米科技有限责任公司 Message pushing method and device
CN106303953A (en) * 2016-07-29 2017-01-04 上海斐讯数据通信技术有限公司 A kind of people flow rate statistical system and method
CN107147584A (en) * 2017-05-12 2017-09-08 郑州云海信息技术有限公司 Method for controlling network flow, storage device and storage control
CN108012258A (en) * 2017-11-29 2018-05-08 北京小米移动软件有限公司 Data flux management method, device, terminal and the server of virtual SIM card
CN110087226A (en) * 2018-01-25 2019-08-02 中兴通讯股份有限公司 Flow statistical method, device, storage medium and electronic device
CN110446171A (en) * 2019-07-16 2019-11-12 深圳市奥克多普科技有限公司 A kind of flow managing method and system
CN110995764A (en) * 2019-12-27 2020-04-10 北京清华亚迅电子信息研究所 Fuzzy test system and method for data flow of application layer of mobile cellular network

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
Construction of Forest and Grass Industry Economic Belt Using Land Resources in Road Side Slope;Zhaohua ZHU;Qingwang LAI;Guogang XU;Guoliang CHI;Xiaorong CHEN;;Asian Agricultural Research(第07期);全文 *

Also Published As

Publication number Publication date
CN114070756A (en) 2022-02-18

Similar Documents

Publication Publication Date Title
US11700540B2 (en) Method and device for monitoring network data
US10917315B2 (en) Network service quality evaluation method and system, and network device
CN109152095B (en) Wireless network connection method for terminal
CN109698934B (en) Region monitoring method and device
JP4395515B2 (en) Method and apparatus for determining gaps in a local service coverage of a mobile phone
CN108235308B (en) Data reporting method and device, mobile terminal and computer readable medium
CN106454968B (en) A kind of caller method and device based on CSFB
WO2020094035A1 (en) Wireless network connection method for terminal
JP2002271833A (en) Communication quality maintenance method for service area in mobile communication system, and its mobile communication terminal and management server system
CN108901035B (en) Identification method and device for terminal of Internet of things
WO2014194704A1 (en) A grouping processing method and system
CN104301161A (en) Computing method, computing device and communication system for business quality index
CN112566078A (en) Device connection method and apparatus, storage medium, and electronic apparatus
CN114175748B (en) Communication frequency adjusting method, device, electronic equipment and storage medium
CN114675983A (en) Business data processing method and device, storage medium and electronic equipment
CN104883705A (en) Problem positioning method for data service complaints and device thereof
CN114070756B (en) Method for counting network traffic and related device
CN111464984B (en) Communication method and device
CN114745275A (en) Node updating method and device in cloud service environment and computer equipment
CN108647139B (en) System test method, device, storage medium and electronic device
CN113300910B (en) Method and system for acquiring use rate, terminal, access point and MEC server
US9479579B2 (en) Grouping processing method and system
CN112653717B (en) Multi-cloud cooperation distributed system and application distribution method
CN108901034B (en) Data service evaluation method and device
CN110781878B (en) Target area determination method and device, storage medium and electronic device

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
GR01 Patent grant
GR01 Patent grant