ITPub博客

首页 > Linux操作系统 > Linux操作系统 > backup database plus archivelog; 命令的理解!

backup database plus archivelog; 命令的理解!

原创 Linux操作系统 作者:bkeep 时间:2009-08-04 16:21:44 0 删除 编辑

 

RMAN> backup database plus archivelog; 命令的理解!

 

个人理解如下:

 

执行命令后系统  切换redo log并归档à 备份归档文件(scn604010609123) à备份数据文件(ckp scn609130/609129à切换redo log并归档à备份归档文件(scn609123609152à 备份spfilecontrol fileckp scn609158

 

具体操作如下:

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

--开始备份归档日志(scn604010609123

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

--开始备份数据文件(scn609130

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

--开始备份数据文件(scn609129

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

--开始备份归档日志(scn609123609152

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

 

--开始备份控制文件和spfilescn609158

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 of Archived Logs in backup set 49

  Thrd Seq     Low SCN    Low Time  Next SCN   Next Time

  ---- ------- ---------- --------- ---------- ---------

  1    7       604010     30-JUL-09 609123     30-JUL-09

 

BS Key  Type LV Size       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 of Datafiles in backup set 50

  File LV Type Ckp SCN    Ckp Time  Name

  ---- -- ---- ---------- --------- ----

  2       Full 609130     30-JUL-09 /opt/oracle/oradata/boy/undotbs01.dbf

  3       Full 609130     30-JUL-09 /opt/oracle/oradata/boy/sysaux01.dbf

  5       Full 609130     30-JUL-09 /opt/oracle/oradata/boy/rman_ts.dbf

 

BS Key  Type LV Size       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 of Datafiles in backup set 51

  File LV Type Ckp SCN    Ckp Time  Name

  ---- -- ---- ---------- --------- ----

  1       Full 609129     30-JUL-09 /opt/oracle/oradata/boy/system01.dbf

  4       Full 609129     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 of Archived Logs in 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  Type LV Size       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 File Included: 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       A 30-JUL-09 /opt/oracle/flash_recovery_area/BOY/archivelog/2009_07_30/o1_mf_1_7_5716p7bz_.arc

44      1    8       A 30-JUL-09 /opt/oracle/flash_recovery_area/BOY/archivelog/2009_07_30/o1_mf_1_8_5716qt6y_.arc

 

 

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/22238176/viewspace-611316/,如需转载,请注明出处,否则将追究法律责任。

上一篇: 没有了~
下一篇: 【oracle】hash
请登录后发表评论 登录
全部评论

注册时间:2009-07-31

  • 博文量
    8
  • 访问量
    10054