Oracle12c_RMAN备份RAC数据库的实施

1、连接目标数据库(这里通过SCAN)

[oracle@oracletest admin]$ rman target sys/yxssystem@orarac

Recovery Manager: Release 12.1.0.1.0 - Production on Mon Mar 23 15:35:15 2015

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

connected to target database: ORARAC (DBID=377624869)

RMAN>

2、设置控制文件自动备份并配置备份路径

RMAN> configure controlfile autobackup on;

using target database control file instead of recovery catalog
new RMAN configuration parameters:
CONFIGURE CONTROLFILE AUTOBACKUP ON;
new RMAN configuration parameters are successfully stored

RMAN> CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '/u01/backup/backupset/ctl_%d_%F';    

new RMAN configuration parameters:
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '/u01/backup/backupset/ctl_%d_%F';
new RMAN configuration parameters are successfully stored

3、执行备份

RMAN> backup as backupset database format '/u01/backup/backupset/df0_%d_%s_%p_%T'

2> plus archivelog delete all input format '/u01/backup/backupset/arch_%d_%s_%p_%T';


Starting backup at 23-MAR-15
current log archived
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=69 instance=orarac2 device type=DISK
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of backup plus archivelog command at 03/23/2015 15:49:22
RMAN-06059: expected archived log not found, loss of archived log compromises recoverability
ORA-19625: error identifying file +FRA/ORARAC/ARCHIVELOG/2015_03_12/thread_1_seq_16.262.874160903
ORA-17503: ksfdopn:2 Failed to open file +FRA/ORARAC/ARCHIVELOG/2015_03_12/thread_1_seq_16.262.874160903
ORA-15012: ASM file '+FRA/ORARAC/ARCHIVELOG/2015_03_12/thread_1_seq_16.262.874160903' does not exist

由于之前手动删除过归档,因此这里报错。

首先要使用RMAN删除归档,执行下面两条命令:

RMAN> crosscheck archivelog all;

RMAN> delete expired archivelog all;

再次执行备份:

RMAN> backup as backupset database format '/u01/backup/backupset/df0_%d_%s_%p_%T' plus archivelog delete all input format '/u01/backup/backupset/arch_%d_%s_%p_%T';


Starting backup at 23-MAR-15
current log archived
using channel ORA_DISK_1
channel ORA_DISK_1: starting archived log backup set
channel ORA_DISK_1: specifying archived log(s) in backup set
input archived log thread=2 sequence=7 RECID=18 STAMP=874209609
input archived log thread=2 sequence=8 RECID=21 STAMP=874249243
input archived log thread=1 sequence=28 RECID=20 STAMP=874245631
input archived log thread=1 sequence=29 RECID=24 STAMP=874253152
input archived log thread=2 sequence=9 RECID=22 STAMP=874253004
input archived log thread=2 sequence=10 RECID=23 STAMP=874253151
input archived log thread=2 sequence=11 RECID=25 STAMP=874253253
input archived log thread=1 sequence=30 RECID=28 STAMP=874285228
input archived log thread=2 sequence=12 RECID=26 STAMP=874274487
input archived log thread=2 sequence=13 RECID=27 STAMP=874285227
input archived log thread=2 sequence=14 RECID=30 STAMP=874317607
input archived log thread=1 sequence=31 RECID=29 STAMP=874303240
input archived log thread=1 sequence=32 RECID=31 STAMP=874317986
input archived log thread=2 sequence=15 RECID=34 STAMP=874335658
input archived log thread=1 sequence=33 RECID=32 STAMP=874328465
input archived log thread=1 sequence=34 RECID=33 STAMP=874335656
input archived log thread=1 sequence=35 RECID=37 STAMP=874361444
input archived log thread=2 sequence=16 RECID=35 STAMP=874347013
input archived log thread=2 sequence=17 RECID=36 STAMP=874361443
input archived log thread=2 sequence=18 RECID=38 STAMP=874378855
input archived log thread=1 sequence=36 RECID=40 STAMP=874396844
input archived log thread=2 sequence=19 RECID=39 STAMP=874389640
input archived log thread=2 sequence=20 RECID=41 STAMP=874404160
input archived log thread=1 sequence=37 RECID=42 STAMP=874419071
input archived log thread=2 sequence=21 RECID=43 STAMP=874425604
input archived log thread=1 sequence=38 RECID=45 STAMP=874440002
input archived log thread=2 sequence=22 RECID=44 STAMP=874436434
input archived log thread=2 sequence=23 RECID=47 STAMP=874465219
input archived log thread=1 sequence=39 RECID=46 STAMP=874448570
input archived log thread=1 sequence=40 RECID=48 STAMP=874479632
input archived log thread=2 sequence=24 RECID=49 STAMP=874501231
input archived log thread=1 sequence=41 RECID=50 STAMP=874515611
input archived log thread=2 sequence=25 RECID=52 STAMP=874533749
input archived log thread=1 sequence=42 RECID=51 STAMP=874533641
input archived log thread=1 sequence=43 RECID=53 STAMP=874535138
input archived log thread=2 sequence=26 RECID=54 STAMP=874566338
input archived log thread=1 sequence=44 RECID=55 STAMP=874567343
input archived log thread=2 sequence=27 RECID=57 STAMP=874602011
input archived log thread=1 sequence=45 RECID=56 STAMP=874595321
input archived log thread=1 sequence=46 RECID=60 STAMP=874621670
input archived log thread=2 sequence=28 RECID=58 STAMP=874620044
input archived log thread=2 sequence=29 RECID=59 STAMP=874621670
input archived log thread=2 sequence=30 RECID=61 STAMP=874652417
input archived log thread=1 sequence=47 RECID=62 STAMP=874656026
input archived log thread=2 sequence=31 RECID=63 STAMP=874684850
input archived log thread=1 sequence=48 RECID=64 STAMP=874689179
channel ORA_DISK_1: starting piece 1 at 23-MAR-15
channel ORA_DISK_1: finished piece 1 at 23-MAR-15
piece handle=/u01/backup/backupset/arch_ORARAC_6_1_20150323 tag=TAG20150323T155749 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:00:15
channel ORA_DISK_1: deleting archived log(s)
archived log file name=+FRA/ORARAC/ARCHIVELOG/2015_03_13/thread_2_seq_7.279.874209609 RECID=18 STAMP=874209609
archived log file name=+FRA/ORARAC/ARCHIVELOG/2015_03_13/thread_2_seq_8.278.874249243 RECID=21 STAMP=874249243
archived log file name=+FRA/ORARAC/ARCHIVELOG/2015_03_13/thread_1_seq_28.280.874245631 RECID=20 STAMP=874245631
archived log file name=+FRA/ORARAC/ARCHIVELOG/2015_03_13/thread_1_seq_29.275.874253153 RECID=24 STAMP=874253152
archived log file name=+FRA/ORARAC/ARCHIVELOG/2015_03_13/thread_2_seq_9.277.874253005 RECID=22 STAMP=874253004
archived log file name=+FRA/ORARAC/ARCHIVELOG/2015_03_13/thread_2_seq_10.276.874253151 RECID=23 STAMP=874253151
archived log file name=+FRA/ORARAC/ARCHIVELOG/2015_03_13/thread_2_seq_11.274.874253253 RECID=25 STAMP=874253253
archived log file name=+FRA/ORARAC/ARCHIVELOG/2015_03_14/thread_1_seq_30.270.874285229 RECID=28 STAMP=874285228
archived log file name=+FRA/ORARAC/ARCHIVELOG/2015_03_13/thread_2_seq_12.272.874274487 RECID=26 STAMP=874274487
archived log file name=+FRA/OR
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值