CN106933704A - A kind of backup method and device - Google Patents
A kind of backup method and device Download PDFInfo
- Publication number
- CN106933704A CN106933704A CN201511028916.9A CN201511028916A CN106933704A CN 106933704 A CN106933704 A CN 106933704A CN 201511028916 A CN201511028916 A CN 201511028916A CN 106933704 A CN106933704 A CN 106933704A
- Authority
- CN
- China
- Prior art keywords
- file
- backup
- data
- backup command
- command
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/07—Responding to the occurrence of a fault, e.g. fault tolerance
- G06F11/14—Error detection or correction of the data by redundancy in operation
- G06F11/1402—Saving, restoring, recovering or retrying
- G06F11/1446—Point-in-time backing up or restoration of persistent data
- G06F11/1448—Management of the data involved in backup or backup restore
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/07—Responding to the occurrence of a fault, e.g. fault tolerance
- G06F11/14—Error detection or correction of the data by redundancy in operation
- G06F11/1402—Saving, restoring, recovering or retrying
- G06F11/1446—Point-in-time backing up or restoration of persistent data
- G06F11/1458—Management of the backup or restore process
- G06F11/1461—Backup scheduling policy
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Quality & Reliability (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
The embodiment of the invention discloses a kind of backup method and device, wherein, backup method includes:Backup command is obtained, backup command is used to indicate the first file that will be currently running to be backed up;According to backup command, stopping is operated to the first file;When completion when stopping operation, starts to back up the corresponding data of the first file to the first file;When data backup corresponding to the first file is completed, recover the operation of the first file, to proceed the operation to the first file.
Description
Technical field
The present invention relates to computer realm, more particularly to a kind of backup method and device.
Background technology
In order in the case where file, loss of data or damaging, protect data from unexpected loss,
Generally the data such as file, system are replicated to realize data protection using the method for backup.
Existing backup method includes two kinds, and one kind is cold standby, i.e. offline backup, refers in closing system
And the data backup carried out under the unrenewable situation of system;Another kind is Hot Spare, refers to that system is in
Normal operation simultaneously constantly carries out the data backup carried out under the situation of data read-write operation.
However, existing backup method has the disadvantage that:
1st, cold standby can cause the interruption of system data business due to needing closing system, reduce system fortune
Capable real-time.
2nd, Hot Spare due in backup procedure file system still operate and produce corresponding read-write being written and read
Data, these data are not only easily damaged or lose in backup procedure, also result in the data letter for backing up out
Cease inconsistent with former data message.
The content of the invention
In order to solve the above technical problems, the embodiment of the present invention is expected to provide a kind of backup method, disclosure satisfy that
Backup is realized in the state of start, and the data message for backing up out meets uniformity with former data message.
The technical proposal of the invention is realized in this way:
In a first aspect, the embodiment of the present invention provides a kind of backup method, including:Obtain backup command, backup
The first file for indicating to be currently running is ordered to be backed up;According to backup command, stop to the first text
Part is operated;When completion when stopping operation, starts to enter the corresponding data of the first file to the first file
Row backup;When data backup corresponding to the first file is completed, recover the operation of the first file, to continue
Carry out the operation to the first file.
Further, stop operating the first file, including:It is defeated that stopping carries out input to the first file
Go out operation.
Further, the operation of the first file is recovered, including:Recover the input-output operation to the first file.
Further, before backup command is obtained, also include:Set up data exchange path, data exchange
Path is used for transmission backup order.
Further, backup command is obtained to specifically include:Backup command is obtained by data exchange path.
Second aspect, the embodiment of the present invention provides a kind of back-up device, including:Acquiring unit, stop element,
Backup units and recovery unit, wherein:Acquiring unit, for obtaining backup command, backup command is used to refer to
Show that the first file that will be currently running is backed up;Stop element, for the backup obtained according to acquiring unit
Order, stopping is operated to the first file;Backup units, for being completed to the first file when stop element
When stopping operation, start to back up the corresponding data of the first file;Recovery unit, for when backup
When unit completes data backup corresponding to the first file, recover the operation of the first file, it is right to proceed
The operation of the first file.
Further, stop element, specifically for:According to the backup command that acquiring unit is obtained, it is right to stop
First file carries out input-output operation.
Further, recovery unit, specifically for:When backup units are completed to the corresponding data of the first file
During backup, recover the input-output operation to the first file.
Further, device also includes setting up unit, for before acquiring unit obtains backup command, building
Vertical data exchange path, data exchange path is used for transmission backup order.
Further, acquiring unit, specifically for:The data exchange path set up by setting up unit is obtained
Backup command.
A kind of backup method and device are the embodiment of the invention provides, by obtaining backup command, backup command
The first file for indicating to be currently running is backed up;According to backup command, stopping is entered to the first file
Row operation;When completing to the first file when stopping operation, start to carry out the corresponding data of the first file standby
Part;When data backup corresponding to the first file is completed, recover the operation of the first file, to proceed
Operation to the first file.Using above-mentioned technic relization scheme, virtual machine is met real in the state of start
Now back up, ensured the data message and the uniformity of former data message for backing up out, improve system backup
Safety and reliability.
Brief description of the drawings
Fig. 1 is a kind of schematic flow sheet one of backup method provided in an embodiment of the present invention;
Fig. 2 is a kind of schematic flow sheet two of backup method provided in an embodiment of the present invention;
Fig. 3 is a kind of schematic flow sheet three of backup method provided in an embodiment of the present invention;
Fig. 4 is a kind of structural representation one of back-up device provided in an embodiment of the present invention;
Fig. 5 is a kind of structural representation two of back-up device provided in an embodiment of the present invention.
Specific embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is carried out clearly
Chu, it is fully described by.
A kind of backup method provided in an embodiment of the present invention is applied on back-up device, wherein, back-up device peace
On with file system, application program, the terminal of database data, backup method is used in terminal
The partial data being currently running in terminal is backed up under open state.
Embodiment one
Fig. 1 is a kind of schematic flow sheet one of backup method provided in an embodiment of the present invention, and the method includes:
Step 101:Backup command is obtained, backup command is carried out for the first file for indicating to be currently running
Backup;
Wherein, the first file, is the partial document system or application program being currently running in terminal.For example,
First file can be the part or all of file of the virtual machine being currently running in terminal.As can be seen that right
When the first file being currently running is operated, for example when being backed up to the corresponding data of the first file, no
The operation of the alternative document in addition to the first file being currently running in terminal can be influenceed.That is, this hair
The backup method that bright embodiment is provided, is the data backup carried out under open state in system, i.e. this hair
The backup method that bright embodiment is provided is a kind of heat backup method.
Exemplarily, Fig. 2 is a kind of schematic flow sheet two of backup method provided in an embodiment of the present invention,
Before obtaining backup command, the method comprising the steps of 100.Specially:
Step 100:Data exchange path is set up, data exchange path is used for transmission backup order.
For example, if the first file being currently running is the file on virtual machine, then can pass through
Guest-agent components set up data exchange path.Wherein, guest-agent is one and operates in virtual machine
Internal application program, the purpose is to realize the interactive communication between host and virtual machine.Specifically,
Guest-agent components can simulate a serial equipment in virtual machine, and a set is provided in host
Word socket interfaces are connect, place is realized using the socket interfaces in the serial equipment and host in virtual machine
Data exchange path between main frame and virtual machine.
Preferably, backup command is obtained to specifically include:Backup command is obtained by data exchange path.
Step 102:According to backup command, stopping is operated to the first file;
Stopping is operated to the first file, including is stopped carrying out the first file reading and writing data, access, divided
Class, merger and sequence etc. are operated.That is, freezing to the first file so that with the first file pair
The data answered no longer produce change, so as to ensure the uniformity of the data message and former data message for backing up out.
In actual applications, it is possible to use guest-agent stops operating the first file, that is, utilize
Guest-agent realizes freezing the first file.It should be noted that stopping is operated to the first file
Implementation also include other modes, the embodiment of the present invention does not do specific restriction to this.
Exemplarily, stop operating the first file, including:It is defeated that stopping carries out input to the first file
Go out operation.
Step 103:When completion when stopping operation, starts data corresponding to the first file to the first file
Backed up;
Step 104:When data backup corresponding to the first file is completed, recover the operation of the first file,
To proceed the operation to the first file.
When data backup corresponding to the first file is completed, by recovering the operation of the first file, i.e., to the
One file is thawed, so as to be backed up to the corresponding data of the first file in the state of being now turned in fact.
In actual applications, it is possible to use guest-agent recovers the operation of the first file, that is, utilize
Guest-agent realizes the defrosting to the first file.It should be noted that recovering the realization of the first running paper
Mode also includes other modes, and the embodiment of the present invention does not do specific restriction to this.
Exemplarily, the operation of the first file is recovered, including:Recover the input-output operation to the first file.
Embodiment two
Fig. 3 is a kind of schematic flow sheet three of backup method provided in an embodiment of the present invention, and it is right that the method is used for
Virtual machine is backed up, including:
Step 301:Data exchange path is set up by guest-agent components;
Step 302:Host passes through data exchange path by backup command using the virtualization manager of itself
Send to back-up device, wherein, backup command is used to indicate the first file that will be currently running to be backed up;
Wherein, host is the computer for installing virtual machine, and host includes virtualization manager.Wherein,
Back-up device may be mounted on computer, it is also possible to install on a virtual machine.
Step 303:Back-up device carries out input-output operation according to backup command, stopping to the first file;
Step 304:When completing to the first file when stopping operation, back-up device starts to the first file pair
The data answered are backed up;
Step 305:When data backup corresponding to the first file is completed, back-up device recovers the first file
Operation.
In sum, a kind of backup method is the embodiment of the invention provides, by obtaining backup command, backup
The first file for indicating to be currently running is ordered to be backed up;According to backup command, stop to the first text
Part is operated;When completion when stopping operation, starts to enter the corresponding data of the first file to the first file
Row backup;When data backup corresponding to the first file is completed, recover the operation of the first file, to continue
Carry out the operation to the first file.Using above-mentioned technic relization scheme, state of the virtual machine in start is met
It is lower to realize backup, the data message and the uniformity of former data message for backing up out have been ensured, improve system standby
The safety and reliability of part.
Embodiment three
Fig. 4 is a kind of structural representation one of back-up device provided in an embodiment of the present invention, with reference to shown in Fig. 4,
The device includes:Acquiring unit 401, stop element 402, backup units 403 and recovery unit 404, its
In:
Acquiring unit 401, for obtaining backup command, backup command is used for indicate to be currently running first
File is backed up;
Stop element 402, for the backup command obtained according to acquiring unit 401, stops to the first file
Operated;
Backup units 403, for completing to the first file when stopping operation when stop element 402, start
The corresponding data of first file are backed up;
Recovery unit 404, for when backup units 403 complete data backup corresponding to the first file,
Recover the operation of the first file, to proceed the operation to the first file.
Further, stop element 402, specifically for:According to the backup command that acquiring unit 401 is obtained,
Stopping carries out input-output operation to the first file.
Further, recovery unit 404, specifically for:When backup units 403 are completed to the first file pair
During the data backup answered, recover the input-output operation to the first file.
Further, Fig. 5 is a kind of structural representation two of back-up device provided in an embodiment of the present invention, ginseng
Examine shown in Fig. 5, device also include set up unit 405, for acquiring unit 401 obtain backup command it
Before, data exchange path is set up, data exchange path is used for transmission backup order.
Further, acquiring unit 401, specifically for:By setting up the data exchange path that unit 405 is set up
Obtain backup command.
In actual applications, above-mentioned acquiring unit 401, stop element 402, backup units 403, recovery are single
First 404 can be realized with unit 405 is set up by the processor in terminal, specially central processing unit
(CPU), microprocessor (MPU), digital signal processor (DSP) or field programmable gate array (FPGA)
Deng realization, also including the memory in terminal, the memory can be connected by system bus with processor,
Wherein, memory is used to store executable program code, and the program code includes computer-managed instruction, deposits
Reservoir may include high-speed RAM memory, it is also possible to also including nonvolatile memory, for example, at least
One magnetic disk storage.
It should be understood by those skilled in the art that, embodiments of the invention can be provided as method, system or meter
Calculation machine program product.Therefore, the present invention can using hardware embodiment, software implementation or combine software and
The form of the embodiment of hardware aspect.And, the present invention can be used and wherein include calculating at one or more
Computer-usable storage medium (the including but not limited to magnetic disk storage and optical storage of machine usable program code
Device etc.) on implement computer program product form.
The present invention is with reference to method according to embodiments of the present invention, equipment (system) and computer program product
Flow chart and/or block diagram describe.It should be understood that flow chart and/or side can be realized by computer program instructions
The knot of flow in each flow and/or square frame and flow chart and/or block diagram and/or square frame in block diagram
Close.Can provide these computer program instructions to all-purpose computer, special-purpose computer, Embedded Processor or
The processor of other programmable data processing devices is producing a machine so that by computer or other can
The instruction of the computing device of programming data processing equipment is produced for realizing in one flow of flow chart or multiple
The device of the function of being specified in one square frame of flow and/or block diagram or multiple square frames.
These computer program instructions may be alternatively stored in can guide computer or other programmable data processing devices
In the computer-readable memory for working in a specific way so that storage is in the computer-readable memory
Instruction produces the manufacture for including instruction, and the instruction is realized in one flow of flow chart or multiple flows and/or side
The function of being specified in one square frame of block diagram or multiple square frames.
These computer program instructions can be also loaded into computer or other programmable data processing devices, made
Obtain and series of operation steps is performed on computer or other programmable devices to produce computer implemented place
Reason, so as to the instruction performed on computer or other programmable devices is provided for realizing in flow chart one
The step of function of being specified in flow or multiple one square frame of flow and/or block diagram or multiple square frames.
The above, only presently preferred embodiments of the present invention is not intended to limit protection model of the invention
Enclose.
Claims (10)
1. a kind of backup method, it is characterised in that including:
Backup command is obtained, the backup command is used to indicate the first file that will be currently running to be backed up;
According to the backup command, stopping is operated to first file;
When completion when stopping operation, starts to enter the corresponding data of first file to first file
Row backup;
When data backup corresponding to first file is completed, recover the operation of first file, with
Proceed the operation to first file.
2. method according to claim 1, it is characterised in that the stopping is entered to first file
Row operation, including:
Stopping carries out input-output operation to first file.
3. method according to claim 2, it is characterised in that the fortune of recovery first file
OK, including:
Recover the input-output operation to first file.
4. according to any described methods of claim 1-3, it is characterised in that before backup command is obtained,
Also include:Data exchange path is set up, the data exchange path is used to transmit the backup command.
5. method according to claim 4, it is characterised in that the acquisition backup command is specifically included:
The backup command is obtained by the data exchange path.
6. a kind of back-up device, it is characterised in that including:Acquiring unit, stop element, backup units and
Recovery unit, wherein:
The acquiring unit, for obtaining backup command, the backup command is used to indicating to be currently running
First file is backed up;
The stop element, for the backup command obtained according to the acquiring unit, stops to described
First file is operated;
The backup units, for completing to first file when stopping operation when the stop element,
Start to back up the corresponding data of first file;
The recovery unit, for being completed to the corresponding data backup of first file when the backup units
When, recover the operation of first file, to proceed the operation to first file.
7. back-up device according to claim 6, it is characterised in that the stop element, it is specific to use
In:
According to the backup command that the acquiring unit is obtained, it is defeated that stopping carries out input to first file
Go out operation.
8. back-up device according to claim 7, it is characterised in that the recovery unit, it is specific to use
In:
When the backup units complete data backup corresponding to first file, recover to described first
The input-output operation of file.
9. according to any described back-up devices of claim 6-8, it is characterised in that described device also includes
Unit is set up, it is described for before the acquiring unit obtains backup command, setting up data exchange path
Data exchange path is used to transmit the backup command.
10. back-up device according to claim 9, it is characterised in that the acquiring unit, specifically
For:The data exchange path acquisition backup command that unit is set up is set up by described.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201511028916.9A CN106933704A (en) | 2015-12-31 | 2015-12-31 | A kind of backup method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201511028916.9A CN106933704A (en) | 2015-12-31 | 2015-12-31 | A kind of backup method and device |
Publications (1)
Publication Number | Publication Date |
---|---|
CN106933704A true CN106933704A (en) | 2017-07-07 |
Family
ID=59442611
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201511028916.9A Pending CN106933704A (en) | 2015-12-31 | 2015-12-31 | A kind of backup method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106933704A (en) |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2012020482A1 (en) * | 2010-08-11 | 2012-02-16 | 富士通株式会社 | Backup method, information processing device, and program |
CN104753992A (en) * | 2013-12-29 | 2015-07-01 | 中国移动通信集团公司 | Method, device and system for data storage and method and device for virtual platform failure recovery |
-
2015
- 2015-12-31 CN CN201511028916.9A patent/CN106933704A/en active Pending
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2012020482A1 (en) * | 2010-08-11 | 2012-02-16 | 富士通株式会社 | Backup method, information processing device, and program |
CN104753992A (en) * | 2013-12-29 | 2015-07-01 | 中国移动通信集团公司 | Method, device and system for data storage and method and device for virtual platform failure recovery |
Non-Patent Citations (1)
Title |
---|
ANIL DESAI: "《The definition guide to virtual platform management》", 31 December 2007, REALTIME出版社 * |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN103890728B (en) | The method of live migration of virtual machine and server | |
CN104166605B (en) | Data backup method and system based on incremental data files | |
CN106354583B (en) | A kind of heat backup method and system of MySQL database | |
CN103198122B (en) | Restart the method and apparatus of memory database | |
CN109086425B (en) | Data processing method and device for database | |
CN108038201B (en) | A kind of data integrated system and its distributed data integration system | |
CN104375877A (en) | Virtual machine online snapshot generating and deleting method | |
CN106371807A (en) | Method and device for extending processor instruction set | |
CN105760241B (en) | A kind of internal storage data deriving method and system | |
CN103370693A (en) | Restarting processes | |
CN105022656A (en) | Management method and device of virtual machine snapshot | |
CN107346210A (en) | Hard disc data method for deleting, server and system | |
CN105653345A (en) | Method and device supporting data nonvolatile random access | |
CN106815095A (en) | Virtual-machine data guard method under a kind of cloud platform environment | |
JP2010277194A (en) | Storage device, data processing method and data processing program | |
CN107329806A (en) | A kind of development environment construction method and device | |
CN116501259A (en) | Disk group dual-activity synchronization method and device, computer equipment and storage medium | |
CN103631682B (en) | The implementation method of data backup and device | |
CN110515767A (en) | Snapshot data backup method, device and equipment and readable storage medium | |
CN104268032A (en) | Multi-controller snapshot processing method and device | |
CN103853827A (en) | Database backup method capable of guaranteeing data consistency | |
CN105161138A (en) | Repair method for situation of incapability of accessing to data block caused by error of Seagate hard disk firmware manager | |
CN104484354A (en) | Snapshot method for guaranteeing data consistency and storage equipment | |
CN106933704A (en) | A kind of backup method and device | |
CN106250274A (en) | The backup method of a kind of virtual machine and device |
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 | ||
RJ01 | Rejection of invention patent application after publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20170707 |