|Oracle® Database Backup and Recovery Reference
11g Release 2 (11.2)
Part Number E10643-03
RMAN connections to a database are specified and authenticated in the same way as SQL*Plus connections to a database. The only difference is that RMAN connections to a target or auxiliary database require the
SYSDBA privilege. The
AS SYSDBA keywords are implied and cannot be explicitly specified. See Oracle Database Administrator's Guide to learn about database connection options when using SQL*Plus.
Caution:Good security practice requires that passwords should not be entered in plain text on the command line. You should enter passwords in RMAN only when requested by an RMAN prompt. See Oracle Database Security Guide to learn about password protection.
RMANfor command-line connection options
You can only run the
CONNECT CATALOG, and
CONNECT AUXILIARY commands at the RMAN prompt and only if RMAN is not already connected to the databases specified by these commands. To connect to a different target, catalog, or auxiliary database you must start a new RMAN session.
An RMAN session runs in
NOCATALOG mode by default if all of the following conditions are met:
You did not specify
NOCATALOG when you started
You have not yet run
CONNECT CATALOG in an RMAN session.
||Establishes a connection between RMAN and an auxiliary database instance.|
||Establishes a connection between RMAN and a recovery catalog database.
If the recovery catalog is a virtual private catalog (see
RMAN issues an
Note: You must use RMAN with a recovery catalog in a Data Guard environment.
||Establishes a connection between RMAN and a target database.
Note: RMAN can connect to physical standby databases as
||Specifies the connection information for the database.|
Example 2-50 Connecting to a Target Database Without a Recovery Catalog
This example starts RMAN in
NOCATALOG mode and then connects to the target database with an Oracle Net service name
prod1. RMAN prompts for the
% rman NOCATALOG RMAN> CONNECT TARGET SYS@prod1; target database Password: password connected to target database: PROD1 (DBID=39525561)
Example 2-51 Connecting to a Target Database in the Default NOCATALOG Mode
This example starts RMAN without specifying either
NOCATALOG and then uses operating system authentication to connect to a target database with operating system authentication. Because no
CONNECT CATALOG command has been run, RMAN defaults to
NOCATALOG mode when you run the
% rman RMAN> CONNECT TARGET / RMAN> BACKUP DATABASE;
At this point in the RMAN session, you cannot run
CONNECT CATALOG because the session has defaulted to
NOCATALOG mode. An attempt to connect to the catalog in this session receives an error:
RMAN> CONNECT CATALOG rman@catdb RMAN-00571: =========================================================== RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS =============== RMAN-00571: =========================================================== RMAN-06445: cannot connect to recovery catalog after NOCATALOG has been used
Example 2-52 Connecting to Target, Recovery Catalog, and Auxiliary Databases
This example connects to a target database by means of operating system authentication and connects to the recovery catalog and auxiliary databases by means of password files. RMAN prompts for the password.
% rman RMAN> CONNECT TARGET; connected to target database: PROD (DBID=39525561) RMAN> CONNECT CATALOG rman@catdb; recovery catalog database Password: password connected to recovery catalog database RMAN> CONNECT AUXILIARY SYS@dupdb; auxiliary database Password: password connected to auxiliary database: DUPDB (not mounted)