Chapter 5 Configuring the RMAN Environment. Objectives Show command to see existing settings Configure command to change settings Backing up the controlfile.

Slides:



Advertisements
Similar presentations
LA Oracle Users Group Succeeding with RMAN Tim Gorman Principal SageLogix, Inc.
Advertisements

INTRODUCTION TO ORACLE Lynnwood Brown System Managers LLC Backup and Recovery Copyright System Managers LLC 2008 all rights reserved.
ITEC474 Control File Maintenance
1 Chapter 15 Duplicating Databases and Transporting Data.
1 Getting The Most Out of RMAN By: Charles Pfeiffer CIO, Remote Control DBA (888)
5 Copyright © 2006, Oracle. All rights reserved. Database Recovery.
RMAN Restore and Recovery
Backup and Recovery (2) Oracle 10g CAP364 1 Hebah ElGibreen.
Backup and Recovery Part 1.
Chapter 12 Performing Incomplete Recovery. Background Viewed as one of the more difficult chapters to write Thought it was important to put in material.
Oracle’s Backup and Recovery Tool
Configuring Recovery Manager
4 Copyright © 2008, Oracle. All rights reserved. Configuring Backup Specifications.
CHAPTER 5 Managing Control Files, Online Redo Logs, and Archiving.
Backup & Recovery with RMAN
9 Copyright © Oracle Corporation, All rights reserved. Oracle Recovery Manager Overview and Configuration.
CHAPTER 17 Configuring RMAN. Introduction to RMAN RMAN was introduced in Oracle 8.0. RMAN is Oracle’s tool for backup and recovery. RMAN is much more.
The Oracle Recovery Manager (RMAN)
Backup Concepts. Introduction Backup and recovery procedures protect your database against data loss and reconstruct the data, should loss occur. The.
CHAPTER 18 RMAN Backups and Reporting. Introduction to RMAN Backups and Reporting The focus of this chapter is backups of: Datafiles Control files Archived.
Agenda  Overview  Configuring the database for basic Backup and Recovery  Backing up your database  Restore and Recovery Operations  Managing your.
Introduction to Oracle Backup and Recovery
Using RMAN to Perform Recovery
Backup Infrastructure – Additional Information Gordon D. Brown, RAL Carlos Fernando Gamboa, BNL 3D Workshop, CNAF, Bologna, Italy 13 th June 2007.
1 RAL Status and Plans Carmine Cioffi Database Administrator and Developer 3D Workshop, CERN, November 2009.
NoCOUG Feb. 8, RMAN in the Trenches: To Go Forward, We Must Backup Philip Rice Univ. of California Santa Cruz.
13 Copyright © Oracle Corporation, All rights reserved. RMAN Complete Recovery.
Oracle Recovery Manager (RMAN) 10g : Reloaded
PPOUG, 05-OCT-01 Agenda RMAN Architecture Why Use RMAN? Implementation Decisions RMAN Oracle9i New Features.
Recovery Manager Overview Target Database Recovery Catalog Database Enterprise Manager Recovery Manager (RMAN) Media Options Server Session.
Database Administration TableSpace & Data File Management
5 Copyright © 2004, Oracle. All rights reserved. Using Recovery Manager.
5 Copyright © 2008, Oracle. All rights reserved. Using RMAN to Create Backups.
Chapter 7 Making Backups with RMAN. Objectives Explain backup sets and image copies RMAN Backup modes’ Types of files backed up Backup destinations Specifying.
11 Copyright © Oracle Corporation, All rights reserved. RMAN Backups.
Backup and Recovery Protects From Data Loss. Backup and Recovery Protects From Data Loss Provides for Media Recovery.
11 Copyright © Oracle Corporation, All rights reserved. RMAN Backups.
Chapter 9 Scripting RMAN. Background Authors felt that scripting was a topic not covered well Authors wanted to cover both Unix/Linux and Windows environments.
Backup & Recovery Backup and Recovery Strategies on Windows Server 2003.
11g(R1/R2) Data guard Enhancements Suresh Gandhi
15 Copyright © 2007, Oracle. All rights reserved. Performing Database Backups.
CHAPTER 5 Managing Control Files and Online Redo Logs.
17 Copyright © Oracle Corporation, All rights reserved. Recovery Catalog Creation and Maintenance.
15 Copyright © Oracle Corporation, All rights reserved. RMAN Incomplete Recovery.
Backup Concepts. Introduction Backup and recovery procedures protect your database against data loss and reconstruct the data, should loss occur. The.
3 Copyright © 2006, Oracle. All rights reserved. Using Recovery Manager.
Overview of Oracle Backup and Recovery Darl Kuhn, Regis University.
2 Copyright © 2007, Oracle. All rights reserved. Configuring for Recoverability.
2 Copyright © 2006, Oracle. All rights reserved. Configuring Recovery Manager.
8 Copyright © 2007, Oracle. All rights reserved. Using RMAN to Duplicate a Database.
3 Copyright © 2007, Oracle. All rights reserved. Using the RMAN Recovery Catalog.
10 Copyright © 2007, Oracle. All rights reserved. Using RMAN Enhancements.
14 Copyright © 2007, Oracle. All rights reserved. Backup and Recovery Concepts.
What is Flashback? Technology that allows you to revert the database to a point in time in the past Several versions of flashback available Different types.
Oracle Recovery Manager Overview and Configuration
RMAN Maintenance.
Sharing experience on RMAN backups ...
Using Recovery Manager
Introduction.
RMAN Maintenance.
RMAN Backups.
Recovery Catalog Creation and Maintenance
Configuring for Recoverability
Performing Database Backups
Configuring Recovery Manager
Duplicating a Database
Configuring Backup Settings
Configuring for Recoverability
Performing Database Recovery
Chapter 5 The Redo Log Files.
Presentation transcript:

