Chinaunix首页 | 论坛 | 博客
  • 博客访问: 669858
  • 博文数量: 759
  • 博客积分: 5000
  • 博客等级: 大校
  • 技术积分: 4845
  • 用 户 组: 普通用户
  • 注册时间: 2008-10-27 13:51
文章分类

全部博文(759)

文章存档

2011年(1)

2008年(758)

我的朋友

分类:

2008-10-27 13:58:02

    我以前介绍过获得redo block size的方法,当然也可以通过dbfsize工具获得。

    现在在这里我想介绍的是另外一种非典型方法,有多非典型呢?

    问题来自于N年前我在一个客户的机器上部署的监控脚本,现在那些脚本看来还在运行着,我最近收到了大量类似如下内容的邮件:

ORA-16038: log 2 sequence# 17151 cannot be archived
ORA-19504: failed to create file ""
ORA-00312: online log 2 thread 1: '/export/home/oracle/oradata/cuwap/redo02.log'
ORA-19504: failed to create file "/data1/oraarc/PTL017151.arc"
ORA-19504: failed to create file "/data1/oraarc/PTL017151.arc"
ORA-27044: unable to write the header block of file
ORA-16038: log 2 sequence# 17151 cannot be archived
ORA-19504: failed to create file ""
ORA-00312: online log 2 thread 1: '/export/home/oracle/oradata/cuwap/redo02.log'
ORA-19504: failed to create file "/data1/oraarc/PTL017151.arc"
ORA-19504: failed to create file "/data1/oraarc/PTL017151.arc"
ORA-27044: unable to write the header block of file
ORA-16038: log 2 sequence# 17151 cannot be archived
ORA-19504: failed to create file ""
ORA-00312: online log 2 thread 1: '/export/home/oracle/oradata/cuwap/redo02.log'
ORA-19502: write error on file "/data1/oraarc/PTL017151.arc", blockno 169985 (blocksize=512)
ORA-27072: skgfdisp: I/O error
ORA-19502: write error on file "/data1/oraarc/PTL017151.arc", blockno 169985 (blocksize=512)
ORA-19502: write error on file "/data1/oraarc/PTL017152.arc", blockno 57345 (blocksize=512)
ORA-27072: skgfdisp: I/O error
ORA-19502: write error on file "/data1/oraarc/PTL017152.arc", blockno 57345 (blocksize=512)
ORA-16038: log 2 sequence# 17151 cannot be archived
ORA-19502: write error on file "", blockno (blocksize=)
ORA-00312: online log 2 thread 1: '/export/home/oracle/oradata/cuwap/redo02.log'
ORA-16038: log 2 sequence# 17151 cannot be archived
ORA-19502: write error on file "", blockno (blocksize=)
ORA-00312: online log 2 thread 1: '/export/home/oracle/oradata/cuwap/redo02.log'
ORA-16038: log 2 sequence# 17151 cannot be archived
ORA-19502: write error on file "", blockno (blocksize=)
ORA-00312: online log 2 thread 1: '/export/home/oracle/oradata/cuwap/redo02.log'
ORA-16038: log 3 sequence# 17152 cannot be archived
ORA-19502: write error on file "", blockno (blocksize=)
ORA-00312: online log 3 thread 1: '/export/home/oracle/oradata/cuwap/redo03.log'

我们注意到,在这些错误信息中,这样的提示至关重要:

ORA-19502: write error on file "/data1/oraarc/PTL017151.arc", blockno 169985 (blocksize=512)
ORA-27072: skgfdisp: I/O error
ORA-19502: write error on file "/data1/oraarc/PTL017151.arc", blockno 169985 (blocksize=512)
ORA-19502: write error on file "/data1/oraarc/PTL017152.arc", blockno 57345 (blocksize=512)

这里的Blocksize就告诉我们,在该系统上(Solaris),Redo Block Size是512 bytes。

这里的BlockNo让我想到了另外一个内容。

     参考Steve Adams网站上的关于Log Buffer Usage的说明我们能找到另外一个有意思的内容,引用一下Steve的图:
log_buffer_mapping

    我们知道,Redo Log Buffer和Redo Log File是通过Block映射(map)来完成空间分配和使用的,于是也就有了两个变量:
1.用以标示SGA中Redo Log Buffer基准位置的变量b
2.用以标示Redo Log File基准位置的变量i

    如果这里存在问题的是redo log file,那么无法写入的blockno实际上就应该和variable (i)有关;当然对于归档日志文件,这里的blockno自然也是由最初的变量推进和定界的。

由以上输出的错误信息我们可以知道:

169985 * 512 /1024 /1024 = 83M

    所以我们还可以判断Redo Log File的大小肯定是大于83M的,在9i中,缺省的Redo Log File大小是100M。

-The End-

【责编:Peng】

--------------------next---------------------

阅读(458) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~