概述
探索ORACLE之RMAN_03一致性备份
作者:吴伟龙
在之前的已经提到过备份分为一致性备份和非一致性备份,它们的区别就在于数据库所处的备份状态不同,并且一致性备份不能做增量备份恢复,需停业务,一致性备份可以做到增量的备份恢复,从而不影响业务的正常流转。
创建一致性备份
创建一致性备份可以是在非归档模式下创建,并且数据库必须处于mount状态下,而且恢复的时候值能恢复到最后一次备份的状态。也就说从备份到发生故障的这段时间都将丢失。操作步骤如下:
1.1检查归档状态:
SQL> archive log list;
Database log modeNo Archive Mode
Automatic
archivalDisabled
Archive
destinationUSE_DB_RECOVERY_FILE_DEST
Oldest online
log sequence8
Current log
sequence10
SQL>
1.2将数据库启动到mount状态
SQL> shutdown immediate
Database
closed.
Database
dismounted.
ORACLE instance
shut down.
SQL> startup mount;
ORACLE instance
started.
Total System
Global Area285212672 bytes
Fixed Size1218968 bytes
Variable
Size79693416 bytes
Database
Buffers197132288 bytes
Redo
Buffers7168000 bytes
Database
mounted.
SQL>
1.3执行备份
1.3.1备份数据库
[oracle@wwldb ~]$ rman target /
Recovery
Manager: Release 10.2.0.1.0 - Production on ÐÇÆÚÒ» 5ÔÂ 21 14:53:47 2012
Copyright (c)
1982, 2005, Oracle.All rights reserved.
connected to
target database: WWL (DBID=5520179, not open)
RMAN> backup database;
Starting backup
at 21-5ÔÂ -12
using target
database control file instead of recovery catalog
allocated
channel: ORA_DISK_1
channel
ORA_DISK_1: sid=156 devtype=DISK
channel
ORA_DISK_1: starting full datafile backupset
channel
ORA_DISK_1: specifying datafile(s) in backupset
input datafile
fno=00001 name=/DBData/WWL/system01.dbf
input datafile
fno=00003 name=/DBData/WWL/sysaux01.dbf
input datafile
fno=00002 name=/DBData/WWL/undotbs01.dbf
input datafile
fno=00004 name=/DBData/WWL/users01.dbf
channel
ORA_DISK_1: starting piece 1 at 21-5ÔÂ -12
channel
ORA_DISK_1: finished piece 1 at 21-5ÔÂ -12
piece handle=/DBBak/bak_WWL_05_21_06nbhucb_1_1
tag=TAG20120521T145403 comment=NONE
channel
ORA_DISK_1: backup set complete, elapsed time: 00:01:16
Finished backup
at 21-5ÔÂ -12
Starting Control
File and SPFILE Autobackup at 21-5ÔÂ -12
piece
handle=/DBSoft/product/10.2.0/db_1/dbs/c-5520179-20120521-00 comment=NONE
Finished Control
File and SPFILE Autobackup at 21-5ÔÂ -12
RMAN>
1.3.2备份USER表空间
RMAN> backup tablespace users;
Starting backup
at 21-5ÔÂ -12
using target
database control file instead of recovery catalog
allocated channel:
ORA_DISK_1
channel
ORA_DISK_1: sid=155 devtype=DISK
channel
ORA_DISK_1: starting full datafile backupset
channel
ORA_DISK_1: specifying datafile(s) in backupset
input datafile
fno=00004 name=/DBData/WWL/users01.dbf
channel
ORA_DISK_1: starting piece 1 at 21-5ÔÂ -12
channel
ORA_DISK_1: finished piece 1 at 21-5ÔÂ -12
piece
handle=/DBBak/bak_WWL_05_21_08nbhvhe_1_1 tag=TAG20120521T151349 comment=NONE
channel
ORA_DISK_1: backup set complete, elapsed time: 00:00:01
Finished backup
at 21-5ÔÂ -12
Starting Control
File and SPFILE Autobackup at 21-5ÔÂ -12
piece
handle=/DBSoft/product/10.2.0/db_1/dbs/c-5520179-20120521-01 comment=NONE
Finished Control
File and SPFILE Autobackup at 21-5ÔÂ -12
RMAN>
最后
以上就是机智泥猴桃为你收集整理的rman一致性备份oracle数据库可以在非归档模式下么,探索ORACLE之RMAN_03一致性备份...的全部内容,希望文章能够帮你解决rman一致性备份oracle数据库可以在非归档模式下么,探索ORACLE之RMAN_03一致性备份...所遇到的程序开发问题。
如果觉得靠谱客网站的内容还不错,欢迎将靠谱客网站推荐给程序员好友。
发表评论 取消回复