6 Administering Backup and Recovery

Source: Internet
Author: User

Oracle? Database 2 day + Real application Clusters Guide
11g Release 2 (11.2)
E17264-13


6 Administering Backup and Recovery
Overview of Oracle RAC Database Backup and Recovery


Note:
For the RMAN utility-properly on Linux platforms, the $ORACLE _home/bin directory must appear in the PATH variable Before The/usr/x11r6/bin directory.
The Enterprise Manager Guided Recovery capability provides a Recovery Wizard that encapsulates the logic required for a WI De range of file restoration and recovery scenarios, including the following:


Complete restoration and recovery of the database
Point-in-time recovery of the database or selected tablespaces
Flashback Database
Other flashback features of Oracle database for Logical-level repair of unwanted changes to Database objects
Media recovery at the block level to data files with corrupt blocks


If The database files is damaged or need recovery, then Enterprise Manager can determine which parts of the database must Be restored from a backup and recovered, including early detection of situations such as corrupted database files. Enterprise Manager guides through the recovery process, prompting for needed information and performing the required R Ecovery actions.


Note: On the Linux platform, in order to keep the Rman function normal, $ORACLE _home/bin must be in the definition of path, and must be in front of/usr/x11r6/bin, remember!!!


About the Fast Recovery area in Oracle RAC


Using a fast recovery area minimizes the need to manually manage disk space for your backup-related files and balance the Use of space among the different types of files. Oracle recommends that's enable a fast recovery area to simplify your backup management.


The larger, the fast recovery area are, the more useful it becomes. Ideally, the fast recovery area should is large enough to contain all the following files:


A copy of all data files
Incremental Backups
Online Redo Logs
Archived redo log files that has not yet been backed up
Control files and control file copies
Autobackups of the control file and database initialization parameter file




The fast recovery area for a Oracle RAC database must is placed on an Oracle ASM disk group, a cluster file system, or on A shared directory is configured through a network file system file for each Oracle RAC instance. In other words, the fast recovery area must is shared among all of the instances of an Oracle RAC database. The preferred configuration for Oracle RAC-IS-use Oracle Automatic Storage Management (Oracle ASM) for storing the fast Recovery area, using a different disk group for your recovery set than for your data files.


The location and disk quota must is the same on all instances. Oracle recommends, the fast recovery area on the shared Oracle ASM disks. In addition, must set the Db_recovery_file_dest and Db_recovery_file_dest_size parameters to the same values on all Stances.


To use the Fast recovery feature, you must first configure the fast recovery area for each instance in your Oracle RAC dat Abase.
----Oracle strongly recommends placing the fast recovery area on a shared ASM disk and setting the same db_recovery_file_dest,db_recovery_file_dest_size parameter on all instances .




Archiving the Oracle Real application Clusters Database Redo Logs


To make your data highly available, it's important to configure the database so can recover your data after a system Failure. Redo logs contain a record of changes that were made to datafiles. Redo logs is stored in Redo log groups, and you must has at least a Redo log groups for your database.


After the redo log files in a group has filled up, the log writer process (LGWR) switches the writing of redo to A new redo log group. Oracle Database can automatically save the inactive group of redo log files to one or more offline destinations, known Col Lectively as the archived redo log (also called the Archive log). The process of turning redo log files into archived redo logs files is called archiving.


When you archive your redo logs, you write redo log files to another location before they is overwritten. This is called the archived redo log. These copies of redo log files extend the amount of redo data that can is saved and used for recovery. Archiving can either enabled or disabled for the database, but Oracle recommends so you enable archiving.




About archived Redo Log Files for a Oracle RAC Database


When your use of Oracle Database Configuration Assistant (DBCA) to create your Oracle Real application Clusters (Oracle RAC) d Atabase, each instance was configured with at least, redo log files, which is stored in the GKFX storage area. If you had a two-node Oracle RAC database, then at least four redo logs is created for the database, and both for each Instan Ce.


If you use a cluster file system to store the archived redo log files for your Oracle RAC database and then the redo log file S is shared file system files. IF You use Oracle ASM to store the archived redo log files for your Oracle RAC database and then each instance automatically Have access to all the archived redo log files generated by the database. If You use GKFX storage or raw devices to store the archived redo log files on each node and then you must configure the OP Erating system to grant access to those directories for each instance of the cluster database, needs access to them.


