[oracle@server ~]$ rman target/
Recovery Manager: Release 10.2.0.1.0 - Production on Fri Jan 7 00:05:03 2011
Copyright (c) 1982, 2005, Oracle. All rights reserved.
connected to target database: orcl (not mounted)
RMAN> set DBID=1266181584
executing command: SET DBID
RMAN> restore controlfile from '/oracle/databak/bak/ctl_1';
Starting restore at 07-JAN-11
using target database control file instead of recovery catalog
allocated channel: ORA_DISK_1
channel ORA_DISK_1: sid=157 devtype=DISK
channel ORA_DISK_1: restoring control file
channel ORA_DISK_1: restore complete, elapsed time: 00:00:01
output filename=/oracle/product/10.2.0/oradata/orcl/control01.ctl
output filename=/oracle/product/10.2.0/oradata/orcl/control02.ctl
output filename=/oracle/product/10.2.0/oradata/orcl/control03.ctl
Finished restore at 07-JAN-11
RMAN> restore database;
Starting restore at 07-JAN-11
using channel ORA_DISK_1
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of restore command at 01/07/2011 00:07:00
ORA-01507: database not mounted
RMAN> mount database;
database mounted
released channel: ORA_DISK_1
RMAN> restore database;
Starting restore at 07-JAN-11
Starting implicit crosscheck backup at 07-JAN-11
allocated channel: ORA_DISK_1
channel ORA_DISK_1: sid=157 devtype=DISK
Crosschecked 6 objects
Finished implicit crosscheck backup at 07-JAN-11
Starting implicit crosscheck copy at 07-JAN-11
using channel ORA_DISK_1
Crosschecked 1 objects
Finished implicit crosscheck copy at 07-JAN-11
searching for all files in the recovery area
cataloging files...
cataloging done
List of Cataloged Files
=======================
File Name: /oracle/flash_recovery_area/ORCL/archivelog/o1_mf_1_28_6klst74t_.arc
File Name: /oracle/flash_recovery_area/ORCL/archivelog/o1_mf_1_31_6klsymnn_.arc
File Name: /oracle/flash_recovery_area/ORCL/archivelog/o1_mf_1_27_6klrro8t_.arc
File Name: /oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_94_6lcn7kgh_.arc
File Name: /oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_96_6lcn7kcz_.arc
File Name: /oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_91_6lblh1k9_.arc
File Name: /oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_95_6lcn7kb0_.arc
File Name: /oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_95_6lblmok8_.arc
File Name: /oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_94_6lbljvrx_.arc
File Name: /oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_92_6lblhbon_.arc
File Name: /oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_93_6lbljnpf_.arc
File Name: /oracle/flash_recovery_area/ORCL/archivelog/o1_mf_1_30_6klsydwy_.arc
File Name: /oracle/flash_recovery_area/ORCL/archivelog/o1_mf_1_29_6klsxt4w_.arc
using channel ORA_DISK_1
channel ORA_DISK_1: starting datafile backupset restore
channel ORA_DISK_1: specifying datafile(s) to restore from backup set
restoring datafile 00001 to /oracle/product/10.2.0/oradata/orcl/system01.dbf
restoring datafile 00002 to /oracle/product/10.2.0/oradata/orcl/undotbs01.dbf
restoring datafile 00004 to /oracle/product/10.2.0/oradata/orcl/users01.dbf
restoring datafile 00005 to /oracle/product/10.2.0/oradata/orcl/example01.dbf
restoring datafile 00008 to /oracle/product/10.2.0/oradata/orcl/user01.dbf
channel ORA_DISK_1: reading from backup piece /oracle/databak/bak/29m1e5pg_1_1
channel ORA_DISK_1: restored backup piece 1
piece handle=/oracle/databak/bak/29m1e5pg_1_1 tag=TAG20110106T111247
channel ORA_DISK_1: restore complete, elapsed time: 00:00:26
channel ORA_DISK_1: starting datafile backupset restore
channel ORA_DISK_1: specifying datafile(s) to restore from backup set
restoring datafile 00003 to /oracle/product/10.2.0/oradata/orcl/sysaux01.dbf
restoring datafile 00006 to /oracle/product/10.2.0/oradata/orcl/tzjh01.dbf
restoring datafile 00007 to /oracle/product/10.2.0/oradata/orcl/bid01.dbf
restoring datafile 00009 to /oracle/product/10.2.0/oradata/orcl/user02.dbf
channel ORA_DISK_1: reading from backup piece /oracle/databak/bak/28m1e5pg_1_1
channel ORA_DISK_1: restored backup piece 1
piece handle=/oracle/databak/bak/28m1e5pg_1_1 tag=TAG20110106T111247
channel ORA_DISK_1: restore complete, elapsed time: 00:00:36
Finished restore at 07-JAN-11
RMAN> recover database;
Starting recover at 07-JAN-11
using channel ORA_DISK_1
starting media recovery
archive log thread 1 sequence 91 is already on disk as file /oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_91_6lblh1k9_.arc
archive log thread 1 sequence 92 is already on disk as file /oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_92_6lblhbon_.arc
archive log thread 1 sequence 93 is already on disk as file /oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_93_6lbljnpf_.arc
archive log thread 1 sequence 94 is already on disk as file /oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_94_6lcn7kgh_.arc
archive log thread 1 sequence 95 is already on disk as file /oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_95_6lcn7kb0_.arc
archive log thread 1 sequence 96 is already on disk as file /oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_96_6lcn7kcz_.arc
channel ORA_DISK_1: starting archive log restore to default destination
channel ORA_DISK_1: restoring archive log
archive log thread=1 sequence=90
channel ORA_DISK_1: reading from backup piece /oracle/databak/bak/2cm1e5sb_1_1
channel ORA_DISK_1: restored backup piece 1
piece handle=/oracle/databak/bak/2cm1e5sb_1_1 tag=TAG20110106T111419
channel ORA_DISK_1: restore complete, elapsed time: 00:00:01
archive log filename=/oracle/flash_recovery_area/ORCL/archivelog/2011_01_07/o1_mf_1_90_6lct885q_.arc thread=1 sequence=90
channel default: deleting archive log(s)
archive log filename=/oracle/flash_recovery_area/ORCL/archivelog/2011_01_07/o1_mf_1_90_6lct885q_.arc recid=106 stamp=739757320
archive log filename=/oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_91_6lblh1k9_.arc thread=1 sequence=91
archive log filename=/oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_92_6lblhbon_.arc thread=1 sequence=92
archive log filename=/oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_93_6lbljnpf_.arc thread=1 sequence=93
archive log filename=/oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_94_6lcn7kgh_.arc thread=1 sequence=94
archive log filename=/oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_95_6lcn7kb0_.arc thread=1 sequence=95
archive log filename=/oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_96_6lcn7kcz_.arc thread=1 sequence=96
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of recover command at 01/07/2011 00:08:43
ORA-00283: recovery session canceled due to errors
RMAN-11003: failure during parse/execution of SQL statement: alter database recover logfile '/oracle/flash_recovery_area/ORCL/archivelog/2011_01_06/o1_mf_1_96_6lcn7kcz_.arc'
ORA-00283: recovery session canceled due to errors
ORA-01246: recovering files through TSPITR of tablespace USER02
ORA-01110: data file 9: '/oracle/product/10.2.0/oradata/orcl/user02.dbf'
RMAN>
Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
SQL> select status from v$instance;
STATUS
------------
MOUNTED
SQL> alter database open;
alter database open
*
ERROR at line 1:
ORA-01589: must use RESETLOGS or NORESETLOGS option for database open
SQL> alter database open resetlogs;
alter database open resetlogs
*
ERROR at line 1:
ORA-01196: file 1 is inconsistent due to a failed media recovery session
ORA-01110: data file 1: '/oracle/product/10.2.0/oradata/orcl/system01.dbf'
SQL> recover datafile 1;
ORA-00283: recovery session canceled due to errors
ORA-01610: recovery using the BACKUP CONTROLFILE option must be done
SQL> shutdown immediate
ORA-01109: database not open
Database dismounted.
ORACLE instance shut down.
SQL> startup
ORACLE instance started.
Total System Global Area 285212672 bytes
Fixed Size 1218968 bytes
Variable Size 79693416 bytes
Database Buffers 197132288 bytes
Redo Buffers 7168000 bytes
Database mounted.
ORA-01589: must use RESETLOGS or NORESETLOGS option for database open
SQL> alter database open resetlogs;
alter database open resetlogs
*
ERROR at line 1:
ORA-01196: file 1 is inconsistent due to a failed media recovery session
ORA-01110: data file 1: '/oracle/product/10.2.0/oradata/orcl/system01.dbf'
SQL> shutdown immediate
ORA-01109: database not open
Database dismounted.
ORACLE instance shut down.
SQL> startup
ORACLE instance started.
Total System Global Area 285212672 bytes
Fixed Size 1218968 bytes
Variable Size 79693416 bytes
Database Buffers 197132288 bytes
Redo Buffers 7168000 bytes
Database mounted.
ORA-01589: must use RESETLOGS or NORESETLOGS option for database open
SQL> alter database open resetlogs;
alter database open resetlogs
*
ERROR at line 1:
ORA-01196: file 1 is inconsistent due to a failed media recovery session
ORA-01110: data file 1: '/oracle/product/10.2.0/oradata/orcl/system01.dbf'
SQL> shutdown immediate
ORA-01109: database not open
Database dismounted.
ORACLE instance shut down.
SQL> startup
ORACLE instance started.
Total System Global Area 285212672 bytes
Fixed Size 1218968 bytes
Variable Size 79693416 bytes
Database Buffers 197132288 bytes
Redo Buffers 7168000 bytes
Database mounted.
ORA-01589: must use RESETLOGS or NORESETLOGS option for database open
SQL> alter database open resetlogs;
alter database open resetlogs
*
ERROR at line 1:
ORA-01196: file 1 is inconsistent due to a failed media recovery session
ORA-01110: data file 1: '/oracle/product/10.2.0/oradata/orcl/system01.dbf'
SQL> exit
Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
[oracle@server orcl]$
SQL> startup nomount
ORACLE instance started.
Total System Global Area 285212672 bytes
Fixed Size 1218968 bytes
Variable Size 79693416 bytes
Database Buffers 197132288 bytes
Redo Buffers 7168000 bytes
SQL> CREATE CONTROLFILE REUSE DATABASE "ORCL" RESETLOGS ARCHIVELOG
2 MAXLOGFILES 16
3 MAXLOGMEMBERS 3
4 MAXDATAFILES 100
5 MAXINSTANCES 8
6 MAXLOGHISTORY 292
7 LOGFILE
8 GROUP 1 '/oracle/product/10.2.0/oradata/orcl/redo01.log' SIZE 50M,
9 GROUP 2 '/oracle/product/10.2.0/oradata/orcl/redo02.log' SIZE 50M,
10 GROUP 3 '/oracle/product/10.2.0/oradata/orcl/redo03.log' SIZE 50M
11 DATAFILE
12 '/oracle/product/10.2.0/oradata/orcl/system01.dbf',
13 '/oracle/product/10.2.0/oradata/orcl/undotbs01.dbf',
14 '/oracle/product/10.2.0/oradata/orcl/sysaux01.dbf',
15 '/oracle/product/10.2.0/oradata/orcl/users01.dbf',
16 '/oracle/product/10.2.0/oradata/orcl/example01.dbf',
17 '/oracle/product/10.2.0/oradata/orcl/tzjh01.dbf',
18 '/oracle/product/10.2.0/oradata/orcl/bid01.dbf',
19 '/oracle/product/10.2.0/oradata/orcl/user01.dbf'
20 CHARACTER SET ZHS16GBK
21 ;
Control file created.
SQL> recover database;
ORA-00283: recovery session canceled due to errors
ORA-01610: recovery using the BACKUP CONTROLFILE option must be done
SQL> exit
Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
[oracle@server orcl]$ sqlplus / as sysdba
SQL*Plus: Release 10.2.0.1.0 - Production on Fri Jan 7 00:15:41 2011
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
SQL> shutdown immediate
ORA-01109: database not open
Database dismounted.
ORACLE instance shut down.
SQL> startup mount
ORACLE instance started.
Total System Global Area 285212672 bytes
Fixed Size 1218968 bytes
Variable Size 79693416 bytes
Database Buffers 197132288 bytes
Redo Buffers 7168000 bytes
Database mounted.
SQL> recover database using backup controlfile;
ORA-00279: change 1154109 generated at 01/06/2011 12:52:50 needed for thread 1
ORA-00289: suggestion :
/oracle/flash_recovery_area/ORCL/archivelog/2011_01_07/o1_mf_1_96_%u_.arc
ORA-00280: change 1154109 for thread 1 is in sequence #96
Specify log: {=suggested | filename | AUTO | CANCEL}
auto
Log applied.
Media recovery complete.
SQL> alter database open resetlogs;
Database altered.
SQL>
阅读(1417) | 评论(0) | 转发(0) |