CN103150232A - Storage snapshot creation method and device - Google Patents

Storage snapshot creation method and device Download PDF

Info

Publication number
CN103150232A
CN103150232A CN2013100428132A CN201310042813A CN103150232A CN 103150232 A CN103150232 A CN 103150232A CN 2013100428132 A CN2013100428132 A CN 2013100428132A CN 201310042813 A CN201310042813 A CN 201310042813A CN 103150232 A CN103150232 A CN 103150232A
Authority
CN
China
Prior art keywords
data
chinese ink
write
brush dipped
disk
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
CN2013100428132A
Other languages
Chinese (zh)
Other versions
CN103150232B (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.)
Inspur Beijing Electronic Information Industry Co Ltd
Original Assignee
Inspur Beijing Electronic Information Industry 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 Inspur Beijing Electronic Information Industry Co Ltd filed Critical Inspur Beijing Electronic Information Industry Co Ltd
Priority to CN201310042813.2A priority Critical patent/CN103150232B/en
Publication of CN103150232A publication Critical patent/CN103150232A/en
Application granted granted Critical
Publication of CN103150232B publication Critical patent/CN103150232B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Techniques For Improving Reliability Of Storages (AREA)
  • Memory System Of A Hierarchy Structure (AREA)

Abstract

The invention provides a storage snapshot creation method and device, which relate to the field of computer application and solve the problem that the snapshot data is inconsistent with the real-time data. The method comprises the following steps that a data brush in cache is written into a disk; and after the data brush is written into the disk, the snapshot of the data which is written into the disk is created. The technical scheme provided by the invention is applicable to the data recovery of storage equipment, and a snapshot creation mechanism which ensures data consistency is realized.

Description

