CN107870874A - A kind of data write-in control method and storage device - Google Patents

A kind of data write-in control method and storage device Download PDF

Info

Publication number
CN107870874A
CN107870874A CN201610844594.3A CN201610844594A CN107870874A CN 107870874 A CN107870874 A CN 107870874A CN 201610844594 A CN201610844594 A CN 201610844594A CN 107870874 A CN107870874 A CN 107870874A
Authority
CN
China
Prior art keywords
level line
page
cache
data
target
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
Application number
CN201610844594.3A
Other languages
Chinese (zh)
Other versions
CN107870874B (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.)
Chengdu Huawei Technology Co Ltd
Original Assignee
Huawei Symantec Technologies 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 Huawei Symantec Technologies Co Ltd filed Critical Huawei Symantec Technologies Co Ltd
Priority to CN202011436741.6A priority Critical patent/CN112559390B/en
Priority to CN201610844594.3A priority patent/CN107870874B/en
Publication of CN107870874A publication Critical patent/CN107870874A/en
Application granted granted Critical
Publication of CN107870874B publication Critical patent/CN107870874B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • G06F12/02Addressing or allocation; Relocation
    • G06F12/08Addressing or allocation; Relocation in hierarchically structured memory systems, e.g. virtual memory systems
    • G06F12/0802Addressing of a memory level in which the access to the desired data or data block requires associative addressing means, e.g. caches
    • G06F12/0866Addressing of a memory level in which the access to the desired data or data block requires associative addressing means, e.g. caches for peripheral storage systems, e.g. disk cache
    • G06F12/0871Allocation or management of cache space
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • G06F12/02Addressing or allocation; Relocation
    • G06F12/08Addressing or allocation; Relocation in hierarchically structured memory systems, e.g. virtual memory systems
    • G06F12/0802Addressing of a memory level in which the access to the desired data or data block requires associative addressing means, e.g. caches
    • G06F12/0877Cache access modes

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

A kind of data write-in control method and storage device, wherein, a kind of data write-in control method includes:When detecting the data write request for target data write-in target storage space, the minimum level of quota of the page resource in cache memory Cache corresponding to target storage space is obtained;When the page-size taken required for target data is more than or equal to the minimum level of quota of page resource, reference level line and Cache actual water level line corresponding to target storage space are obtained;When actual water level line is more than or equal to reference level line, determined to refer to waiting time according to reference level line, and after being delayed with reference to waiting time, for the page in target data distribution Cache.Using the embodiment of the present invention, be advantageous to be lifted the stability of storage device data write performance.

Description