Chapter 5 Configuring the RMAN Environment

Objectives Show command to see existing settings Configure command to change settings Backing up the controlfile Recovering the controlfile Specifying retention periods Configuring backup device types Configuring the default backup type Using compression

Objectives (cont.) Configuring multiple backup copies Configuring backup optimization Specifying backup piece file names Tagging RMAN backups Configuring RMAN channels Creating backup retention policy Configuring backup size limits

Rman Configuration Settings Use ‘show’ command – To see a particular RMAN configuration setting – Always stored in target database controlfile – ‘show all’ will display all settings – Also see V$RMAN_CONFIGURATION view

Rman Settings (cont.) Key parameters of note: – Configure retention policy to redundancy 1 – Configure backup optimization off – Configure default device type to disk – Configure controlfile autobackup off – Configure device type disk parallelism 1 backup type to backupset – Configure datafile backup copies for device type disk to 1 – Configure maxsetsize to unlimited – Configure encryption for database off

Rman Settings (cont.)

Configuring RMAN Use ‘configure’ command Changes settings for: – Backup – Restore – Duplication – Maintenance Target database settings stored in controlfile Recovery catalog stores settings for all registered databases Database must be in mount or open state Reset to default setting using ‘configure... clear’ command

Configuring RMAN (cont.) To change single setting: Change multiple settings at once with ‘run’ block:

Automatic Controlfile Backups Disabled by default Oracle recommends enabling if no recovery catalog is used Enabling ensures controlfile backup after: – Successful completion of backup or copy command – ‘create catalog’ command runs – Any structural change to the database Simplifies backup scripts Simplifies recovery process Also backs up server parameter file (spfile)

Controlfile Backups (cont.) Examples of structural changes include: – Adding tablespace or datafile – Dropping datafile – Altering a tablespace online or offline – Adding an online redo log – Renaming a datafile

Controlfile Backup Location By default: – Written to flashback area (if specified) – If no flashback area, goes to: $ORACLE_HOME/dbs (Unix) $ORACLE_HOME\database (Windows) Can specify location using ‘configure’ command