Storage snapshot creation method and apparatus
Technical field
The present invention relates to computer application field, relate in particular to a kind of storage snapshot creation method and apparatus.
Background technology
When memory device generation application and trouble or file corruption, use snapshot can in time carry out data and recover, the state when data are reverted to snapshot generation time point.
Existing snapshot can not guarantee to store snapshot and use the consistance of data constantly, as database, a transaction is arranged, optimum should be the moment that transaction occurs to do snapshot, and snapshot of the prior art is regularly general or hand-guided creates, and can't satisfy the needs of database transaction not timing generation and real-time data memory.Like this, recover if need to carry out data, also can't obtain database transaction data constantly.In addition, when front end had read-write operation, also in the front end buffer memory, this partial data also can't add snapshot to some data, had affected the consistance of snapshot storage data and real time data.
Summary of the invention
The invention provides a kind of storage snapshot creation method and apparatus, solved the inconsistent problem of snapshot data and real time data.
A kind of storage snapshot creation method comprises:
Data in buffer memory are write with a brush dipped in Chinese ink into disk;
After data are write with a brush dipped in Chinese ink disk and completed, carry out snapshot creation to writing with a brush dipped in Chinese ink to the data of described disk.
Preferably, before the described step of data in buffer memory being write with a brush dipped in Chinese ink disk, also comprise:
Server identification database affairs;
When recognizing a certain Database Events of using constantly, that triggers client data cachedly writes with a brush dipped in Chinese ink operation, and the data of the client of this Database Events are write disk buffering.
Preferably, described server identification database affairs are specially:
Described server and database intelligent linkage, the operation of identification database, each is to the namely corresponding db transaction of the operation of database.
Preferably, described triggering client data cached write with a brush dipped in Chinese ink operation and is specially:
Server sends the data cached instruction of writing with a brush dipped in Chinese ink to client.
The present invention also provides a kind of storage snapshot creation device, comprising:
Write with a brush dipped in Chinese ink module, be used for the data of buffer memory are write with a brush dipped in Chinese ink into disk;
The snapshot creation module is used for after data are write with a brush dipped in Chinese ink disk and completed, and carries out snapshot creation to writing with a brush dipped in Chinese ink to the data of described disk.
Preferably, above-mentioned storage snapshot creation device also comprises:
Monitoring modular is used for the identification database affairs;
Write with a brush dipped in Chinese ink trigger module, be used for when recognizing a certain Database Events of using constantly, that triggers client data cachedly writes with a brush dipped in Chinese ink operation, and the data of the client of this Database Events are write disk buffering.
The invention provides a kind of storage snapshot creation method and apparatus, data in buffer memory are write with a brush dipped in Chinese ink into disk, after data are write with a brush dipped in Chinese ink disk and are completed, carry out snapshot creation to writing with a brush dipped in Chinese ink to the data of described disk, after writing disk, data create in real time snapshot, realize guaranteeing the snapshot creation mechanism of data consistency, solved the inconsistent problem of snapshot data and real time data.
Description of drawings
Fig. 1 is a kind of process flow diagram of storing the snapshot creation method that embodiments of the invention one provide;
Fig. 2 is a kind of structural representation of storing the snapshot creation device that embodiments of the invention two provide;
Fig. 3 is a kind of structural representation of storing the snapshot creation device that embodiments of the invention three provide.
Embodiment
Existing snapshot can not guarantee to store snapshot and use the consistance of data constantly, as database, a transaction is arranged, optimum should be the moment that transaction occurs to do snapshot, and snapshot of the prior art is regularly general or hand-guided creates, and can't satisfy the needs of database transaction not timing generation and real-time data memory.Like this, recover if need to carry out data, also can't obtain database transaction data constantly.In addition, when front end had read-write operation, also in the front end buffer memory, this partial data also can't add snapshot to some data, had affected the consistance of snapshot storage data and real time data.
In order to address the above problem, embodiments of the invention provide a kind of storage snapshot creation method and apparatus.Hereinafter in connection with accompanying drawing, embodiments of the invention are elaborated.Need to prove, in the situation that do not conflict, the embodiment in the application and the feature in embodiment be combination in any mutually.
At first by reference to the accompanying drawings, embodiments of the invention one are described.
The embodiment of the present invention provides a kind of storage snapshot creation method, uses flow process that the method completes the storage snapshot creation as shown in Figure 1, comprising:
Step 101, server identification database affairs;
In this step, can be mounted with on server and use the perception Agent, to guarantee the integrality of data.Server and database intelligent linkage carry out perception to db transaction, and be concrete, can detect the operation to database, to guarantee correctly to recognize some data transactions of using constantly (using the time of origin that refers to a concrete affairs point constantly).
Step 102, when recognizing a certain Database Events of using constantly, that triggers client data cachedly writes with a brush dipped in Chinese ink operation, and the data of the client of this Database Events are write disk buffering;
In this step, when server detected Database Events, server sent an instruction to client, and indication writes disk buffering with the data of the client of this Database Events.
Step 103, the data in buffer memory are write with a brush dipped in Chinese ink into disk;
In this step, the data in buffer memory are write with a brush dipped in Chinese ink disk, lack data cached protection when avoiding snapshot creation.Usually data when writing disk, first write data in buffer memory, then at asynchronous write disk sometime afterwards.
Step 104, after data are write with a brush dipped in Chinese ink disk and are completed, carry out snapshot creation to writing with a brush dipped in Chinese ink to the data of described disk.
Below in conjunction with accompanying drawing, embodiments of the invention two are described.
The embodiment of the present invention provides a kind of storage snapshot creation device, and its structure comprises as shown in Figure 2:
Write with a brush dipped in Chinese ink module 201, be used for the data of buffer memory are write with a brush dipped in Chinese ink into disk;
Snapshot creation module 202 is used for after data are write with a brush dipped in Chinese ink disk and completed, and carries out snapshot creation to writing with a brush dipped in Chinese ink to the data of described disk.
Preferably, described storage snapshot creation device also comprises:
Monitoring modular 203 is used for the identification database affairs;
Write with a brush dipped in Chinese ink trigger module 204, be used for when recognizing a certain Database Events of using constantly, that triggers client data cachedly writes with a brush dipped in Chinese ink operation, and the data of the client of this Database Events are write disk buffering.
Above-mentioned storage snapshot creation device can be integrated in server, completes corresponding function by server.
Below in conjunction with accompanying drawing, embodiments of the invention three are described.
The embodiment of the present invention provides a kind of storage snapshot creation device, and its structure comprises as shown in Figure 3:
Use sensing module 301, with the database application intelligent linkage, affairs are carried out perception, to guarantee correctly to recognize some db transactions constantly of using.
Cache flush program module 302 can adopt writing of data to postpone to write usually, at first data is write in buffer memory when writing data, and the refurbishing procedure module triggers buffer memory and writes the rear end disk operating, and data are write the rear end disk.
Snapshot creation module 303, data cached write disk after, create snapshot.
Described application sensing module 301 is connected with database application, in order to perception data storehouse transaction operation, a certain moment that can guarantee to get back to application.
Described cache flush program module 302 is connected with described application sensing module 301, for the treatment of the data in buffer memory are write with a brush dipped in Chinese ink the rear end disk.
Described snapshot creation module 303 is used for creating snapshot after the data of buffer memory are write with a brush dipped in Chinese ink the rear end.
Embodiments of the invention provide a kind of storage snapshot creation method and apparatus, data in buffer memory are write with a brush dipped in Chinese ink into disk, after data are write with a brush dipped in Chinese ink disk and are completed, carry out snapshot creation to writing with a brush dipped in Chinese ink to the data of described disk, after writing disk, data create in real time snapshot, realize guaranteeing the snapshot creation mechanism of data consistency, solved the inconsistent problem of snapshot data and real time data.
The all or part of step that one of ordinary skill in the art will appreciate that above-described embodiment can realize with the computer program flow process, described computer program can be stored in a computer-readable recording medium, described computer program (as system, unit, device etc.) on corresponding hardware platform is carried out, when carrying out, comprise step of embodiment of the method one or a combination set of.
Alternatively, all or part of step of above-described embodiment also can realize with integrated circuit, and these steps can be made into respectively integrated circuit modules one by one, perhaps a plurality of modules in them or step is made into the single integrated circuit module and realizes.Like this, the present invention is not restricted to any specific hardware and software combination.
Each device/functional module/functional unit in above-described embodiment can adopt general calculation element to realize, they can concentrate on single calculation element, also can be distributed on the network that a plurality of calculation elements form.
Each device/functional module/functional unit in above-described embodiment is realized with the form of software function module and during as independently production marketing or use, can be stored in a computer read/write memory medium.The above-mentioned computer read/write memory medium of mentioning can be ROM (read-only memory), disk or CD etc.
Anyly be familiar with those skilled in the art in the technical scope that the present invention discloses, can expect easily changing or replacing, within all should being encompassed in protection scope of the present invention.Therefore, protection scope of the present invention should be as the criterion with the described protection domain of claim.

