oracle的io优化--db_writer_processes & dbwr_io_slaves对比

2023-11-01

author:skate
time:2011/09/29

db_writer_processes 和 dbwr_io_slaves对比

 

在计算机世界里,磁盘的发展速度远低于cpu,memory。磁盘io现在已经成为计算机的瓶颈,对于oracle的db系统。磁盘io更是
重要。在oracle里为了提高io的速度,常用参数db_writer_processes 和 dbwr_io_slaves

在数据库里事务数非常高,或db cache很大,一个DBWn process跟不上数据的load,我们可以调整这两个参数,这两个
参数的作用就是增加io读写进程,启用异步io,加快io的速度

多个 slaves 可以并行写数据文件,而多个dbwr也可以并行写数据文件
一个 dbwr 多个 slaves是 dbwr 搜集dirty  buffer 而 slaves 写数据文件
多个dbwr 可以并行地搜集dirty buffer 并且并行地写数据文件

但是如果系统支持AIO一般不用设置多dbwr 或者 io slaves

db_writer_processes:在多cpu,多磁盘的环境,一般是每8个cpu一个dbwr进程

 

什么时候配置这两个参数
如果系统的io是瓶颈是,检查os是否支持异步io,如果支持异步io,但目前没有使用,那就启用异步io来缓解io瓶颈。如果os不支持异步io,
或os已经启用异步io,但io还是瓶颈,那我们可以配置多个dbwr进程。配置这两个参数是要注意,大都是如下

一个db_writer_processes,多个dbwr_io_slaves
多个db_writer_processes,dbwr_io_slaves不启用

 


官网如下:http://download.oracle.com/docs/cd/B10501_01/server.920/a96533/instance_tune.htm

Consider Multiple Database Writer (DBWR) Processes or I/O Slaves
Configuring multiple database writer processes, or using I/O slaves, is useful when the transaction rates are high or when the buffer cache size is so large that a single DBWn process cannot keep up with the load.

DB_WRITER_PROCESSES
The DB_WRITER_PROCESSES initialization parameter lets you configure multiple database writer processes (from DBW0 to DBW9 and from DBWa to DBWj). Configuring multiple DBWR processes distributes the work required to identify buffers to be written, and it also distributes the I/O load over these processes. Multiple db writer processes are highly recommended for systems with multiple CPUs (at least one db writer for every 8 CPUs) or multiple processor groups (at least as many db writers as processor groups).

Based upon the number of CPUs and the number of processor groups, Oracle either selects an appropriate default setting for DB_WRITER_PROCESSES or adjusts a user-specified setting.

DBWR_IO_SLAVES
If it is not practical to use multiple DBWR processes, then Oracle provides a facility whereby the I/O load can be distributed over multiple slave processes. The DBWR process is the only process that scans the buffer cache LRU list for blocks to be written out. However, the I/O for those blocks is performed by the I/O slaves. The number of I/O slaves is determined by the parameter DBWR_IO_SLAVES.

DBWR_IO_SLAVES is intended for scenarios where you cannot use multiple DB_WRITER_PROCESSES (for example, where you have a single CPU). I/O slaves are also useful when asynchronous I/O is not available, because the multiple I/O slaves simulate nonblocking, asynchronous requests by freeing DBWR to continue identifying blocks in the cache to be written. Asynchronous I/O at the operating system level, if you have it, is generally preferred.

DBWR I/O slaves are allocated immediately following database open when the first I/O request is made. The DBWR continues to perform all of the DBWR-related work, apart from performing I/O. I/O slaves simply perform the I/O on behalf of DBWR. The writing of the batch is parallelized between the I/O slaves.


--------------------------------------------------------------------------------
Note:
Implementing DBWR_IO_SLAVES requires that extra shared memory be allocated for I/O buffers and request queues. Multiple DBWR processes cannot be used with I/O slaves. Configuring I/O slaves forces only one DBWR process to start.

--------------------------------------------------------------------------------


Choosing Between Multiple DBWR Processes and I/O Slaves
Configuring multiple DBWR processes benefits performance when a single DBWR process is unable to keep up with the required workload. However, before configuring multiple DBWR processes, check whether asynchronous I/O is available and configured on the system. If the system supports asynchronous I/O but it is not currently used, then enable asynchronous I/O to see if this alleviates the problem. If the system does not support asynchronous I/O, or if asynchronous I/O is already configured and there is still a DBWR bottleneck, then configure multiple DBWR processes.


--------------------------------------------------------------------------------
Note:
If asynchronous I/O is not available on your platform, then asynchronous I/O can be disabled by setting the DISK_ASYNCH_IO initialization parameter to FALSE.

--------------------------------------------------------------------------------


Using multiple DBWRs parallelizes the gathering and writing of buffers. Therefore, multiple DBWn processes should deliver more throughput than one DBWR process with the same number of I/O slaves. For this reason, the use of I/O slaves has been deprecated in favor of multiple DBWR processes. I/O slaves should only be used if multiple DBWR processes cannot be configured.
 

-------end--------

 

 

 

 

本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

oracle的io优化--db_writer_processes & dbwr_io_slaves对比 的相关文章

