You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Tor rewrites its state file every few seconds because AvoidDiskWrites is not set #4445
build/tor/torrc.template has no AvoidDiskWrites line, so Tor writes its state file to disk very often.
What it impacts
Anyone running the stack on flash or small SSD storage. On a DIY test server (12 threads, remote-node mode, no rigs connected) the Tor container wrote 1.2 to 1.5 GB a day.
Constant wear for no benefit.
Unknown: how much of the volume is the state file versus other Tor files; the option's effect on this stack was not measured.
How I found it
Measured on that test server: the 14.5 KB state file had 7 different write times in 20 seconds. grep AvoidDiskWrites across build/ and docker-compose.yml finds nothing on current develop.
Code references are from develop at 32d9834a. Checked for an existing issue: none found.
How important is it
Performance: a one-line change against steady disk wear on the exact hardware the project targets.
Acceptance criteria
build/tor/torrc.template contains AvoidDiskWrites 1, and a stack test asserts it in the rendered config.
Repeating the 20 second state-file check on the same kind of server shows fewer distinct write times.
Tor still bootstraps and keeps its onion keys across a restart.
Possible solutions
Smallest: add AvoidDiskWrites 1 to the template.
Alternative: also put Tor's cache files on a memory-backed mount, keeping the keys on disk.
Blocked on #4502. Blocked on pithead#4502. tier4-e2e jobs 1099 and 1110 (phases lifecycle,rotate-onion, head 4bb57b8) failed the same 5 rows twice. The first failure is the backup restore round-trip. Its restore.log (artifact results/lifecycle-restore/restore.log of job 1110) says "This backup's configuration was written by pithead 2.0.4; this machine runs 2.0.3". That is the develop-v2.0.5 VERSION mismatch that #4502 covers. The other four failures follow from it: the dashboard had no rows, the encrypted restore did not start the stack, the onion fixture was refused, and the original config could not be restored. The 238 passing rows include the Tor rows, and none of the failures concern Tor config or startup. Finished: the one-line AvoidDiskWrites 1 template change, its test assertion, tiers 1-3 green on this head, and a PR comment explaining the block. Still needed: once #4502 closes, bring the base in, resubmit tier4-e2e (lifecycle,rotate-onion), paste the evidence block, and correct the PR body's unverified tor --verify-config claim.
The runner resumes this issue when that one closes.
Activity
Ask Tor to write its state to disk less often (#4445)
test: fix timing-sensitive window assertions in support-bundle tests (#…
file-budget: raise test-control-support-bundle ceiling 440→442 (#4445)
test: fix timing-sensitive window assertions in support-bundle tests (#…
pithead-developer commentedon Nov 27, 2026
Blocked on #4502. Blocked on pithead#4502. tier4-e2e jobs 1099 and 1110 (phases lifecycle,rotate-onion, head 4bb57b8) failed the same 5 rows twice. The first failure is the backup restore round-trip. Its restore.log (artifact results/lifecycle-restore/restore.log of job 1110) says "This backup's configuration was written by pithead 2.0.4; this machine runs 2.0.3". That is the develop-v2.0.5 VERSION mismatch that #4502 covers. The other four failures follow from it: the dashboard had no rows, the encrypted restore did not start the stack, the onion fixture was refused, and the original config could not be restored. The 238 passing rows include the Tor rows, and none of the failures concern Tor config or startup. Finished: the one-line
AvoidDiskWrites 1template change, its test assertion, tiers 1-3 green on this head, and a PR comment explaining the block. Still needed: once #4502 closes, bring the base in, resubmit tier4-e2e (lifecycle,rotate-onion), paste the evidence block, and correct the PR body's unverifiedtor --verify-configclaim.The runner resumes this issue when that one closes.