Claims (6)

1. a storage snapshot creation method, is characterized in that, comprising:
Data in buffer memory are write with a brush dipped in Chinese ink into disk;
After data are write with a brush dipped in Chinese ink disk and completed, carry out snapshot creation to writing with a brush dipped in Chinese ink to the data of described disk.
2. storage snapshot creation method according to claim 1, is characterized in that, before the described step of data in buffer memory being write with a brush dipped in Chinese ink disk, also comprises:
Server identification database affairs;
When recognizing a certain Database Events of using constantly, that triggers client data cachedly writes with a brush dipped in Chinese ink operation, and the data of the client of this Database Events are write disk buffering.
3. storage snapshot creation method according to claim 2, is characterized in that, described server identification database affairs are specially:
Described server and database intelligent linkage, the operation of identification database, each is to the namely corresponding db transaction of the operation of database.
4. storage snapshot creation method according to claim 2, is characterized in that, described triggering client data cached write with a brush dipped in Chinese ink operation and be specially:
Server sends the data cached instruction of writing with a brush dipped in Chinese ink to client.
5. a storage snapshot creation device, is characterized in that, comprising:
Write with a brush dipped in Chinese ink module, be used for the data of buffer memory are write with a brush dipped in Chinese ink into disk;
The snapshot creation module is used for after data are write with a brush dipped in Chinese ink disk and completed, and carries out snapshot creation to writing with a brush dipped in Chinese ink to the data of described disk.
6. storage snapshot creation device according to claim 5, is characterized in that, this device also comprises:
Monitoring modular is used for the identification database affairs;
Write with a brush dipped in Chinese ink trigger module, be used for when recognizing a certain Database Events of using constantly, that triggers client data cachedly writes with a brush dipped in Chinese ink operation, and the data of the client of this Database Events are write disk buffering.
CN201310042813.2A 2013-02-01 2013-02-01 Store snapshot creation method and device Active CN103150232B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201310042813.2A CN103150232B (en) 2013-02-01 2013-02-01 Store snapshot creation method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310042813.2A CN103150232B (en) 2013-02-01 2013-02-01 Store snapshot creation method and device

