SQL> alter database archivelog;
alter database archivelog
*
ERROR at line 1:
ORA-01126: database must be mounted in this instance and not open in any
instance
SQL> shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> conn /as sysdba
Connected to an idle instance.
SQL> startup mount
ORACLE instance started.
Total System Global Area 285212672 bytes
Fixed Size 1267044 bytes
Variable Size 134220444 bytes
Database Buffers 142606336 bytes
Redo Buffers 7118848 bytes
Database mounted.
SQL> alter database archivelog;
Database altered.
SQL> archive log list
Database log mode Archive Mode
Automatic archival Enabled
Archive destination USE_DB_RECOVERY_FILE_DEST
Oldest online log sequence 30
Next log sequence to archive 32
Current log sequence 32
SQL>
SQL> alter database open
2 ;
Database altered.
SQL> select name from v$datafile;
NAME
--------------------------------------------------------------------------------
/home/oracle/app/oracle/oradata/rac1/system01.dbf
/home/oracle/app/oracle/oradata/rac1/undotbs01.dbf
/home/oracle/app/oracle/oradata/rac1/sysaux01.dbf
/home/oracle/app/oracle/oradata/rac1/users01.dbf
/home/oracle/app/oracle/oradata/rac1/test.dbf
SQL>
SQL>
SQL> select * from v$log;
GROUP# THREAD# SEQUENCE# BYTES MEMBERS ARCHIVED
---------- ---------- ---------- ---------- ---------- ---------
STATUS FIRST_CHANGE# FIRST_TIME
------------------------------------------------ ------------- ---------------
1 1 31 52428800 1 YES
INACTIVE 447809 13-MAY-11
2 1 32 52428800 1 NO
CURRENT 449829 13-MAY-11
3 1 30 52428800 1 YES
INACTIVE 410455 07-MAY-11
SQL> select * from v$logfile;
GROUP# STATUS TYPE
---------- --------------------- ---------------------
MEMBER
--------------------------------------------------------------------------------
IS_RECOVE
---------
1 ONLINE
/home/oracle/app/oracle/oradata/rac1/redo01.log
NO
2 ONLINE
/home/oracle/app/oracle/oradata/rac1/redo02.log
NO
GROUP# STATUS TYPE
---------- --------------------- ---------------------
MEMBER
--------------------------------------------------------------------------------
IS_RECOVE
---------
3 ONLINE
/home/oracle/app/oracle/oradata/rac1/redo03.log
NO
SQL>
SQL> select name from v$archived_log;
no rows selected
[oracle@ora01 ~]$
[oracle@ora01 ~]$ rman target / nocatalog
Recovery Manager: Release 10.2.0.4.0 - Production on Sat May 14 00:44:11 2011
Copyright (c) 1982, 2007, Oracle. All rights reserved.
connected to target database: RAC1 (DBID=654422300)
using target database control file instead of recovery catalog
RMAN>
RMAN> backup database plus archivelog
2> ;
Starting backup at 14-MAY-11
current log archived
allocated channel: ORA_DISK_1
channel ORA_DISK_1: sid=142 devtype=DISK
channel ORA_DISK_1: starting archive log backupset
channel ORA_DISK_1: specifying archive log(s) in backup set
input archive log thread=1 sequence=32 recid=1 stamp=751078378
channel ORA_DISK_1: starting piece 1 at 14-MAY-11
channel ORA_DISK_1: finished piece 1 at 14-MAY-11
piece handle=/home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_annnn_TAG20110514T005258_6wwf6w7s_.bkp tag=TAG20110514T005258 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:00:02
Finished backup at 14-MAY-11
Starting backup at 14-MAY-11
using channel ORA_DISK_1
channel ORA_DISK_1: starting full datafile backupset
channel ORA_DISK_1: specifying datafile(s) in backupset
input datafile fno=00001 name=/home/oracle/app/oracle/oradata/rac1/system01.dbf
input datafile fno=00002 name=/home/oracle/app/oracle/oradata/rac1/undotbs01.dbf
input datafile fno=00003 name=/home/oracle/app/oracle/oradata/rac1/sysaux01.dbf
input datafile fno=00004 name=/home/oracle/app/oracle/oradata/rac1/users01.dbf
input datafile fno=00005 name=/home/oracle/app/oracle/oradata/rac1/test.dbf
channel ORA_DISK_1: starting piece 1 at 14-MAY-11
RMAN-03009: failure of backup command on ORA_DISK_1 channel at 05/14/2011 00:56:08
ORA-19809: limit exceeded for recovery files
ORA-19804: cannot reclaim 52428800 bytes disk space from 268435456 limit
continuing other job steps, job failed will not be re-run
channel ORA_DISK_1: starting full datafile backupset
channel ORA_DISK_1: specifying datafile(s) in backupset
including current control file in backupset
including current SPFILE in backupset
channel ORA_DISK_1: starting piece 1 at 14-MAY-11
channel ORA_DISK_1: finished piece 1 at 14-MAY-11
piece handle=/home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_ncsnf_TAG20110514T005301_6wwfdws6_.bkp tag=TAG20110514T005301 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:00:07
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of backup plus archivelog command at 05/14/2011 00:56:15
RMAN-03009: failure of backup command on ORA_DISK_1 channel at 05/14/2011 00:56:08
ORA-19809: limit exceeded for recovery files
ORA-19804: cannot reclaim 52428800 bytes disk space from 268435456 limit
RMAN>
RMAN>
RMAN> show all
2> ;
RMAN configuration parameters are:
CONFIGURE RETENTION POLICY TO REDUNDANCY 1; # default
CONFIGURE BACKUP OPTIMIZATION OFF; # default
CONFIGURE DEFAULT DEVICE TYPE TO DISK; # default
CONFIGURE CONTROLFILE AUTOBACKUP OFF; # default
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '%F'; # default
CONFIGURE DEVICE TYPE DISK PARALLELISM 1 BACKUP TYPE TO BACKUPSET; # default
CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE MAXSETSIZE TO UNLIMITED; # default
CONFIGURE ENCRYPTION FOR DATABASE OFF; # default
CONFIGURE ENCRYPTION ALGORITHM 'AES128'; # default
CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default
CONFIGURE SNAPSHOT CONTROLFILE NAME TO '/home/oracle/app/oracle/product/10.2.0/db/dbs/snapcf_rac1.f'; # default
RMAN> backup database archivelog ;
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-00558: error encountered while parsing input commands
RMAN-01009: syntax error: found ";": expecting one of: "all, from, high, like, logseq, low, scn, sequence, time, until"
RMAN-01007: at line 1 column 28 file: standard input
RMAN> backup database plus archivelog
2> ;
Starting backup at 14-MAY-11
current log archived
using channel ORA_DISK_1
channel ORA_DISK_1: starting archive log backupset
channel ORA_DISK_1: specifying archive log(s) in backup set
input archive log thread=1 sequence=32 recid=1 stamp=751078378
input archive log thread=1 sequence=33 recid=2 stamp=751080417
channel ORA_DISK_1: starting piece 1 at 14-MAY-11
channel ORA_DISK_1: finished piece 1 at 14-MAY-11
piece handle=/home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_annnn_TAG20110514T012657_6wwh6m3v_.bkp tag=TAG20110514T012657 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:00:02
Finished backup at 14-MAY-11
Starting backup at 14-MAY-11
using channel ORA_DISK_1
channel ORA_DISK_1: starting full datafile backupset
channel ORA_DISK_1: specifying datafile(s) in backupset
input datafile fno=00001 name=/home/oracle/app/oracle/oradata/rac1/system01.dbf
input datafile fno=00002 name=/home/oracle/app/oracle/oradata/rac1/undotbs01.dbf
input datafile fno=00003 name=/home/oracle/app/oracle/oradata/rac1/sysaux01.dbf
input datafile fno=00004 name=/home/oracle/app/oracle/oradata/rac1/users01.dbf
input datafile fno=00005 name=/home/oracle/app/oracle/oradata/rac1/test.dbf
channel ORA_DISK_1: starting piece 1 at 14-MAY-11
channel ORA_DISK_1: finished piece 1 at 14-MAY-11
piece handle=/home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_nnndf_TAG20110514T012700_6wwh6nrb_.bkp tag=TAG20110514T012700 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:02:15
channel ORA_DISK_1: starting full datafile backupset
channel ORA_DISK_1: specifying datafile(s) in backupset
including current control file in backupset
including current SPFILE in backupset
channel ORA_DISK_1: starting piece 1 at 14-MAY-11
channel ORA_DISK_1: finished piece 1 at 14-MAY-11
piece handle=/home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_ncsnf_TAG20110514T012700_6wwhby0w_.bkp tag=TAG20110514T012700 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:00:03
Finished backup at 14-MAY-11
Starting backup at 14-MAY-11
current log archived
using channel ORA_DISK_1
channel ORA_DISK_1: starting archive log backupset
channel ORA_DISK_1: specifying archive log(s) in backup set
input archive log thread=1 sequence=34 recid=3 stamp=751080559
channel ORA_DISK_1: starting piece 1 at 14-MAY-11
channel ORA_DISK_1: finished piece 1 at 14-MAY-11
piece handle=/home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_annnn_TAG20110514T012919_6wwhc0to_.bkp tag=TAG20110514T012919 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:00:02
Finished backup at 14-MAY-11
RMAN> exit
Recovery Manager complete.
[oracle@ora01 ~]$ sqlplus /nolog
SQL*Plus: Release 10.2.0.4.0 - Production on Sat May 14 01:37:33 2011
Copyright (c) 1982, 2007, Oracle. All Rights Reserved.
SQL> conn /as sysdba
selConnected.
SQL> select * from v$log;
GROUP# THREAD# SEQUENCE# BYTES MEMBERS ARCHIVED
---------- ---------- ---------- ---------- ---------- ---------
STATUS FIRST_CHANGE# FIRST_TIME
------------------------------------------------ ------------- ---------------
1 1 34 52428800 1 YES
INACTIVE 455796 14-MAY-11
2 1 35 52428800 1 NO
CURRENT 455870 14-MAY-11
3 1 33 52428800 1 YES
INACTIVE 454352 14-MAY-11
SQL> set linesize 1000;
SQL> /
GROUP# THREAD# SEQUENCE# BYTES MEMBERS ARCHIVED STATUS FIRST_CHANGE# FIRST_TIME
---------- ---------- ---------- ---------- ---------- --------- ------------------------------------------------ ------------- ---------------
1 1 34 52428800 1 YES INACTIVE 455796 14-MAY-11
2 1 35 52428800 1 NO CURRENT 455870 14-MAY-11
3 1 33 52428800 1 YES INACTIVE 454352 14-MAY-11
SQL>
SQL>
SQL>
SQL> alter system switch log
2 ;
alter system switch log
*
ERROR at line 1:
ORA-01900: LOGFILE keyword expected
SQL> alter system switch logfile;
System altered.
SQL>
SQL>
SQL> select * from v$log;
GROUP# THREAD# SEQUENCE# BYTES MEMBERS ARCHIVED STATUS FIRST_CHANGE# FIRST_TIME
---------- ---------- ---------- ---------- ---------- --------- ------------------------------------------------ ------------- ---------------
1 1 34 52428800 1 YES INACTIVE 455796 14-MAY-11
2 1 35 52428800 1 YES ACTIVE 455870 14-MAY-11
3 1 36 52428800 1 NO CURRENT 456164 14-MAY-11
SQL>
SQL>
SQL> shutdown about
SP2-0717: illegal SHUTDOWN option
SQL> shutdown abort
ORACLE instance shut down.
SQL> exit
Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
[oracle@ora01 ~]$
[oracle@ora01 ~]$
[oracle@ora01 ~]$
[oracle@ora01 ~]$
[oracle@ora01 ~]$ rman target / nocatalog
Recovery Manager: Release 10.2.0.4.0 - Production on Sat May 14 01:53:59 2011
Copyright (c) 1982, 2007, Oracle. All rights reserved.
connected to target database (not started)
RMAN> set dbid=
2> 654422300
executing command: SET DBID
RMAN> startup force nomount;
Oracle instance started
Total System Global Area 285212672 bytes
Fixed Size 1267044 bytes
Variable Size 134220444 bytes
Database Buffers 142606336 bytes
Redo Buffers 7118848 bytes
RMAN> show all
2> ;
RMAN configuration parameters are:
CONFIGURE RETENTION POLICY TO REDUNDANCY 1; # default
CONFIGURE BACKUP OPTIMIZATION OFF; # default
CONFIGURE DEFAULT DEVICE TYPE TO DISK; # default
CONFIGURE CONTROLFILE AUTOBACKUP OFF; # default
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '%F'; # default
CONFIGURE DEVICE TYPE DISK PARALLELISM 1 BACKUP TYPE TO BACKUPSET; # default
CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE MAXSETSIZE TO UNLIMITED; # default
CONFIGURE ENCRYPTION FOR DATABASE OFF; # default
CONFIGURE ENCRYPTION ALGORITHM 'AES128'; # default
CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default
RMAN> set controlfile autobackup format for device type disk to '/home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/%F';
executing command: SET CONTROLFILE AUTOBACKUP FORMAT
RMAN> restore controlfile from autobackup;
Starting restore at 14-MAY-11
allocated channel: ORA_DISK_1
channel ORA_DISK_1: sid=156 devtype=DISK
recovery area destination: /home/oracle/app/oracle/flash_recovery_area
database name (or database unique name) used for search: RAC1
channel ORA_DISK_1: no autobackups found in the recovery area
channel ORA_DISK_1: looking for autobackup on day: 20110514
channel ORA_DISK_1: looking for autobackup on day: 20110513
channel ORA_DISK_1: looking for autobackup on day: 20110512
channel ORA_DISK_1: looking for autobackup on day: 20110511
channel ORA_DISK_1: looking for autobackup on day: 20110510
channel ORA_DISK_1: looking for autobackup on day: 20110509
channel ORA_DISK_1: looking for autobackup on day: 20110508
channel ORA_DISK_1: no autobackup in 7 days found
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of restore command at 05/14/2011 01:57:24
RMAN-06172: no autobackup found or specified handle is not a valid copy or piece
RMAN>
RMAN> set controlfile autobackup format for device type disk to '/home/oracle/app/oracle/flash_recovery_area/%F';
executing command: SET CONTROLFILE AUTOBACKUP FORMAT
RMAN> restore controlfile from autobackup;
Starting restore at 14-MAY-11
using channel ORA_DISK_1
recovery area destination: /home/oracle/app/oracle/flash_recovery_area
database name (or database unique name) used for search: RAC1
channel ORA_DISK_1: no autobackups found in the recovery area
channel ORA_DISK_1: looking for autobackup on day: 20110514
channel ORA_DISK_1: looking for autobackup on day: 20110513
channel ORA_DISK_1: looking for autobackup on day: 20110512
channel ORA_DISK_1: looking for autobackup on day: 20110511
channel ORA_DISK_1: looking for autobackup on day: 20110510
channel ORA_DISK_1: looking for autobackup on day: 20110509
channel ORA_DISK_1: looking for autobackup on day: 20110508
channel ORA_DISK_1: no autobackup in 7 days found
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of restore command at 05/14/2011 01:59:07
RMAN-06172: no autobackup found or specified handle is not a valid copy or piece
RMAN>
RMAN> set controlfile autobackup format for device type disk to '/home/oracle/app/oracle/flash_recovery_area';
executing command: SET CONTROLFILE AUTOBACKUP FORMAT
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of CSET command at 05/14/2011 01:59:43
RMAN-06492: controlfile autobackup format "/home/oracle/app/oracle/flash_recovery_area" must specify a "%F" format specifier
RMAN>
RMAN>
RMAN>
RMAN>
RMAN> set controlfile autobackup format for device type disk to '/home/oracle/app/oracle/flash_recovery_area/%F';
executing command: SET CONTROLFILE AUTOBACKUP FORMAT
RMAN> restore controlfile from autobackup;
Starting restore at 14-MAY-11
using channel ORA_DISK_1
recovery area destination: /home/oracle/app/oracle/flash_recovery_area
database name (or database unique name) used for search: RAC1
channel ORA_DISK_1: no autobackups found in the recovery area
channel ORA_DISK_1: looking for autobackup on day: 20110514
channel ORA_DISK_1: looking for autobackup on day: 20110513
channel ORA_DISK_1: looking for autobackup on day: 20110512
channel ORA_DISK_1: looking for autobackup on day: 20110511
channel ORA_DISK_1: looking for autobackup on day: 20110510
channel ORA_DISK_1: looking for autobackup on day: 20110509
channel ORA_DISK_1: looking for autobackup on day: 20110508
channel ORA_DISK_1: no autobackup in 7 days found
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of restore command at 05/14/2011 02:00:38
RMAN-06172: no autobackup found or specified handle is not a valid copy or piece
RMAN> show all
2> ;
RMAN configuration parameters are:
CONFIGURE RETENTION POLICY TO REDUNDANCY 1; # default
CONFIGURE BACKUP OPTIMIZATION OFF; # default
CONFIGURE DEFAULT DEVICE TYPE TO DISK; # default
CONFIGURE CONTROLFILE AUTOBACKUP OFF; # default
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '%F'; # default
CONFIGURE DEVICE TYPE DISK PARALLELISM 1 BACKUP TYPE TO BACKUPSET; # default
CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE MAXSETSIZE TO UNLIMITED; # default
CONFIGURE ENCRYPTION FOR DATABASE OFF; # default
CONFIGURE ENCRYPTION ALGORITHM 'AES128'; # default
CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default
RMAN>
RMAN>
RMAN>
RMAN>
RMAN>
RMAN>
RMAN>
RMAN>
RMAN> set controlfile autobackup format for device type disk to '/home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/%F';
executing command: SET CONTROLFILE AUTOBACKUP FORMAT
RMAN>
RMAN> restore controlfile autobackup;
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-00558: error encountered while parsing input commands
RMAN-01009: syntax error: found "autobackup": expecting one of: "archivelog, channel, check, controlfile, clone, database, datafile, device, from, force, high, (, preview, ;, spfile, standby, tablespace, to, until, validate"
RMAN-01007: at line 2 column 21 file: standard input
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-00558: error encountered while parsing input commands
RMAN-01009: syntax error: found ";": expecting one of: "allocate, alter, backup, beginline, blockrecover, catalog, change, connect, copy, convert, create, crosscheck, configure, duplicate, debug, delete, drop, exit, endinline, flashback, host, {, library, list, mount, open, print, quit, recover, register, release, replace, report, renormalize, reset, restore, resync, rman, run, rpctest, set, setlimit, sql, switch, spool, startup, shutdown, send, show, test, transport, upgrade, unregister, validate"
RMAN-01007: at line 2 column 31 file: standard input
RMAN>
RMAN> restore controlfile from autobackup;
Starting restore at 14-MAY-11
using channel ORA_DISK_1
recovery area destination: /home/oracle/app/oracle/flash_recovery_area
database name (or database unique name) used for search: RAC1
channel ORA_DISK_1: no autobackups found in the recovery area
channel ORA_DISK_1: looking for autobackup on day: 20110514
channel ORA_DISK_1: looking for autobackup on day: 20110513
channel ORA_DISK_1: looking for autobackup on day: 20110512
channel ORA_DISK_1: looking for autobackup on day: 20110511
channel ORA_DISK_1: looking for autobackup on day: 20110510
channel ORA_DISK_1: looking for autobackup on day: 20110509
channel ORA_DISK_1: looking for autobackup on day: 20110508
channel ORA_DISK_1: no autobackup in 7 days found
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of restore command at 05/14/2011 02:05:01
RMAN-06172: no autobackup found or specified handle is not a valid copy or piece
RMAN>
RMAN>
RMAN>
RMAN> show all
2> ;
RMAN configuration parameters are:
CONFIGURE RETENTION POLICY TO REDUNDANCY 1; # default
CONFIGURE BACKUP OPTIMIZATION OFF; # default
CONFIGURE DEFAULT DEVICE TYPE TO DISK; # default
CONFIGURE CONTROLFILE AUTOBACKUP OFF; # default
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '%F'; # default
CONFIGURE DEVICE TYPE DISK PARALLELISM 1 BACKUP TYPE TO BACKUPSET; # default
CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE MAXSETSIZE TO UNLIMITED; # default
CONFIGURE ENCRYPTION FOR DATABASE OFF; # default
CONFIGURE ENCRYPTION ALGORITHM 'AES128'; # default
CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default
RMAN>
RMAN> startup force mount
Oracle instance started
database mounted
Total System Global Area 285212672 bytes
Fixed Size 1267044 bytes
Variable Size 134220444 bytes
Database Buffers 142606336 bytes
Redo Buffers 7118848 bytes
RMAN> restore database
2> ;
Starting restore at 14-MAY-11
allocated channel: ORA_DISK_1
channel ORA_DISK_1: sid=157 devtype=DISK
channel ORA_DISK_1: starting datafile backupset restore
channel ORA_DISK_1: specifying datafile(s) to restore from backup set
restoring datafile 00001 to /home/oracle/app/oracle/oradata/rac1/system01.dbf
restoring datafile 00002 to /home/oracle/app/oracle/oradata/rac1/undotbs01.dbf
restoring datafile 00003 to /home/oracle/app/oracle/oradata/rac1/sysaux01.dbf
restoring datafile 00004 to /home/oracle/app/oracle/oradata/rac1/users01.dbf
restoring datafile 00005 to /home/oracle/app/oracle/oradata/rac1/test.dbf
channel ORA_DISK_1: reading from backup piece /home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_nnndf_TAG20110514T012700_6wwh6nrb_.bkp
channel ORA_DISK_1: restored backup piece 1
piece handle=/home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_nnndf_TAG20110514T012700_6wwh6nrb_.bkp tag=TAG20110514T012700
channel ORA_DISK_1: restore complete, elapsed time: 00:02:26
Finished restore at 14-MAY-11
RMAN> recover database
2> ;
Starting recover at 14-MAY-11
using channel ORA_DISK_1
starting media recovery
media recovery complete, elapsed time: 00:00:05
Finished recover at 14-MAY-11
RMAN> alter database open;
database opened
RMAN> show all
2> ;
RMAN configuration parameters are:
CONFIGURE RETENTION POLICY TO REDUNDANCY 1; # default
CONFIGURE BACKUP OPTIMIZATION OFF; # default
CONFIGURE DEFAULT DEVICE TYPE TO DISK; # default
CONFIGURE CONTROLFILE AUTOBACKUP OFF; # default
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '%F'; # default
CONFIGURE DEVICE TYPE DISK PARALLELISM 1 BACKUP TYPE TO BACKUPSET; # default
CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE MAXSETSIZE TO UNLIMITED; # default
CONFIGURE ENCRYPTION FOR DATABASE OFF; # default
CONFIGURE ENCRYPTION ALGORITHM 'AES128'; # default
CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default
CONFIGURE SNAPSHOT CONTROLFILE NAME TO '/home/oracle/app/oracle/product/10.2.0/db/dbs/snapcf_rac1.f'; # default
RMAN>
RMAN>
RMAN> configure controlfile autobackup on;
new RMAN configuration parameters:
CONFIGURE CONTROLFILE AUTOBACKUP ON;
new RMAN configuration parameters are successfully stored
RMAN> configure channel device type disk format '/home/oracle/app/oracle/backup/%U';
new RMAN configuration parameters:
CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT '/home/oracle/app/oracle/backup/%U';
new RMAN configuration parameters are successfully stored
released channel: ORA_DISK_1
RMAN>
RMAN>
RMAN> select * from v$controlfile;
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-00558: error encountered while parsing input commands
RMAN-01009: syntax error: found "identifier": expecting one of: "allocate, alter, backup, beginline, blockrecover, catalog, change, connect, copy, convert, create, crosscheck, configure, duplicate, debug, delete, drop, exit, endinline, flashback, host, {, library, list, mount, open, print, quit, recover, register, release, replace, report, renormalize, reset, restore, resync, rman, run, rpctest, set, setlimit, sql, switch, spool, startup, shutdown, send, show, test, transport, upgrade, unregister, validate"
RMAN-01008: the bad identifier was: select
RMAN-01007: at line 1 column 1 file: standard input
RMAN> SHOW CONTROLFILE AUTOBACKUP FORMAT;
RMAN configuration parameters are:
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '%F'; # default
RMAN>
RMAN>
RMAN>
RMAN>
RMAN> show all
2> ;
RMAN configuration parameters are:
CONFIGURE RETENTION POLICY TO REDUNDANCY 1; # default
CONFIGURE BACKUP OPTIMIZATION OFF; # default
CONFIGURE DEFAULT DEVICE TYPE TO DISK; # default
CONFIGURE CONTROLFILE AUTOBACKUP ON;
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '%F'; # default
CONFIGURE DEVICE TYPE DISK PARALLELISM 1 BACKUP TYPE TO BACKUPSET; # default
CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT '/home/oracle/app/oracle/backup/%U';
CONFIGURE MAXSETSIZE TO UNLIMITED; # default
CONFIGURE ENCRYPTION FOR DATABASE OFF; # default
CONFIGURE ENCRYPTION ALGORITHM 'AES128'; # default
CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default
CONFIGURE SNAPSHOT CONTROLFILE NAME TO '/home/oracle/app/oracle/product/10.2.0/db/dbs/snapcf_rac1.f'; # default
RMAN> list backup controlfile ;
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-00558: error encountered while parsing input commands
RMAN-01009: syntax error: found ";": expecting one of: "double-quoted-string, integer, single-quoted-string, tag"
RMAN-01007: at line 1 column 25 file: standard input
RMAN> list backup of controlfile
2> ;
List of Backup Sets
===================
BS Key Type LV Size Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
1 Full 6.80M DISK 00:00:06 14-MAY-11
BP Key: 1 Status: AVAILABLE Compressed: NO Tag: TAG20110514T000125
Piece Name: /home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_ncsnf_TAG20110514T000125_6wwb6b9c_.bkp
Control File Included: Ckp SCN: 451358 Ckp time: 14-MAY-11
BS Key Type LV Size Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
3 Full 6.80M DISK 00:00:05 14-MAY-11
BP Key: 3 Status: AVAILABLE Compressed: NO Tag: TAG20110514T005301
Piece Name: /home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_ncsnf_TAG20110514T005301_6wwfdws6_.bkp
Control File Included: Ckp SCN: 454454 Ckp time: 14-MAY-11
BS Key Type LV Size Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
6 Full 6.80M DISK 00:00:02 14-MAY-11
BP Key: 6 Status: AVAILABLE Compressed: NO Tag: TAG20110514T012700
Piece Name: /home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_ncsnf_TAG20110514T012700_6wwhby0w_.bkp
Control File Included: Ckp SCN: 455866 Ckp time: 14-MAY-11
RMAN>
RMAN>
RMAN>
RMAN>
RMAN> crosscheck backup of controlfile;
allocated channel: ORA_DISK_1
channel ORA_DISK_1: sid=157 devtype=DISK
crosschecked backup piece: found to be 'AVAILABLE'
backup piece handle=/home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_ncsnf_TAG20110514T000125_6wwb6b9c_.bkp recid=1 stamp=751075289
crosschecked backup piece: found to be 'AVAILABLE'
backup piece handle=/home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_ncsnf_TAG20110514T005301_6wwfdws6_.bkp recid=3 stamp=751078572
crosschecked backup piece: found to be 'AVAILABLE'
backup piece handle=/home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_ncsnf_TAG20110514T012700_6wwhby0w_.bkp recid=6 stamp=751080558
Crosschecked 3 objects
RMAN>
RMAN> delete backup;
using channel ORA_DISK_1
List of Backup Pieces
BP Key BS Key Pc# Cp# Status Device Type Piece Name
------- ------- --- --- ----------- ----------- ----------
1 1 1 1 AVAILABLE DISK /home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_ncsnf_TAG20110514T000125_6wwb6b9c_.bkp
2 2 1 1 AVAILABLE DISK /home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_annnn_TAG20110514T005258_6wwf6w7s_.bkp
3 3 1 1 AVAILABLE DISK /home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_ncsnf_TAG20110514T005301_6wwfdws6_.bkp
4 4 1 1 AVAILABLE DISK /home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_annnn_TAG20110514T012657_6wwh6m3v_.bkp
5 5 1 1 AVAILABLE DISK /home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_nnndf_TAG20110514T012700_6wwh6nrb_.bkp
6 6 1 1 AVAILABLE DISK /home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_ncsnf_TAG20110514T012700_6wwhby0w_.bkp
7 7 1 1 AVAILABLE DISK /home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_annnn_TAG20110514T012919_6wwhc0to_.bkp
Do you really want to delete the above objects (enter YES or NO)? yes
deleted backup piece
backup piece handle=/home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_ncsnf_TAG20110514T000125_6wwb6b9c_.bkp recid=1 stamp=751075289
deleted backup piece
backup piece handle=/home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_annnn_TAG20110514T005258_6wwf6w7s_.bkp recid=2 stamp=751078380
deleted backup piece
backup piece handle=/home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_ncsnf_TAG20110514T005301_6wwfdws6_.bkp recid=3 stamp=751078572
deleted backup piece
backup piece handle=/home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_annnn_TAG20110514T012657_6wwh6m3v_.bkp recid=4 stamp=751080419
deleted backup piece
backup piece handle=/home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_nnndf_TAG20110514T012700_6wwh6nrb_.bkp recid=5 stamp=751080420
deleted backup piece
backup piece handle=/home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_ncsnf_TAG20110514T012700_6wwhby0w_.bkp recid=6 stamp=751080558
deleted backup piece
backup piece handle=/home/oracle/app/oracle/flash_recovery_area/RAC1/backupset/2011_05_14/o1_mf_annnn_TAG20110514T012919_6wwhc0to_.bkp recid=7 stamp=751080560
Deleted 7 objects
RMAN>
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/22434753/viewspace-695369/ ,如需转载,请注明出处,否则将追究法律责任。