CN104463014B - A kind of oracle database guard method based on snapshot - Google Patents
A kind of oracle database guard method based on snapshot Download PDFInfo
- Publication number
- CN104463014B CN104463014B CN201410756636.9A CN201410756636A CN104463014B CN 104463014 B CN104463014 B CN 104463014B CN 201410756636 A CN201410756636 A CN 201410756636A CN 104463014 B CN104463014 B CN 104463014B
- Authority
- CN
- China
- Prior art keywords
- snapshot
- storage device
- database
- agent
- request
- 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.)
- Active
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F21/00—Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
- G06F21/60—Protecting data
- G06F21/62—Protecting access to data via a platform, e.g. using keys or access control rules
- G06F21/6218—Protecting access to data via a platform, e.g. using keys or access control rules to a system of files or objects, e.g. local or distributed file system or database
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Computer Security & Cryptography (AREA)
- Bioethics (AREA)
- General Health & Medical Sciences (AREA)
- Computer Hardware Design (AREA)
- Health & Medical Sciences (AREA)
- Software Systems (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Databases & Information Systems (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
The present invention relates to a kind of oracle database guard method based on snapshot, comprise the following steps:Main frame carry storage device, and oracle database is installed on a storage device;Client sends snapshot request according to snapshot task to storage device;Corresponding file path is sent to snapshot agent by storage device according to snapshot request is received;Snapshot agent is converted into the volid of correspondence storage volume according to the file path that registration file will be received;Storage device obtains corresponding volname after receiving volid, and sends confirmation request to proxy snapshot;Snapshot agent judges whether current database example can back up, if so, then keeping database instance coherency state, after performing snapshot operation, storage device sends to snapshot agent and releases request, releases database instance coherency state.Compared with prior art, the present invention has to main frame dependence small, Information Security and high reliability.
Description
Technical field
The present invention relates to the cross discipline technical field that computer memory technical and data management technique are combined, especially
It is related to a kind of oracle database guard method based on snapshot.
Background technology
Data protection always is an important research field of computer memory technical and data management technique.From early stage
Mankind's beginning using stone inscription, bamboo stick and sheepskin volume record information, data storage as a kind of knowledge acquisition and the means for exchanging just
Pass on.
Data storage is from paper technology, the art of printing, laser printing, then paper tape, floppy disk, hard disk, CD finally etc. is no
It is disconnected to be developed so far, along with the arrival of information age, requirement of the people to the safety and reliability of data also more and more higher.
Oracle database as the client/server of current main flow or one of the database of B/S architectures, for it provides a kind of peace
Complete reliable data protection mode is become for exigence.
Existing data guard method is made a general survey of, can be substantially divided three classes:Remote copy, snapshot and clone.
(1) remote copy is exactly the file or block number that will be backed up according to by network transmission to long-distance disaster website, realization
The backup and protection of data.But the method cost time is more, host resource is taken.
(2) snapshot refers to image of the data at certain time point, is a completely available copy of data, there is provided in line number
According to recovery.In addition snapshot also provides a data access channel to store user, when former data carry out application on site to be processed,
User can access snapshot data, can also carry out the work such as testing using snapshot.Therefore, all storage systems, no matter senior middle school
Low side, as long as being applied to on-line system, then snapshot just turns into an indispensable function.
(3) clone refers to the physical replication at set of source data time point.If snapshot is the shadow of certain moment sizing, that
Clone is exactly entity true, is totally independent of set of source data.Therefore for snapshot, clone needs one
Individual extra memory space deposits data block.
Current application of these technologies in data protection is very big to the dependence of main frame, rarely has the guarantor to data application
Shield.
The content of the invention
The purpose of the present invention provides a kind of based on snapshot for the defect for overcoming above-mentioned prior art to exist
Oracle database guard method, is protected using storage end to data application, solves prior art to host dependency
Big problem, realizes online real-time guard, it is ensured that the safety and reliability of data.Simultaneously using snapshot agent to database
It is monitored, it is ensured that the uniformity of data during snapshot operation.
The purpose of the present invention can be achieved through the following technical solutions:
A kind of oracle database guard method based on snapshot, comprises the following steps:
1) main frame carry storage device, the corresponding registration file of generation, and oracle database is installed on a storage device;
2) client sends snapshot request according to snapshot task to storage device;
3) according to snapshot request is received, acquisition needs the database instance of snapshot to storage device, while by corresponding file
Path is sent to snapshot agent;
4) snapshot agent is converted into the volid of correspondence storage volume according to the file path that registration file will be received, and returns
Back to storage device;
5) storage device obtains corresponding volname after receiving volid, and sends confirmation request to proxy snapshot;
6) snapshot agent judges whether current database example can back up, if so, then keeping database instance uniformity
State, performs step 7), if it is not, then exiting;
7) after performing snapshot operation, storage device sends to snapshot agent and releases request, releases database instance uniformity
State.
The main frame carry storage device includes iscsi, FC, FCoE or IB by the way of.
The snapshot task is triggered by start button or calls triggering by the plan target cycle.
The snapshot task includes that needing snapshot database instance name, snapshot to perform frequency, snapshot performs the time, retains note
Record number and task names.
At least include a database instance for needing snapshot in the snapshot request.
The step 6) in, snapshot agent judges whether current database example can back up according to database positioning, when
Under archive mode during normal startup, current database example can be backed up database.
Compared with prior art, the present invention has the advantages that:
1st, the dependence to main frame is reduced.Protection data are stored in storage device, it is ensured that Host Status do not influence data safety
Property and availability.
2nd, because the present invention is the data protection based on snapping technique, it is not necessary to extra memory space, additionally, can realize
Instantaneous rollback.
3rd, the present invention is the protection based on application, it is possible to achieve the synchronous protection of single instance or multiple examples.
4th, when being protected to data, other operations of main frame are not influenceed.Will not because of data backup to be carried out end
Only operate, it is to avoid stand-by period of user.
5th, the present invention can be protected to the All Files of oracle database, including control file, Parameter File, day
Will file and Parameter File etc., it is ensured that the safety and reliability of data.
6th, it is that data conformity provide guarantee present invention employs snapshot agent mechanism.
Brief description of the drawings
Fig. 1 is theory diagram of the invention;
Fig. 2 is present invention registration application flow schematic diagram;
Fig. 3 creates snapshot task schematic flow sheet for the present invention;
Fig. 4 performs snapshot task schematic flow sheet for the present invention.
Specific embodiment
The present invention is described in detail with specific embodiment below in conjunction with the accompanying drawings.The present embodiment is with technical solution of the present invention
Premised on implemented, give detailed implementation method and specific operating process, but protection scope of the present invention is not limited to
Following embodiments.
By storage device carry on main frame, carry storage device includes iscsi, FC, FCoE to the present invention by the way of
Or IB etc..The present embodiment is illustrated by taking iscsi memory technologies as an example, and oracle database is built in storage device iscsi
In volume, the dependence to main frame can be so reduced, realize the safety and integrity of data, while creating example and table sky
Between, configuration oracle is archive mode, then installs the snapshot agent for database monitoring.
As shown in figure 1, by the carry of storage device 2 on main frame 3, client 1 sends snapshot and asks to storage device 2 first
Ask, storage device 2 can send the file path asked and want snapshot to snapshot agent Agent again after receiving request.Now Agent
Iscsi technologies can be utilized, with reference to registry information, file path is converted into the volid of storage volume.Storage device 2 is according to this
Volid determines the true path of the file for wanting snapshot, and notifies that Agent will carry out snapshot.If data can be backed up, Agent exists
Receive the information relief data and be consistent proterties state, the uniformity of data when ensuring snapshot with this.
Before snapshot operation is carried out, business main frame need to be registered.As shown in Fig. 2 according to the host IP address of input
Or the cluster and type of database of selection can determine one or more applications to be protected.This is using lower and can have multiple real
Example, the protection of multiple examples is realized by the protection to application.
Snapshot task is created after the completion of registration, as shown in Figure 3.Task names, task type (snapshot) are determined first and are protected
Stay recovery point.Then snapshot object is selected, storage rear end (storage device) calls rest interfaces to obtain IP main frames to snapshot agent
Or on cluster selected type all database instances.User can voluntarily select which example to carry out snapshot to, while input is fast
According to information such as frequency, the times for performing, complete snapshot task and create.
When user clicks on start button or the plan target cycle calls triggering snapshot operation, storage rear end can receive soon
According to request, and database file path is sent to snapshot agent.File path is being converted into the volume that carry gets on by snapshot agent
Volid after return to storage rear end.Now storage rear end just can determine the title of volume according to the volid of volume, while to fast
Request is sent according to agency, judges whether the database instance in the snapshot task can back up.If can back up, storage end can be again
Sent to snapshot agent and asked, allow database instance to be consistent proterties state.After storage rear end has performed snapshot operation, to snapshot
Agency sends the request operation for releasing coherency state, completes snapshot.Perform snapshot task flow as shown in Figure 4:
Step s101, client sends snapshot request according to snapshot task to storage device.
Step s102, storage device needs the database instance of snapshot according to snapshot request, acquisition is received, while will correspondence
File path be sent to snapshot agent, a database instance for needing snapshot is at least included in snapshot request.
Step s103, snapshot agent is converted into correspondence storage volume according to the file path that registration file will be received
Volid, and return to storage device.
Realize the protection of data, it is most important that ensure the uniformity of data.The present invention provides one for database
Operate interface, that is, snapshot agent.Storage device, first can be to snapshot agent after the snapshot request from client is received
Request is sent, and transmits the database file path for wanting snapshot.This document path is the path that client is seen, rather than
Database true path on a storage device.Therefore must be changed accordingly, to realize the snapshot to data storage.
Registration table is as a set of control operation system appearance and how to respond the file that incoming event works.Its HKEY_
What is deposited in LOCAL_MACHIN root keys is the setting for control system and software.HARDWARE/DEVICEMAP under it
Key is used for storage equipment map.Therefore in the present embodiment, when the storage volume carry of storage device is on main frame, Jiu Hui
Corresponding registration file is generated under HARDWARE/DEVICEMAP/Scsi in corresponding Target Id catalogues.Can be with by parsing
It was found that, the information of virtual volume, including TargetName and volid, it is stored in the registration file under Target Id catalogues.
Therefore only need to find corresponding registration file, the volume volid that just can be matched.But existing iscsi volumes of letter of acquisition
The technology of breath can't obtain its TargetId, can only obtain its TargetName.Therefore need by contrast registration file
TargetName parts, can just uniquely determine the volid of corresponding storage volume.
Step s104, storage device receives the title volname of acquisition respective roll after volid.
Step s105, storage device sends confirmation request to proxy snapshot, and snapshot agent judges to work as according to database positioning
Whether preceding database instance can back up, if database normally starts under archive mode, judge current database example energy
Enough backups, perform step s106, if it is not, then exiting.
Step s106, keeps database instance coherency state.
Step s107, performs snapshot operation.
Step s108, after snapshot operation, storage device sends to snapshot agent and releases request, releases database instance consistent
Proterties state.
Step s109, the result of this execution is write to database.
Claims (6)
1. a kind of oracle database guard method based on snapshot, it is characterised in that comprise the following steps:
1) main frame carry storage device, the corresponding registration file of generation, and oracle database is installed on a storage device;
2) client sends snapshot request according to snapshot task to storage device;
3) according to snapshot request is received, acquisition needs the database instance of snapshot to storage device, while by corresponding file path
It is sent to snapshot agent;
4) snapshot agent is converted into the volid of correspondence storage volume according to the file path that registration file will be received, and returns to
Storage device;
5) storage device obtains corresponding volname after receiving volid, and sends confirmation request to proxy snapshot;
6) snapshot agent judges whether current database example can back up, if so, database instance coherency state is then kept,
Perform step 7), if it is not, then exiting;
7) after performing snapshot operation, storage device sends to snapshot agent and releases request, releases database instance coherency state.
2. the oracle database guard method based on snapshot according to claim 1, it is characterised in that the main frame is hung
Carry storage device includes iscsi, FC, FCoE or IB by the way of.
3. the oracle database guard method based on snapshot according to claim 1, it is characterised in that the snapshot is appointed
Business is triggered by start button or calls triggering by the plan target cycle.
4. the oracle database guard method based on snapshot according to claim 1 or 3, it is characterised in that described fast
Include that needing snapshot database instance name, snapshot to perform frequency, snapshot performs time, reservation record number and task name according to task
Claim.
5. the oracle database guard method based on snapshot according to claim 1, it is characterised in that the snapshot please
At least include a database instance for needing snapshot in asking.
6. the oracle database guard method based on snapshot according to claim 1, it is characterised in that the step 6)
In, snapshot agent judges whether current database example can back up according to database positioning, when database is under archive mode
During normal startup, current database example can be backed up.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410756636.9A CN104463014B (en) | 2014-12-10 | 2014-12-10 | A kind of oracle database guard method based on snapshot |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410756636.9A CN104463014B (en) | 2014-12-10 | 2014-12-10 | A kind of oracle database guard method based on snapshot |
Publications (2)
Publication Number | Publication Date |
---|---|
CN104463014A CN104463014A (en) | 2015-03-25 |
CN104463014B true CN104463014B (en) | 2017-06-09 |
Family
ID=52909034
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201410756636.9A Active CN104463014B (en) | 2014-12-10 | 2014-12-10 | A kind of oracle database guard method based on snapshot |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN104463014B (en) |
Families Citing this family (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106021020B (en) * | 2016-05-12 | 2019-03-12 | 中国工商银行股份有限公司 | A kind of dual-active data station application data hanging method and device |
CN108717462A (en) * | 2018-05-28 | 2018-10-30 | 郑州云海信息技术有限公司 | A kind of database snapshot verification method and system |
CN109597707B (en) * | 2018-10-25 | 2024-04-23 | 平安科技(深圳)有限公司 | Clone volume data copying method, device and computer readable storage medium |
CN110990379B (en) * | 2019-11-24 | 2022-06-17 | 北京浪潮数据技术有限公司 | DB2 database disaster tolerance and control method and system |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1786959A (en) * | 2004-12-08 | 2006-06-14 | 国际商业机器公司 | Method for optimizing a snapshot operation on a file basis |
CN102012947A (en) * | 2010-12-16 | 2011-04-13 | 创新科存储技术有限公司 | Method and system for online backup of database |
CN102419758A (en) * | 2010-09-28 | 2012-04-18 | 金蝶软件(中国)有限公司 | Data processing system and method |
CN103765406A (en) * | 2011-06-30 | 2014-04-30 | 亚马逊科技公司 | Methods and apparatus for remotely updating executing processes |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2012055966A1 (en) * | 2010-10-27 | 2012-05-03 | MAX-PLANCK-Gesellschaft zur Förderung der Wissenschaften e.V. | Protecting data integrity with storage leases |
-
2014
- 2014-12-10 CN CN201410756636.9A patent/CN104463014B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1786959A (en) * | 2004-12-08 | 2006-06-14 | 国际商业机器公司 | Method for optimizing a snapshot operation on a file basis |
CN102419758A (en) * | 2010-09-28 | 2012-04-18 | 金蝶软件(中国)有限公司 | Data processing system and method |
CN102012947A (en) * | 2010-12-16 | 2011-04-13 | 创新科存储技术有限公司 | Method and system for online backup of database |
CN103765406A (en) * | 2011-06-30 | 2014-04-30 | 亚马逊科技公司 | Methods and apparatus for remotely updating executing processes |
Also Published As
Publication number | Publication date |
---|---|
CN104463014A (en) | 2015-03-25 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
USRE47852E1 (en) | Snapshot and replication of a multi-stream application on multiple hosts at near-sync frequency | |
CN106407356B (en) | Data backup method and device | |
US8260747B2 (en) | System, method, and computer program product for allowing access to backup data | |
US10037251B1 (en) | File system rollback to previous point in time | |
US10402115B2 (en) | State machine abstraction for log-based consensus protocols | |
US8020037B1 (en) | Creation of a test bed for testing failover and failback operations | |
CN104239166B (en) | A kind of method that file backup is realized to virtual machine in operation | |
US7725776B2 (en) | Method for displaying pair state of copy pairs | |
US10565071B2 (en) | Smart data replication recoverer | |
US20230015095A1 (en) | Database information backup method and recovery method, electronic device, and computer readable storage medium | |
US9396052B2 (en) | Periodic validation and health reports of disaster recovery plan | |
CN104216793B (en) | Application Backup, the method and apparatus recovered | |
CN104463014B (en) | A kind of oracle database guard method based on snapshot | |
US20130166505A1 (en) | Monitoring replication lag between geographically dispersed sites | |
US8078585B2 (en) | Reactive file recovery based on file naming and access information | |
US10452502B2 (en) | Handling node failure in multi-node data storage systems | |
US11243843B2 (en) | Method and system for optimizing backup and backup discovery operations using change based metadata tracking (CBMT) | |
KR20080042881A (en) | Transaction consistency and problematic states | |
CN111656325B (en) | Fast recovery from failures in a time-ordered log-structured key-value storage system | |
US20210111962A1 (en) | Topographical search | |
CN101937378B (en) | Method for carrying out back-up protection on data of storage equipment and computer system | |
US11119866B2 (en) | Method and system for intelligently migrating to a centralized protection framework | |
CN109739691A (en) | DB Backup and restoration methods, device, terminal device and storage medium | |
US9557932B1 (en) | Method and system for discovering snapshot information based on storage arrays | |
US10387262B1 (en) | Federated restore of single instance databases and availability group database replicas |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
CB02 | Change of applicant information |
Address after: 201112 Shanghai, Minhang District, United Airlines route 1188, building second layer A-1 unit 8 Applicant after: SHANGHAI EISOO INFORMATION TECHNOLOGY CO., LTD. Address before: 201112 Shanghai, Minhang District, United Airlines route 1188, building second layer A-1 unit 8 Applicant before: Shanghai Eisoo Software Co.,Ltd. |
|
COR | Change of bibliographic data | ||
GR01 | Patent grant | ||
GR01 | Patent grant |