A kind of data write-in control method and storage device
Technical field
The present invention relates to technical field of data storage, more particularly to a kind of data write-in control method and storage device.
Background technology
The final goal of storage is disk array to be write data to;But because disk array response speed is not generally with The demand of upper upper-layer service, so it is generally necessary to adding write buffer.It is also, usually used in storage product general at present Cache (cache memory, between CPU and memory, scale is smaller, but speed is very high;Generally it is made up of SRAM) To improve the write performance of disk array.By taking RAID5 as an example, after business datum writes Cache, if the data energy in Cache Gather into whole piece data and then brush disk array down.But in the case where random write order is more, gather into the machine brushed under whole piece data It can reduce, so that the data in Cache increase;Now if always will not by the data write-in disk array in Cache Cache spaces are caused to be fully written, available page resource is reduced.So in general Cache spaces are provided with high and low water level Line.So-called waterline is a kind of vivid concept;Cache memory space is imagined as a reservoir, the data of write-in are suitable In the water for injecting the reservoir, with increasing for write-in data, the water level of reservoir is gradually increasing;High and low waterline is to pre-set Be used for indicate Cache the occupied degree of memory space two sizes values.When occupied block numbers in Cache (block, Write Cache smallest allocation unit) when being higher than high-water line, begin to start brush, when occupied block numbers are less than low water During bit line, then stop brush, business datum is continued to build up in Cache is write, until reaching high-water line again.
At present, often there is the problem of performance is unstable and performance is relatively low in storage device, and this has a strong impact on the reality of client Using.As client is to the performance requirement more and more higher of storage device, how to ensure storage device in the steady of various application environments Fixed, reliable work is this area urgent problem to be solved.
The content of the invention
The present invention provides a kind of data write-in control method and storage device, is higher than reference level line by actual water level line When Delay distribution Cache page resource, the data write performance fluctuation of storage device is reduced, to lift storage device data The stability of write performance.
In a first aspect, the embodiment of the present invention provides a kind of data write-in control method, including:
When detecting the data write request for target data write-in target storage space, the target storage is obtained The minimum level of quota of page resource in cache memory Cache corresponding to space;
It is the target when page-size taken required for the target data is more than or equal to the minimum level of quota Partial data in data distributes the page resource of the minimum level of quota;
Obtain reference level line corresponding to the target storage space and the actual water level line of the Cache;
When the actual water level line is more than or equal to the reference level line, determine to refer to according to the reference level line Waiting time, and be described in the unallocated data distribution in the target data after the reference waiting time that is delayed The page in Cache.
It can be seen that in the embodiment of the present invention, storage device is more than for target storage space to be written and occupancy page-size The target data of minimum level of quota, the page resource of minimum level of quota in Cache is first distributed for the partial data in target data, its It is secondary, when the actual water level line in detecting Cache is higher than reference level line corresponding to target storage space, it is delayed as number of targets According to unallocated data distribution Cache in the page, relative to the data of the Cache in the prior art without reference level line mechanism Writing scheme, the performance inconsistency that can be avoided Cache actual water level line quick high to a certain extent and bring, is advantageous to carry Rise the stability of storage device data write performance.
With reference in a first aspect, in some possible implementations, methods described also includes:
It is the unallocated data distribution in the target data when the actual water level line is less than the reference level line The page in the Cache.
As can be seen that in optional embodiment of the present invention, when actual water level line is less than reference level line, i.e. Cache's In the case that free Page resource is also well-to-do, storage device allows unallocated numbers of the Cache immediately in caching of target data According to advantageously ensuring that Cache treatment effeciency.
With reference in a first aspect, in some possible implementations, described is the unallocated data in the target data Distribute after the page in the page resource, methods described also includes:
Obtain at least one history actual water level of the Cache corresponding to the target storage space in preset period of time Line;
Waterline going through more than or equal to the reference level line at least one history actual water level line be present During the waterline of historical facts border, reduce the reference level line to update reference level line corresponding to the target storage space;
It is actual less than the history of the reference level line to there is waterline at least one history actual water level line During waterline, increase the reference level line to update reference level line corresponding to the target storage space.
As can be seen that in optional embodiment of the present invention, according to Cache history actual water level line to target storage space Corresponding reference level line enters Mobile state adjustment, is advantageous to be lifted the accuracy of data write-in control.
With reference in a first aspect, in some possible implementations, described is the unallocated data in the target data The page distributed in the Cache, including:
Obtain the free page size in the Cache;
The page taken required for the unallocated data that the free page size is more than or equal in the target data It is the page that the unallocated data in the target data is distributed in the Cache during size of face;
The page-size taken required for the unallocated data that the free page size is less than in the target data When, the data write request is put into waiting list, and the free page size in the Cache is detected is more than or waited It is described in the unallocated data distribution in the target data during page-size taken required for the target data The page in Cache.
With reference in a first aspect, in some possible implementations, the reference level line is with the waiting time for just Proportionate relationship;
The target storage space include it is following any one:
LUN LUN, volume Volume and file system corresponding to disk array.
Second aspect, a kind of offer storage device of the embodiment of the present invention, the device, which has, to be realized in above method design The function of the behavior of storage device.The function can be realized by hardware, and it is real that corresponding software can also be performed by hardware It is existing.The hardware or software include one or more modules corresponding with above-mentioned function phase.
In a possible design, storage device includes processor and communication interface, and the processor is configured as propping up Hold storage device and perform corresponding function in the above method.Further, storage device can also include memory, the storage Device includes cache memory Cache and disk array, and the memory is used to couple with processor, and it preserves storage device Necessary programmed instruction and data.
The third aspect, the embodiments of the invention provide a kind of computer-readable recording medium, the computer-readable storage medium Matter stores program code.Said procedure code includes being used to perform described in first aspect either method of the embodiment of the present invention Part or all of step instruction.
Brief description of the drawings
In order to illustrate more clearly about the embodiment of the present invention or technical scheme of the prior art, below will be to embodiment or existing There is the required accompanying drawing used in technology description to be briefly described, it should be apparent that, drawings in the following description are only this Some embodiments of invention, for those of ordinary skill in the art, on the premise of not paying creative work, can be with Other accompanying drawings are obtained according to these accompanying drawings.
Fig. 1 is the process schematic that storage device disclosed in prior art writes data into Cache;
Fig. 2 is that the data of the storage device disclosed in prior art write the service feature fluctuation schematic diagram of business;
Fig. 3 A are a kind of schematic flow sheets of data write-in control method provided in an embodiment of the present invention;
Fig. 3 B are a kind of process schematics of data write-in control method provided in an embodiment of the present invention;
Fig. 4 A are a kind of unit composition frame charts of storage device provided in an embodiment of the present invention;
Fig. 4 B are a kind of structural representations of storage device provided in an embodiment of the present invention;
Fig. 5 is the structural representation of another storage device provided in an embodiment of the present invention.
Embodiment
In order that those skilled in the art more fully understand the present invention program, below in conjunction with the embodiment of the present invention Accompanying drawing, the technical scheme in the embodiment of the present invention is clearly and completely described, it is clear that described embodiment is only Part of the embodiment of the present invention, rather than whole embodiments.Based on the embodiment in the present invention, those of ordinary skill in the art The every other embodiment obtained under the premise of creative work is not made, belongs to the scope of protection of the invention.
Term " first ", " second " in description and claims of this specification and above-mentioned accompanying drawing etc. are to be used to distinguish Different objects, rather than for describing particular order.In addition, term " comprising " and " having " and their any deformations, it is intended that It is to cover non-exclusive include.Such as process, method, system, product or the equipment for containing series of steps or unit do not have The step of being defined in the step of having listed or unit, but alternatively also including not listing or unit, or alternatively also wrap Include for other intrinsic steps of these processes, method, product or equipment or unit.
Referenced herein " embodiment " is it is meant that the special characteristic, structure or the characteristic that describe can wrap in conjunction with the embodiments In at least one embodiment of the present invention.Each position in the description occur the phrase might not each mean it is identical Embodiment, nor the independent or alternative embodiment with other embodiments mutual exclusion.Those skilled in the art explicitly and Implicitly understand, embodiment described herein can be combined with other embodiments.
The scheme that unified water level control is first carried out to being directed to cache memory Cache in the prior art below is said It is bright.In existing scheme, Cache page resource (spatial cache in cache is embodied in units of the page) is according to height Water level carries out page resource distribution, LUN (Logical of the strategy that the page resource distributes suitable for storage device Unit Number, LUN), volume the type such as Volume and file system memory space.Referring to Fig. 1, Fig. 1 is prior art Middle storage device writes data into Cache process schematic, when storage device detects the write request for target data, First, the free page resource in Cache is obtained, secondly, judges whether free page resource is more than the reference page of target data Face resource, if so, the page resource then distributed for target data in free page resource, if it is not, then the write request is put into Waiting list.
It can be seen that because whole page resources of Cache in the prior art are according to having, distribute, enter without the principle then waited Row resource allocation, when the partial service (such as LUN operational data storage, but be not limited to LUN) of storage device can not get page , there is performance inconsistency in the situation of face resource.Such as go out existing network in some period, some LUN rear end I/O path (below Cache) The situation that network postpones or disk performance declines, cause to write page data can not quick lower wall, and Cache continues according to unified Have, distribute, without then waiting principle to continue to distribute resource, this make it that Cache actual water level line is quickly high, and each LUN can not be real When obtain and write page resource and hydraulic performance decline, when reaching cache high-water line, storage device starts to complete in Cache Portion page data carries out quick brush, and after quick brush, the actual water level line in Cache rapidly drops to low water line, each LUN It can obtain and write page resource, performance rapid increase, so as to cause service feature big ups and downs, the exemplary plot of service feature fluctuation is such as Shown in Fig. 2, wherein IOPS is the number (Input/Output Operations Per Second) per second for being written and read operation.
Based on above-mentioned prior art, below in conjunction with the accompanying drawing in the embodiment of the present invention, to the skill in the embodiment of the present invention Art scheme is described.
The flow that Fig. 3 A and Fig. 3 B, Fig. 3 A are a kind of data write-in control methods provided in an embodiment of the present invention is referred to show It is intended to, Fig. 3 B are a kind of process schematics of data write-in control method provided in an embodiment of the present invention.As illustrated, notebook data Write-in control method comprises the following steps:
S301, storage device obtain when detecting the data write request for target data write-in target storage space Take the minimum level of quota of the page resource in cache memory Cache corresponding to the target storage space;
Wherein, the storage device for example can be that there is cache memory Cache computer equipment, storage to set Each class of electronic devices such as standby, base station, wearable device.
Wherein, the target storage space include it is following any one:
LUN LUN, volume Volume and file system corresponding to disk array.
S302, the page-size that the storage device takes required for the target data are more than the minimum level of quota When, for the page resource of the partial data distribution minimum level of quota in the target data;
S303, the storage device obtain reference level line and the Cache reality corresponding to the target storage space Border waterline;
S304, the storage device is when the actual water level line is more than or equal to the reference level line, according to described Reference level line determines refer to waiting time, and be delayed it is described with reference to waiting time after, in the target data not The page distributed in Cache described in data distribution.
Wherein, the reference level line and the waiting time are proportional relationship;When reference level line is larger, set It larger waiting time, can so alleviate Cache traffic pressure, avoid Cache actual water level line from exceeding high-water line The performance big ups and downs brought after brush are carried out, when reference level line is smaller, less waiting time is set, takes into account Cache Business processing efficiency, growth process when avoiding waiting for and excessive influence Cache business processing real-time.
It can be seen that in the embodiment of the present invention, storage device is more than for target storage space to be written and occupancy page-size The target data of minimum level of quota, the page resource of minimum level of quota in Cache is first distributed for the partial data in target data, its It is secondary, when the actual water level line in detecting Cache is higher than reference level line corresponding to target storage space, it is delayed as number of targets According to unallocated data distribution Cache in the page, relative to the data of the Cache in the prior art without reference level line mechanism Writing scheme, the performance inconsistency that can be avoided Cache actual water level line quick high to a certain extent and bring, is advantageous to carry Rise the stability of storage device data write performance.
In one example, the storage device also performs following operation:
When the actual water level line is less than the reference level line, the storage device be the target data in not The page distributed in Cache described in data distribution.
In this illustration, when actual water level line is less than reference level line, i.e. the free Page resource of Cache also compares In the case of well-to-do, storage device allows unallocated data of the Cache immediately in caching of target data, advantageously ensures that Cache Treatment effeciency.
In one example, the page that the unallocated data in the target data is distributed in the page resource Afterwards, the storage device also performs following operation:
Obtain at least one history actual water level of the Cache corresponding to the target storage space in preset period of time Line;
Waterline going through more than or equal to the reference level line at least one history actual water level line be present During the waterline of historical facts border, reduce the reference level line to update reference level line corresponding to the target storage space;
It is actual less than the history of the reference level line to there is waterline at least one history actual water level line During waterline, increase the reference level line to update reference level line corresponding to the target storage space.
In this illustration, according to Cache history actual water level line to reference level line corresponding to target storage space Enter Mobile state adjustment, i.e., when history actual water level line is more than reference level line, reduce reference level line and prolonged with as much as possible When data write-in business, alleviate Cache performance burden, when history actual water level line is less than reference level line, increase refers to Waterline maintains Cache business efficiency, in this way, by based on Cache to cache the data that most data write business in real time Practical business pressure reference level line is entered Mobile state adjustment, be advantageous to lifted storage device data write-in control accuracy With it is intelligent.
In one example, the storage device is that the unallocated data in the target data is distributed in the Cache The specific implementation of the page be:
Obtain the free page size in the Cache;
The page taken required for the unallocated data that the free page size is more than or equal in the target data It is the page that the unallocated data in the target data is distributed in the Cache during size of face;
The page-size taken required for the unallocated data that the free page size is less than in the target data When, the data write request is put into waiting list, and the free page size in the Cache is detected is more than or waited It is described in the unallocated data distribution in the target data during page-size taken required for the target data The page in Cache.
In one example, the storage device also performs following operation:
The page-size that the storage device takes required for the target data is less than or equal to the minimum level of quota When, it is directly the page resource in the target data distribution Cache.
In this illustration, because the different memory spaces in storage device can preset corresponding different minimum match somebody with somebody Volume, the base page resource requirement of each memory space is so may insure, avoid memory space from can not being obtained because of long-time Page resource in Cache and influence service feature.
It is above-mentioned that mainly the scheme of the embodiment of the present invention is described from the angle of storage device.It is understood that For storage device in order to realize above-mentioned function, it comprises perform the corresponding hardware configuration of each function and/or software module.Ability Field technique personnel should be readily appreciated that, with reference to the unit and algorithm steps of each example of the embodiments described herein description Suddenly, the present invention can be realized with the combining form of hardware or hardware and computer software.Some function actually with hardware still The mode of computer software driving hardware performs, application-specific and design constraint depending on technical scheme.Professional skill Art personnel can specifically realize described function to each using distinct methods, but it is this realize it is not considered that It is beyond the scope of this invention.
The embodiment of the present invention can carry out the division of functional unit according to above method example to storage device, for example, can Each functional unit is divided with corresponding each function, two or more functions can also be integrated in a processing unit In.Above-mentioned integrated unit can both be realized in the form of hardware, can also be realized in the form of SFU software functional unit.Need It is noted that the division in the embodiment of the present invention to unit is schematical, only a kind of division of logic function is actual real There can be other dividing mode now.
In the case of using integrated unit, Fig. 4 A show one kind of storage device involved in above-described embodiment Possible structural representation.Storage device 400 includes:Processing unit 402 and communication unit 403.Processing unit 402 is used for depositing The action of storage equipment is controlled management, for example, processing unit 402 is used to support storage device to perform the step S301 in Fig. 3 A Other processes to S304 and/or for techniques described herein.Communication unit 403 is used to support storage device to set with other Standby communication.Storage device can also include memory cell 401, program code and data for memory storage devices.
Wherein, processing unit 402 can be processor or controller, such as can be central processing unit (Central Processing Unit, CPU), general processor, digital signal processor (Digital Signal Processor, DSP), Application specific integrated circuit (Application-Specific Integrated Circuit, ASIC), field programmable gate array It is (Field Programmable Gate Array, FPGA) or other PLDs, transistor logic, hard Part part or its any combination.What it can realize or perform with reference to described by the disclosure of invention various exemplary patrols Collect square frame, module and circuit.The processor can also be the combination for realizing computing function, such as include one or more micro- places Manage device combination, combination of DSP and microprocessor etc..
Communication unit 403 can be communication interface, transceiver, transmission circuit etc., wherein, communication interface is to be referred to as, can be with Including one or more interfaces, such as can include:Storage device and from the interface between server and/or other interfaces.Deposit Storage unit 401 can be memory.
When processing unit 402 is processor, communication unit 403 is communication interface, when memory cell 401 is memory, this Storage device involved by inventive embodiments can be the storage device shown in Fig. 4 B.
Specifically, the processing unit 402 is used to detect the data for target data write-in target storage space During write request, obtained by the communication unit 403 in cache memory Cache corresponding to the target storage space Page resource minimum level of quota;Be additionally operable to the page-size that is taken required for the target data be more than or equal to it is described most It is the page resource of the partial data distribution minimum level of quota in the target data during low quota;It is additionally operable to by described Communication unit 403 obtains reference level line corresponding to the target storage space and the actual water level line of the Cache;It is additionally operable to When the actual water level line is more than or equal to the reference level line, when being determined according to the reference level line with reference to waiting It is long, and be that the unallocated data in the target data is distributed in the Cache after the reference waiting time that is delayed The page.
In one example, the processing unit 402, it is additionally operable to be less than the reference level line in the actual water level line When, it is the page that the unallocated data in the target data is distributed in the Cache.
In one example, unallocated data of the processing unit 402 in for the target data distributes the page After the page in resource, it is additionally operable to obtain at least one of the Cache corresponding to the target storage space in preset period of time Individual history actual water level line;It is additionally operable to have waterline at least one history actual water level line more than or equal to described During the history actual water level line of reference level line, reduce the reference level line to update ginseng corresponding to the target storage space Examine waterline;It is additionally operable to waterline going through less than the reference level line at least one history actual water level line be present During the waterline of historical facts border, increase the reference level line to update reference level line corresponding to the target storage space.
In one example, it is described be the page side that the unallocated data in the target data is distributed in the Cache Face, the processing unit 402 are specifically used for:Obtain the free page size in the Cache;It is and big in the free page It is in the target data during page-size of the small required occupancy of the unallocated data being more than or equal in the target data The page that distributes in the Cache of unallocated data;And it is less than in the free page size in the target data During the page-size taken required for unallocated data, the data write request is put into waiting list, and detecting It is the mesh when stating the page-size of occupancy required for the free page size in Cache is more than or equal to the target data Mark the page that the unallocated data in data is distributed in the Cache.
In one example, the reference level line and the waiting time are proportional relationship;
The target storage space include it is following any one:LUN LUN, volume Volume corresponding to disk array And file system.
Refering to shown in Fig. 4 B, the storage device 410 includes:Processor 412, communication interface 413, memory 411.It is optional , storage device 410 can also include bus 414.Wherein, communication interface 413, processor 412 and memory 411 can lead to Cross bus 414 to be connected with each other, memory 411 includes Cache and disk array, and the disk array can for example include serially connecting Connection small computer system interface (Serial Attached Small Computer System Interface, SAS) hard disk With solid state hard disc (Solid State Disk, SSD) etc.;Bus 414 can be Peripheral Component Interconnect standard (Peripheral Component Interconnect, abbreviation PCI) bus or EISA (Extended Industry Standard Architecture, abbreviation EISA) bus etc..The bus 414 can be divided into address bus, data/address bus, control Bus processed etc..For ease of representing, only represented in Fig. 4 B with a thick line, it is not intended that an only bus or a type of Bus.
Storage device shown in above-mentioned Fig. 4 A or Fig. 4 B is it can be appreciated that a kind of device for storage device, the present invention Embodiment does not limit.
The embodiment of the present invention additionally provides another storage device, as shown in figure 5, for convenience of description, illustrate only with The related part of the embodiment of the present invention, particular technique details do not disclose, refer to present invention method part.The storage Equipment can be to include mobile phone, tablet personal computer, PDA (Personal Digital Assistant, personal digital assistant), POS Any terminal device such as (Point of Sales, point-of-sale terminal), vehicle-mounted computer, so that storage device is mobile phone as an example:
Fig. 5 is illustrated that the block diagram of the part-structure of the mobile phone related to storage device provided in an embodiment of the present invention.Ginseng Fig. 5 is examined, mobile phone includes:Radio frequency (Radio Frequency, RF) circuit 510, memory 520, input block 530, display unit 540th, sensor 550, voicefrequency circuit 560, Wireless Fidelity (Wireless Fidelity, WiFi) module 570, processor 580, And the grade part of power supply 550.It will be understood by those skilled in the art that the handset structure shown in Fig. 5 is not formed to mobile phone Limit, can include than illustrating more or less parts, either combine some parts or different parts arrangement.
Each component parts of mobile phone is specifically introduced with reference to Fig. 5:
RF circuits 510 can be used for the reception and transmission of information.Generally, RF circuits 510 include but is not limited to antenna, at least one Individual amplifier, transceiver, coupler, low-noise amplifier (Low Noise Amplifier, LNA), duplexer etc..In addition, RF circuits 510 can also be communicated by radio communication with network and other equipment.Above-mentioned radio communication can use any communication Standard or agreement, including but not limited to global system for mobile communications (Global System of Mobile Communication, GSM), general packet radio service (General Packet Radio Service, GPRS), code division it is more Location (Code Division Multiple Access, CDMA), WCDMA (Wideband Code Division Multiple Access, WCDMA), Long Term Evolution (Long Term Evolution, LTE), Email, Short Message Service (Short Messaging Service, SMS) etc..
Memory 520 can be used for storage software program and module, and processor 580 is stored in memory 520 by operation Software program and module, so as to perform the various function application of mobile phone and data processing.Memory 520 can mainly include Cache memory Cache and disk array, disk array include storing program area and storage data field, wherein, store journey Sequence area can storage program area, application program (determination of average playing duration etc.) needed at least one function etc.;Store number It can be stored according to area and created data (such as history playing duration etc.) etc. are used according to mobile phone.In addition, memory 520 can be with Including high-speed random access memory, nonvolatile memory, for example, at least disk memory, a flash memory can also be included Device or other volatile solid-state parts.
Input block 530 can be used for the numeral or character information for receiving input, and produce with the user of mobile phone set with And the key signals input that function control is relevant.Specifically, input block 530 may include fingerprint recognition module 531 and other are defeated Enter equipment 532.Fingerprint recognition module 531, user can be gathered in finger print data thereon.Except fingerprint recognition module 531, input Unit 530 can also include other input equipments 532.Specifically, other input equipments 532 can include but is not limited to touch-control One kind in screen, physical keyboard, function key (such as volume control button, switch key etc.), trace ball, mouse, action bars etc. It is or a variety of.
Display unit 540 can be used for display by user input information or be supplied to user information and mobile phone it is various Menu.Display unit 540 may include display screen 541, optionally, can use liquid crystal display (Liquid Crystal Display, LCD), the form such as Organic Light Emitting Diode (Organic Light-Emitting Diode, OLED) it is aobvious to configure Display screen 541.Although in Figure 5, fingerprint recognition module 531 and display screen 541 are the parts independent as two to realize mobile phone Input and input function, it is but in some embodiments it is possible to fingerprint recognition module 531 and display screen 541 is integrated and real The input of existing mobile phone and playing function.
Mobile phone may also include at least one sensor 550, such as optical sensor, motion sensor and other sensors. Specifically, optical sensor may include ambient light sensor and proximity transducer, wherein, ambient light sensor can be according to ambient light Light and shade adjust the brightness of display screen 541, proximity transducer can when mobile phone is moved in one's ear, close display screen 541 and/or Backlight.As one kind of motion sensor, accelerometer sensor can detect in all directions the big of (generally three axles) acceleration It is small, size and the direction of gravity are can detect that when static, available for identification mobile phone posture application (such as horizontal/vertical screen switching, phase Close game, magnetometer pose calibrating), Vibration identification correlation function (such as pedometer, tap) etc.;It can also configure as mobile phone The other sensors such as gyroscope, barometer, hygrometer, thermometer, infrared ray sensor, will not be repeated here.
Voicefrequency circuit 560, loudspeaker 561, microphone 562 can provide the COBBAIF between user and mobile phone.Audio-frequency electric Electric signal after the voice data received conversion can be transferred to loudspeaker 561, sound is converted to by loudspeaker 561 by road 560 Signal plays;On the other hand, the voice signal of collection is converted to electric signal by microphone 562, is turned after being received by voicefrequency circuit 560 Voice data is changed to, then after voice data playback process device 580 is handled, through RF circuits 510 to be sent to such as another mobile phone, Or voice data is played to memory 520 further to handle.
WiFi belongs to short range wireless transmission technology, and mobile phone can help user's transceiver electronicses postal by WiFi module 570 Part, browse webpage and access streaming video etc., it has provided the user wireless broadband internet and accessed.Although Fig. 5 is shown WiFi module 570, but it is understood that, it is simultaneously not belonging to must be configured into for mobile phone, can not change as needed completely Become in the essential scope of invention and omit.
Processor 580 is the control centre of mobile phone, using various interfaces and the various pieces of connection whole mobile phone, is led to Cross operation or perform the software program and/or module being stored in memory 520, and call and be stored in memory 520 Data, the various functions and processing data of mobile phone are performed, so as to carry out integral monitoring to mobile phone.Optionally, processor 580 can wrap Include one or more processing units;Preferably, processor 580 can integrate application processor and modem processor, wherein, should Operating system, user interface and application program etc. are mainly handled with processor, modem processor mainly handles radio communication. It is understood that above-mentioned modem processor can not also be integrated into processor 580.
Mobile phone also includes the power supply 550 (such as battery) to all parts power supply, it is preferred that power supply can pass through power supply pipe Reason system and processor 580 are logically contiguous, so as to realize management charging, electric discharge and power managed by power-supply management system Etc. function.
Although being not shown, mobile phone can also include camera, bluetooth module etc., will not be repeated here.
In embodiment shown in earlier figures 3, each step method flow can based on the mobile phone structure realize.
In embodiment shown in earlier figures 4A, each unit function can based on the mobile phone structure realize.
The step of method or algorithm described by the embodiment of the present invention can be realized in a manner of hardware or Realized by the mode of computing device software instruction.Software instruction can be made up of corresponding software module, and software module can To be stored on random access memory (Random Access Memory, RAM), flash memory, read-only storage (Read Only Memory, ROM), Erasable Programmable Read Only Memory EPROM (Erasable Programmable ROM, EPROM), electrically erasable can Program read-only memory (Electrically EPROM, EEPROM), register, hard disk, mobile hard disk, read-only optical disc (CD- ROM) or in the storage medium of any other form well known in the art.A kind of exemplary storage medium is coupled to processing Device, so as to enable a processor to from the read information, and information can be write to the storage medium.Certainly, storage is situated between Matter can also be the part of processor.Processor and storage medium can be located in ASIC.In addition, the ASIC can be located at In gateway device or mobile management network element.Certainly, processor and storage medium can also be present in gateway as discrete assembly In equipment or mobile management network element.
Those skilled in the art it will be appreciated that in said one or multiple examples, retouched by the embodiment of the present invention The function of stating can be realized with hardware, software, firmware or their any combination.When implemented in software, can be by this A little functions are stored in computer-readable medium or entered as one or more instructions on computer-readable medium or code Row transmission.Computer-readable medium includes computer-readable storage medium and communication media, and wherein communication media includes being easy to from one Any medium of computer program is transmitted to another place in place.Storage medium can be that universal or special computer can be deposited Any usable medium taken.
Above-described embodiment, the purpose, technical scheme and beneficial effect of the embodiment of the present invention are carried out It is further described, should be understood that the embodiment that the foregoing is only the embodiment of the present invention, and do not have to In limit the embodiment of the present invention protection domain, it is all on the basis of the technical scheme of the embodiment of the present invention, done it is any Modification, equivalent substitution, improvement etc., it all should be included within the protection domain of the embodiment of the present invention.

