linux系统
sysbench测试工具
sysbench安装:进入linux命令行:ubuntu系统: apt install sysbenchcentos系统: yum install sysbench
cpu性能:sysbench cpu --cpu-max-prime=20000 --threads=4 run
磁盘io性能://写入测试数据文件测试:sysbench --test=fileio --threads=4 --file-total-size=3G --file-test-mode=rndrw prepare结果:3g文件,分开128个小文件,平均一个24m, 实际写入速度11.81m/s
磁盘io性能://测试io性能:sysbench --test=fileio --threads=4 --file-total-size=3G --file-test-mode=rndrw run随机读写测试结果:读宽带:2.58M/s,写宽带:1.71M/s注意:测试完清理删除3g测试文件:sysbench --test=fileio --threads=4 --file-total-size=3G --file-test-mode=rndrw cleanup
内存分配及传输速度:测试8K顺序分配:sysbench --threads=4 --events=10000 --test=memory --memory-block-size=8K --memory-total-size=10G --memory-access-mode=seq run测试结果: 4385.97m/s
内存分配及传输速度:测试8K随机分配。sysbench --threads=4 --events=10000 --test=memory --memory-block-size=8K --memory-total-size=10G --memory-access-mode=rnd run测试结果:299m/s