ITPub博客

首页 > Linux操作系统 > Linux操作系统 > 关于RAMN能不能再非归档模式下进行备份的问题

关于RAMN能不能再非归档模式下进行备份的问题

原创 Linux操作系统 作者:DB_BLOCK 时间:2013-11-04 17:12:08 0 删除 编辑

在OCP的考试中,有一道题目就是RMAN一定要在归档模式下进行备份,是否正确的一道题。


 我们就针对这个问题,做以下验证


RMAN到底在非归档时能不能进行备份。
SQL> archive log list;
Database log mode              No Archive Mode
Automatic archival             Disabled
Archive destination            /u01/app/oracle/products/11.2.0/dbs/arch
Oldest online log sequence     56
Current log sequence           58

RMAN> backup database;

Starting backup at 05-OCT-13
using channel ORA_DISK_1
channel ORA_DISK_1: starting full datafile backup set
channel ORA_DISK_1: specifying datafile(s) in backup set
RMAN-03009: failure of backup command on ORA_DISK_1 channel at 10/05/2013 15:44:47
ORA-19602: cannot backup or copy active file in NOARCHIVELOG mode
continuing other job steps, job failed will not be re-run
channel ORA_DISK_1: starting full datafile backup set
channel ORA_DISK_1: specifying datafile(s) in backup set
including current control file in backup set
including current SPFILE in backup set
channel ORA_DISK_1: starting piece 1 at 05-OCT-13
channel ORA_DISK_1: finished piece 1 at 05-OCT-13
piece handle=/u01/app/oracle/products/11.2.0/dbs/02ollcvg_1_1 tag=TAG20131005T154446 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:00:15
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================

RMAN-03009: failure of backup command on ORA_DISK_1 channel at 10/05/2013 15:44:47
ORA-19602: cannot backup or copy active file in NOARCHIVELOG mode

我们可以看到,备份失败了,那么,我们知道,在数据库是打开的情况下,时刻都有读写,所以,我们在open情况下用RMAN备份数据库,哪怕就是备份了,也是没有用的。
那么我们在mount的时候能不能备份呢?
SQL> shutdown immediate;
Database closed.
Database dismounted.
ORACLE instance shut down.

SQL> startup mount;
ORACLE instance started.

Total System Global Area  622149632 bytes
Fixed Size                  2230912 bytes
Variable Size             503317888 bytes
Database Buffers          113246208 bytes
Redo Buffers                3354624 bytes
Database mounted.

oracle@Ray:/home/oracle>rman target /

Recovery Manager: Release 11.2.0.3.0 - Production on Sat Oct 5 15:58:35 2013

Copyright (c) 1982, 2011, Oracle and/or its affiliates.  All rights reserved.

connected to target database: ORA11G (DBID=4213800794, not open)

RMAN> backup database;

Starting backup at 05-OCT-13
using target database control file instead of recovery catalog
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=18 device type=DISK
channel ORA_DISK_1: starting full datafile backup set
channel ORA_DISK_1: specifying datafile(s) in backup set
input datafile file number=00001 name=/u01/app/oracle/oradata/system01.dbf
input datafile file number=00002 name=/u01/app/oracle/oradata/ora11g/sysaux01.dbf
input datafile file number=00005 name=/u01/app/oracle/oradata/ora11g/example01.dbf
input datafile file number=00003 name=/u01/app/oracle/oradata/ora11g/undotbs01.dbf
input datafile file number=00004 name=/u01/app/oracle/oradata/ora11g/users01.dbf
input datafile file number=00007 name=/u01/app/oracle/oradata/panfeng01.dbf
input datafile file number=00008 name=/u01/app/oracle/oradata/ora11g/undo01.dba
input datafile file number=00006 name=/u01/app/oracle/oradata/ora11g/panfeng01.dbf
channel ORA_DISK_1: starting piece 1 at 05-OCT-13
channel ORA_DISK_1: finished piece 1 at 05-OCT-13
piece handle=/u01/app/oracle/products/11.2.0/dbs/03olldq5_1_1 tag=TAG20131005T155859 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:05:26
channel ORA_DISK_1: starting full datafile backup set
channel ORA_DISK_1: specifying datafile(s) in backup set
including current control file in backup set
including current SPFILE in backup set
channel ORA_DISK_1: starting piece 1 at 05-OCT-13
channel ORA_DISK_1: finished piece 1 at 05-OCT-13
piece handle=/u01/app/oracle/products/11.2.0/dbs/04olle4c_1_1 tag=TAG20131005T155859 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:00:01
Finished backup at 05-OCT-13


在mount状态时,备份不会出现错误,所以,在mount状态时可以在非归档模式下进行备份,但是,他和冷备没有区别。



欢迎大家批评指正:
QQ交流群:300392987
论        坛:www.oraclefreebase.com

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

上一篇: 没有了~
请登录后发表评论 登录
全部评论

注册时间:2013-09-25

  • 博文量
    12
  • 访问量
    124554