Claims (11)

  1. A kind of 1. data write-in control method, it is characterised in that including:
    When detecting the data write request for target data write-in target storage space, the target storage space is obtained The minimum level of quota of page resource in corresponding cache memory Cache;
    It is the portion in the target data when page-size taken required for the target data is more than the minimum level of quota Divided data distributes the page resource of the minimum level of quota;
    Obtain reference level line corresponding to the target storage space and the actual water level line of the Cache;
    When the actual water level line is more than or equal to the reference level line, determined according to the reference level line with reference to wait Duration, and be that the unallocated data in the target data is distributed in the Cache after the reference waiting time that is delayed The page.
  2. 2. according to the method for claim 1, it is characterised in that methods described also includes:
    It is described in the unallocated data distribution in the target data when the actual water level line is less than the reference level line The page in Cache.
  3. 3. according to the method described in any one of claim 1 or 2, it is characterised in that described is not dividing in the target data After the page in page resource described in data distribution, methods described also includes:
    Obtain at least one history actual water level line of the Cache corresponding to the target storage space in preset period of time;
    It is real more than or equal to the history of the reference level line to there is waterline at least one history actual water level line During the waterline of border, reduce the reference level line to update reference level line corresponding to the target storage space;
    The history actual water level that waterline is less than the reference level line at least one history actual water level line be present During line, increase the reference level line to update reference level line corresponding to the target storage space.
  4. 4. according to the method for claim 3, it is characterised in that described is the unallocated data distribution in the target data The page in the Cache, including:
    Obtain the free page size in the Cache;
    The page taken required for the unallocated data that the free page size is more than or equal in the target data is big Hour, it is the page that the unallocated data in the target data is distributed in the Cache;
    , will during the page-size taken required for the unallocated data that the free page size is less than in the target data The data write request is put into waiting list, and the free page size in the Cache is detected is more than or equal to institute It is that the unallocated data in the target data is distributed in the Cache when stating the page-size taken required for target data The page.
  5. 5. according to the method described in claim any one of 1-4, it is characterised in that the reference level line and the waiting time For proportional relationship;
    The target storage space include it is following any one:
    LUN LUN, volume Volume and file system corresponding to disk array.
  6. A kind of 6. storage device, it is characterised in that including:Processing unit and communication unit,
    The processing unit, for when detecting the data write request for target data write-in target storage space, leading to Cross the communication unit and obtain the minimum of page resource in cache memory Cache corresponding to the target storage space Quota;It is described when the page-size for being additionally operable to take required for the target data is more than or equal to the minimum level of quota Partial data in target data distributes the page resource of the minimum level of quota;It is additionally operable to by described in communication unit acquisition The actual water level line of reference level line corresponding to target storage space and the Cache;It is additionally operable to big in the actual water level line When the reference level line, determined to refer to waiting time according to the reference level line, and in the ginseng that is delayed It is the page that the unallocated data in the target data is distributed in the Cache after examining waiting time.
  7. 7. storage device according to claim 6, it is characterised in that the processing unit, be additionally operable in the actual water It is the page that the unallocated data in the target data is distributed in the Cache when bit line is less than the reference level line.
  8. 8. according to the storage device described in any one of claim 6 or 7, it is characterised in that the processing unit is for the mesh The unallocated data marked in data is distributed after the page in the page resource, is additionally operable to obtain the target in preset period of time At least one history actual water level line of the Cache corresponding to memory space;It is additionally operable to actual at least one history When the history actual water level line that waterline is more than or equal to the reference level line in waterline be present, reduce the reference level Line is to update reference level line corresponding to the target storage space;It is additionally operable at least one history actual water level line When the history actual water level line that waterline is less than the reference level line be present, increase the reference level line to update the mesh Mark reference level line corresponding to memory space.
  9. 9. storage device according to claim 8, it is characterised in that it is described be the target data in unallocated number In terms of the page distributed in the Cache, the processing unit is specifically used for:The free page obtained in the Cache is big It is small;And the page taken required for the unallocated data that the free page size is more than or equal in the target data It is the page that the unallocated data in the target data is distributed in the Cache during size;It is and big in the free page When being less than the page-size taken required for the unallocated data in the target data, the data write request is put into Waiting list, and the occupancy required for the free page size in detecting the Cache is more than or equal to the target data Page-size when, be the page that the unallocated data in the target data is distributed in the Cache.
  10. 10. according to the storage device described in claim any one of 6-9, it is characterised in that the reference level line with it is described etc. When a length of proportional relationship;
    The target storage space include it is following any one:
    LUN LUN, volume Volume and file system corresponding to disk array.
  11. A kind of 11. storage device, it is characterised in that including:Processor, memory, communication interface, the processor are deposited with described Reservoir connects with the communication interface;
    The memory storage has executable program code, and the communication interface is used for radio communication;
    The processor is used to call the executable program code in the memory, performs as claim 1-5 is any Method described by.
