【ORACLE】ORA-00245: control file backup operation failed

从oracle 11.2.0.2.0开始,控制文件的快照文件必须能够被所有节点的数据实例访问到,并且必须放在共享的位置。否则,使用RMAN进行备份控制文件的时候会报如下错误:

ORA-00245: control file backup operation failed。

当使用备份脚本备份的时候,这个错误可能会导致备份工作中断。

公司同事也正好遇到这个问题。 

METALINK 中的两篇文档:

RAC BACKUP FAILS WITH ORA-00245: CONTROL FILE BACKUP OPERATION FAILED          [ID 1268725.1]

RMAN Snapshot Controlfile Must Reside on Shared Device for RAC database in 11G [ID 1263621.1]

解释并解决了此问题!摘要如下:

"RMAN creates a copy of the control file for read consistency, this is the snapshot controlfile. Due to the changes made to the controlfile backup mechanism in 11gR2 any instances in the cluster may write to the snapshot controlfile. Therefore, the snapshot controlfile file needs to be visible to all instances.

The same happens when a backup of the controlfile is created directly from sqlplus any instance in the cluster may write to the backup controfile file.

In 11gR2 onwards, the controlfile backup happens without holding the control file enqueue. For non-RAC database, this doesn't change anything. 

But, for RAC database, the snapshot controlfile location must be in a shared file system that will be accessible from all the nodes."

当遇到此类问题时,警告日志文件会出现如下内容:

Alert log file content:

2011-08-20 00:11:53.650000 +02:00

Errors in file /opt/app/oracle/diag/rdbms/orcl/trace/cmsdb1_ora_15751.trc:

ORA-00245: control file backup operation failed

Trace File content:

Starting control autobackup

*** 2011-08-20 00:11:53.650

ORA-00245: control file backup operation failed

Got error: 245

Autobackup failed with following error

ORA-00245: control file backup operation failed

当前的控制文件配置:

rman target /

show all;

CONFIGURE SNAPSHOT CONTROLFILE NAME TO '/u01/app/oracle/product/11.2.0/db_1/dbs/snapcf_orcl.f'; # default

我们的环境中使用了asm,所以将控制文件备份到ASM中。

使用如下配置解决此问题:

rman target /

Recovery Manager: Release 11.2.0.2.0 - Production on Tue Aug 21 10:00:33 2011

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

connected to target database: CMSDB (DBID=1390673463)

RMAN> CONFIGURE SNAPSHOT CONTROLFILE NAME TO '+FLASH/SNCFORCL.ORA';

using target database control file instead of recovery catalog

new RMAN configuration parameters:

CONFIGURE SNAPSHOT CONTROLFILE NAME TO '+FLASH/SNCFORCL.ORA';

new RMAN configuration parameters are successfully stored

RMAN>

时间: 2024-11-20 14:21:09

【ORACLE】ORA-00245: control file backup operation failed的相关文章

【oracle】ORA-01580 error creating control backup file

早上查看报警邮件的时候发现了ORA-01580 error creating control backup file. 通常次错误与RMAN 备份控制文件的策略有关: 比如: RMAN> backup current controlfile; Starting backup at 22-AUG-11 using channel ORA_DISK_1 channel ORA_DISK_1: starting full datafile backupset channel ORA_DISK_1: s

Oracle技术:snapshot control file enqueue

rman备份db时出现了:waiting for snapshot control file enqueue提示,很少看到这个提示,记录一下. RMAN> run{ 2> backup database; 3> delete noprompt obsolete; 4> backup archivelog all; 5> } Starting backup at 2011-09-30 15:31:00 using channel ORA_DISK_1 channel ORA_D

【ORACLE】relink oracle 10g 数据库

通常要迁移一个数据库,我们会使用 1 冷备份,整个数据库迁移, 2 rman duplicate 功能进行复制到本机或者复制到异机, 前面两种都必须先在目标库上安装软件.这里测试另外一种方法:对于单实例数据库,复制整个oracle 10g 数据库到另一个服务器,relink 之后可以重新使用.. 查看源库数据库库文件在$ORACLE_BASE 目录下的分布: oracle@yangDB1:/opt/oracle>ll 总计 36 drwxrwx--- 3 oracle oinstall 4096

【oracle】静默安装 oracle 11gr2

[序言] oracle 提供了静默安装方法在不适用图形界面的情况下安装 oracle 软件 ,创建db,配置netca,快速完成oracle 的部署.  在以下情形中可以使用静默安装    a OUI 的 GUI 界面远程交互比较慢 .    b 数据库服务器无法使用图形界面访问.    c 批量部署oracle (标准环境统一情况下可以使用oracle 的relink ,这样更加快速). 本文主要讲述基本安装步骤,不涉及oracle 安装完成之后的运维规范: 监控,备份,定时日志清理,基础运维

【Oracle】修改oracle监听端口

修改oracle 监听端口号,过程相对比较简单: 1 修改 listener.ora ,tnsnames.ora 文件中的端口号 2 重启监听 lsnrctl stop ,lsnrctl start 上面的过程是对于 监听名为默认的LISTENER 而言的,如果listener.oar文件中的监听名不是默认的,就重启时必须指定监听名.比如将端口号由1521改为1523 oracle@rac3:/opt/oracle/11.2.0/alifpre/network/admin>vi listener

【Oracle】lsnrctl reload 命令操作

上一篇简单介绍了lsnrctl reload的原理!这篇文章实验一下给数据库增加静态监听,reload 监听并查看监听器的日志: oracle@rac1:/opt/oracle/11.2.0/yangdb/network/admin>lsnrctl status LSNRCTL for Linux: Version 11.2.0.2.0 - Production on 13-SEP-2011 14:21:41 Copyright (c) 1991, 2010, Oracle.  All righ

【Oracle】 rman 删除归档日志的命令

   因为数据仓库上asm的磁盘空间不足,需要删除早期的归档日志,查看资料有以下两种方式: delete archivelog until time 'sysdate-N'; delete archivelog all completed before 'sysdate-N'; 这两个命令的差别在哪里呢? 使用list 命令来查看一下究竟... RMAN>  list archivelog until time 'sysdate-1'; using target database control

【Oracle】service_name和service_names的关系

从oracle9i开始,后台进程PMON自动在监听器中注册初始化参数SERVICE_NAMES中定义的服务名,SERVICE_NAMES默认为db_name.db_dimain.客户端tns配置中SERVICE_NAME的名称必须是SERVICE_NAMES或其中的一个NAME. 1 listenter.ora文件中的 GLOBAL_DBNAME和tnsnames.ora文件SERVICE_NAME的配置一样时,GLOBAL_DBNAME = A, 连接串中的SERVICE_NAME = A,此

【Oracle】Python 连接Oracle 数据库

Python 连接Oracle 数据库,需要使用cx_Oracle 包. 1 下载cx_Oracle 该包的下载地址:http://cx-oracle.sourceforge.net/ 下载的时候,注意选择与操作系统和oracle版本相对应的cx_Oracle版本. 2 安装 [root@rac3 python]# rpm -ivh cx_Oracle-5.1.1-11g-py24-1.x86_64.rpm  Preparing...                ###############