Database Reference
In-Depth Information
1. Running the RMAN Client Remotely or Locally
It's possible to run the rman utility from a remote server and connect to a target database via Oracle Net:
$ rman target sys/foo@remote_db
This allows you to run RMAN backups on disparate remote servers from one central location. When you run
RMAN remotely, the backup files are always created on the target database server.
Whenever possible, I run the rman client locally on the target server and connect, like this:
$ rman target /
This approach is simple and adequate for most requirements. You don't have to worry about network issues or
password files, and there are never compatibility issues with the rman client and the target database. If you run RMAN
remotely, you need to be sure the remote rman executable is compatible with the target database. For example, you
may establish that the remote rman executable you're running is an Oracle 12c version of the RMAN client and need to
determine if it's possible to connect that client to a remote Oracle 9i target database. If you run the rman client locally
on the target server, there is never a compatibility issue because the rman client is always the same version as the
target database.
2. Specifying the Backup User
As discussed previously, RMAN requires that you use a database user with SYSDBA privileges. Whether I'm running
RMAN from the command line or invoking RMAN in a script, in most scenarios, I connect directly as SYS to the target
database. For example, here is how I connect to RMAN from the command line:
$ rman target /
Some DBAs don't use this approach; they opt to set up a user separate from SYS and cite security concerns as a
rationale for doing this.
I prefer to use the SYS account directly, because when connecting to RMAN locally on the server, there is no need
to specify a username and password. This means that you never have to hard-code usernames and passwords into any
backup scripts or specify a username and password on the command line that can be viewed by rogue developers or
managers looking over your shoulder.
3. Using Online or Offline Backups
Most production databases have 24-7 availability requirements. Therefore, your only option is online RMAN backups.
Your database must be in archivelog mode for online backups. You need to consider carefully to place archive redo
logs, how to format them, how often to back them up, and how long to retain them before deletion. These topics are
discussed in subsequent sections.
if you make offline backups, you must shut down your database with IMMEDIATE , NORMAL , or TRANSACTIONAL
and then place it in mount mode. rMan needs the database in mount mode so that it can read from and write to the
control file.
Note
 
 
Search WWH ::




Custom Search