CN201610844594.3A 2016-09-23 2016-09-23 Data write-in control method and storage device Active CN107870874B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN202011436741.6A CN112559390B (en) 2016-09-23 2016-09-23 Data writing control method and storage device
CN201610844594.3A CN107870874B (en) 2016-09-23 2016-09-23 Data write-in control method and storage device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610844594.3A CN107870874B (en) 2016-09-23 2016-09-23 Data write-in control method and storage device

Related Child Applications (1)

Application Number Title Priority Date Filing Date
CN202011436741.6A Division CN112559390B (en) 2016-09-23 2016-09-23 Data writing control method and storage device

Publications (2)

Publication Number Publication Date
CN107870874A true CN107870874A (en) 2018-04-03
CN107870874B CN107870874B (en) 2020-12-15

Family

ID=61751096

Family Applications (2)

Application Number Title Priority Date Filing Date
CN201610844594.3A Active CN107870874B (en) 2016-09-23 2016-09-23 Data write-in control method and storage device
CN202011436741.6A Active CN112559390B (en) 2016-09-23 2016-09-23 Data writing control method and storage device

Family Applications After (1)

Application Number Title Priority Date Filing Date
CN202011436741.6A Active CN112559390B (en) 2016-09-23 2016-09-23 Data writing control method and storage device

