【转载】ORA-27054 错误解决

问题描述

在一个oracle rac环境里,执行rman进行日志的备份,发生了ora-27054的错误,数据库日志无法备份。

1.1 主机和数据库环境
#oslevel -s

6100-05-01-1016

#df -g

/dev/lv_archivelog 100.00 99.55 1% 7 1% /archivelog/orcl1

db_node2:/archivelog/orcl2 100.00 96.18 4% 33 1% /archivelog/orcl2

Rac 的另外一个主机的目录/archivelog/orcl2 mountdb_node1/archivelog/orcl2 目录,目录的访问权限已经正确设置

#su - oracle

$sqlplus / as sysdba

SQL*Plus: Release 10.2.0.5.0 - Production on Tue May 24 10:01:47 2011

Copyright (c) 1982, 2010, Oracle. All Rights Reserved.

Connected to:

Oracle Database 10g Enterprise Edition Release 10.2.0.5.0 - 64bit Production

With the Partitioning, Real Application Clusters, OLAP, Data Mining

and Real Application Testing options

1.2 rman备份的脚本

RMAN> connect target *

2> run{

3> allocate channel d1 type disk maxpiecesize 2g;

4> allocate channel d2 type disk maxpiecesize 2g;

5> sql 'alter system archive log thread 1 current';

6> sql 'alter system archive log thread 2 current';

7> host 'rm -f /archivelog/orcl1/arc*_1.bak';

8> backup copies 2 archivelog all delete input format '/rman/arc_%s_%t_%U.bak';

9> host 'mv /rman/arc*_1.bak /archivelog/orcl1';

10> release channel d1;

11> release channel d2;

12> }

13>


1.3 db_node1上执行 rman 备份时,ora-27054错误

using target database control file instead of recovery catalog

allocated channel: d1

channel d1: sid=1139 instance=orcl1 devtype=DISK

allocated channel: d2

channel d2: sid=1073 instance=orcl1 devtype=DISK

sql statement: alter system archive log thread 1 current

sql statement: alter system archive log thread 2 current

Starting backup at 24-MAY-11

current log archived

released channel: d1

released channel: d2

RMAN-00571: ===========================================================

RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============

RMAN-00571: ===========================================================

RMAN-03002: failure of backup command at 05/24/2011 09:26:41

RMAN-06059: expected archived log not found, lost of archived log compromises recoverability

ORA-19625: error identifying file /archivelog/orcl2/orcl_2_3377_739815553.arc

ORA-27054: NFS file system where the file is created or resides is not mounted with correct options

Additional information: 6

Recovery Manager complete.

问题分析

首先目录的访问权限没有问题,尝试在db_node1上的/archivelog/orcl2 目录上建立,修改文件都没有问题,说明nfs设置没有问题.

METALINK上搜索ora-27054 nfs,找到了一篇文章 ORA-27054 ERRORS WHEN RUNNING RMAN WITH NFS [ID 387700.1]

 文档中提及造成问题的原因可能是oracle去考虑nfs的问题总之需要执行命令。

Alter system set events '10298 trace name context forever,level 32'

问题解决

在执行rman备份的节点执行:

SQL>Alter system set events '10298 trace name context forever,level 32'

执行这个命令,不需要重新启动rac的实例,也不需要重新启动DB.但上面的命令在下次数据库重新启动后就失效了,需要再次手工执行。(笔者曾经在数据库重新启动后,忘记了执行这个语句,导致日志文件目录差点爆满)。

如果想数据库重新启动后,自动执行这个命令,则执行下面的命令:

SQL>alter system set event='10298 trace name context forever,level 32' SCOPE=SPFILE;

细心的朋友会发现上面提到的两个命令还是有一点小小区别的。

执行完命令后,再次执行rman的备份,正常。

RMAN> connect target *

2> run{

3> allocate channel d1 type disk maxpiecesize 2g;

4> allocate channel d2 type disk maxpiecesize 2g;

5> sql 'alter system archive log thread 1 current';

6> sql 'alter system archive log thread 2 current';

7> host 'rm -f /archivelog/orcl1/arc*_1.bak';

8> backup copies 2 archivelog all delete input format '/rman/arc_%s_%t_%U.bak';

9> host 'mv /rman/arc*_1.bak /archivelog/orcl1';

10> release channel d1;

11> release channel d2;

12> }

13>

allocated channel: d1

channel d1: sid=919 instance=orcl1 devtype=DISK

allocated channel: d2

channel d2: sid=906 instance=orcl1 devtype=DISK

sql statement: alter system archive log thread 1 current

sql statement: alter system archive log thread 2 current

Starting backup at 24-MAY-11

current log archived

channel d1: starting compressed archive log backupset

channel d1: specifying archive log(s) in backup set

input archive log thread=1 sequence=5095 recid=7539 stamp=751940283

。。。。。。

archive log filename=/archivelog/orcl2/orcl_2_3385_739815553.arc recid=7574 stamp=751973830

Finished backup at 24-MAY-11

Starting Control File and SPFILE Autobackup at 24-MAY-11

piece handle=/oracle/product/10.2.0/db/dbs/c-1267596289-20110524-01 comment=NONE

Finished Control File and SPFILE Autobackup at 24-MAY-11

released channel: d1

released channel: d2

Recovery Manager complete.

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

转载于:http://blog.itpub.net/11088128/viewspace-709278/

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

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

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值