Learn about Oracle recovery Structure

Source: Internet
Author: User

Oracle recovery structure is the basic knowledge we all need to master. The following describes the composition of Oracle recovery structure in detail and hopes to enlighten you.

When a customer's application or tool program accesses the Oracle server over the network, the client allocates user processes to the application, and the server will configure the server processes for the application, in addition, all SQL operations applied by the customer are ultimately executed by the server process.

The Oracle server consists of a routine and a data database. To allow your applications to access the Oracle server, you must start the routine and open the database. If no startup routine is available, an error message ORA-01034 is displayed: Oracle not available; if the database is not opened, an error ORA-01033 is displayed: Oracle initization or shutdown in progress.

A routine is a set of Memory Structures and background processes. The memory structure mainly includes data cache, redo log buffer, and shared pool, these memory structures are collectively referred to as SGA (Sytem Global Area). Background processes mainly include SMON, PMON, DBWR, CKPT, and LGWR. When a client application accesses the Oracle server, make sure that the database has been opened. by querying the dynamic performance view V $ INSTANCE, you can determine the information of the current routine, including the routine name, the host name where the routine is located, and the routine status ).

Database. A database is a collection of OS (Operate System) files. It consists of data files, control files, and redo log files. Before performing backup and recovery operations on the database, you need to develop backup and recovery policies. Different log operation modes and different backup and recovery policies are required. By querying the dynamic performance view V $ DATABASE, you can determine the information of the current DATABASE, including the DATABASE name, log operation mode, and current SCN value ).

A database consists of three types of files: data files, control files, and redo log files. When managing Oracle databases, you must not only manage data files, control files, and redo logs, but also frequently use other OS file archives and parameter files ).

Data files are used to store database data, including system data dictionaries, user data tables, indexes, clusters, and UNDO data. When a database or tablespace is created, the data file is specified using the DATAFILE option. A database is logically composed of one or more tablespaces, while a TABLESPACE is physically composed of one or more data files.

Tablespace. Tablespace is a logical component of the database. Different tablespaces require different backup and recovery policies. For example, the SYSTEM tablespace must be restored in the MOUNT state, and the data table space can be restored in the OPEN state, but the temporary tablespace does not need to be restored. You can query the data dictionary DBA_TABLESPACES to display the table space details.

A data file. A tablespace consists of one or more data files. The tablespace size is actually the sum of the sizes of all the data files it contains. You can query the data dictionary DBA_DATA_FILES, the relationship between the tablespace and the data file is displayed.

When performing backup and recovery operations, you often need to provide the dynamic information of data files. For the dynamic information of data files, you can query the dynamic performance view V $ DATAFILE and V $ DATAFILE_HEADER, the dynamic information of V $ DATAFILE comes from the control file, while the dynamic information of V $ DATAFILE_HEADER comes from the data file header. Under normal conditions, the two dynamic performance views have identical checkpoint SCN values. However, if the data file is corrupted and the data file is backed up, then, V $ DATAFILE_HEADER can determine the starting SCN value of application Redo, while V $ DATAFILE can determine the ending SCN value of application redo.

Log group, in a single instance environment, there is only one redo thread; In the RACReal Appplication Cluster environment, there are multiple redo threads, each redo thread contains at least two log groups, by querying the dynamic performance view V $ LOG, you can view all the LOG group information of the redo thread, including the LOG group number, LOG member count, LOG group status, size, and LOG serial number.

The control file is used to record and maintain the physical structure of the database. Each Oracle database must contain at least one control file. When using Oracle Server, one routine can only access one database, oracle uses control files to establish associations between routines and databases. When a database is loaded, Oracle determines the control file based on the initialization parameter control_file. When the database is opened, Oracle opens all data files and redo logs based on the information recorded in the control file, you can query V $ CONTROLFILE to display all the control files of the current database.

Archive logs are non-active redo logs. You can use archive logs to keep all redo history records. When a media failure occurs in the database, you can use data file copies and redo history records to completely restore the database. Archive logs are generated only in archive mode. Oracle automatically generates archive logs when switching logs.
 

The section of the Oracle database

Oracle STARTUP script in Linux

Learn about Oracle startup parameters

Oracle conversion functions

Oracle DECODE function syntax

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.