1.2.2 备份USER表空间
RMAN> backuptablespace users;
Starting backupat 23-MAY-12
using channelORA_DISK_1
channelORA_DISK_1: starting full datafile backupset
channelORA_DISK_1: specifying datafile(s) in backupset
input datafilefno=00004 name=/DBData/WWL/users01.dbf
channelORA_DISK_1: starting piece 1 at 23-MAY-12
channelORA_DISK_1: finished piece 1 at 23-MAY-12
piecehandle=/DBBak/bak_WWL_05_23_0cnbn2a3_1_1 tag=TAG20120523T133147 comment=NONE
channelORA_DISK_1: backup set complete, elapsed time: 00:00:04
Finished backupat 23-MAY-12
Starting ControlFile and SPFILE Autobackup at 23-MAY-12
piece handle=/DBSoft/product/10.2.0/db_1/dbs/c-5520179-20120523-01comment=NONE
Finished ControlFile and SPFILE Autobackup at 23-MAY-12
RMAN>
1.2.3 备份数据文件
RMAN> backup datafile 1,2,3;
Starting backupat 23-MAY-12
using channelORA_DISK_1
channelORA_DISK_1: starting full datafile backupset
channelORA_DISK_1: specifying datafile(s) in backupset
input datafilefno=00001 name=/DBData/WWL/system01.dbf
input datafilefno=00003 name=/DBData/WWL/sysaux01.dbf
input datafile fno=00002name=/DBData/WWL/undotbs01.dbf
channelORA_DISK_1: starting piece 1 at 23-MAY-12
channelORA_DISK_1: finished piece 1 at 23-MAY-12
piecehandle=/DBBak/bak_WWL_05_23_0enbn2bk_1_1 tag=TAG20120523T133235 comment=NONE
channelORA_DISK_1: backup set complete, elapsed time: 00:01:48
Finished backupat 23-MAY-12
Starting ControlFile and SPFILE Autobackup at 23-MAY-12
piecehandle=/DBSoft/product/10.2.0/db_1/dbs/c-5520179-20120523-02 comment=NONE
Finished ControlFile and SPFILE Autobackup at 23-MAY-12
RMAN>
1.2.4 备份控制文件
RMAN> backup current controlfile;
Starting backupat 23-MAY-12
using channelORA_DISK_1
channelORA_DISK_1: starting full datafile backupset
channelORA_DISK_1: specifying datafile(s) in backupset
includingcurrent control file in backupset
channelORA_DISK_1: starting piece 1 at 23-MAY-12
channelORA_DISK_1: finished piece 1 at 23-MAY-12
piecehandle=/DBBak/bak_WWL_05_23_0gnbn2je_1_1 tag=TAG20120523T133645 comment=NONE
channelORA_DISK_1: backup set complete, elapsed time: 00:00:01
Finished backupat 23-MAY-12
Starting ControlFile and SPFILE Autobackup at 23-MAY-12
piecehandle=/DBSoft/product/10.2.0/db_1/dbs/c-5520179-20120523-03 comment=NONE
Finished ControlFile and SPFILE Autobackup at 23-MAY-12
RMAN>
1.2.5 备份spfile文件
RMAN> backup spfile;
Starting backupat 23-MAY-12
using channelORA_DISK_1
channelORA_DISK_1: starting full datafile backupset
channelORA_DISK_1: specifying datafile(s) in backupset
includingcurrent SPFILE in backupset
channelORA_DISK_1: starting piece 1 at 23-MAY-12
channelORA_DISK_1: finished piece 1 at 23-MAY-12
piecehandle=/DBBak/bak_WWL_05_23_0inbn2l2_1_1 tag=TAG20120523T133737 comment=NONE
channelORA_DISK_1: backup set complete, elapsed time: 00:00:02
Finished backupat 23-MAY-12
Starting ControlFile and SPFILE Autobackup at 23-MAY-12
piecehandle=/DBSoft/product/10.2.0/db_1/dbs/c-5520179-20120523-04 comment=NONE
Finished ControlFile and SPFILE Autobackup at 23-MAY-12
RMAN>
1.2.6 查看我们刚才备份的信息:
RMAN> list backup;
如下信息是之前做的备份:
using target database control file instead of recoverycatalog
List of Backup Sets
===================
BS Key Type LVSize Device Type Elapsed TimeCompletion Time
------- ---- -- ---------- ----------- ---------------------------
2 Full 522.59M DISK 00:00:59 18-MAY-12
BP Key:2 Status: AVAILABLE Compressed: NO Tag: TAG20120518T185700
Piece Name:/DBBak/bak_WWL_05_18_04nbaffs_1_1
List of Datafilesin backup set 2
File LV Type CkpSCN Ckp Time Name
---- -- -------------- --------- ----
1 Full 618100 18-MAY-12 /DBData/WWL/system01.dbf
2 Full 618100 18-MAY-12 /DBData/WWL/undotbs01.dbf
3 Full 618100 18-MAY-12 /DBData/WWL/sysaux01.dbf
4 Full 618100 18-MAY-12 /DBData/WWL/users01.dbf
BS Key Type LVSize Device Type Elapsed TimeCompletion Time
------- ---- -- ---------- ----------- ---------------------------
3 Full 6.80M DISK 00:00:02 18-MAY-12
BP Key:3 Status: AVAILABLE Compressed: NO Tag: TAG20120518T185806
Piece Name:/DBSoft/product/10.2.0/db_1/dbs/c-5520179-20120518-01
Control FileIncluded: Ckp SCN: 618100 Ckp time:18-MAY-12
SPFILE Included:Modification time: 18-MAY-12
BS Key Type LVSize Device Type Elapsed TimeCompletion Time
------- ---- -- ---------- ----------- ---------------------------
4 Full 523.54M DISK 00:01:09 21-MAY-12
BP Key:4 Status: AVAILABLE Compressed: NO Tag: TAG20120521T145403
Piece Name:/DBBak/bak_WWL_05_21_06nbhucb_1_1
List of Datafilesin backup set 4
File LV Type CkpSCN Ckp Time Name
---- -- -------------- --------- ----
1 Full 622304 21-MAY-12 /DBData/WWL/system01.dbf
2 Full 622304 21-MAY-12 /DBData/WWL/undotbs01.dbf
3 Full 622304 21-MAY-12 /DBData/WWL/sysaux01.dbf
4 Full 622304 21-MAY-12 /DBData/WWL/users01.dbf
BS Key Type LVSize Device Type Elapsed TimeCompletion Time
------- ---- -- ---------- ----------- ---------------------------
5 Full 6.80M DISK 00:00:01 21-MAY-12
BP Key:5 Status: AVAILABLE Compressed: NO Tag: TAG20120521T145520
Piece Name:/DBSoft/product/10.2.0/db_1/dbs/c-5520179-20120521-00
Control FileIncluded: Ckp SCN: 622304 Ckp time:21-MAY-12
SPFILE Included:Modification time: 21-MAY-12
BS Key Type LVSize Device Type Elapsed TimeCompletion Time
------- ---- -- ---------- ----------- ---------------------------
6 Full 368.00K DISK 00:00:00 21-MAY-12
BP Key:6 Status: AVAILABLE Compressed: NO Tag: TAG20120521T151349
Piece Name:/DBBak/bak_WWL_05_21_08nbhvhe_1_1
List of Datafilesin backup set 6
File LV Type CkpSCN Ckp Time Name
---- -- -------------- --------- ----
4 Full 622968 21-MAY-12 /DBData/WWL/users01.dbf
BS Key Type LVSize Device Type Elapsed TimeCompletion Time
------- ---- -- ---------- ----------- ---------------------------
7 Full 6.80M DISK 00:00:01 21-MAY-12
BP Key:7 Status: AVAILABLE Compressed: NO Tag: TAG20120521T151351
Piece Name:/DBSoft/product/10.2.0/db_1/dbs/c-5520179-20120521-01
Control FileIncluded: Ckp SCN: 622968 Ckp time:21-MAY-12
SPFILE Included:Modification time: 21-MAY-12