随机推荐

  • Java面试官最爱问的volatile关键字

    在Java的面试当中 面试官最爱问的就是volatile关键字相关的问题 经过多次面试之后 你是否思考过 为什么他们那么爱问volatile关键字相关的问题 而对于你 如果作为面试官 是否也会考虑采用volatile关键字作为切入点呢 为什
  • 如何建立chrony服务器

    Chrony由两个程序组成 分别是chronyd和chronyc chronyd是一个后台运行的守护进程 用于调整内核中运行的系统时钟和时钟服务器同步 它确定计算机增减时间的比率 并对此进行补偿 chronyc提供了一个用户界面 用于监控性
  • 生成 Linux 运行时间报告的 Bash 脚本

    出于一些原因 你可能需要每月收集一次 Linux 系统运行时间报告 Magesh Maruthamuthu 出于一些原因 你可能需要每月收集一次 Linux 系统运行时间报告 如果是这样 你可以根据需要使用以下 bash 脚本 之一 我们为
  • Effect Hook

    1 数据获取 设置订阅以及手动更改 React 组件中的 DOM 都属于副作用 2 可以把 useEffect Hook 看做 componentDidMount componentDidUpdate 和 componentWillUnmo
  • 关于 Windows 10 下安装 Linux 过程及报 'WSL...' 错误的解决办法

    今天下午在群里看到有朋友发有关 Windows 10 下按安装 Linux 系统 的消息 小白我很是激动啊 Linux 贴近工作 Windows 贴近生活 割舍不下 虽然可以在Windows下安装虚拟机 但是真的很占空间 0 0 而这个消息
  • 逻辑回归、激活函数sigmoid、损失及优化、案例代码实现

    一 逻辑回归 逻辑回归 Logistic Regression 是机器学习中的一种分类模型 是一种分类算法 与回归之间有一定的联系 由于算法的简单和高效 在实际中应用非常广泛 应用场景 广告点击率 是否为垃圾邮件 是否患病 金融诈骗 虚假账
  • Java-API简析_java.lang.Float类(基于 Latest JDK)(浅析源码)

    版权声明 未经博主同意 谢绝转载 请尊重原创 博主保留追究权 https blog csdn net m0 69908381 article details 131129886 出自 进步 于辰的博客 因为我发现目前 我对Java API的
  • Sqoop的简单使用案例和一些常用命令及参数

    Sqoop的简单使用案例 1 导入数据 在Sqoop中 导入 概念指 从非大数据集群 RDBMS 向大数据集群 HDFS HIVE HBASE 中传输数据 叫做 导入 即使用import关键字 1 1 RDBMS到HDFS 1 确定Mysq
  • java——编程案例

    文章目录 案例1 买飞机票 案例2 找素数 案例3 开发验证码 案例4 数组元素的复制 案例5 评委打分 案例6 数字加密 案例7 模拟双色球 案例1 买飞机票 import java util Scanner public class T
  • stm32ftp服务器实现文件传输,stm32 ftp服务器

    stm32 ftp服务器 内容精选 换一换 客户端压力机硬件要求如表1所示 负载均衡节点 LVS 硬件要求如表2所示 缓存节点 Nginx ATS 硬件要求如表3所示 源站节点 Nginx 硬件要求如表4所示 操作系统要求如表5所示 软件要
  • MSN下载2010最新版

    转载的 哈哈 我的笔记 MSN 最新微软官网下载地址 NLP伪原创技术早期并不是很受欢迎 基于主动学习的伪原创句法识别研究 这几年专注于Web开发 Web界面设计的心得在这篇文章中已经与大家分享 做项目时 如何做比较美观大方的数据输入窗体
  • apisix高性能网关-中文开发文档

    2020年6月12日13 48 33 github https github com apache incubator apisix 目前此项目已有成为apache孵化项目 官方中文文档 https github com apache in
  • 拓展人脉,把握机会,摆脱“孔乙己的长衫”

    孔乙己的长衫 学历究竟成为敲门砖还是枷锁 孔乙已是鲁迅笔下人物 穷困流倒还穿着象征读书人的长衫 迁腐 麻木 最近 大家自我调佩是 当代孔乙己 学历成为思想负担 找工作时高不成低不就 我将从以下几个方面来说一说我对这方面的看法 我认为 在当今
  • 1. 两数之和

    目录 给定一个整数数组 nums 和一个整数目标值 target 请你在该数组中找出 和为目标值 target 的那 两个 整数 并返回它们的数组下标 你可以假设每种输入只会对应一个答案 但是 数组中同一个元素在答案里不能重复出现 你可以按
  • 数据结构--计算表达式完整版(涉及乘方)

    思路 两个栈 数据栈与符号栈 在描述优先级时 我们将加减描述为 I级 乘除为 II既 乘方为 III级 1 在之前的只有加减乘除的计算表达式里 就有了初步思路 当我们要计算的时候 局部计算函数 数字栈与符号栈 分别在数字栈顶取出两个操作数
  • i2c_SLAVE

    driver driver通过I2C的接口与DUT相连 负责接收DUT通过接口传来的地址数据等读写信息并作出反应 将sequencer中传来的trans中的数据驱动到总线上并根据设置的ack和nack作出回应 将总线上写来的数据存到tran
  • Visual Studio 2019 C语言程序(VS2019 C语言)

    新的Visual Studio 2019出来已经有一段时间了 博主也是一开始就从vs2017换到了vs2019 发现整体的操作流程还是有一定的改变 因为之前发表过一个vs2017的博客 对Visual Studio IDE和风格确实非常喜欢
  • Qt5 通过 QFtp 实现 Ftp文件下载

    在Qt5环境下使用自编译的QFtp库 参考官方提供的实例 对部分内容进行更改 实现了Ftp下载文件的客户端 详细代码如下 h头文件 ifndef FTPWINDOW H define FTPWINDOW H include
  • linux下查看某服务端口对应的进程ID

    Linux下查看某端口号所对应的进程ID 使用lsof命令 格式为 lsof i 端口号 例如 lsof i 30000 root Web Service CAServer lsof i 30000 COMMAND PID USER FD
  • oracle的io优化--db_writer_processes & dbwr_io_slaves对比

    author skate time 2011 09 29 db writer processes 和 dbwr io slaves对比 在计算机世界里 磁盘的发展速度远低于cpu memory 磁盘io现在已经成为计算机的瓶颈 对于orac