OpenRiot v7.9.19 — The One That Finally Frees the Drive
“You can encrypt it. You can mount it. You can unmount it. But can you FREE it?” — The OpenRiot Crew, discovering that bioctl -d takes the volume name, not the chunk name, after 17 failed attempts
Release Overview
v7.9.19 makes the Disk Manager actually usable for encrypted USB drives. Mount, umount, format, and encrypt now work end-to- end without hanging, crashing, or leaving stale softraid volumes that block subsequent operations.
The big fix: detachSoftraidChunk() — a dmesg-powered
fallback that scans for virtual devices at the softraid bus and
tries bioctl -d on each non-root one. Previous code tried
bioctl -d sd2a and bioctl -d sd2, but bioctl -d needs the
volume name (sd3), not the chunk name. So the volume never got
detached, and re-encrypting failed with “chunk already in use”.
The Passthrough Odyssey
The passphrase handling went through four iterations:
| Iteration | Method | Result |
|---|---|---|
| 1 | cmd.Stdin = passphrase + "\n" |
Hung on /dev/tty |
| 2 | -P passphrase flag |
“bioctl: invalid option – P” |
| 3 | -p /tmp/file (user-owned) |
“Must be owned by root” |
| 4 | `doas sh -c ‘printf… > /tmp/file | Works — root-owned with |
| && chmod 600’` | chmod 600 |
The correct approach: write the passphrase TWICE (entry +
confirmation for new volumes, once for unlock) to a temp file
via doas sh -c 'printf...' so the file is root-owned, then
use bioctl -c C -p passfile.
The Streaming Failure
The encrypt/mount/umount commands went through three architectural iterations:
| Iteration | Pattern | Failure mode |
|---|---|---|
| 1 | Synchronous (original) | Blocked TUI, no progress |
| 2 | Goroutine + channel | Bubble Tea never re-read |
| 3 | Goroutine + stored chan | Value receiver lost ref |
| 4 | Synchronous + log builder | Reliable, simple, correct |
The final approach: a single synchronous func() tea.Msg that
runs ALL steps sequentially, builds a log string, and returns a
single resultMsg. If any step fails, the error includes the
log up to that point. On success, the result screen shows the
full operation log.
The mount/umount Rework
Mount now handles three cases correctly:
| Device type | Behavior |
|---|---|
| Physical chunk with RAID | bioctl -c C -p to unlock, |
| (sd2) | then mount virtual device |
| Virtual device, attached | Mount /dev/sdXa directly |
| (sd3) | |
| Regular partition | Mount /dev/sdXa directly |
Umount detaches the softraid volume after unmounting. Format and Encrypt detach any existing volume before starting.
Other Fixes
findRaidDevicefor virtual devices (sd3): falls through to direct mount when no softraid mapping existsguardDriveblocks internal chunks (sd0 NVMe) but allows removable chunks (sd2 USB) for format/mount/encrypt- Bus type ([NVMe], [USB], [CRYPTO]) and model name shown in drive list so users know what they’re touching
- i3 floating rule added for
openriot_diskwindow class - All
doascalls use-n(non-interactive) to prevent password prompts from hanging the TUI
🧾 Files Changed
| File | Change |
|---|---|
source/disk/update.go |
Rewrote mountCmd, encryptCmd, |
| umountCmd, formatCmd as sync log- | |
| builders. Added detachSoftraidChunk | |
| with dmesg fallback. Passphrase via | |
| temp file + chmod 600. Mount fallback | |
| for virtual devices. | |
source/disk/backend.go |
guardDrive allows removable chunks. |
| BusType, ModelName fields on Drive. | |
source/disk/view.go |
Bus type + model name display. |
| [CHUNK] → [SOFTRAID] for humans. | |
source/disk/model.go |
stateConfirmPassword for encrypt |
| passphrase confirmation. | |
source/disk/filter.go |
Show all drives, selection-time |
| guards instead of exclusion. | |
source/disk/export_test.go |
NEW — test bridges |
source/disk/diskintegration_test.go |
NEW — system test |
config/i3/config |
openriot_disk floating rule |
config/rofi/apps.txt |
openriot_disk window class |
docs/v7.9.18-Release-Notes.md |
NEW — initial Disk Man. |
🗣️ Final Words
“bioctl -d needs the volume name. Not the chunk name. Not the partition name. Not your hopes and dreams. The volume name.” — The OpenRiot Crew, after six hours of “chunk already in use”