SPB Git

Repository Public

BENCHMARKS.md 3.5 KB 64 lines markdown

1<!--2MacLustr Storage Node3File: docs/BENCHMARKS.md4Author: Simon-Pierre Boucher5Contact: contact@spboucher.ai6-->7# Benchmarks — measured values only89Everything below was measured on 2026-12-01 on the production coordinator (m4mn, Mac mini M4 Pro, internal SSD). **No10measurement on a physical iPhone or iPad exists yet**: the app had not been installed on a device when this was written.11The device figures that matter most (flash write speed, hashing speed, Wi-Fi throughput, heat) are the ones still missing;12the app measures them itself (Settings → Diagnostics → Storage benchmark) and sends the result to the coordinator, where13`mlstore node <name>` shows it under `bench`.1415## 1. End-to-end transfers through the gateway1617Client: the app in the iOS simulator on a MacBook, on a university network (not the cluster's LAN). Path: laptop →18Internet → BHS64 (Caddy, Beauharnois) → WireGuard → m4mn on the home connection, and back. Fragments of 8 MiB, 3 parallel19transfers, background `URLSession`. A simulator is a Mac process: these numbers describe the **network path and the20coordinator**, not an iPhone.2122| Run | Fragments | Volume | Wall time | Aggregate |23|---|---|---|---|---|24| First object, cold connections | 8 | 57.2 MiB | 26 s | 2.2 MiB/s |25| 300 MB object (coordinator restarted during the run) | 36 | 286.1 MiB | 36 s | 7.9 MiB/s |26| Refill after a drain (both objects) | 44 | 343.3 MiB | 50 s | 6.8 MiB/s |27| Second node (iPad simulator), both objects | 44 | 343.3 MiB | 45 s | 7.7 MiB/s |2829Per transfer, coordinator → device (43 fragments of 8 MiB): minimum 0.5, median 4.7, maximum 11.4 MiB/s.30Device → coordinator (3 fragments of 8 MiB returned): 1.4, 1.9 and 2.8 MiB/s.3132All 136 transfers recorded that day completed; every stored fragment passed its possession proof (143 checks at the time33of the last run). Downloads from the cluster to a device leave the home connection by its **uplink**, which is the34bottleneck of this path; on the local network path the uplink is not involved — that path was not measured (the test35machine was not on the cluster's LAN).3637## 2. Coordinator: fragment size3839256 MiB of random data, isolated instance on m4mn, one size per run. Read = decrypt, verify every fragment and the whole40object, including the start of the CLI process.4142| Fragment size | Fragments | Read back (verified) |43|---|---|---|44| 4 MiB | 64 | 0.44 s |45| 8 MiB | 32 | 0.44 s |46| 16 MiB | 16 | 0.50 s |47| 32 MiB | 8 | 0.55 s |48| 64 MiB | 4 | 0.55 s |4950Production ingest observed with 8 MiB fragments: 286.1 MiB encrypted, hashed and written with fsync in 0.7 s.51(The ingest timings of the per-size runs were not captured and are not reported.)5253**Reading**: on the coordinator the fragment size makes no practical difference (hundreds of MiB/s either way). The choice54is therefore driven by the device and the network: a smaller fragment loses less when a transfer is interrupted, costs55less to re-verify, and lets a quota fill more finely; a larger one means fewer requests. **8 MiB is the production56setting**, chosen on these grounds and not yet confirmed by device measurements. It is a coordinator setting57(`MSC_FRAGMENT_MIB`, 4–64); changing it affects only objects ingested afterwards.5859## 3. To measure on real devices6061Run on each device type and record in this file: the in-app storage benchmark (4 / 16 / 64 MiB: write + fsync, SHA-256,62read; thermal state before and after); sustained transfer of 10, 50 and 100 GB with throughput, battery and thermal state63over time; local network path against gateway path; background completion rate over a night on power.64
Files main
Menu

Theme