最近我買到了二手的 Raspberry Pi 4 8GB,這裡分享一些簡單的效能測試方法。
7z b(推薦)
7zip 提供了一個指令可以用來測試效能。
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
:~$ 7z b
7-Zip [64] 16.02 : Copyright (c) 1999-2016 Igor Pavlov : 2016-05-21
p7zip Version 16.02 (locale=C.UTF-8,Utf16=on,HugeFiles=on,64 bits,4 CPUs LE)
LE
CPU Freq: 64000000 - - - - - - - -
RAM size: 7811 MB, # CPU hardware threads: 4
RAM usage: 882 MB, # Benchmark threads: 4
Compressing | Decompressing
Dict Speed Usage R/U Rating | Speed Usage R/U Rating
KiB/s % MIPS MIPS | KiB/s % MIPS MIPS
22: 3893 341 1110 3787 | 74504 398 1597 6356
23: 3733 349 1089 3804 | 73285 398 1593 6341
24: 3657 361 1091 3933 | 72108 398 1589 6330
25: 3534 368 1097 4035 | 70803 399 1579 6301
---------------------------------- | ------------------------------
Avr: 355 1097 3890 | 398 1589 6332
Tot: 377 1343 5111
|
參考:7z benchmark for Raspberry Pi 4
以下是我在 Raspberry Pi 4 上的測試結果:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
pi@PI204:~ $ pi@PI204:~ $ 7z b
7-Zip [64] 16.02 : Copyright (c) 1999-2016 Igor Pavlov : 2016-05-21
p7zip Version 16.02 (locale=en_GB.UTF-8,Utf16=on,HugeFiles=on,64 bits,4 CPUs LE)
LE
CPU Freq: - - - - - - - - -
RAM size: 7809 MB, # CPU hardware threads: 4
RAM usage: 882 MB, # Benchmark threads: 4
Compressing | Decompressing
Dict Speed Usage R/U Rating | Speed Usage R/U Rating
KiB/s % MIPS MIPS | KiB/s % MIPS MIPS
22: 4316 342 1229 4199 | 89104 400 1903 7602
23: 4172 355 1199 4252 | 87453 399 1894 7567
24: 4006 362 1189 4308 | 85778 400 1884 7530
25: 3543 322 1255 4046 | 83766 399 1866 7455
---------------------------------- | ------------------------------
Avr: 345 1218 4201 | 400 1887 7539
Tot: 372 1552 5870
pi@PI204:~ $
|
我也在 Raspberry Pi 3 上進行了測試,但由於運行了 Loki 和 Grafana,測試過程中卡住了,所以中斷了測試。
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
pi@PI203:~ $ 7z b
7-Zip [64] 16.02 : Copyright (c) 1999-2016 Igor Pavlov : 2016-05-21
p7zip Version 16.02 (locale=en_GB.UTF-8,Utf16=on,HugeFiles=on,64 bits,4 CPUs LE)
LE
CPU Freq: - - - - - - - - -
RAM size: 907 MB, # CPU hardware threads: 4
RAM usage: 882 MB, # Benchmark threads: 4
Compressing | Decompressing
Dict Speed Usage R/U Rating | Speed Usage R/U Rating
KiB/s % MIPS MIPS | KiB/s % MIPS MIPS
22: 1944 299 633 1892 | 46232 361 1091 3944
23: 1820 302 615 1855 | 45204 360 1086 3911
24: 1683 297 609 1811 | 43703 357 1074 3837
|
以下是我在 Ubuntu 桌機上的測試結果:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
malagege@malagege-ubuntu:~$ 7z b
7-Zip [64] 16.02 : Copyright (c) 1999-2016 Igor Pavlov : 2016-05-21
p7zip Version 16.02 (locale=zh_TW.UTF-8,Utf16=on,HugeFiles=on,64 bits,8 CPUs Intel(R) Core(TM) i7-4790K CPU @ 4.00GHz (306C3),ASM,AES-NI)
Intel(R) Core(TM) i7-4790K CPU @ 4.00GHz (306C3)
CPU Freq: - 64000000 - - - - - - -
RAM size: 23951 MB, # CPU hardware threads: 8
RAM usage: 1765 MB, # Benchmark threads: 8
Compressing | Decompressing
Dict Speed Usage R/U Rating | Speed Usage R/U Rating
KiB/s % MIPS MIPS | KiB/s % MIPS MIPS
22: 24049 659 3552 23395 | 280380 784 3049 23915
23: 24803 718 3521 25272 | 275331 780 3054 23826
24: 23076 716 3464 24812 | 272103 781 3057 23882
25: 22489 741 3464 25678 | 269085 786 3048 23947
---------------------------------- | ------------------------------
Avr: 709 3500 24789 | 783 3052 23893
Tot: 746 3276 24341
|
rpi-benchmark
1
|
curl -L https://raw.githubusercontent.com/aikoncwd/rpi-benchmark/master/rpi-benchmark.sh | sudo bash
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
Raspberry Pi Benchmark Test
Author: AikonCWD
Version: 3.0
temp=42.3'C arm_freq=1800
core_freq=500
core_freq_min=200
gpu_freq=500
gpu_freq_min=250
sd_clock=50.000 MHz
Running InternetSpeed test...
Ping: 5.446 ms Download: 61.56 Mbit/s
Upload: 15.01 Mbit/s
Running CPU test... WARNING: the --test option is deprecated. You can pass a script name or path on the command line without any options.
total time: 10.0002s
min: 0.22
avg: 0.23
max: 4.24
temp=50.6'C
Running THREADS test... WARNING: the --test option is deprecated. You can pass a script name or path on the command line without any options.
total time: 10.0018s
min: 4.27 avg: 4.44 max: 15.42
temp=51.1'C
Running MEMORY test...
WARNING: the --test option is deprecated. You can pass a script name or path on the command line without any options.
3072.00 MiB transferred (8517.61 MiB/sec)
total time: 0.3572s
min: 0.00
avg: 0.00
max: 8.01
temp=53.0'C
Running HDPARM test...
Timing buffered disk reads: 136 MB in 3.04 seconds = 44.75 MB/sec
temp=44.8'C
Running DD WRITE test...
^[[B536870912 bytes (537 MB, 512 MiB) copied, 19.377 s, 27.7 MB/s
temp=42.8'C
Running DD READ test...
536870912 bytes (537 MB, 512 MiB) copied, 11.5297 s, 46.6 MB/s
temp=42.8'C
AikonCWD's rpi-benchmark completed!
|
其他方法
彩蛋
最近研究了如何更改 sourcelist 為台灣鏡像,這裡記錄一下。