spfile 和pfile 在数据库open和shutdown 的两种情况下的恢复成功(二)

2014-11-24 18:38:21 · 作者: · 浏览: 5
meter file for retrival of spfile
Oracle instance started


Total System Global Area 159383552 bytes


Fixed Size 1218268 bytes
Variable Size 54528292 bytes
Database Buffers 100663296 bytes
Redo Buffers 2973696 bytes


RMAN> restore spfile from autobackup;


Starting restore at 08-DEC-11
using target database control file instead of recovery catalog
allocated channel: ORA_DISK_1
channel ORA_DISK_1: sid=36 devtype=DISK


RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of restore command at 12/08/2011 20:06:44
RMAN-06495: must explicitly specify DBID with SET DBID command


RMAN> set dbid 4046377924


executing command: SET DBID


RMAN> restore spfile from autobackup;


Starting restore at 08-DEC-11
using channel ORA_DISK_1


channel ORA_DISK_1: looking for autobackup on day: 20111208
channel ORA_DISK_1: looking for autobackup on day: 20111207
channel ORA_DISK_1: looking for autobackup on day: 20111206
channel ORA_DISK_1: looking for autobackup on day: 20111205
channel ORA_DISK_1: looking for autobackup on day: 20111204
channel ORA_DISK_1: looking for autobackup on day: 20111203
channel ORA_DISK_1: looking for autobackup on day: 20111202
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 12/08/2011 20:07:18
RMAN-06172: no autobackup found or specified handle is not a valid copy or piece


RMAN> restore spfile from '/u02/rman/ctl_c-4046377924-20111208-00';


Starting restore at 08-DEC-11
using channel ORA_DISK_1


channel ORA_DISK_1: autobackup found: /u02/rman/ctl_c-4046377924-20111208-00
channel ORA_DISK_1: SPFILE restore from autobackup complete
Finished restore at 08-DEC-11


RMAN>


pfile 从spfile create 就可以了。


========
总结: spfile 和pfile 在数据库open和shutdown 的两种情况下的恢复成功。