CN104461940A - Efficient caching and delayed writing method for network virtual disk client side - Google Patents
Efficient caching and delayed writing method for network virtual disk client side Download PDFInfo
- Publication number
- CN104461940A CN104461940A CN201410788824.XA CN201410788824A CN104461940A CN 104461940 A CN104461940 A CN 104461940A CN 201410788824 A CN201410788824 A CN 201410788824A CN 104461940 A CN104461940 A CN 104461940A
- Authority
- CN
- China
- Prior art keywords
- disk
- data
- write
- network virtual
- sector
- 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
Landscapes
- Memory System Of A Hierarchy Structure (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
The invention discloses an efficient caching and delayed writing method for a network virtual disk client side. The efficient caching and delayed writing method has the advantages that multiple sectors are read for a reading request, partial transmission data quantity is increased slightly while transmission frequency is reduced effectively, and negative factors of network delay are avoided; for a writing request, to-be-written sector data are written into a local cache before returning, and the data are not really sent to a server side to generate a delay combination effect, so that the negative factors of network delay are avoided, and a network virtual disk with good performance, high stability and high adaptability can be achieved.
Description
Technical field
The present invention relates to field of data storage, especially a kind of method to network virtual magnetic disk read-write on client side.
Background technology
The essence of network virtual magnetic disk system is exactly utilize disk drive technology, in an operating system the disk of virtual " truly ", all read-write requests of interception disk, is redirected to background server and stores, realize the virtual of storage by network remote.What virtual disk driver was simulated in client operating system is block device, all request of access all like for the same sector read-write requests of physical disk in fact, see at this level, only have reading and writing two kinds operation, sector number and the sector number of just each request are different.Noticing that operating system is to the read-write of disk, is always least unit with sector.
In the realization of network virtual magnetic disk system, what be difficult to most to overcome is efficiency, we know, the read or write speed of general USB flash disk is at 5 ~ 15MB/S, the read or write speed of PC hard disk is generally at 50 ~ 100MB/S, server S CSI disk can reach 300 ~ 500MB/S, network virtual magnetic disk is because need to be accessed by network remote, the efficiency of network has just become with postponing the maximum bottleneck restricting whole system, such as, under 100000000 net environment, the theoretical upper values of Internet Transmission is 12.5MB/S, in actual use, the highest general 8-10MB/S or lower of can only reaching, under such network condition, the efficiency of network virtual magnetic disk will be very low, more many all slowly than common U disk, substantially unavailable.
Summary of the invention
The object of the invention is the deficiency existed for prior art, a kind of network virtual magnetic disk client high-efficiency buffer memory is provided and postpones wiring method, for network bandwidth deficiency or unstable network, can realize that there is good performance, stability and adaptive network virtual magnetic disk.
For achieving the above object, network virtual magnetic disk client high-efficiency buffer memory of the present invention and delay wiring method can adopt following technical scheme:
A kind of network virtual magnetic disk client high-efficiency buffer memory and delay wiring method, comprising:
For read request, when needs read certain disk sector, some sectors that always order pre-read is follow-up backward, and by the data in the disk sector of all readings all stored in local cache, when again reading sector, search in present local cache, if having found, just directly return, no longer pass through Internet Transmission;
For write request, just return after the sector data write local cache that will write, simultaneously, regular supervision scanning local cache, by the data variation extracting section in buffer memory out, then pack, compress, be transferred to server end, by the finger daemon of server, data are really written in the image file of disk.
Compared with prior art, network virtual magnetic disk client high-efficiency buffer memory and to postpone to pre-read the sector hit rate of buffer memory for read request in wiring method quite high in the present invention, although increase slightly portion transfers data amount, but effectively decrease the frequency of transmission, evade the unfavorable factor of network delay; And for write request, just return after the sector data write local cache that will write, really be not sent to service end thus the amalgamation that is delayed, when data accumulation to certain amount or etc. really write disk again after time to be specified thus improve write performance, the unfavorable factor of circumvent network time delay, can realize having good performance, stability and adaptive network virtual magnetic disk.
Accompanying drawing explanation
Fig. 1 is network virtual magnetic disk client high-efficiency buffer memory of the present invention and the application schematic diagram postponing wiring method.
Embodiment
Refer to shown in Fig. 1, the present invention discloses a kind of network virtual magnetic disk client high-efficiency buffer memory and postpones wiring method, comprising:
For read request, when needs read certain disk sector, some sectors (being generally decided to be 64K byte, supposing that sector-size is 4k, is exactly 16 sectors) that always order pre-read is follow-up backward, and by the data in the disk sector of all readings all stored in local cache, when again reading sector, search in present local cache, if having found, just directly return, no longer pass through Internet Transmission; According to reality test, the sector hit rate pre-reading buffer memory is quite high, although increase slightly portion transfers data amount, effectively decreases the frequency of transmission, has evaded the unfavorable factor of network delay.
For write request, just return after the sector data write local cache that will write, simultaneously, regular supervision scanning local cache, by the data variation extracting section in buffer memory out, then pack, compress, be transferred to server end, by the finger daemon of server, data are really written in the image file of disk.
In write request, the large-scale address space that virtual disk needs is carried out sectional management, as, be a management unit with 64M byte, physical file set up by disk, and utilizes the File Mapping API of operating system that physical file is mapped to internal memory, access fast to provide; The structure of buffer unit is expanded, increases the record of unique and strictly increasing write mark stamp, and the interrecord structure such as sectors status flag.For in write request, the process aspect of data, adopts QuickLZ algoritic module, reads and writes the very uneven scene of this packing density done good adaptation and optimization for disk block.
In the present invention, the efficient caching technology of proposition and the delay write algorithm of optimization, for the network bandwidth, not enough or unstable network, can realize having good performance, stability and adaptive network virtual magnetic disk product.
Claims (3)
1. network virtual magnetic disk client high-efficiency buffer memory and a delay wiring method, is characterized in that, comprising:
For read request, when needs read certain disk sector, some sectors that always order pre-read is follow-up backward, and by the data in the disk sector of all readings all stored in local cache, when again reading sector, search in present local cache, if having found, just directly return, no longer pass through Internet Transmission;
For write request, just return after the sector data write local cache that will write, simultaneously, regular supervision scanning local cache, by the data variation extracting section in buffer memory out, then pack, compress, be transferred to server end, by the finger daemon of server, data are really written in the image file of disk.
2. network virtual magnetic disk client high-efficiency buffer memory according to claim 1 and delay wiring method, it is characterized in that: in write request, the large-scale address space that virtual disk needs is carried out sectional management, physical file set up by disk, and utilize the File Mapping API of operating system that physical file is mapped to internal memory, access fast to provide;
The structure of buffer unit is expanded, increases the record of unique and strictly increasing write mark stamp, and the interrecord structure such as sectors status flag.
3. network virtual magnetic disk client high-efficiency buffer memory according to claim 2 and delay wiring method, is characterized in that: in write request, the process aspect of data, adopt QuickLZ algoritic module.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410788824.XA CN104461940A (en) | 2014-12-17 | 2014-12-17 | Efficient caching and delayed writing method for network virtual disk client side |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410788824.XA CN104461940A (en) | 2014-12-17 | 2014-12-17 | Efficient caching and delayed writing method for network virtual disk client side |
Publications (1)
Publication Number | Publication Date |
---|---|
CN104461940A true CN104461940A (en) | 2015-03-25 |
Family
ID=52908026
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201410788824.XA Pending CN104461940A (en) | 2014-12-17 | 2014-12-17 | Efficient caching and delayed writing method for network virtual disk client side |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN104461940A (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106406981A (en) * | 2016-09-18 | 2017-02-15 | 深圳市深信服电子科技有限公司 | Disk data reading/writing method and virtual machine monitor |
CN108628550A (en) * | 2018-04-28 | 2018-10-09 | 深信服科技股份有限公司 | A kind of method, apparatus and system of reading disk mapped file |
CN111045604A (en) * | 2019-12-11 | 2020-04-21 | 苏州浪潮智能科技有限公司 | Small file read-write acceleration method and device based on NVRAM |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20070050761A1 (en) * | 2005-08-30 | 2007-03-01 | Microsoft Corporation | Distributed caching of files in a network |
CN101419535A (en) * | 2008-11-19 | 2009-04-29 | 北京航空航天大学 | Distributed virtual magnetic disc system of virtual machine |
CN101763226A (en) * | 2010-01-19 | 2010-06-30 | 北京航空航天大学 | Cache method for virtual storage devices |
CN101996051A (en) * | 2009-08-25 | 2011-03-30 | 联想(北京)有限公司 | Virtual disk system, virtual disk implementation method and terminal equipment |
-
2014
- 2014-12-17 CN CN201410788824.XA patent/CN104461940A/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20070050761A1 (en) * | 2005-08-30 | 2007-03-01 | Microsoft Corporation | Distributed caching of files in a network |
CN101419535A (en) * | 2008-11-19 | 2009-04-29 | 北京航空航天大学 | Distributed virtual magnetic disc system of virtual machine |
CN101996051A (en) * | 2009-08-25 | 2011-03-30 | 联想(北京)有限公司 | Virtual disk system, virtual disk implementation method and terminal equipment |
CN101763226A (en) * | 2010-01-19 | 2010-06-30 | 北京航空航天大学 | Cache method for virtual storage devices |
Non-Patent Citations (1)
Title |
---|
任婉: "Windows API中的文件映射应用", 《河南科技学院学报(自然科学版)》 * |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106406981A (en) * | 2016-09-18 | 2017-02-15 | 深圳市深信服电子科技有限公司 | Disk data reading/writing method and virtual machine monitor |
CN108628550A (en) * | 2018-04-28 | 2018-10-09 | 深信服科技股份有限公司 | A kind of method, apparatus and system of reading disk mapped file |
CN108628550B (en) * | 2018-04-28 | 2022-02-22 | 深信服科技股份有限公司 | Method, device and system for reading disk mapping file |
CN111045604A (en) * | 2019-12-11 | 2020-04-21 | 苏州浪潮智能科技有限公司 | Small file read-write acceleration method and device based on NVRAM |
CN111045604B (en) * | 2019-12-11 | 2022-11-01 | 苏州浪潮智能科技有限公司 | Small file read-write acceleration method and device based on NVRAM |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US9058112B2 (en) | Retrieving data in a storage system using thin provisioning | |
CN102760101B (en) | SSD-based (Solid State Disk) cache management method and system | |
US8751725B1 (en) | Hybrid storage aggregate | |
US9069680B2 (en) | Methods and systems for determining a cache size for a storage system | |
US10282286B2 (en) | Address mapping using a data unit type that is variable | |
US8793466B2 (en) | Efficient data object storage and retrieval | |
Mao et al. | POD: Performance oriented I/O deduplication for primary storage systems in the cloud | |
WO2018019119A1 (en) | Method and device for dynamic partial-parallel data layout for continuous data storage | |
CN102609361B (en) | Method and device for transferring storage data of virtual machine | |
US20080126684A1 (en) | Caching method for nand flash translation layer | |
CN105426127A (en) | File storage method and apparatus for distributed cluster system | |
CN108595349B (en) | Address translation method and device for mass storage device | |
CN103399823B (en) | The storage means of business datum, equipment and system | |
CN107562644B (en) | Compression method of solid state disk mapping table | |
CN113467705B (en) | Enhanced reading of data chunks | |
TWI584120B (en) | Method and system for dynamically adaptive caching | |
US9946463B2 (en) | Compression of indirection tables | |
KR20170010810A (en) | Method, device and user equipment for reading/writing data in nand flash | |
CN104461940A (en) | Efficient caching and delayed writing method for network virtual disk client side | |
WO2014153931A1 (en) | File storage method and device, access client and metadata server system | |
CN115826882B (en) | Storage method, device, equipment and storage medium | |
CN106557277B (en) | The reading method and device of disk array | |
CN103491124A (en) | Method for processing multimedia message data and distributed cache system | |
JP5924482B2 (en) | Storage device | |
US10642494B2 (en) | Method, electronic device and computer program product for data processing |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20150325 |
|
RJ01 | Rejection of invention patent application after publication |