Full introduction to Oracle database backup and recovery (1)

Source: Internet
Author: User

1. Export/Import (Export/Import)

The Export can be used to extract data from the database, and the Import can be used to send the extracted data back to the Oracle database.

1. Simple Export of data (Export) and Import of data (Import)

Oracle supports three types of output:

(1) the data of the specified table is exported in the T mode.
(2) user mode (U mode), which exports all objects and data of the specified user.
(3) Full database mode (Full mode). All objects in the slave database are exported.

The data Import process is the inverse process of data Export (Export). The data files are imported into the database and the database data is exported to the data file respectively.

2. incremental Export/Import

Incremental export is a common data backup method. It can only be implemented for the entire database and must be exported as a SYSTEM. During this export, the system does not require any answers. The default export file name is export. dmp. If you do not want your output file to be named export. dmp, you must specify the file name to use in the command line.

Incremental export includes three types:

(1) "Complete" incremental Export (complete) backs up three databases, for example, exp system/manager inctype = Complete file = 040731.dmp.
(2) incremental export the data changed after the last backup, for example, exp system/manager inctype = incremental file = 040731.dmp.
(3) "accumulative" incremental export the accumulative export mode is to export the changed information in the database since the last "complete" export. For example, exp system/manager inctype = cumulative file = 040731.dmp.
The database administrator can schedule a backup schedule and export data in three different ways.

For example, you can make the following arrangements for database blocking tasks:

Monday: Full backup (A) Tuesday: Incremental Export (B) Wednesday: Incremental Export (C)

Thursday: Incremental Export (D) Friday: accumulative Export (E) Saturday: Incremental Export (F)

Sunday: Incremental Export (G ).

If the database is accidentally damaged on Sunday, the database administrator can follow these steps to reply to the database:

Step 1: Use the create database Command to regenerate the DATABASE structure;

Step 2: create a large enough additional rollback;

Step 3: import A: imp system/manager inctype = restore full = y FILE =

Step 4: Accumulative incremental import E: imp system/manager inctype = restore full = y file = E

Step 5: import the latest incremental F: imp system/manager inctype = restore full = y file = F

Ii. Cold backup

Cold backup occurs when the database is shut down normally. When the database is shut down normally, it will provide us with a complete database. This article describes how to copy key files to another location during cold backup. The fastest and safest way to back up Oracle information during cold backup. Advantages of cold backup:

1. It is a very fast backup method (just copy files );
2. Easy to archive (simple copy );
3. It is easy to restore to a certain point in time (you only need to copy the file back );
4. It can be combined with the archiving method to restore the database in the "best state;
5. Low maintenance and high security.

However, cold backup also has the following shortcomings:

1. When used separately, only recovery at a certain time point can be provided;
2. During the whole backup process, the database must be backed up instead of other work. That is to say, in the cold backup process, the database must be closed;
3. If the disk space is limited, it can only be copied to tape and other external storage devices, and the speed will be slow;
4. data cannot be restored by table or by user.


Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.