CN107277104A - The processing method and wireless router of a kind of web page access data - Google Patents
The processing method and wireless router of a kind of web page access data Download PDFInfo
- Publication number
- CN107277104A CN107277104A CN201710306572.6A CN201710306572A CN107277104A CN 107277104 A CN107277104 A CN 107277104A CN 201710306572 A CN201710306572 A CN 201710306572A CN 107277104 A CN107277104 A CN 107277104A
- Authority
- CN
- China
- Prior art keywords
- module
- memory space
- access data
- file
- transfer memory
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/50—Network services
- H04L67/56—Provisioning of proxy services
- H04L67/568—Storing data temporarily at an intermediate stage, e.g. caching
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/90—Details of database functions independent of the retrieved data types
- G06F16/95—Retrieval from the web
- G06F16/958—Organisation or management of web site content, e.g. publishing, maintaining pages or automatic linking
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L45/00—Routing or path finding of packets in data switching networks
- H04L45/60—Router architectures
Landscapes
- Engineering & Computer Science (AREA)
- Databases & Information Systems (AREA)
- Theoretical Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Data Mining & Analysis (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Mobile Radio Communication Systems (AREA)
Abstract
The invention discloses a kind of processing method of web page access data and wireless router, including:Step S100 obtains the corresponding access data of the web access requests information when wireless terminal sends web access requests information by wireless router, and by the access data storage in temporary memory space;The access data stored in the temporary memory space are sent to transfer memory space and stored, and empty the temporary memory space when reaching default transmission condition by step S200;Step S300 when reach called time on default when, the corresponding current compression file of the access data in the transfer memory space is reported into server, and empty the transfer memory space.The problem of cpu resource being consumed excessively present invention effectively prevents the frequent reporting message of kernel, and improve the stability of wireless router.
Description
Technical field
The present invention relates to the processing method and wireless routing of wireless communication field, more particularly to a kind of web page access data
Device.
Background technology
With the fast development of internet and wireless network, panoramic wireless terminal is flooded with the life of people,
Under such environment, the internet behavior for understanding user is aobvious to the analysis of business big data and police's supervisory user Lawful access internet
Obtain particularly important.
The existing mode for obtaining user's internet behavior, is the Internet data that user is collected by wireless router mostly,
And first store it in the kernel state of wireless router, upload onto the server again afterwards.This mode occupies wireless routing
The precious kernel state of device, greatly increases the risk that wireless router system collapses.
Also the meeting having often obtains an Internet data, and this Internet data of acquisition just is passed through into Netlink communication interfaces
The User space of wireless router is reported to, is uploaded onto the server again afterwards.It is this frequently to report the mode of Internet data to cause nothing
The cpu resource of line router is seriously consumed, and 32 that Netlink communication interfaces are only fixed in wireless router, is taken
One Netlink communication interface, can produce certain influence to the handling capacity of wireless router, so that Consumer's Experience is influenceed,
The content of the invention
It is an object of the invention to provide a kind of processing method of web page access data and wireless router, can effectively it receive
Collect the access data of user's online, the resource consumption to wireless router can be reduced again.
The technical scheme that the present invention is provided is as follows:
A kind of processing method of web page access data, including:Step S100 is sent when wireless terminal by wireless router
During web access requests information, the corresponding access data of the web access requests information are obtained, and the access data are deposited
It is stored in temporary memory space;Step S200 is when reaching default transmission condition, described in being stored in the temporary memory space
Access data to send to the storage of transfer memory space, and empty the temporary memory space;Step S300, which works as, reaches default report
During the time, the corresponding current compression file of the access data in the transfer memory space is reported into server, and clearly
The empty transfer memory space.
In the above-mentioned technical solutions, the problem of effectively prevent the frequent reporting message of kernel and consume cpu resource excessively.And
Data storage will be accessed in transfer memory space (i.e. User space), the stability of wireless router is effectively improved.Timing will
The corresponding current compression file of access data in transfer memory space reports to server, and empties transfer memory space, both
The function of data acquisition feedback is realized, prevents that wireless router memory consumption is excessive again, improves the stabilization of wireless router
Property.
Further, the step S200 includes:Step S210 judges whether also there is residue in the temporary memory space
Memory space;Step S220 then performs step S250 when the residual memory space is not present in the temporary memory space;Step
Rapid S250, which sends the access data stored in the temporary memory space to transfer memory space, to be stored, and is emptied described
Temporary memory space.
In the above-mentioned technical solutions, temporary memory space is opened up, and the access data is reported in a plurality of form
Transfer memory space, reduces the occupancy of cpu resource.
Further, the step S200 also includes:Step S230 is deposited when the temporary memory space also has the residue
When storing up space, then judge whether to reach the default transmission time;Step S240 then performs step when reaching the default transmission time
Rapid S250.
In the above-mentioned technical solutions, the setting of transmission time is preset primarily to preventing from accessing data retention in internal memory state
In.
Further, the step S300 includes:Step S320 is according to the access stored in the transfer memory space
Data, generate the corresponding access file of the access data;The access file of step S321 compression generations, forms described work as
Preceding compressed file;The current compression file is reported to server by step S322, and empties the transfer memory space.
In the above-mentioned technical solutions, can be by the access number stored in transfer memory space after the formation of current compression file
According to emptying, the convenient follow-up access data storage sended over from temporary memory space is in transfer memory space.
Further, also include after the step S322:Step S323 reports to the clothes when the current compression file
It is engaged in after device, the current compression file is converted into history compressed file;The step S300 further comprises:Step S310 will
The history compressed file is deleted.
In the above-mentioned technical solutions, the compressed file after reporting is left to give the correct time on next time and deleted again, it is to avoid in appearance
Report lost property to the authorities situation about losing.
The present invention also provides a kind of wireless router, including:Acquisition module, for passing through wireless router when wireless terminal
When sending web access requests information, the corresponding access data of the web access requests information are obtained;Temporary storage module, with
The acquisition module electrical connection, the temporary storage module is used to store the access data that the acquisition module is obtained;With
And, after the access data are sent to transfer memory module, the temporary storage module is further used for described in storage
Data are accessed to empty;Sending module, is electrically connected with the temporary storage module, when reaching default transmission condition, the transmission
Module sends the access data stored in the temporary storage module to transfer memory module;And, it is default when reaching
On when calling time, the sending module is further used for the access data in the transfer memory module are corresponding current
Compressed file reports to server;Transfer memory module, is electrically connected with the sending module, and the transfer memory module is used to deposit
Store up the access data that the sending module is sent;And, after the current compression file reports to server, it is described in
Turn memory module to be further used for emptying the access data of storage.
In the above-mentioned technical solutions, the problem of effectively prevent the frequent reporting message of kernel and consume cpu resource excessively.And
Data storage will be accessed in transfer memory space (i.e. User space), the stability of wireless router is effectively improved.Timing will
The corresponding current compression file of access data in transfer memory space reports to server, and empties transfer memory space, both
The function of data acquisition feedback is realized, prevents that wireless router memory consumption is excessive again, improves the stabilization of wireless router
Property.
Further, in addition to:Judge module, is electrically connected with the temporary storage module and the sending module, described to sentence
Disconnected module is used to judge whether also there is residual memory space in the temporary storage module;The sending module, is further used
In when residual memory space is not present in the temporary storage module, the sending module will be deposited in the temporary storage module
The access data of storage are sent to transfer memory module.
Further, the judge module, is further used for when the temporary storage module also has the remaining storage sky
Between when, the judge module judges whether to reach the default transmission time;The sending module, is further used for that default hair ought be reached
When sending the time, the access data stored in the temporary storage module are sent to transfer and store mould by the sending module
Block.
Further, in addition to:Generation module, is electrically connected with the transfer memory module, when reach called time on default when,
The generation module is used for according to the access data stored in the transfer memory module, generates the access data correspondence
Access file;Compression module, is electrically connected with the generation module and the sending module, and the compression module is used to compress life
Into the access file, form the current compression file;The sending module, is further used for current compression text
Part reports to server.
Further, the compression module, is further used for after the current compression file reports to the server, institute
State compression module and the current compression file is converted into history compressed file;The processing system of the web page access data is also wrapped
Include:Removing module, is electrically connected with the compression module, when reaching that the removing module is used for will be described when being called time on default
History compressed file is deleted.
Compared with prior art, the processing method of web page access data of the invention and wireless router beneficial effect exist
In:
The a plurality of access data that temporary memory space (kernel state) is collected are to report to transfer memory space (user together
State), it is to avoid frequently report to transfer memory space and cause a large amount of resources for taking CPU.And utilize Genelink communication interfaces
Realize that access data sends to transfer memory space from temporary memory space, further effectively prevent Netlink communication interfaces
The problem of resource scarcity.Data storage will be accessed in User space, the memory space of kernel state is saved, add wireless router
The stability of a system.In addition, the access data in transfer memory space are reported to server by timing, and it is empty to empty transfer storage
Between, prevent memory consumption excessive.Deleted in addition, history compressed file can be left to when reaching and being called time on default next time, it is to avoid
Report to the situation that mistake occurs in server.
Brief description of the drawings
Below by clearly understandable mode, preferred embodiment is described with reference to the drawings, to a kind of web page access data
Processing method and above-mentioned characteristic, technical characteristic, advantage and its implementation of wireless router are further described.
Fig. 1 is the flow chart of processing method one embodiment of web page access data of the present invention;
Fig. 2 is the flow chart of another embodiment of the processing method of web page access data of the present invention;
Fig. 3 is the structural representation of wireless router one embodiment of the present invention;
Fig. 4 is the structural representation of another embodiment of wireless router of the present invention.
Drawing reference numeral explanation:
10. acquisition module, 20. temporary storage modules, 30. sending modules, 40. transfer memory modules, 50. judge modules,
60. generation module, 70. compression modules, 80. removing modules.
Embodiment
In order to illustrate more clearly about the embodiment of the present invention or technical scheme of the prior art, control is illustrated below
The embodiment of the present invention.It should be evident that drawings in the following description are only some embodiments of the present invention, for
For those of ordinary skill in the art, on the premise of not paying creative work, other can also be obtained according to these accompanying drawings
Accompanying drawing, and obtain other embodiments.
To make only to schematically show part related to the present invention in simplified form, each figure, they are not represented
Its as product practical structures.In addition, so that simplified form is readily appreciated, there is identical structure or function in some figures
Part, only symbolically depicts one of those, or has only marked one of those.Herein, " one " is not only represented
" only this ", can also represent the situation of " more than one ".
In one embodiment of the invention, as shown in figure 1, a kind of processing method of web page access data, including:Step
S100 obtains web access requests information corresponding when wireless terminal sends web access requests information by wireless router
Data are accessed, and data storage will be accessed in temporary memory space;Step S200 will be deposited temporarily when reaching default transmission condition
The access data stored in storage space are sent to the storage of transfer memory space, and empty temporary memory space;Step S300, which works as, to be reached
When being called time on presetting, the corresponding current compression file of access data in transfer memory space is reported into server, and
Empty transfer memory space.
Specifically, this implementation is realized based on wireless router, each nothing being connected with it is collected by wireless router
The access data of line terminal access webpage, and server is reported to, it is that follow-up business big data analysis etc. provides big data sample
This.
Wireless terminal can be the wireless terminals such as mobile phone, tablet personal computer, notebook computer.Wireless terminal is connected by Wi-Fi
It is connected on the wireless network that wireless router is sent, so as to realize network savvy.
Web page access data collecting function is added in wireless router, can be real-time when this function is active
The information that monitoring wireless terminal is sent, when the information of its transmission is web access requests information, just obtains corresponding access number
According to.Web access requests information, it can be understood as user clicks web page interlinkage, will open corresponding webpage.And web page access
The corresponding data that access of solicited message include:The domain name (and/or IP address) of this webpage, the physical address (Media of wireless terminal
Access Control, MAC), the transmission time of this web access requests information, contemporary wireless terminals be connected into the nothing of wireless routing
Line network information (SSID that i.e. wireless terminal is connected into) etc..
A memory space is opened up in kernel state as temporary memory space, the storage size of this temporary memory space can
With little, for example:1K., can be immediately by the visit stored in temporary memory space when it is filled with or reaches the default transmission time
Ask that data are sent to transfer memory space, and empty temporary memory space, be that the access data subsequently obtained are prepared.Access number
According to being to be sent to transfer memory space with many strips, transmission frequency is reduced, so as to reduce wireless router CPU resource
Occupancy.In addition, when the access data in temporary memory space are sent into transfer memory space, being communicated by Genelink
Interface realizes the transmission for accessing data, rather than uses Netlink communication interfaces.Netlink communication interfaces only have 32 (i.e. 0
To 31), limited amount, therefore it is relatively more precious;, can and Genelink communication interfaces are a special Netlink communication interfaces
Unrestrictedly to use, the problem of can thoroughly solving Netlink communication interface resource scarcitys.Therefore, communicated using Genelink
Access data in temporary memory space are sent to transfer memory space by interface, further save the money of wireless router
Source.
A memory space is hewed out as transfer memory space in User space, is sent for storing from temporary memory space
The access data come over.Data storage will be accessed in transfer memory space (that is, User space), wireless router is effectively increased
Stability.Kernel state (i.e. kernel spacing) is the shared space of each process, and the space of kernel state is limited, only opens up a fritter
Memory space is as temporary memory space, when reaching default transmission condition, will access data storage in transfer memory space (i.e.
User space), can be effectively saved in kernel spacing, and kernel spacing can cause whole system to be collapsed if there is mistake, and
It is exactly that a process is exited at most to occur mistake in User space, so, information, which is stored in User space, can effectively increase wirelessly
The stability of router.
It is periodic that wireless router is reported to server, therefore, has and is called time on default.Here default reports
Time can voluntarily be set according to demand by engineer.Here server can be ftp server.In addition, being given the correct time on default
Between setting wherein turn the access data of memory space also for allowing wireless router timing to empty, so as to prevent its internal memory from disappearing
Consumption is excessive.
In the present embodiment, a plurality of access data can be together sent to transfer memory space and stored, effectively prevent kernel
Frequent reporting message and the problem of consume cpu resource excessively.And data storage will be accessed in transfer memory space (i.e. User space),
It is effectively improved the stability of wireless router.Store empty in addition, data will be accessed and sent from temporary memory space to transfer
Between when, Genelink communication interfaces can be used, further save wireless router resource it is nervous the problem of.Regularly by transfer
The corresponding current compression file of access data in memory space reports to server, and empties transfer memory space, both realizes
The function of data acquisition feedback, prevents that wireless router memory consumption is excessive, improves the stability of wireless router again.
Preferably, step S200 includes:Step S210 judges whether also there is residual memory space in temporary memory space;
Step S220 then performs step S250 when residual memory space is not present in temporary memory space;Step S250 is by interim storage
The access data stored in space are sent to the storage of transfer memory space, and empty temporary memory space.
Specifically, the temporary memory space capacity in kernel state is smaller, can when many wireless terminals are connected into wireless network
When not up to can preset the transmission time, temporary memory space is just filled with, in order to smoothly collect follow-up access data, when
When temporary memory space is filled with, the access data in temporary memory space can be sent to transfer memory space immediately.In hair
After the completion of sending, temporary memory space is emptied, storage location is provided for the access data that subsequently obtain.
Opening up for temporary memory space, allows access data to report to transfer memory space in a plurality of form, reduction
The occupancy of cpu resource.
Preferably, step S200 also includes:Step S230 then sentences when temporary memory space also has residual memory space
It is disconnected whether to reach the default transmission time;Step S240 then performs step S250 when reaching the default transmission time;When not up to pre-
If during the time of transmission, then performing step S100.
Specifically, the default transmission time can voluntarily be set according to demand by engineer, such as:500ms.During default transmission
Between setting primarily to prevent access data retention in internal memory state.
Data are accessed on a small quantity when temporary memory space is only stored, be not filled with, but when having reached the default transmission time, still
The access data stored in temporary memory space can be sent to transfer memory space, it is to avoid these access the stagnant of data on a small quantity
Stay, lose.
Preferably, step S300 includes:Step S320 is accessed according to the access data stored in transfer memory space, generation
The corresponding access file of data;The access file of step S321 compression generations, forms current compression file;Step S322 will be current
Compressed file reports to server, and empties transfer memory space.
Specifically, the access data of storage need to report to clothes in the form of a file in transfer memory space (i.e. User space)
Business device.Therefore, when reached called time on default when, text can be accessed by the access data generation in transfer memory space is corresponding
Part., can be again by the access compressing file of generation, as current compression file, then by this compressed file in order to accelerate transmission speed
Report to server.
After the formation of current compression file, the access data stored in transfer memory space can be emptied, it is convenient follow-up from
The access data storage sended in temporary memory space is in transfer memory space.
Preferably, also include after step S322:Step S323, will be current after current compression file reports to server
Compressed file is converted to history compressed file;Step S300 further comprises:History compressed file is deleted (step by step S310
S310 is located at before step S20).
Specifically, when reach called time on default when, first last history compressed file can be deleted.Why will be upper
Compressed file after report is left to give the correct time on next time and deleted again, if being to report current compression file because setting, delete current pressure
Contracting file is carried out simultaneously, it is possible that reporting the situation of failure (for example:May it not report also, current compression file is just
Delete);In order to avoid there is the situation for reporting failure, therefore, it is arranged such.
It should be noted that history compressed file is not stored in temporary memory space, transfer memory space is also not stored in,
When deleting, system can search out it according to the title of history compressed file, then be deleted.Therefore, history is compressed into text
Part is left on next time deletion of giving the correct time, and can't influence the process for accessing data acquisition, storing, reporting.
In addition, the order that history compressed file is deleted is before generation current compression file, it is to find this for convenience to go through
History compressed file.
In another embodiment of the present invention, as shown in Fig. 2 a kind of processing method of web page access data, including:
Step S100 is when wireless terminal sends web access requests information by wireless router, and obtaining web page access please
The corresponding access data of information are sought, and data storage will be accessed in temporary memory space.
Step S200 sends the access data stored in temporary memory space to transfer when reaching default transmission condition
Memory space is stored, and empties temporary memory space;Step S200 includes:
Step S210 judges whether also there is residual memory space in temporary memory space;
Step S220 then performs step S250 when residual memory space is not present in temporary memory space;
Step S230 is when also there is residual memory space in temporary memory space, then when judging whether to reach default send
Between, when the not up to default transmission time, then perform step S100;
Step S240 then performs step S250 when reaching the default transmission time;
The access data stored in temporary memory space are sent to transfer memory space and stored by step S250, and are emptied and faced
When memory space.
Step S300 when reach called time on default when, by the corresponding current compression of access data in transfer memory space
File reports to server, and empties transfer memory space;Step S300 includes:
Step S310 deletes history compressed file;
Step S320 is according to the access data stored in transfer memory space, and generation accesses the corresponding access file of data;
The access file of step S321 compression generations, forms current compression file;
Current compression file is reported to server by step S322, and empties transfer memory space;
Current compression file is converted to history compression text by step S323 after current compression file reports to server
Part.
Specifically, a plurality of access data that temporary memory space (kernel state) is collected in the present embodiment are to report to together
Transfer memory space (User space), it is to avoid frequently report to transfer memory space and cause a large amount of resources for taking CPU.And utilize
Genelink communication interfaces realize that access data sends to transfer memory space from temporary memory space, further effectively prevent
The problem of Netlink communication interface resource scarcitys.Data storage will be accessed in User space, the memory space of kernel state is saved,
Add the stability of a system of wireless router.In addition, the access data in transfer memory space are reported to server by timing,
And transfer memory space is emptied, prevent memory consumption excessive.In addition, history compressed file, which can be left to, reaches default report next time
Deleted during the time, it is to avoid report to the situation that mistake occurs in server.
In another embodiment of the present invention, a kind of processing method of web page access data, its principle is:In netif_
Hook Function is added in receive_skb functions to obtain access data.For example:In/linux/net/core/dev.c plus
Enter function hook
If opening web page access data collecting function, cathpkt_hook=cathpkt_handler;
Each field of void cathpkt_handler (struct sk_buff*skb) function pair skb packets is carried out
Analysis, if http bags and the inside has GET (i.e. web access requests information), then the access number in acquisition skb packets
According to for example:Hosturl (domain name and/or IP address), (wireless terminal) MAC, timestramp and skb->dev->name
(SSID that wireless terminal is connected into).
Then the access data got are stored in inside buf_ring (temporary memory space opened up in internal memory state), such as
Access data storage in fruit buf_ring is full (for example:1K), then call genetlink that access data are sent to use immediately
Family state process (cathpkt), cathpkt processes are sent to if full after postponement 500ms.
Call genetlink built-in functions to receive the message that genetlink is put forward in cathpkt processes, parse and deposit
Store up into an array (transfer memory space), the array can store 1024 records (can also be more, by engineer according to need
It is configured).In another embodiment, if the space of this data is finished, no longer (next temporary memory space is sent out for storage
The access data brought replace the data in last memory space).
The User space process sets timer (preset on call time), first deletes the compressed file that last time reports generation
(i.e. history compressed file), if this, which have collected, generates text under the access data of wireless terminal, write-in/tmp/ catalogues
Part, then ciphered compressed and reports the access data of the wireless terminal being collected into ftpput to ftp server, and by array
Reset (i.e. with space:Make the global variable current_collect_num=0 defined in User space process cathpkt), then
The access data that genetlink is reported up again can just be then stored into the data cover before last ftp is reported in array,
Go round and begin again.
In another embodiment of the present invention, as shown in figure 3, a kind of wireless router, including:Acquisition module 10, is used
In when wireless terminal sends web access requests information by wireless router, obtaining, web access requests information is corresponding to visit
Ask data;Temporary storage module 20, is electrically connected with acquisition module, and temporary storage module is used for the access for storing acquisition module acquisition
Data;And, after access data are sent to transfer memory module, temporary storage module is further used for the access number of storage
According to emptying;Sending module 30, is electrically connected with temporary storage module, when reaching default transmission condition, and sending module will be deposited temporarily
The access data stored in storage module are sent to transfer memory module;And, when reaching that sending module enters when being called time on default
One step is used to the corresponding current compression file of access data in transfer memory module reporting to server;Transfer memory module
40, electrically connected with sending module, transfer memory module is used for the access data for storing sending module transmission;And, when current pressure
Contracting file is reported to after server, and transfer memory module is further used for emptying the access data of storage.
Specifically, this implementation is realized based on wireless router, each nothing being connected with it is collected by wireless router
The access data of line terminal access webpage, and server is reported to, it is that follow-up business big data analysis etc. provides big data sample
This.
Wireless terminal can be the wireless terminals such as mobile phone, tablet personal computer, notebook computer.Wireless terminal is connected by Wi-Fi
It is connected on the wireless network that wireless router is sent, so as to realize network savvy.
Web page access data collecting function is added in wireless router, can be real-time when this function is active
The information that monitoring wireless terminal is sent, when the information of its transmission is web access requests information, just obtains corresponding access number
According to.Web access requests information, it can be understood as user clicks web page interlinkage, will open corresponding webpage.And web page access
The corresponding data that access of solicited message include:The domain name (and/or IP address) of this webpage, the physical address (Media of wireless terminal
Access Control, MAC), the transmission time of this web access requests information, contemporary wireless terminals be connected into the nothing of wireless routing
Line network information (SSID that i.e. wireless terminal is connected into) etc..
A memory space is opened up in kernel state as temporary memory space, the storage size of this temporary memory space can
With little, for example:1K., can be immediately by the visit stored in temporary memory space when it is filled with or reaches the default transmission time
Ask that data are sent to transfer memory space, and empty temporary memory space, be that the access data subsequently obtained are prepared.Access number
According to being to be sent to transfer memory space with many strips, transmission frequency is reduced, so as to reduce wireless router CPU resource
Occupancy.In addition, when the access data in temporary memory space are sent into transfer memory space, being communicated by Genelink
Interface realizes the transmission for accessing data, rather than uses Netlink communication interfaces.Netlink communication interfaces only have 32 (i.e. 0
To 31), limited amount, therefore it is relatively more precious;, can and Genelink communication interfaces are a special Netlink communication interfaces
Unrestrictedly to use, the problem of can thoroughly solving Netlink communication interface resource scarcitys.Therefore, communicated using Genelink
Access data in temporary memory space are sent to transfer memory space by interface, further save the money of wireless router
Source.
A memory space is hewed out as transfer memory space in User space, is sent for storing from temporary memory space
The access data come over.Data storage will be accessed in transfer memory space (that is, User space), wireless router is effectively increased
Stability.Kernel state (i.e. kernel spacing) is the shared space of each process, and the space of kernel state is limited, only opens up a fritter
Memory space is as temporary memory space, when reaching default transmission condition, will access data storage in transfer memory space (i.e.
User space), can be effectively saved in kernel spacing, and kernel spacing can cause whole system to be collapsed if there is mistake, and
It is exactly that a process is exited at most to occur mistake in User space, so, information, which is stored in User space, can effectively increase wirelessly
The stability of router.
It is periodic that wireless router is reported to server, therefore, has and is called time on default.Here default reports
Time can voluntarily be set according to demand by engineer.Here server can be ftp server.In addition, being given the correct time on default
Between setting wherein turn the access data of memory space also for allowing wireless router timing to empty, so as to prevent its internal memory from disappearing
Consumption is excessive.
In the present embodiment, a plurality of access data can be together sent to transfer memory space and stored, effectively prevent kernel
Frequent reporting message and the problem of consume cpu resource excessively.And data storage will be accessed in transfer memory space (i.e. User space),
It is effectively improved the stability of wireless router.Store empty in addition, data will be accessed and sent from temporary memory space to transfer
Between when, Genelink communication interfaces can be used, further save wireless router resource it is nervous the problem of.Regularly by transfer
The corresponding current compression file of access data in memory space reports to server, and empties transfer memory space, both realizes
The function of data acquisition feedback, prevents that wireless router memory consumption is excessive, improves the stability of wireless router again.
Preferably, in addition to:Judge module 50, is electrically connected, judge module is used for temporary storage module and sending module
Judge whether also there is residual memory space in temporary storage module;Sending module 30, is further used for working as temporary storage module
In be not present residual memory space when, sending module by the access data stored in temporary storage module send to transfer store mould
Block.
Specifically, the temporary memory space capacity in kernel state is smaller, can when many wireless terminals are connected into wireless network
When not up to can preset the transmission time, temporary memory space is just filled with, in order to smoothly collect follow-up access data, when
When temporary memory space is filled with, the access data in temporary memory space can be sent to transfer memory space immediately.In hair
After the completion of sending, temporary memory space is emptied, storage location is provided for the access data that subsequently obtain.
Opening up for temporary memory space, allows access data to report to transfer memory space in a plurality of form, reduction
The occupancy of cpu resource.
Preferably, judge module 50, are further used for, when temporary storage module also has residual memory space, judging mould
Block judges whether to reach the default transmission time;Sending module 30, is further used for when reaching the default transmission time, sending module
The access data stored in temporary storage module are sent to transfer memory module.
Specifically, the default transmission time can voluntarily be set according to demand by engineer, such as:500ms.During default transmission
Between setting primarily to prevent access data retention in internal memory state.
Data are accessed on a small quantity when temporary memory space is only stored, be not filled with, but when having reached the default transmission time, still
The access data stored in temporary memory space can be sent to transfer memory space, it is to avoid these access the stagnant of data on a small quantity
Stay, lose.
Preferably, in addition to:Generation module 60, is electrically connected with transfer memory module, when reach called time on default when, it is raw
It is used for into module according to the access data stored in transfer memory module, generation accesses the corresponding access file of data;Compress mould
Block 70, is electrically connected with generation module and sending module, and compression module is used for the access file for compressing generation, forms current compression text
Part;Sending module 30, is further used for current compression file reporting to server.
Specifically, the access data of storage need to report to clothes in the form of a file in transfer memory space (i.e. User space)
Business device.Therefore, when reached called time on default when, text can be accessed by the access data generation in transfer memory space is corresponding
Part., can be again by the access compressing file of generation, as current compression file, then by this compressed file in order to accelerate transmission speed
Report to server.
After the formation of current compression file, the access data stored in transfer memory space can be emptied, subsequently from interim
The access data sended in memory space can be stored in transfer memory space.
Preferably, compression module 70, are further used for after current compression file reports to server, compression module ought
Preceding compressed file is converted to history compressed file;The processing system of web page access data also includes:Removing module 80, with compression mould
Block is electrically connected, when reaching that removing module is used to delete history compressed file when being called time on default.
Specifically, when reach called time on default when, first last history compressed file can be deleted.Why will be upper
Compressed file after report is left to give the correct time on next time and deleted again, if being to report current compression file because setting, delete current pressure
Contracting file is carried out simultaneously, it is possible that reporting the situation of failure (for example:May it not report also, current compression file is just
Delete);In order to avoid there is the situation for reporting failure, therefore, it is arranged such.
It should be noted that history compressed file is not stored in temporary memory space, transfer memory space is also not stored in,
When deleting, system can search out it according to the title of history compressed file, then be deleted.Therefore, history is compressed into text
Part is left on next time deletion of giving the correct time, and can't influence the process for accessing data acquisition, storing, reporting.
In addition, the order that history compressed file is deleted is before generation current compression file, it is to find this for convenience to go through
History compressed file.
It should be noted that above-described embodiment can independent assortment as needed.Described above is only the preferred of the present invention
Embodiment, it is noted that for those skilled in the art, is not departing from the premise of the principle of the invention
Under, some improvements and modifications can also be made, these improvements and modifications also should be regarded as protection scope of the present invention.
Claims (10)
1. a kind of processing method of web page access data, it is characterised in that including:
Step S100 is when wireless terminal sends web access requests information by wireless router, and obtaining the web page access please
The corresponding access data of information are sought, and by the access data storage in temporary memory space;
Step S200 when reaching default transmission condition, by the access data stored in the temporary memory space send to
Transfer memory space is stored, and empties the temporary memory space;
Step S300 when reach called time on default when, the access data in the transfer memory space are corresponding current
Compressed file reports to server, and empties the transfer memory space.
2. the processing method of web page access data as claimed in claim 1, it is characterised in that the step S200 includes:
Step S210 judges whether also there is residual memory space in the temporary memory space;
Step S220 then performs step S250 when the residual memory space is not present in the temporary memory space;
The access data stored in the temporary memory space are sent to transfer memory space and stored by step S250, and clearly
The empty temporary memory space.
3. the processing method of web page access data as claimed in claim 2, it is characterised in that the step S200 also includes:
Step S230 then judges whether to reach default transmission when the temporary memory space also has the residual memory space
Time;
Step S240 then performs step S250 when reaching the default transmission time.
4. the processing method of the web page access data as described in claim 1-3 is any, it is characterised in that the step S300 bags
Include:
Step S320 generates the corresponding visit of the access data according to the access data stored in the transfer memory space
Ask file;
The access file of step S321 compression generations, forms the current compression file;
The current compression file is reported to server by step S322, and empties the transfer memory space.
5. the processing method of web page access data as claimed in claim 4, it is characterised in that:
Also include after the step S322:
The current compression file is converted to history by step S323 after the current compression file reports to the server
Compressed file;
The step S300 further comprises:
Step S310 deletes the history compressed file.
6. a kind of wireless router, it is characterised in that including:
Acquisition module, for when wireless terminal sends web access requests information by wireless router, obtaining the webpage
The corresponding access data of accessing request information;
Temporary storage module, is electrically connected with the acquisition module, and the temporary storage module is obtained for storing the acquisition module
The access data taken;And, after the access data are sent to transfer memory module, the temporary storage module enters one
Walk for the access data of storage to be emptied;
Sending module, is electrically connected with the temporary storage module, when reaching default transmission condition, and the sending module will be described
The access data stored in temporary storage module are sent to transfer memory module;And, when reach called time on default when,
The sending module is further used on the corresponding current compression file of the access data in the transfer memory module
Report to server;
Transfer memory module, is electrically connected with the sending module, and the transfer memory module is used to store the sending module hair
The access data sent;And, after the current compression file reports to server, the transfer memory module is further
For the access data of storage to be emptied.
7. wireless router as claimed in claim 6, it is characterised in that also include:
Judge module, is electrically connected with the temporary storage module and the sending module, and the judge module is used to judge described
Whether also there is residual memory space in temporary storage module;
The sending module, is further used for when residual memory space is not present in the temporary storage module, the transmission
Module sends the access data stored in the temporary storage module to transfer memory module.
8. wireless router as claimed in claim 7, it is characterised in that:
The judge module, is further used for when the temporary storage module also has the residual memory space, described to sentence
Disconnected module judges whether to reach the default transmission time;
The sending module, is further used for when reaching the default transmission time, and the sending module is by the interim storage mould
The access data stored in block are sent to transfer memory module.
9. the wireless router as described in claim 6-8 is any, it is characterised in that also include:
Generation module, is electrically connected with the transfer memory module, when reaching that the generation module is used for root when being called time on default
According to the access data stored in the transfer memory module, the corresponding access file of the access data is generated;
Compression module, is electrically connected with the generation module and the sending module, and the compression module is used for the institute for compressing generation
Access file is stated, the current compression file is formed;
The sending module, is further used for the current compression file reporting to server.
10. wireless router as claimed in claim 9, it is characterised in that:
The compression module, is further used for after the current compression file reports to the server, the compression module
The current compression file is converted into history compressed file;
The processing system of the web page access data also includes:
Removing module, is electrically connected with the compression module, when reaching that the removing module is used for will be described when being called time on default
History compressed file is deleted.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710306572.6A CN107277104A (en) | 2017-05-04 | 2017-05-04 | The processing method and wireless router of a kind of web page access data |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710306572.6A CN107277104A (en) | 2017-05-04 | 2017-05-04 | The processing method and wireless router of a kind of web page access data |
Publications (1)
Publication Number | Publication Date |
---|---|
CN107277104A true CN107277104A (en) | 2017-10-20 |
Family
ID=60073691
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201710306572.6A Pending CN107277104A (en) | 2017-05-04 | 2017-05-04 | The processing method and wireless router of a kind of web page access data |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN107277104A (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN108632454A (en) * | 2018-03-29 | 2018-10-09 | 广东欧珀移动通信有限公司 | Information processing method and device, computer readable storage medium, terminal |
CN110177024A (en) * | 2019-05-06 | 2019-08-27 | 北京奇安信科技有限公司 | Monitoring method and client, server-side, the system of hotspot device |
CN114154099A (en) * | 2021-12-07 | 2022-03-08 | 北京达佳互联信息技术有限公司 | Routing information processing method, device, equipment and storage medium |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20160034397A1 (en) * | 2013-04-16 | 2016-02-04 | Huawei Technologies Co., Ltd. | Method and Apparatus for Processing Data and Computer System |
CN105407481A (en) * | 2015-10-23 | 2016-03-16 | 上海斐讯数据通信技术有限公司 | Internet access data acquisition method |
CN106027595A (en) * | 2016-04-25 | 2016-10-12 | 乐视控股(北京)有限公司 | Access log processing method and system for CDN node |
-
2017
- 2017-05-04 CN CN201710306572.6A patent/CN107277104A/en active Pending
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20160034397A1 (en) * | 2013-04-16 | 2016-02-04 | Huawei Technologies Co., Ltd. | Method and Apparatus for Processing Data and Computer System |
CN105407481A (en) * | 2015-10-23 | 2016-03-16 | 上海斐讯数据通信技术有限公司 | Internet access data acquisition method |
CN106027595A (en) * | 2016-04-25 | 2016-10-12 | 乐视控股(北京)有限公司 | Access log processing method and system for CDN node |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN108632454A (en) * | 2018-03-29 | 2018-10-09 | 广东欧珀移动通信有限公司 | Information processing method and device, computer readable storage medium, terminal |
CN108632454B (en) * | 2018-03-29 | 2021-06-25 | Oppo广东移动通信有限公司 | Information processing method and device, computer readable storage medium and terminal |
CN110177024A (en) * | 2019-05-06 | 2019-08-27 | 北京奇安信科技有限公司 | Monitoring method and client, server-side, the system of hotspot device |
CN110177024B (en) * | 2019-05-06 | 2021-10-01 | 奇安信科技集团股份有限公司 | Monitoring method of hotspot equipment, client, server and system |
CN114154099A (en) * | 2021-12-07 | 2022-03-08 | 北京达佳互联信息技术有限公司 | Routing information processing method, device, equipment and storage medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108063818B (en) | Data downloading method, device, terminal and computer readable storage medium | |
CN106453572B (en) | Method and system based on Cloud Server synchronous images | |
CN107277104A (en) | The processing method and wireless router of a kind of web page access data | |
CN106954248A (en) | A kind of method for network access and device | |
CN106997351A (en) | A kind of caching resource management method and system and device | |
CN107590144A (en) | A kind of file memory method and terminal | |
CN114070791B (en) | Speed limiting processing method and device for data traffic | |
CN108415962A (en) | A kind of cloud storage system | |
CN106686148A (en) | Method and system for increasing uploading speed of objects in object storage system | |
CN105988941B (en) | Cache data processing method and device | |
CN106569917A (en) | Data backup method and mobile terminal | |
CN106933702A (en) | A kind of method of intelligent terminal storage space management, device and intelligent terminal | |
CN103729440B (en) | A kind of method and device of access website | |
CN112363841B (en) | Application process searching and killing method and device, electronic equipment and storage medium | |
CN112787828A (en) | Application flow statistical method and device and mobile electronic device | |
CN116594834A (en) | Operation and maintenance data processing method and device for multi-protocol server | |
CN102902593A (en) | Protocol distribution processing system based on cache mechanism | |
CN1331036C (en) | Method for data storage by a mobile terminal and mobile terminal storage device | |
CN112433779B (en) | Application site preloading method, device and storage medium based on ERP system | |
CN114020208A (en) | Data garbage recovery method and device, computer equipment and storage medium | |
CN114040378A (en) | Application arranging method and device, computer equipment and storage medium | |
CN107193496A (en) | A kind of memory space method for saving and device | |
CN114153714A (en) | Log information based capacity adjustment method, device, equipment and storage medium | |
CN107168648A (en) | File memory method, device and terminal | |
CN112422618A (en) | Position sensing data reporting method, device and system |
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: 20171020 |