RMAN> backup database plus archivelog;命令的理解!
个人理解如下:
执行命令后系统
切换redo log并归档
备份归档文件(scn:604010~609123)
备份数据文件(ckp scn:609130/609129)
切换redo log并归档
备份归档文件(scn:609123~609152)
备份spfile和control file(ckp scn:609158)
具体操作如下:
RMAN> backup database plus archivelog;
Starting backup at 30-JUL-09
current log archived //命令开始,切换redo log并归档!
using channel ORA_DISK_1
using channel ORA_DISK_2
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=7 recid=43 stamp=693543239
channel ORA_DISK_1: starting piece 1 at 30-JUL-09
channel ORA_DISK_1: finished piece 1 at 30-JUL-09
--开始备份归档日志(scn:604010~609123)
piece handle=/opt/oracle/flash_recovery_area/BOY/backupset/2009_07_30/o1_mf_annnn_TAG20090730T025359_5716pgom_.bkp tag=TAG20090730T025359 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:00:05
Finished backup at 30-JUL-09
Starting backup at 30-JUL-09
using channel ORA_DISK_1
using channel ORA_DISK_2
channel ORA_DISK_1: starting full datafile backupset
channel ORA_DISK_1: specifying datafile(s) in backupset
input datafile fno=00001 name=/opt/oracle/oradata/boy/system01.dbf
input datafile fno=00004 name=/opt/oracle/oradata/boy/users01.dbf
channel ORA_DISK_1: starting piece 1 at 30-JUL-09
channel ORA_DISK_2: starting full datafile backupset
channel ORA_DISK_2: specifying datafile(s) in backupset
input datafile fno=00003 name=/opt/oracle/oradata/boy/sysaux01.dbf
input datafile fno=00002 name=/opt/oracle/oradata/boy/undotbs01.dbf
input datafile fno=00005 name=/opt/oracle/oradata/boy/rman_ts.dbf
channel ORA_DISK_2: starting piece 1 at 30-JUL-09
channel ORA_DISK_2: finished piece 1 at 30-JUL-09
--开始备份数据文件(scn:609130)
piece handle=/opt/oracle/flash_recovery_area/BOY/backupset/2009_07_30/o1_mf_nnndf_TAG20090730T025407_5716pjdb_.bkp tag=TAG20090730T025407 comment=NONE
channel ORA_DISK_2: backup set complete, elapsed time: 00:00:26
channel ORA_DISK_1: finished piece 1 at 30-JUL-09
--开始备份数据文件(scn:609129)
piece handle=/opt/oracle/flash_recovery_area/BOY/backupset/2009_07_30/o1_mf_nnndf_TAG20090730T025407_5716pj5t_.bkp tag=TAG20090730T025407 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:00:42
Finished backup at 30-JUL-09
Starting backup at 30-JUL-09
current log archived --切换redo log并归档!
using channel ORA_DISK_1
using channel ORA_DISK_2
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=8 recid=44 stamp=693543290
channel ORA_DISK_1: starting piece 1 at 30-JUL-09
channel ORA_DISK_1: finished piece 1 at 30-JUL-09
--开始备份归档日志(scn:609123~609152)
piece handle=/opt/oracle/flash_recovery_area/BOY/backupset/2009_07_30/o1_mf_annnn_TAG20090730T025450_5716qvd3_.bkp tag=TAG20090730T025450 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:00:02
Finished backup at 30-JUL-09
--开始备份控制文件和spfile(scn:609158)
Starting Control File and SPFILE Autobackup at 30-JUL-09
piece handle=/opt/oracle/flash_recovery_area/BOY/autobackup/2009_07_30/o1_mf_s_693543292_5716qws7_.bkp comment=NONE
Finished Control File and SPFILE Autobackup at 30-JUL-09
RMAN> list backup;
List of Backup Sets
===================
BS Key Size Device Type Elapsed Time Completion Time
------- ---------- ----------- ------------ ---------------
49 2.79M DISK 00:00:04 30-JUL-09
BP Key: 48 Status: AVAILABLE Compressed: NO Tag: TAG20090730T025359
Piece Name: /opt/oracle/flash_recovery_area/BOY/backupset/2009_07_30/o1_mf_annnn_TAG20090730T025359_5716pgom_.bkp
List ofArchived Logsin backup set 49
Thrd Seq Low SCN Low Time Next SCN Next Time
---- ------- ---------- --------- ---------- ---------
1 7 604010 30-JUL-09609123 30-JUL-09
BS Key TypeLVSize Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
50 Full 183.75M DISK 00:00:19 30-JUL-09
BP Key: 49 Status: AVAILABLE Compressed: NO Tag: TAG20090730T025407
Piece Name: /opt/oracle/flash_recovery_area/BOY/backupset/2009_07_30/o1_mf_nnndf_TAG20090730T025407_5716pjdb_.bkp
List ofDatafilesin backup set 50
FileLVTypeCkp SCN Ckp Time Name
---- -- ---- ---------- --------- ----
2 Full609130 30-JUL-09 /opt/oracle/oradata/boy/undotbs01.dbf
3 Full609130 30-JUL-09 /opt/oracle/oradata/boy/sysaux01.dbf
5 Full609130 30-JUL-09 /opt/oracle/oradata/boy/rman_ts.dbf
BS Key TypeLVSize Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
51 Full 358.00M DISK 00:00:39 30-JUL-09
BP Key: 50 Status: AVAILABLE Compressed: NO Tag: TAG20090730T025407
Piece Name: /opt/oracle/flash_recovery_area/BOY/backupset/2009_07_30/o1_mf_nnndf_TAG20090730T025407_5716pj5t_.bkp
List ofDatafilesin backup set 51
FileLVTypeCkp SCN Ckp Time Name
---- -- ---- ---------- --------- ----
1 Full609129 30-JUL-09 /opt/oracle/oradata/boy/system01.dbf
4 Full609129 30-JUL-09 /opt/oracle/oradata/boy/users01.dbf
BS Key Size Device Type Elapsed Time Completion Time
------- ---------- ----------- ------------ ---------------
52 6.50K DISK 00:00:01 30-JUL-09
BP Key: 51 Status: AVAILABLE Compressed: NO Tag: TAG20090730T025450
Piece Name: /opt/oracle/flash_recovery_area/BOY/backupset/2009_07_30/o1_mf_annnn_TAG20090730T025450_5716qvd3_.bkp
List ofArchived Logsin backup set 52
Thrd Seq Low SCN Low Time Next SCN Next Time
---- ------- ---------- --------- ---------- ---------
1 8 609123 30-JUL-09 609152 30-JUL-09
BS Key TypeLVSize Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
53 Full 6.92M DISK 00:00:00 30-JUL-09
BP Key: 52 Status: AVAILABLE Compressed: NO Tag: TAG20090730T025452
Piece Name: /opt/oracle/flash_recovery_area/BOY/autobackup/2009_07_30/o1_mf_s_693543292_5716qws7_.bkp
Control FileIncluded:Ckp SCN: 609158 Ckp time: 30-JUL-09
SPFILE Included: Modification time: 29-JUL-09
疑问+灵感:
其实我没做copy备份,可是下面的命令能看到归档文件!那么是不是可以通过delete copy来删除归档文件呢?
答案:好像可以!
RMAN> list copy;
List of Archived Log Copies
Key Thrd Seq S Low Time Name
------- ---- ------- - --------- ----
43 1 7 A30-JUL-09 /opt/oracle/flash_recovery_area/BOY/archivelog/2009_07_30/o1_mf_1_7_5716p7bz_.arc
44 1 8 A30-JUL-09 /opt/oracle/flash_recovery_area/BOY/archivelog/2009_07_30/o1_mf_1_8_5716qt6y_.arc