Publications (2)

Publication Number Publication Date
CN103150232A true CN103150232A (en) 2013-06-12
CN103150232B CN103150232B (en) 2016-06-01

Family

ID=48548329

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310042813.2A Active CN103150232B (en) 2013-02-01 2013-02-01 Store snapshot creation method and device

Country Status (1)

Country Link
CN (1) CN103150232B (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104866245A (en) * 2015-06-03 2015-08-26 北京麓柏科技有限公司 Method and device for synchronous snapshot between cache equipment and storage system
CN106919471A (en) * 2015-12-25 2017-07-04 中国电信股份有限公司 For the method and system that snapshot is set up
CN110990379A (en) * 2019-11-24 2020-04-10 北京浪潮数据技术有限公司 DB2 database disaster tolerance and control method and system
CN111209346A (en) * 2020-04-24 2020-05-29 腾讯科技(深圳)有限公司 Block chain data archiving method and device and computer readable storage medium
CN111506453A (en) * 2019-01-31 2020-08-07 阿里巴巴集团控股有限公司 Disk snapshot creating method, device, system and storage medium

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1567262A (en) * 2003-06-10 2005-01-19 联想(北京)有限公司 On-line data backup method based on data volume snapshot
US20070005914A1 (en) * 2005-06-29 2007-01-04 Thompson Dianne C Backup and restore operations using a single snapshot driven by a server job request
CN101316184A (en) * 2007-06-01 2008-12-03 华为技术有限公司 Disaster tolerance switching method, system and device
CN101359301A (en) * 2008-08-19 2009-02-04 成都市华为赛门铁克科技有限公司 Auto snapshot method and device
CN101807170A (en) * 2009-02-17 2010-08-18 英业达集团(天津)电子技术有限公司 Management method of cache of storage area network
CN101968755A (en) * 2010-11-04 2011-02-09 清华大学 Application load change adaptive snapshot generating method
CN102043687A (en) * 2009-10-20 2011-05-04 杭州华三通信技术有限公司 Copy on first write device for realizing data snapshot and control method
CN102819615A (en) * 2012-08-30 2012-12-12 天津火星科技有限公司 Database continuous data protection method based on application snapshot
CN102843396A (en) * 2011-06-22 2012-12-26 中兴通讯股份有限公司 Data writing and reading method and device in distributed caching system

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1567262A (en) * 2003-06-10 2005-01-19 联想(北京)有限公司 On-line data backup method based on data volume snapshot
US20070005914A1 (en) * 2005-06-29 2007-01-04 Thompson Dianne C Backup and restore operations using a single snapshot driven by a server job request
CN101316184A (en) * 2007-06-01 2008-12-03 华为技术有限公司 Disaster tolerance switching method, system and device
CN101359301A (en) * 2008-08-19 2009-02-04 成都市华为赛门铁克科技有限公司 Auto snapshot method and device
CN101807170A (en) * 2009-02-17 2010-08-18 英业达集团(天津)电子技术有限公司 Management method of cache of storage area network
CN102043687A (en) * 2009-10-20 2011-05-04 杭州华三通信技术有限公司 Copy on first write device for realizing data snapshot and control method
CN101968755A (en) * 2010-11-04 2011-02-09 清华大学 Application load change adaptive snapshot generating method
CN102843396A (en) * 2011-06-22 2012-12-26 中兴通讯股份有限公司 Data writing and reading method and device in distributed caching system
CN102819615A (en) * 2012-08-30 2012-12-12 天津火星科技有限公司 Database continuous data protection method based on application snapshot

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104866245A (en) * 2015-06-03 2015-08-26 北京麓柏科技有限公司 Method and device for synchronous snapshot between cache equipment and storage system
CN104866245B (en) * 2015-06-03 2018-09-14 马鞍山创久科技股份有限公司 The method and apparatus of synchronisation snapshot between buffer memory device and storage system
CN106919471A (en) * 2015-12-25 2017-07-04 中国电信股份有限公司 For the method and system that snapshot is set up
CN106919471B (en) * 2015-12-25 2020-03-20 中国电信股份有限公司 Method and system for snapshot creation
CN111506453A (en) * 2019-01-31 2020-08-07 阿里巴巴集团控股有限公司 Disk snapshot creating method, device, system and storage medium
CN111506453B (en) * 2019-01-31 2023-06-16 阿里巴巴集团控股有限公司 Disk snapshot creation method, device, system and storage medium
CN110990379A (en) * 2019-11-24 2020-04-10 北京浪潮数据技术有限公司 DB2 database disaster tolerance and control method and system
CN110990379B (en) * 2019-11-24 2022-06-17 北京浪潮数据技术有限公司 DB2 database disaster tolerance and control method and system
CN111209346A (en) * 2020-04-24 2020-05-29 腾讯科技(深圳)有限公司 Block chain data archiving method and device and computer readable storage medium
CN111209346B (en) * 2020-04-24 2020-07-28 腾讯科技(深圳)有限公司 Block chain data archiving method and device and computer readable storage medium

Also Published As

Publication number Publication date
CN103150232B (en) 2016-06-01

Similar Documents

Publication Publication Date Title
US8689047B2 (en) Virtual disk replication using log files
CN106471478B (en) Device controller and method for performing multiple write transactions atomically within a non-volatile data storage device
CN106354582B (en) A kind of continuous data protection method
CN103150232A (en) Storage snapshot creation method and device
CN102567146B (en) Log backup method and device and smart card
US10423589B2 (en) Quick initialization of data regions in a distributed storage system
CN106557145A (en) Circuit breaking protective system and its method
JP2007507811A5 (en)
CN103765373A (en) Data storage method, data storage device, and storage equipment
CN104166605A (en) Data backup method and system based on incremental data files
CN102347866A (en) Data configuration system and method in network management
CN105589887A (en) Data processing method for distributed file system and distributed file system
US8880834B2 (en) Low latency and persistent data storage
CN105138426B (en) A kind of business data method for protecting consistency and device based on snapshot
CN101937378B (en) Method for carrying out back-up protection on data of storage equipment and computer system
CN111240879B (en) SAS card firmware log collection method, system, device and storage medium
CN115599601A (en) Volume backup method and system based on CBT (compact disc-based transport table) of disk
CN108874574A (en) A kind of garbage reclamation processing method and relevant apparatus
CN101901174B (en) Method for enhancing reliability of program of multi-replica contrast mechanism based on code segment
CN103176867A (en) Fast file differential backup method
CN104699550A (en) Error recovery method based on lockstep architecture
CN105068760B (en) Date storage method, data storage device and storage device
CN110198331A (en) A kind of method and system of synchrodata
CN104462403A (en) File intercepting method and device
US10949102B2 (en) Leveraging snapshot for time series pattern analysis prediction

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