CN103186477A - Control method for cache region of server - Google Patents
Control method for cache region of server Download PDFInfo
- Publication number
- CN103186477A CN103186477A CN2011104588235A CN201110458823A CN103186477A CN 103186477 A CN103186477 A CN 103186477A CN 2011104588235 A CN2011104588235 A CN 2011104588235A CN 201110458823 A CN201110458823 A CN 201110458823A CN 103186477 A CN103186477 A CN 103186477A
- Authority
- CN
- China
- Prior art keywords
- server buffer
- data file
- buffer district
- upper limit
- execution
- 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.)
- Granted
Links
Landscapes
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
- Memory System Of A Hierarchy Structure (AREA)
Abstract
The invention provides a control method for the cache region of a server. According to the method, comprehensive adjustment and control on aspects of efficient time limit, upper limit capacity and upper limit file quantity of the files in the cache region of the server are performed, so as to enable the quantity of the data files in the cache region of the server to be controlled effectively, the fact that the cache region of the server is kept under a safe capacity storage range at any time is ensured, the safe storage range of the cache region is broken through under the condition that the quantity of the upper limit files can not be triggered due to less files and larger capacity, the available periods of all files within the cache region tracked are also considered, overdue data files are picked out in time for making a new cache space, and the cache region of the server is enabled to be kept under an optimized state at any time, therefore, improvement to the data response speed of the server is facilitated, and various implementation manners are available to meet requirements of different conditions.
Description
Technical field
The present invention relates to communication network technology and server technical field, be specifically related to a kind of server buffer district control method.
Background technology
Server refers to that a management resource in computer communication network externally provides the high-performance computer of business service.Type of server has a lot, for example data server, file server, web page server, streaming media server, search server etc., they intercept in the computer communication network service request from computer client or client mobile communication end, and service request responded and handle, and then for computer client or client mobile communication end provide various business service, enriched network application.
The quality of service that server provides largely shows its response speed aspect.And in the prioritization scheme for speed of response of server, be one of most important optimization project to the optimization in server buffer district; Reasonably distribute, the Control Server buffer area, can improve server to a great extent to the response speed of the data file called in the recent period.Therefore how can be more rationally, effectively the server buffer district is controlled, then become an important research direction of server technology.
Summary of the invention
At above shortcomings in the prior art, the object of the present invention is to provide a kind of server buffer district control method, with rationally, the effectively adjustment control that the server buffer district is more optimized is to improve the response speed of server.
For achieving the above object, the present invention has adopted following technological means:
A kind of server buffer district control method, by file effective time limit, upper limit capacity and the upper limit quantity of documents that pre-sets the server buffer district, storage space to the server buffer district carries out upper limit volume controlled, and the data file of storing in the server buffer district is carried out file effective time limit and the control of upper limit quantity of documents, realize the comprehensive adjustment to server buffer district residue memory capacity.
But as a kind of selection scheme, this method specifically comprises the steps:
A1) in real time each data file of storing in the server buffer district is carried out corresponding tracking timing, when the tracking timing of data file correspondence arrives the file effective time limit, it is deleted, and when data file enters buffer area, trigger execution in step a2);
A2) judge whether the quantity of documents of having stored in the current time server buffer district has surpassed upper limit quantity of documents, if execution in step a4), otherwise execution in step a3);
A3) judge whether the memory capacity that has taken in the current time server buffer district has surpassed upper limit capacity, if execution in step a4), otherwise return step a1);
A4) the deletion current time deposits a data file in server buffer district the earliest in, returns step a1 then).
But as a kind of selection scheme, this method specifically comprises the steps:
B1) in real time each data file of storing in the server buffer district is carried out corresponding tracking timing, when the tracking timing of data file correspondence arrives the file effective time limit, it is deleted, and when data file enters buffer area, trigger execution in step b2);
B2) judge whether the quantity of documents of having stored in the current time server buffer district has surpassed upper limit quantity of documents, if execution in step b4), otherwise execution in step b3);
B3) judge whether the memory capacity that has taken in the current time server buffer district has surpassed upper limit capacity, if execution in step b4), otherwise return step b1);
B4) the deletion current time deposits a data file in server buffer district, execution in step b5 then the earliest in);
B5) judge whether the memory capacity that has taken in the current time server buffer district has surpassed upper limit capacity, if return step b4), otherwise return step b1).
But as a kind of selection scheme, this method specifically comprises the steps:
C1) in real time each data file of storing in the server buffer district is carried out corresponding tracking timing, when the tracking timing of data file correspondence arrives the file effective time limit, it is deleted, and when data file enters buffer area, trigger execution in step c2);
C2) judge whether the memory capacity that has taken in the current time server buffer district has surpassed upper limit capacity, if execution in step c4), otherwise execution in step c3);
C3) judge whether the quantity of documents of having stored in the current time server buffer district has surpassed upper limit quantity of documents, if execution in step c4), otherwise return step c1);
C4) the deletion current time deposits a data file in server buffer district the earliest in, returns step c1 then).
But as a kind of selection scheme, this method specifically comprises the steps:
D1) in real time each data file of storing in the server buffer district is carried out corresponding tracking timing, when the tracking timing of data file correspondence arrives the file effective time limit, it is deleted, and when data file enters buffer area, trigger execution in step d2);
D2) judge whether the memory capacity that has taken in the current time server buffer district has surpassed upper limit capacity, if execution in step d4), otherwise execution in step d3);
D3) judge whether the quantity of documents of having stored in the current time server buffer district has surpassed upper limit quantity of documents, if execution in step d6), otherwise return steps d 1);
D4) the deletion current time deposits a data file in server buffer district, execution in step d5 then the earliest in);
D5) judge whether the memory capacity that has taken in the current time server buffer district has surpassed upper limit capacity, if return steps d 4), otherwise return steps d 1);
D6) the deletion current time deposits a data file in server buffer district the earliest in, returns steps d 1 then).
In the above-mentioned server buffer district control method, further, each data file of storing in real time to the server buffer district is carried out in the process of corresponding tracking timing, if data file is serviced to think highly of newly and calls, then the tracking timing of its correspondence resets and follows the tracks of timing again.
Than prior art, the beneficial effect of the inventive method is, by to file effective time limit in the server buffer district, control is comprehensively adjusted in three aspects of upper limit capacity and upper limit quantity of documents, make when the quantity of data file is effectively controlled in the server buffer district, guaranteed that the server buffer district all is in safe capacity storage scope at any time, can be not less because of file, capacity is than the safe storage scope that breaks through buffer area under the situation that can't trigger the control of upper limit quantity of documents greatly, and take into account the term of validity of each file in the trace cache district, timely new spatial cache is vacateed in the rejecting of stale data file, make the server buffer district all keep optimal state at any time, help to improve the data in server response speed.
Embodiment
Unlike the prior art, the present invention has adopted file effective time limit, upper limit capacity and the upper limit quantity of documents of a kind of server buffer district control method by pre-seting the server buffer district, storage space to the server buffer district carries out upper limit volume controlled, and the data file of storing in the server buffer district is carried out file effective time limit and the control of upper limit quantity of documents, realize the comprehensive adjustment to server buffer district residue memory capacity.Thus, make when the quantity of data file is effectively controlled in the server buffer district, guaranteed that the server buffer district all is in safe capacity storage scope at any time, and take into account the term of validity of each file in the trace cache district, timely the stale data file is rejected and vacate new spatial cache, make the server buffer district all keep optimal state at any time.
The concrete implementation and operation mode of server buffer of the present invention district control method can have multiple mode.
A: upper limit quantity of documents is preferential:
The upper limit quantity of documents priority scheme of server buffer of the present invention district control method to carrying out Comprehensive Control in the server buffer district, is more suitable for the preferential applicable cases of buffer memory quantity demand for control by preferentially considering upper limit quantity of documents, and its idiographic flow is as follows:
A1) in real time each data file of storing in the server buffer district is carried out corresponding tracking timing, when the tracking timing of data file correspondence arrives the file effective time limit, it is deleted, and when data file enters buffer area, trigger execution in step a2);
A2) judge whether the quantity of documents of having stored in the current time server buffer district has surpassed upper limit quantity of documents, if execution in step a4), otherwise execution in step a3);
A3) judge whether the memory capacity that has taken in the current time server buffer district has surpassed upper limit capacity, if execution in step a4), otherwise return step a1);
A4) the deletion current time deposits a data file in server buffer district the earliest in, returns step a1 then).
B: upper limit quantity of documents is preferentially taken into account upper limit capacity cycle detection:
In above-mentioned upper limit quantity of documents preferential (mode A), cause situation memory capacity to surpass the situation of upper limit capacity greatly if newly enter the data file of buffer area, if it is smaller that current time deposits a data file in server buffer district the earliest in, be difficult to then guarantee that the server buffer district recovers optimum condition in time.Therefore, as the optimization of limit quantity of documents preferential (mode A), the present invention also provides upper limit quantity of documents preferentially to take into account the embodiment of upper limit volume controlled cycle detection, and its idiographic flow is as follows:
B1) in real time each data file of storing in the server buffer district is carried out corresponding tracking timing, when the tracking timing of data file correspondence arrives the file effective time limit, it is deleted, and when data file enters buffer area, trigger execution in step b2);
B2) judge whether the quantity of documents of having stored in the current time server buffer district has surpassed upper limit quantity of documents, if execution in step b4), otherwise execution in step b3);
B3) judge whether the memory capacity that has taken in the current time server buffer district has surpassed upper limit capacity, if execution in step b4), otherwise return step b1);
B4) the deletion current time deposits a data file in server buffer district, execution in step b5 then the earliest in);
B5) judge whether the memory capacity that has taken in the current time server buffer district has surpassed upper limit capacity, if return step b4), otherwise return step b1).
C, upper limit capacity are preferential:
For there not being the preferential applicable cases of buffer memory quantity demand for control, then function is suitable for upper limit capacity priority scheme more, and its idiographic flow is as follows:
C1) in real time each data file of storing in the server buffer district is carried out corresponding tracking timing, when the tracking timing of data file correspondence arrives the file effective time limit, it is deleted, and when data file enters buffer area, trigger execution in step c2);
C2) judge whether the memory capacity that has taken in the current time server buffer district has surpassed upper limit capacity, if execution in step c4), otherwise execution in step c3);
C3) judge whether the quantity of documents of having stored in the current time server buffer district has surpassed upper limit quantity of documents, if execution in step c4), otherwise return step c1);
C4) the deletion current time deposits a data file in server buffer district the earliest in, returns step c1 then).
D, upper limit capacity are preferentially taken into account cycle detection:
Upper limit capacity preferential (mode C) only, still exist the data file that newly enters buffer area to make the server buffer district be difficult in time recover the problem of optimum condition greatly, therefore the upper limit capacity that further proposes to optimize is preferentially taken into account the cycle detection mode, and its idiographic flow is as follows:
D1) in real time each data file of storing in the server buffer district is carried out corresponding tracking timing, when the tracking timing of data file correspondence arrives the file effective time limit, it is deleted, and when data file enters buffer area, trigger execution in step d2);
D2) judge whether the memory capacity that has taken in the current time server buffer district has surpassed upper limit capacity, if execution in step d4), otherwise execution in step d3);
D3) judge whether the quantity of documents of having stored in the current time server buffer district has surpassed upper limit quantity of documents, if execution in step d6), otherwise return steps d 1);
D4) the deletion current time deposits a data file in server buffer district, execution in step d5 then the earliest in);
D5) judge whether the memory capacity that has taken in the current time server buffer district has surpassed upper limit capacity, if return steps d 4), otherwise return steps d 1);
D6) the deletion current time deposits a data file in server buffer district the earliest in, returns steps d 1 then).
But no matter use any embodiment of above-mentioned A ~ D, can both effectively carry out file effective time limit, upper limit capacity and upper limit quantity of documents three aspects to the server buffer district and take into account monitoring, the adjustment that makes the server buffer district more be optimized is controlled, and helps to improve response speed and the operational performance of server.
As further optimization, server buffer of the present invention district control method can also further be taken into account the mode of file valid period renewal, namely each data file of storing in real time to the server buffer district is carried out in the process of corresponding tracking timing, if data file is serviced to think highly of newly and calls, then the tracking timing of its correspondence resets and follows the tracks of timing again.In the valid period that makes that the data file called again in the buffer area can obtain to upgrade, remain the server buffer district to newly calling the rapid response of data like this.
Explanation is at last, above embodiment is only unrestricted in order to technical scheme of the present invention to be described, although the present invention has been described in detail with reference to embodiment, those of ordinary skill in the art is to be understood that, can make amendment or be equal to replacement technical scheme of the present invention, and not breaking away from aim and the scope of technical solution of the present invention, it all should be encompassed in the middle of the claim scope of the present invention.
Claims (6)
1. server buffer district control method, it is characterized in that, by file effective time limit, upper limit capacity and the upper limit quantity of documents that pre-sets the server buffer district, storage space to the server buffer district carries out upper limit volume controlled, and the data file of storing in the server buffer district is carried out file effective time limit and the control of upper limit quantity of documents, realize the comprehensive adjustment to server buffer district residue memory capacity.
2. server buffer according to claim 1 district control method is characterized in that this method specifically comprises the steps:
A1) in real time each data file of storing in the server buffer district is carried out corresponding tracking timing, when the tracking timing of data file correspondence arrives the file effective time limit, it is deleted, and when data file enters buffer area, trigger execution in step a2);
A2) judge whether the quantity of documents of having stored in the current time server buffer district has surpassed upper limit quantity of documents, if execution in step a4), otherwise execution in step a3);
A3) judge whether the memory capacity that has taken in the current time server buffer district has surpassed upper limit capacity, if execution in step a4), otherwise return step a1);
A4) the deletion current time deposits a data file in server buffer district the earliest in, returns step a1 then).
3. server buffer according to claim 1 district control method is characterized in that this method specifically comprises the steps:
B1) in real time each data file of storing in the server buffer district is carried out corresponding tracking timing, when the tracking timing of data file correspondence arrives the file effective time limit, it is deleted, and when data file enters buffer area, trigger execution in step b2);
B2) judge whether the quantity of documents of having stored in the current time server buffer district has surpassed upper limit quantity of documents, if execution in step b4), otherwise execution in step b3);
B3) judge whether the memory capacity that has taken in the current time server buffer district has surpassed upper limit capacity, if execution in step b4), otherwise return step b1);
B4) the deletion current time deposits a data file in server buffer district, execution in step b5 then the earliest in);
B5) judge whether the memory capacity that has taken in the current time server buffer district has surpassed upper limit capacity, if return step b4), otherwise return step b1).
4. server buffer according to claim 1 district control method is characterized in that this method specifically comprises the steps:
C1) in real time each data file of storing in the server buffer district is carried out corresponding tracking timing, when the tracking timing of data file correspondence arrives the file effective time limit, it is deleted, and when data file enters buffer area, trigger execution in step c2);
C2) judge whether the memory capacity that has taken in the current time server buffer district has surpassed upper limit capacity, if execution in step c4), otherwise execution in step c3);
C3) judge whether the quantity of documents of having stored in the current time server buffer district has surpassed upper limit quantity of documents, if execution in step c4), otherwise return step c1);
C4) the deletion current time deposits a data file in server buffer district the earliest in, returns step c1 then).
5. server buffer according to claim 1 district control method is characterized in that this method specifically comprises the steps:
D1) in real time each data file of storing in the server buffer district is carried out corresponding tracking timing, when the tracking timing of data file correspondence arrives the file effective time limit, it is deleted, and when data file enters buffer area, trigger execution in step d2);
D2) judge whether the memory capacity that has taken in the current time server buffer district has surpassed upper limit capacity, if execution in step d4), otherwise execution in step d3);
D3) judge whether the quantity of documents of having stored in the current time server buffer district has surpassed upper limit quantity of documents, if execution in step d6), otherwise return steps d 1);
D4) the deletion current time deposits a data file in server buffer district, execution in step d5 then the earliest in);
D5) judge whether the memory capacity that has taken in the current time server buffer district has surpassed upper limit capacity, if return steps d 4), otherwise return steps d 1);
D6) the deletion current time deposits a data file in server buffer district the earliest in, returns steps d 1 then).
6. according to each described server buffer district control method of claim 2 ~ 5, it is characterized in that, each data file of storing in real time to the server buffer district is carried out in the process of corresponding tracking timing, if data file is serviced to think highly of newly and calls, then the tracking timing of its correspondence resets and follows the tracks of timing again.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201110458823.5A CN103186477B (en) | 2011-12-31 | 2011-12-31 | Control method for cache region of server |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201110458823.5A CN103186477B (en) | 2011-12-31 | 2011-12-31 | Control method for cache region of server |
Publications (2)
Publication Number | Publication Date |
---|---|
CN103186477A true CN103186477A (en) | 2013-07-03 |
CN103186477B CN103186477B (en) | 2016-08-03 |
Family
ID=48677652
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201110458823.5A Active CN103186477B (en) | 2011-12-31 | 2011-12-31 | Control method for cache region of server |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN103186477B (en) |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US5590300A (en) * | 1991-03-05 | 1996-12-31 | Zitel Corporation | Cache memory utilizing address translation table |
US6032227A (en) * | 1996-09-30 | 2000-02-29 | International Business Machines Corporation | System and method for cache management in mobile user file systems |
US20030093488A1 (en) * | 2001-11-15 | 2003-05-15 | Hiroshi Yoshida | Data communication apparatus and data communication method |
CN1822009A (en) * | 2005-02-14 | 2006-08-23 | 精工爱普生株式会社 | File operation limiting system, file operation limiting program, file operation limiting method, electronic device and printing apparatus |
CN102221986A (en) * | 2010-04-15 | 2011-10-19 | 研祥智能科技股份有限公司 | High-speed data cache and collection system based on PCI (Peripheral Component Interconnect) bus |
-
2011
- 2011-12-31 CN CN201110458823.5A patent/CN103186477B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US5590300A (en) * | 1991-03-05 | 1996-12-31 | Zitel Corporation | Cache memory utilizing address translation table |
US6032227A (en) * | 1996-09-30 | 2000-02-29 | International Business Machines Corporation | System and method for cache management in mobile user file systems |
US20030093488A1 (en) * | 2001-11-15 | 2003-05-15 | Hiroshi Yoshida | Data communication apparatus and data communication method |
CN1822009A (en) * | 2005-02-14 | 2006-08-23 | 精工爱普生株式会社 | File operation limiting system, file operation limiting program, file operation limiting method, electronic device and printing apparatus |
CN102221986A (en) * | 2010-04-15 | 2011-10-19 | 研祥智能科技股份有限公司 | High-speed data cache and collection system based on PCI (Peripheral Component Interconnect) bus |
Also Published As
Publication number | Publication date |
---|---|
CN103186477B (en) | 2016-08-03 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN101519078B (en) | Method for synchronizing multi-region data of comprehensive monitoring system | |
EP3151515B1 (en) | Data storage method, sdn controller and distributed network storage system | |
US8745158B2 (en) | Application-guided bandwidth-managed caching | |
JP3810530B2 (en) | Video server system, content dynamic arrangement device, and content dynamic arrangement method | |
WO2016169308A1 (en) | Method and system for cloud-based storage of video, and method and system for previewing cloud-stored video | |
CN101426024B (en) | Data flow controlling method, system and apparatus | |
JP2015530781A (en) | Just-in-time distributed video cache | |
CN102724314B (en) | A kind of distributed caching client based on metadata management | |
CN102833352A (en) | Distributed cache management system and method for implementing distributed cache management | |
WO2011044829A1 (en) | Resource buffering method, resource acquisition method, apparatus and system thereof | |
CN102521269A (en) | Index-based computer continuous data protection method | |
JP2014526763A5 (en) | ||
CN104050250A (en) | Distributed key-value query method and query engine system | |
CN102521279A (en) | Playing method, playing system and player of streaming media files | |
CN103049527A (en) | Large power grid oriented parallel real-time database master and slave switching management system | |
CN103514258A (en) | Centralized recording, preprocessing and replaying method based on offline cache file operation | |
CN105095495A (en) | Distributed file system cache management method and system | |
CN102497389B (en) | Big umbrella caching algorithm-based stream media coordination caching management method and system for IPTV | |
CN101794306B (en) | Multi-type video file block storage system and method | |
CN102917287A (en) | Intelligent optical network exchange device and edge cashing method facing content center | |
CN102710790B (en) | Memcached implementation method and system based on metadata management | |
CN102143000A (en) | Method for controlling data recovery, node, control device and disaster-recovery system | |
CN103369368B (en) | Video cloud on-demand cache scheduling method supporting multi-code-rate version | |
CN103186477A (en) | Control method for cache region of server | |
CN102752374B (en) | System and method for storing and accessing power utilization efficacy data |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C14 | Grant of patent or utility model | ||
GR01 | Patent grant | ||
TR01 | Transfer of patent right | ||
TR01 | Transfer of patent right |
Effective date of registration: 20200605 Address after: Room 502-1, floor 5, building 2, courtyard 10, KEGU 1st Street, economic development zone, Daxing District, Beijing 100081 Patentee after: Singularity Xinyuan International Technology Development (Beijing) Co.,Ltd. Address before: The 401121 northern New District of Chongqing municipality Mount Huangshan Road 5 south of Mercury Technology Building 1 floor office No. 3 Patentee before: A-MEDIA COMMUNICATION TECH Co.,Ltd. |