(O'Reilly) Oracle RMAN (Pocket Reference).pdf

(1286 KB) Pobierz
22905759 UNPDF
Chapter 1. Oracle RMANPocket Reference
1.1 Introduction
This book is a quick-reference guide for Recovery Manager (RMAN), Oracle's utility to manage all
of your Oracle database backup and recovery activities. This book is not a comprehensive backup
and recovery book. It contains an overview of RMAN architecture, shows briefly how to backup and
restore databases using RMAN, describes catalog setup issues, and provides quick-reference syntax
diagrams of RMAN commands.
The purpose of this book is to help you quickly find the syntax for, and use, RMAN commands to
back up, restore, and recover a database. We assume that you, the reader, have basic Oracle database
administrator (DBA) skills, and that you are familiar with backup and recovery concepts. We also
point out that the batch mode examples in this book are scripted with Unix shell scripts. Many of
these examples contain Unix paths that are appropriate for our environment. If you are developing
your own set of scripts, you will want to change the examples to reflect your own environment.
1.1.1 Acknowledgments
Many thanks to "our man," editor Jonathan Gennick. His feedback and suggestions have added
significant improvements and clarity to this book. Thanks also to the technical reviewers Jeff Cox,
Tim Gorman, Dick Goulet, Mark Hampton, Steve Orr, Walt Weaver, and Jeremiah Wilton.
1.1.2 Caveats
We have taken the Pareto's Law approach in writing this book, in that we have tried to cover topics
that you are most likely to encounter while using RMAN. This material does not cover every type of
environment, nor does it cover all of the backup and recovery scenarios that you will encounter as an
Oracle DBA.
While some of the more common backup and recovery scenarios are covered in this book, it is still
critical that you are comfortable with your RMAN implementation and can recover your database no
matter what type of failure occurs. We can't stress enough the importance of regular testing in
preparation for recovering from unplanned disasters.
A sound implementation and regular testing will give you the confidence to handle the impending 2
A.M. call: "Hey, I'm getting this strange ORA-01116 error, unable to open file, what do I do?"
1.1.3 Conventions
UPPERCASE
Indicates an RMAN keyword, SQL keyword, or the name of a database object.
italic
Used for filenames, directory names, and URLs. Also used for emphasis and for the first use
of a technical term.
Constant width
Used for examples showing code.
Constant width bold
Indicates user input in examples showing an interaction.
Constant width italic
Used in syntax descriptions to indicate user-defined terms.
[]
Used in syntax descriptions to denote optional elements.
{}
Used in syntax descriptions to denote a required choice.
|
Used in syntax descriptions to separate choices.
_
Used in syntax descriptions to indicate that the underlined option is the default.
O/S
Abbreviation of "operating system."
.2 RMAN Architecture
Recovery Manager (RMAN) is a utility that can manage all of your Oracle backup and recovery
activities. DBAs are often wary of using RMAN because of its perceived complexity and its control
over performing critical tasks. The traditional backup and recovery methods are tried-and-true. Thus,
when your livelihood depends on your ability to back up and recover the database, why implement a
technology like RMAN? The reason is that RMAN comes with several benefits:
Incremental backups that only copy data blocks that have changed since the last backup.
Tablespaces are not put in backup mode, thus there is no extra redo log generation during
online backups.
Detection of corrupt blocks during backups.
Parallelization of I/O operations.
Automatic logging of all backup and recovery operations.
Built-in reporting and listing commands.
RMAN's architecture is a combination of an executable program (the rman utility) and background
processes that interact with one or more databases and with I/O devices. There are several key
architectural components to be aware of:
RMAN executable
Server processes
Channels
Target database
Recovery catalog database (optional)
Media management layer (optional)
Backups, backup sets, and backup pieces
The following sections describe each of these components.
1.2.1 RMAN Executable
The RMAN executable, usually named rman, is the program that manages all backup and recovery
operations. You interact with the RMAN executable to specify backup and recovery operations you
want to perform.
You don't need an extra license for RMAN; it comes as a standard utility
included with an Oracle 8.0.x, Oracle8 i , or Oracle9 i installation.
The executable then interacts with the target database, starts the necessary server processes, and
performs the operations that you requested. Finally, the RMAN executable records those operations
in the target database's control file and the recovery catalog database, if you have one.
1.2.2 Server Processes
RMAN server processes are background processes, started on the server, used to communicate
between RMAN and the databases. They can also communicate between RMAN and any disk, tape,
or other I/O devices. RMAN server processes do all the real work for a backup or restore operation,
and a typical backup or restore operation results in several server processes being started.
Server processes are started under the following conditions:
When you start RMAN and connect to your target database
When you connect to your catalog -- if you are using a recovery catalog database
When you allocate and open an I/O channel during a backup or recovery operation
1.2.3 Channels
A channel is an RMAN server process started when there is a need to communicate with an I/O
device, such as a disk or a tape. A channel is what reads and writes RMAN backup files. Any time
you issue an RMAN allocate channel command, a server process is started on the target database
server. It is through the allocation of channels that you govern I/O characteristics such as:
Type of I/O device being read or written to, either a disk or an sbt_tape
Number of processes simultaneously accessing an I/O device
Maximum size of files created on I/O devices
Maximum rate at which database files are read
Maximum number of files open at a time
22905759.054.png 22905759.055.png 22905759.056.png 22905759.001.png 22905759.002.png 22905759.003.png 22905759.004.png 22905759.005.png 22905759.006.png 22905759.007.png 22905759.008.png 22905759.009.png 22905759.010.png 22905759.011.png 22905759.012.png 22905759.013.png 22905759.014.png 22905759.015.png 22905759.016.png 22905759.017.png 22905759.018.png 22905759.019.png 22905759.020.png 22905759.021.png 22905759.022.png 22905759.023.png 22905759.024.png 22905759.025.png 22905759.026.png 22905759.027.png 22905759.028.png 22905759.029.png 22905759.030.png 22905759.031.png 22905759.032.png 22905759.033.png 22905759.034.png 22905759.035.png 22905759.036.png 22905759.037.png 22905759.038.png 22905759.039.png 22905759.040.png 22905759.041.png 22905759.042.png 22905759.043.png 22905759.044.png 22905759.045.png 22905759.046.png 22905759.047.png 22905759.048.png 22905759.049.png 22905759.050.png 22905759.052.png 22905759.053.png
Zgłoś jeśli naruszono regulamin