zoukankan      html  css  js  c++  java
  • DD测磁盘读写性能

    1、测试磁盘的纯写入性能 dd if=/dev/zero of=/file

    [oracle@11g ~]$ touch ddTest
    [oracle@11g ~]$ time dd if=/dev/zero of=/home/oracle/ddTest bs=1k count=1024
    1024+0 records in
    1024+0 records out
    1048576 bytes (1.0 MB) copied, 0.0261858 s, 40.0 MB/s

    real 0m0.029s
    user 0m0.009s
    sys 0m0.017s
    [oracle@11g ~]$ du -h ddTest
    1.0M ddTest

    2、 测试磁盘的纯读取性能 dd if=/file of=/dev/null

    [oracle@11g ~]$ time dd if=/dev/zero^Cf=/home/oracle/ddTest bs=1k count=1024
    [oracle@11g ~]$ touch test1
    [oracle@11g ~]$ time dd if=/home/oracle/test1 of=/dev/null bs=1k count=1024
    0+0 records in
    0+0 records out
    0 bytes (0 B) copied, 0.000124694 s, 0.0 kB/s

    real 0m0.001s
    user 0m0.000s
    sys 0m0.000s
    [oracle@11g ~]$ du -h /home/oracle/test1
    0 /home/oracle/test1

    3、 测试磁盘的读写性能 dd if=/file1 of=/file2
    [oracle@11g ~]$ time dd if=/home/oracle/test1 of=/home/oracle/test bs=1k count=1024
    0+0 records in
    0+0 records out
    0 bytes (0 B) copied, 0.000124904 s, 0.0 kB/s

    real 0m0.002s
    user 0m0.001s
    sys 0m0.000s

  • 相关阅读:
    编程路上有你们陪着值了
    我是屌丝程序猿,我为自己代言.
    JSON转换类
    深入理解requestAnimationFrame
    CentOS部署yapi
    前端三种路由方式
    yarn安装使用
    三大框架对比
    es6异步编程
    JS原型链
  • 原文地址:https://www.cnblogs.com/andy6/p/7234976.html
Copyright © 2011-2022 走看看