Oraclecapabilityi/o(压力测试数据库服务器i/o性能)
内容导读
互联网集市收集整理的这篇技术教程文章主要介绍了Oraclecapabilityi/o(压力测试数据库服务器i/o性能),小编现在分享给大家,供广大互联网技能从业者学习和参考。文章包含3686字,纯文字阅读大概需要6分钟。
内容图文
![Oraclecapabilityi/o(压力测试数据库服务器i/o性能)](/upload/InfoBanner/zyjiaocheng/555/5a974236a13e497091a13c63daf1a89b.jpg)
简单说明一下怎么影响重做数据的一个因素,那就是i/o吞吐量,oracle的介质恢复依赖于i/o,如果i/o存在瓶颈,那么势必会影响备库的
简单说明一下怎么影响重做数据的一个因素,那就是i/o吞吐量,Oracle的介质恢复依赖于i/o,如果i/o存在瓶颈,那么势必会影响备库的介质恢复。
那么i/o stack包含hbas,存储相关的交换机、存储物理磁盘。那么oracle建议在应用程序部署的时候,建议去验证i/o避免存在问题。但是之前有一个很刺手的问题,那就是如何去验证i/o侧吞吐量,换句话说怎么去验证i/o吞吐量更符合真实的生产环境。
In Oracle Database 11g, the Real Application Testing feature (Capture/Replay) was introduced to inject real (captured) workload into the system. However, another new 11g feature is available to help assess the I/O capability of the database's storage system, and gauge maximum IOPS and Mbytes/s.
capability i/o feature 是依据一个数据库内部的函数(dbms_resource_manager.calibrateio()),该函数是oracle database内部集成的,更能满足测试i/o问题,且在最后将输出相关报告信息。
那么执行这个包需要注意什么呢?
1、权限,,必须具有sysdba执行该过程的权限,另外需要打开timed_statistics。
2、确定异步i/o在数据库的所有数据文件和临时文件都已经得到应用启动,我们可以通过v$datafile 和v$iostat_file视图关联进行、确认。
eg:
col name format a50
select name,asynch_io from v$datafile f,v$iostat_file i
where f.file#=i.file_no
and (filetype_name='Data File' or filetype_name='Temp File');
如果异步i/o没有启动,设置disk_asynch_io=true启动该功能,但默认是开启的,如果在linux中最大slots使用完毕,那么将自动关闭噶 功能,这也就是为什么虽然设置了disk_asynch_io=true了却依然没有达到效果。最大的slots可以查看/proc/sys/fs/aio-max-nr 当前使用的可以查看/proc/sys/fs/aio-nr去分别确认。
3、确保服务器只有需要测试的数据库开启,避免 其他应用软件的影响。
4、对于RAC,需要确保所有的实例都开启,因为 将会对所有节点做全面的校对,执行该过程只需在一个实例即可。
5、确保只有一个用户执行一个校对i/o的操作。可以通过v$io_calibration_status查看当前鉴定状态。
另外查看资料了解到有这么几个过程:
The calibration will run in different phases. In the first phase, small block random I/O
workload is performed on each node and then concurrently on all nodes. The second
phase will generate large block sequential I/O on each node. Note, that the Calibrate
I/O is expecting that a datafile is spread across all disks specified in NUM_DISKS
variable. Furthermore, offline files are not considered for file I/O.
一旦执行完毕,其结果将存在于dba_rsrc_io_calibrate表中。
好了。
了解到这些,下面开始去实验操作。让实践得真知。
语法如下:
SET SERVEROUTPUT ON
DECLARE
lat INTEGER;
iops INTEGER;
mbps INTEGER;
BEGIN
-- DBMS_RESOURCE_MANAGER.CALIBRATE_IO (
DBMS_RESOURCE_MANAGER.CALIBRATE_IO (2, 10, iops, mbps, lat);
DBMS_OUTPUT.PUT_LINE ('max_iops = ' || iops);
DBMS_OUTPUT.PUT_LINE ('latency = ' || lat);
DBMS_OUTPUT.PUT_LINE ('max_mbps = ' || mbps);
end;
/
参数介绍如下:
Parameter Description
num_physical_disks
Approximate number of physical disks in the database storage(物理磁盘个数 input)
max_latency
Maximum tolerable latency in milliseconds for database-block-sized IO requests(最大可用容忍延迟的毫秒数 input)
max_iops
Maximum number of I/O requests per second that can be sustained. The I/O requests are randomly-distributed, database-block-sized reads.(持续中每秒请求最大i/o的数量 output)
max_mbps
Maximum throughput of I/O that can be sustained, expressed in megabytes per second. The I/O requests are randomly-distributed, 1 megabyte reads.(持续中最大的吞吐量M为单位)
actual_latency
Average latency of database-block-sized I/O requests at max_iops rate, expressed in milliseconds(平均延迟)
更多详情见请继续阅读下一页的精彩内容:
内容总结
以上是互联网集市为您收集整理的Oraclecapabilityi/o(压力测试数据库服务器i/o性能)全部内容,希望文章能够帮你解决Oraclecapabilityi/o(压力测试数据库服务器i/o性能)所遇到的程序开发问题。 如果觉得互联网集市技术教程内容还不错,欢迎将互联网集市网站推荐给程序员好友。
内容备注
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 gblab@vip.qq.com 举报,一经查实,本站将立刻删除。
内容手机端
扫描二维码推送至手机访问。