The primary consideration when configuring archiving are to ensure so all archived redo logs can being read from every node During recovery, and if possible during backups. During recovery, because the archived log destinations is visible from the node that performs the recovery, Oracle RAC CA N successfully recover the archived redo log data. For creating backups of your Oracle RAC database, the strategy that's choose depends on how do you configure the archiving Destinations for each node. Whether only one node or all nodes perform archived redo log backups, you must ensure so the archived redo logs for ever Y instance is backed up.


To backup the archived redo logs from a single node, that node must has access to the archived log files of the other INS Tances. The archived redo log naming scheme that it's important because when a node writes to a log with a specific filename On the It file system, the file must is readable by any node that must access this archived redo log. For example, if Node1 archives a log to/oracle/arc_dest/log_1_100_23452345.arc, then Node2 can back up this archived redo Log only if it can read/oracle/arc_dest/log_1_100_23452345.arc on its own file system.






About Parallelism and Backups Across multiple RMAN Channels


Recovery Manager (RMAN) depends on server sessions, processes this run on the database server, to perform backup and Recov ery tasks. Each server session is in the turn corresponds to an RMAN channel, representing one stream of data to or from a backup device. RMAN supports parallelism, which is the use of multiple channels and server sessions to perform the work of a single backu P Job or file restoration task.


Because the control file, SPFILE, and data files are accessible by any instance, the backup operation of these files is di Stributed across all the allocated channels. For backups of the archived redo logs, the actions performed by RMAN depend on the type of archiving scheme used by your Or Acle RAC database.


If You use a local archiving scheme and then each instance writes the archived redo log files to a local directory. When multiple channels is allocated that has access to the archived redo log, for each archived redo log file, RMAN dete Rmines which channels has access to that archived redo log file. Then, RMAN groups the archived redo log files The can is accessed by a channel and schedules a backup job using that Chan Nel.


If each node in the cluster writes the archived redo logs files to Oracle ASM, a clustered file system, or other type of sh ared storage, then each instance have access to all the archived redo log files. The the backup of the archived redo log is distributed across all the allocated channels.






Configuring archiving for Your Oracle RAC Database


For the Oracle RAC, each instance have its own thread of redo. The preferred configuration for Oracle RAC are to configure the fast recovery area using a Oracle ASM disk group that is S Eparate from the Oracle ASM disk group used for your data files. Alternatively, you can use a cluster file system archiving scheme.


To configure archiving for your Oracle RAC database:


The database Home page of Enterprise Manager Database Control, while logged in as a SYSDBA user, select availability.


The availability subpage appears.


In the Backup/recovery section, under the heading Setup, select Recovery Settings.


The Recovery Settings page appears.


In the Media Recovery section, select the ARCHIVELOG mode option.


In the Log Archive Filename format field, accept the default value, or enter the desired format.


For clustered databases, the format of the archive log file name should contain the%t modifier, to indicate which redo L OG thread the archived redo log file belongs to. As a best practice, the format for the archive log file name should also include the%s (log sequence number) and%r (Rese TLogs identifier) modifiers.


If the archive log destination is the same for all instances and then the Archive Log Destination field, change the value The archive log destination for the cluster database.


For example, you might set it to +data if using Oracle ASM, or To/u01/oradata/arch if you want local archiving on each no Beh


If You must configure a different archive log destination for any instance and then you must go to the initialization Paramet ERs page and modify the log_archive_dest_1 parameter that corresponds to the instance for which you want to configure the Archive log destination. The Instance column should display the name of the Instance, for example Sales1. The Value field to contain the location of the archive log destination for that instance.


About configuring Access to the Archive Log


During recovery, because the archive log file destinations is visible from the node that performs the recovery, Oracle RA C can successfully access the archived redo log files during recovery.


If you don't use shared storage or a clustered file system to store the archived redo log files for your cluster database Must make the archived redo log files available to the node performing the recovery.

6 Administering Backup and Recovery

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.