ITPub博客

首页 > 数据库 > Oracle > 053.【实验:磁盘与内存的访问性能比较】

053.【实验:磁盘与内存的访问性能比较】

原创 Oracle 作者:limintjhn 时间:2013-01-06 20:24:38 0 删除 编辑

【实验环境】
1.笔记本电脑thinkpad-E420
2.在虚拟机上安装的RHEL4.8
3.Oracle Database 10.2.0.1

【实验】
SQL> set timing on;
SQL> alter system flush buffer_cache;

System altered.

Elapsed: 00:00:00.11
SQL> select /*+no_index(t)*/ count(*) from scott.t_db_cache t;

COUNT(*)
----------
528000

Elapsed: 00:00:04.50
SQL> select /*+no_index(t)*/ count(*) from scott.t_db_cache t;

COUNT(*)
----------
528000

Elapsed: 00:00:00.02

【小结】
1.磁盘访问用时4.50秒,内存访问用时0.02秒
2.相差225倍

[@more@]

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

请登录后发表评论 登录
全部评论

注册时间:2013-02-03

  • 博文量
    53
  • 访问量
    36584