今天开始学习rman恢复技术,今天初入门,先学习spfile丢失后的恢复操作,分为两部分:1、环境搭建以及前提准备;2、恢复操作过程
一、环境准备
先对数据库进行全备份
1、 连接数据库
[oracle@rac3 ~]$ rman target /
Recovery Manager: Release 10.2.0.1.0 - Production on Sun Jun 3006:29:22 2013
Copyright (c) 1982, 2005, Oracle. All rights reserved.
connected to target database: ORCL (DBID=1347045716)
此处要将DBID记录下来,因为后面的恢复需要用到。
2、 对数据库进行全备份包括归档日志
RMAN> backup database plus archivelogdelete input;
3、 查看备份后备份片的位置
RMAN> list backup;
List of BackupSets
===================
BS Key Size Device Type Elapsed Time Completion Time
----------------- ----------- ------------ ---------------
6 121.91M DISK 00:00:09 30-JUN-13
BP Key: 6 Status: AVAILABLE Compressed: NO Tag: TAG20130630T063920
Piece Name:/opt/oracle/flash_recovery_area/ORCL/backupset/2013_06_30/o1_mf_annnn_TAG20130630T063920_8wyrjstl_.bkp
List of Archived Logs in backup set 6
Thrd Seq Low SCN Low Time Next SCN Next Time