Country Status (1)

Country Link
CN (2) CN107870874B (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110569203A (en) * 2019-08-09 2019-12-13 华为技术有限公司 input control method and device and storage equipment
CN110908604A (en) * 2019-11-08 2020-03-24 浪潮电子信息产业股份有限公司 Request processing delay adjusting method and device, electronic equipment and storage medium
CN111680065A (en) * 2020-05-25 2020-09-18 泰康保险集团股份有限公司 Processing system, equipment and method for lag data in streaming computation
CN112306904A (en) * 2020-11-20 2021-02-02 新华三大数据技术有限公司 Cache data disk refreshing method and device

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115562617B (en) * 2022-11-30 2023-03-03 苏州浪潮智能科技有限公司 Depth setting method and system of FIFO memory and electronic equipment

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5210829A (en) * 1990-12-12 1993-05-11 Digital Equipment Corporation Adjustable threshold for buffer management
CN103823765A (en) * 2014-02-26 2014-05-28 浙江宇视科技有限公司 Method and device for dynamic regulation of cache refreshing strategy
CN104090731A (en) * 2014-07-09 2014-10-08 浙江宇视科技有限公司 Method and device for automatically adjusting Cache refreshing parameters
CN104182361A (en) * 2014-08-20 2014-12-03 北京国双科技有限公司 Data caching processing method and device

Family Cites Families (17)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6252849B1 (en) * 1998-06-30 2001-06-26 Sun Microsystems, Inc. Flow control using output port buffer allocation
CN100407696C (en) * 2005-01-25 2008-07-30 华为技术有限公司 Method for transmitting message data by IP facsimile gateway
CN100462940C (en) * 2007-01-30 2009-02-18 金蝶软件(中国)有限公司 Method and apparatus for cache data in memory
CN101340358B (en) * 2007-07-04 2011-04-20 鼎桥通信技术有限公司 Flow control method, system and flow control entity
CN101957800A (en) * 2010-06-12 2011-01-26 福建星网锐捷网络有限公司 Multichannel cache distribution method and device
CN102075436B (en) * 2011-02-10 2014-09-17 华为数字技术(成都)有限公司 Ethernet, and data transmitting method and device thereof
CN102129876B (en) * 2011-04-07 2014-12-03 浙江宇视科技有限公司 Data storage method and equipment for video monitoring system
CN102307224A (en) * 2011-05-17 2012-01-04 华为软件技术有限公司 Method and device for realizing service isolation in cloud computing system, and cloud server
CN103136115B (en) * 2011-11-23 2015-08-19 英业达集团(天津)电子技术有限公司 The method and system of request access zero-copy high-speed cache
CN102436356B (en) * 2011-12-12 2014-12-24 华为数字技术(成都)有限公司 Method and device for distributing writing page space
CN102693164B (en) * 2012-05-03 2014-09-17 中国石油集团川庆钻探工程有限公司地球物理勘探公司 Equipment and method for preventing buffer overflow
US8959305B1 (en) * 2012-06-29 2015-02-17 Emc Corporation Space reclamation with virtually provisioned devices
CN103064639B (en) * 2012-12-28 2016-08-03 华为技术有限公司 Date storage method and device
CN103345368B (en) * 2013-07-18 2015-05-06 内蒙古科技大学 Data caching method in buffer storage
US9292448B2 (en) * 2013-09-19 2016-03-22 Google Inc. Dynamic sizing of memory caches
CN105446888B (en) * 2014-05-30 2018-10-12 华为技术有限公司 The method of mobile data, controller and storage system between storage device
CN105159612A (en) * 2015-09-06 2015-12-16 浪潮(北京)电子信息产业有限公司 Distribution method of free space of disk

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5210829A (en) * 1990-12-12 1993-05-11 Digital Equipment Corporation Adjustable threshold for buffer management
CN103823765A (en) * 2014-02-26 2014-05-28 浙江宇视科技有限公司 Method and device for dynamic regulation of cache refreshing strategy
CN104090731A (en) * 2014-07-09 2014-10-08 浙江宇视科技有限公司 Method and device for automatically adjusting Cache refreshing parameters
CN104182361A (en) * 2014-08-20 2014-12-03 北京国双科技有限公司 Data caching processing method and device

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110569203A (en) * 2019-08-09 2019-12-13 华为技术有限公司 input control method and device and storage equipment
CN110569203B (en) * 2019-08-09 2021-11-30 华为技术有限公司 Input control method and device and storage equipment
CN110908604A (en) * 2019-11-08 2020-03-24 浪潮电子信息产业股份有限公司 Request processing delay adjusting method and device, electronic equipment and storage medium
CN111680065A (en) * 2020-05-25 2020-09-18 泰康保险集团股份有限公司 Processing system, equipment and method for lag data in streaming computation
CN111680065B (en) * 2020-05-25 2023-11-10 泰康保险集团股份有限公司 Processing system, equipment and method for hysteresis data in stream type calculation
CN112306904A (en) * 2020-11-20 2021-02-02 新华三大数据技术有限公司 Cache data disk refreshing method and device
CN112306904B (en) * 2020-11-20 2022-03-29 新华三大数据技术有限公司 Cache data disk refreshing method and device

Also Published As

Publication number Publication date
CN112559390A (en) 2021-03-26
CN107870874B (en) 2020-12-15
CN112559390B (en) 2023-06-06

Similar Documents

Publication Publication Date Title
CN107870874A (en) A kind of data write-in control method and storage device
CN102832975A (en) Data transmission method, data transmission device and terminal with touch screen
CN104065634B (en) Online game steal-number processing method and system
CN107885458A (en) A kind of method for sorting of disk fragmentses, terminal and computer-readable recording medium
CN107402783A (en) The management control method and user terminal of a kind of background application
CN106095489B (en) A kind of application control method and mobile terminal
CN107608861A (en) Cooling control method and device
CN106484326B (en) A kind of data transmission processing method and mobile terminal
CN106649735A (en) Log data recording method and apparatus
US20220058118A1 (en) Garbage Data Scrubbing Method, and Device
CN107678989A (en) UART and USB multiplex circuits and mobile terminal
CN106576123A (en) A method, an apparatus and an electronic device for controlling an electronic device
CN105930077A (en) Method and device for adjusting size of objects displayed by screens
CN106534288A (en) Data transmission method and mobile terminal
CN107766139A (en) Application management method and device
CN107317918A (en) Parameter setting method and related product
CN106793010A (en) A kind of method for network access and equipment
CN103793267B (en) The access method and device of queue
WO2021114357A1 (en) Application program optimization method, apparatus, storage medium, and electronic device
CN107066324A (en) A kind of control method and equipment of finger prints processing resource
CN105988715A (en) Data storage method and device
CN107066890A (en) A kind of method and device for handling and file being encrypted using obscuring
CN107480997A (en) A kind of method of mobile payment, terminal and storage medium
CN105302747B (en) A kind of memory starting control method and memory start control device
CN106657544A (en) Incoming call recording method and terminal equipment

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
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20220831

Address after: 611731 No. 1899, Xiyuan Avenue, high tech Zone (West District), Chengdu, Sichuan

Patentee after: Chengdu Huawei Technologies Co.,Ltd.

Address before: 611731 Qingshui River District, Chengdu hi tech Zone, Sichuan, China

Patentee before: HUAWEI DIGITAL TECHNOLOGIES (CHENG DU) Co.,Ltd.