最新消息:重新回归WordPress,我要比较认真的开始更新我的博客了。

linux性能测试工具sysbench

笔记 hanlei 769浏览

以前用过,后来忘了,这次记在BLOG里,顺便把测试过的一些结果也记录下来。

软件安装简单,只需要”apt install sysbench” 或 “yum install sysbench”

下面是我用来测试CPU让命令

sysbench --test=cpu --cpu-max-prime=20000 run

下面记录的是panther X2的跑分结果,CPU是RK3566

sysbench 1.0.20 (using system LuaJIT 2.1.0-beta3)

Running the test with following options:
Number of threads: 1
Initializing random number generator from current time


Prime numbers limit: 20000

Initializing worker threads...

Threads started!

CPU speed:
    events per second:   345.65

General statistics:
    total time:                          10.0013s
    total number of events:              3458

Latency (ms):
         min:                                    2.87
         avg:                                    2.89
         max:                                   12.52
         95th percentile:                        2.86
         sum:                                 9996.40

Threads fairness:
    events (avg/stddev):           3458.0000/0.00
    execution time (avg/stddev):   9.9964/0.00


#四核
sysbench 1.0.20 (using system LuaJIT 2.1.0-beta3)

Running the test with following options:
Number of threads: 4
Initializing random number generator from current time


Prime numbers limit: 20000

Initializing worker threads...

Threads started!

CPU speed:
    events per second:  1346.88

General statistics:
    total time:                          10.0013s
    total number of events:              13474

Latency (ms):
         min:                                    2.90
         avg:                                    2.97
         max:                                   19.49
         95th percentile:                        2.91
         sum:                                39986.94

Threads fairness:
    events (avg/stddev):           3368.5000/7.26
    execution time (avg/stddev):   9.9967/0.00


我家云的结果

sysbench 0.4.12:  multi-threaded system evaluation benchmark

Running the test with following options:
Number of threads: 1

Doing CPU performance benchmark

Threads started!
Done.

Maximum prime number checked in CPU test: 20000


Test execution summary:
    total time:                          24.3206s
    total number of events:              10000
    total time taken by event execution: 24.3130
    per-request statistics:
         min:                                  2.39ms
         avg:                                  2.43ms
         max:                                  5.00ms
         approx.  95 percentile:               2.52ms

Threads fairness:
    events (avg/stddev):           10000.0000/0.00
    execution time (avg/stddev):   24.3130/0.00

tn3399的测试结果

sysbench 1.0.11 (using system LuaJIT 2.1.0-beta3)

Running the test with following options:
Number of threads: 1
Initializing random number generator from current time


Prime numbers limit: 20000

Initializing worker threads...

Threads started!

CPU speed:
    events per second:   695.62

General statistics:
    total time:                          10.0006s
    total number of events:              6959

Latency (ms):
         min:                                  1.42
         avg:                                  1.44
         max:                                  3.44
         95th percentile:                      1.44
         sum:                               9992.28

Threads fairness:
    events (avg/stddev):           6959.0000/0.00
    execution time (avg/stddev):   9.9923/0.00

转载请注明:HANLEI'BLOG » linux性能测试工具sysbench