Recovery Steps using Controlfile Restore of server parameter file RMAN starts instance with restored SPFILE RMAN restores controlfile Controlfile is mounted Datafiles are restored Recover database occurs Extra steps necessary if recovery catalog is used

Snapshot Controlfile RMAN automatically creates when: – Resynchronizing with the recovery catalog – Making a backup of the controlfile Needed to maintain read-consistent view of controlfile By default: – Written to: $ORACLE_HOME/dbs (Unix) $ORACLE_HOME\database (Windows) – Can specify location with ‘configure’ command – Flashback area not used

Specifying Retention Period If keeping metadata in controlfile – Use control_file-record_keep_time initialization parameter (specified in days) – Default is seven days – Can specify a range of 0 to 365 days – Metadata stored in ‘reusable’ section of controlfile – Also see V$CONTROLFILE_RECORD_SECTION

Configuring Backup Device Type Disk is default device type Use ‘configure’ to change device type or restore default setting Can override at backup time

Configuring Default Backup Type Default is a backup set Can change to image copy with ‘configure’ Revert to backup set with either of the following:

Using Compression Can save storage space Reduces network traffic Default is non-compressed backup set Can compress for both disk and tape Can read compressed backup set without uncompressing You can choose compression algorithm See V$RMAN_COMPRESSION_ALGORITHM

Configuring Multiple Backup Copies Called duplexing RMAN makes multiple copies of backup pieces Default is one copy Using ‘configure’ copies parameter Cannot make duplex backups to flash recovery area Useful to place backups on different media All copies still within same backup set

Configuring Backup Optimization By default, turned off – Means RMAN backs up every file Turn on with ‘configure’ When set to on, RMAN skips files already backed up Applies to following files – Datafiles – Archived redo logs – Backup sets

Specifying Backup Piece Filenames Useful to make meaningful names Accomplished with format parameter within backup command Can also use db_file_name_convert Restrictions may apply if using media manager Can also use with image copies

Tagging RMAN Backups Names backup for easy identification Assign character string or ‘tag’ If none specified, RMAN assigns default tag Can tag both backup set or image copies

Configuring RMAN Channels Can be configured for automatic allocation Can be configured manually At least one channel must be allocated to run the following commands: – Backup – Restore – Recover – Duplicate – Create catalog – Validate

Configuring Automatic Channels If used, channel allocation automatic for all RMAN sessions Can configure default device type for channels Must be a single device type (disk or tape) Can specify degree of parallelism Can specify maximum backup piece size Can always override with ‘run’ block Generic parameter settings can be set up for all automatic channels Channel allocation differs between backup/copy commands and restore command

Manually Allocating Channels Done inside a ‘run’ block Naming a channel ‘id’ is optional Channel ‘id’ used when reporting errors Channels released when ‘run’ block ends Can also be explicitly released Example to allocate and release channels:

Allocating Maintenance Channel Used for maintenance tasks: – Change – Delete – Crosscheck Can only be used at RMAN prompt (no ‘run’ block) Not necessary if at least one default channel allocated for each device type Example of deleting a backup:

Creating Backup Retention Policy Can be specified in two ways: – Based on time – Based on number of copies Any backup older than retention is marked as obsolete Can set retention policy to ‘none’ (infinite) If using incremental backups, retention will exceed configured retention period Also see V$BACKUP_FILES

Archived Redo Log Deletion Policy No policy used by default Specified which archived logs eligible for deletion Only logs in flash recovery area automatically deleted Logs in other locations need manual deletion Does not affect logs within backup sets

Configuring Backup Size Limits For backup pieces: – Limit via maxpiecesize parameter – Done to accommodate limitations on storage devices For backup sets – Limit via maxsetsize parameter – Done to accommodate O/S limitations – Many factors need evaluation in determining backup set size Cannot limit the size of image copies