Hello everyone,
To simplify and automate filesystem benchmarking on Haiku, I’ve created the fs-test framework.
My current benchmarking workflow is:
-
Boot into a Haiku system using a test image (an .iso).
-
Inside that running Haiku instance, install the bonnie++ benchmarking tool.
-
Create a virtual disk image to test the target filesystem and mount it.
-
Run the fs-test script against the mounted disk image, which automatically executes the bonnie++ benchmark and safely stores the results.
This makes comparing multiple hardware setups or filesystems (like BFS or ext2) incredibly easy. I’m thinking of adding all the generic tests to the filesystems inside this framework. Is this approach right? Here is the result of Benchmarking :
~/haiku/src/tests/add-ons/kernel/file_systems> ./fs-test --fs=bfs --test=benchmark --format=human /boot/home/mnt/
Filesystem: bfs
Mount path: /boot/home/mnt/
[TEST] benchmark
----------------------------------------
# bonnie++ benchmark on /boot/home/mnt/ (bfs)
# bonnie++ -d /boot/home/mnt/ -s 1G -n 16 -u user -q
# Results: ./results/bfs_bonnie_20260318_194741.csv
# Version 2.00a ------Sequential Output------ --Sequential Input- --Random-
-Per Chr- --Block-- -Rewrite- -Per Chr- --Block-- --Seeks--
Name:Size etc /sec %CP /sec %CP /sec %CP /sec %CP /sec %CP /sec %CP
shredder 1G 1332k 99 176m 14 10.9m 5 2583k 71 12.5m 5 4573 63
Latency 15325us 513ms 373ms 14411us 16025us 22463us
Version 2.00a ------Sequential Create------ --------Random Create--------
shredder -Create-- --Read--- -Delete-- -Create-- --Read--- -Delete--
files /sec %CP /sec %CP /sec %CP /sec %CP /sec %CP /sec %CP
16 16384 5 +++++ +++ 16384 6 16384 6 +++++ +++ 16384 7
Latency 3895ms 90us 3388ms 2861ms 660us 4609ms
1.98,2.00a,shredder,1,1773863696,1G,,8192,5,1332,99,179974,14,11206,5,2583,71,12795,5,4573,63,16,,,,,737,5,+++++,+++,879,6,683,6,+++++,+++,641,7,15325us,513ms,373ms,14411us,16025us,22463us,3895ms,90us,3388ms,2861ms,660us,4609ms
ok 1 - benchmark
----------------------------------------
[PASS] benchmark
========================================
SUMMARY: 1 passed, 0 failed
Results: ./results
========================================