| Oracle9i Recovery Manager Reference Release 2 (9.2) Part Number A96565-01 |
|
RMAN Commands , 12 of 59

To make the following changes:
AVAILABLE or UNAVAILABLE. This feature is useful when a previously unavailable file is made available again, or you do not want a specific backup or copy to be eligible to be restored but also do not want to delete it.DELETED. This feature is useful when you remove a file by using an operating system command rather than the RMAN CHANGE command, and want to remove its repository record as well.| See Also:
Oracle9i Recovery Manager User's Guide to change the availability status of a backup or copy, and Oracle9i Recovery Manager User's Guide to learn how to make a backup or copy exempt from the retention policy |
CHANGE command within the braces of a a RUN command or at the RMAN prompt.CHANGE only on files that are recorded in the RMAN repository and belong to the current database incarnation.KEEP FOREVER clause requires use of a recovery catalog.CHANGE command that requires either a manual or automatic maintenance channel is the CHANGE ... AVAILABLE command. However, a maintenance channel is not required when CHANGE ... AVAILABLE is used with a file that is disk only (that is, an ARCHIVELOG, DATAFILECOPY, or CONTROLFILECOPY).
If you use CHANGE ... AVAILABLE on files that are not disk-only, and have objects created on device types that are not configured for automatic channels, then issue manual maintenance commands on these channels. For example, if you created a backup on an sbt channel, but have only a DISK channel automatically configured, then you must manually allocate an sbt channel before CHANGE ... AVAILABLE can operate on the backup.
To obtain the primary keys of the records whose status you want to change, run a LIST command or query the recovery catalog views.
| Syntax Element | Description |
|---|---|
|
|
Operates on the specified backups: backup sets, backup pieces, and proxy copies. If you do not specify an option for Note: Use the |
|
|
Operates on datafile copies, archived redo logs, and image copies of archived redo logs. If you do not specify an option for |
|
|
restricts the list of objects operated on to the object type specified in the See Also: "listObjList" |
|
restricts the command based on the specified options. See Also: "maintQualifier" |
|
|
Specifies archived logs. See "archivelogRecordSpecifier". |
|
|
Specifies the object whose availability status you are changing. See "recordSpec". |
|
|
|
Changes the status of a backup or copy to |
|
|
Changes the status of a backup or copy to |
|
|
Removes references to a datafile copy or archived redo log (but not a backup piece or backup set) from the recovery catalog, and updates records in the target control file to status Caution: If you resynchronize from a backup control file, or upgrade the recovery catalog, then uncataloged records can sometimes reappear in the catalog metadata. |
|
|
Executes the |
|
Changes the exemption status of a backup or copy in relation to the configured retention policy. For example, specify Note: You can also specify See Also: "keepOption" |
This example changes the status of backup set 100 as well as all backups of server parameter files created more than one day ago to UNAVAILABLE. You do not need to allocate a maintenance channel:
CHANGE BACKUPSET 100 UNAVAILABLE; CHANGE BACKUP OF SPFILE COMPLETED BEFORE 'SYSDATE-1' UNAVAILABLE;
In this example, you first move all archived logs to a temporary directory and then uncatalog them:
HOST 'mv $ORACLE_HOME/oradata/trgt/arch/* /tmp/arch'; CHANGE COPY OF ARCHIVELOG ALL UNCATALOG; EXIT;
From the UNIX command shell you use Perl to create a command file that contains a CATALOG command for each archived log:
% perl5 -e '@files=</tmp/arch/*>; foreach (@files) \ ? {print "CATALOG ARCHIVELOG '$_'\;\n";}' > $HOME/rman.cmd
Finally, you start RMAN and run the command file to catalog the relocated logs:
% rman TARGET / @$HOME/rman.cmd
This example, which requires a recovery catalog, changes an ordinary backup into a long-term backup:
CHANGE BACKUP TAG 'consistent_db_bkup' KEEP FOREVER NOLOGS;
|
![]() Copyright © 1996, 2002 Oracle Corporation. All Rights Reserved. |
|