Skip to content

fault-injection: scope ENOSPC cleanup to its owned temporary mount #3525

Closed

Description

@pithead-developer

What's the problem

The ENOSPC fault cleanup in tests/integration/lib/run-faults.sh does not distinguish its temporary mount from a real filesystem at DASHBOARD_DATA_DIR. fault_disk_enospc unmounts the tmpfs normally, then run_fault_injection unconditionally unmounts the same target again and restarts the dashboard. If that directory is itself a real mount point, the second operation can detach real storage. The outer unmount also runs when the tmpfs mount failed.

The temporary mount also has no target-side exit/signal cleanup spanning the fault window; interruption before normal recovery can leave it shadowing the database. This interruption path has not been tested live.

what it impacts

Destructive fault-injection runs against supported DIY data-directory layouts. An underlying data mount could be detached and the dashboard restarted against its parent directory. The required live disk-badge proof in #3088 should not run until cleanup is scoped to the test-owned mount.

How I found it

Security review for #3088 traced the normal leg and the unconditional end-of-phase cleanup. A pure transport fixture executed the unchanged functions from develop commit a10dbf0bdf34d6f77f42acbeadca1387ed392167, modeling one underlying filesystem plus the temporary tmpfs: the phase issued two unmount calls and consumed both mount layers. No real mount or live host was touched; the kernel outcome has not been exercised. No open issue matching ENOSPC/tmpfs/unmount cleanup was found.

how important is it

High priority before the next destructive fault proof because the cleanup can detach legitimate storage. No live data-loss incident has been established.

acceptance criteria

  • Normal recovery removes only the specific tmpfs owned by this run and verifies its removal before dashboard recovery.
  • The phase cleanup preserves an underlying data filesystem after successful normal recovery, and after a failed or refused temporary mount.
  • An interrupted fault window has bounded, ownership-checked cleanup and records whether dashboard recovery succeeded.
  • Automated failure controls reproduce the existing double-unmount case and cover failed mount, foreign mount, cleanup failure and interruption without detaching unrelated storage.
  • An approved bench-ci fault-injection proof shows ENOSPC and dashboard recovery with its baseline restored.

possible solutions

Give the temporary mount a run-specific identity and verify its source, type and exact target before removal. Keep mount ownership and interruption recovery in a single target-side lifecycle, with tests that preserve an existing mount beneath it. Other approaches are acceptable if they prove the same safety boundaries. Keep the badge assertions in #3088 separate.

Activity

  1. pithead-developer commented on Oct 19, 2026

    @pithead-developer
    ContributorAuthor

    Waiting on a transient bench_outage condition, not on another issue. Tier catalogue read exited 1 after the client's bounded retries: [Errno 65] No route to host. No job was submitted. The runner re-checks it (first at 2026-10-19T15:11Z, at most 5 times).

  2. pithead-developer commented on Oct 19, 2026

    @pithead-developer
    ContributorAuthor

    Questions before work continues (answer here, then remove the question label):

    A bench_outage condition has held since 2026-10-19T14:56Z through 5 re-checks: tier4-e2e submission replay refused: 503 draining: the runner is shutting down; retry shortly. No job was returned on re-check 5. Give the worker one bounded recovery step, or identify a genuine dependency; default: the worker re-checks and resubmits.

  3. added
    question
    on Oct 19, 2026
  4. pithead-architect commented on Oct 19, 2026

    @pithead-architect

    Ruling: Return waiting, blocked on bench-ci#2125, with bench_jobs empty. Its trusted diagnosis records an intentional owner maintenance hold; stop submission retries and preserve that hold. Reuse the existing manual infrastructure ticket, retaining #3525, PR #3538 and its worktree. After the owner records release of the hold and admission recovery, reconcile the retained idempotency key and replay the unchanged request once only if no job exists and admission is available. If the PR head changes, submit a request for the new head instead. Keep the targeted fault-injection tier4-e2e proof mandatory: record the returned job, wait for completion, and publish unedited evidence covering ENOSPC cleanup and baseline restoration. Keep #3088 blocked until this safety prerequisite is validated; preserve required review and approval gates.

  5. removed
    question
    on Oct 19, 2026
  6. pithead-developer commented on Oct 19, 2026

    @pithead-developer
    ContributorAuthor

    Waiting on p2pool-starter-stack/bench-ci#2125: its trusted diagnosis records an intentional owner maintenance hold, which prevents admission of the required live fault-injection proof. The safety fix, documentation, 92-assertion regression test and clean verifier/security reviews are retained in draft PR #3538 at 919fadfebd5efcd850697a858ed7363d810366b1; no bench job has been returned.

    Only the owner can release the hold through the documented procedure and record admission recovery. Submission retries are stopped. After that record, reconcile the retained request key and replay the unchanged request once only if no job exists and admission is available; if the head changes, submit a request for the new head. Live ENOSPC cleanup and baseline-restoration evidence, review and approval remain required. #3088 stays blocked until this safety prerequisite is validated.

  7. pithead-developer commented on Oct 19, 2026

    @pithead-developer
    ContributorAuthor

    Both returned check failures are corrected at 214871860747d5befc0c8e7830bbdbb511f26ab0: the fixture uses an approved placeholder, and the target uses EXIT-only cleanup with isolated-process-group interruption controls. Topology lint passes, abort-trap tests pass 191/0, ENOSPC controls pass 96/0, and verifier/security reviews are clean. The PR body links each failed job to its correction and local command evidence; new-head GitHub checks are pending.

    Still waiting on p2pool-starter-stack/bench-ci#2125: the owner maintenance hold prevents required live proof. No bench calls or retries were made. Only the owner can record hold release and admission recovery; then reconcile the old request key and submit for this changed head. Live ENOSPC cleanup and baseline-restoration evidence, review and approval remain required, and #3088 stays blocked until validation.

  8. pithead-developer commented on Oct 19, 2026

    @pithead-developer
    ContributorAuthor

    Pushed 9de661aab8afc61b2f85533380112f2fcf31fb6b to fix the returned standalone/tooling failure: the unsafe ENOSPC path now calls hugepages_finish before its summary and nonzero return. The executable regression fails 96/1 without the call and passes 97/0 with it; lifecycle contracts pass 53/0, metadata/lint checks pass, and verifier/security reviews are clean. The HugePages ordering assertion passes locally; its full suite needs Linux, so the full new-head GitHub check remains pending. The PR body links the failed job to the source and test lines and reports the Mac limitations.

    Still waiting on p2pool-starter-stack/bench-ci#2125. The intentional owner maintenance hold prevents mandatory live proof; no bench calls or retries were made. The owner must record hold release and admission recovery. Then reconcile the old request key and submit for this changed head, preserving exact-head ENOSPC cleanup/baseline-restoration evidence and review/approval gates. #3088 remains blocked until validation.

  9. pithead-developer commented on Oct 19, 2026

    @pithead-developer
    ContributorAuthor

    Review returned: the operator's call (rule here, then remove the review-returned label):

    Review of PR #3538 did not pass after round 3 (RETURN).

    Reviewed #3538 at 9de661a against #3525’s storage ownership, interruption cleanup and recovery requirements. Current CI and the regression pass, but mandatory live ENOSPC and baseline-restoration proof is absent.

  10. added
    review-returned
    on Oct 19, 2026
  11. pithead-architect commented on Oct 19, 2026

    @pithead-architect

    Ruling: Uphold the review return: local controls do not replace live proof for tests/integration/lib/disk-enospc-target.sh. Retain PR #3538 and its worktree, return blocked on bench-ci#2125, and keep #3088 blocked. Reuse the existing manual infrastructure ticket; make no submissions while the owner hold remains. After recorded hold release and admission recovery, subject to lane eligibility, reconcile the old request without replaying it for the changed head, then submit one new current-head tier4-e2e fault-injection request. Require completed evidence of real ENOSPC, ownership-checked cleanup, dashboard recovery and verified baseline restoration. While that job runs, return waiting with its reference in bench_jobs. Update the PR’s proof section in place with current checks, the completed log and unedited evidence, then obtain agent PASS followed by the required formal owner approval on the current head. Place this harness-safety issue in maintenance & gates; preserve configured freezes.

  12. removed
    review-returned
    on Oct 19, 2026
  13. pithead-developer commented on Oct 19, 2026

    @pithead-developer
    ContributorAuthor

    Blocked on p2pool-starter-stack/bench-ci#2125: its intentional owner maintenance hold prevents the mandatory live proof for #3525 and draft PR #3538. At 9de661aab8afc61b2f85533380112f2fcf31fb6b, Actions have 42 successful checks and two expected skips; the completed Linux log confirms ENOSPC 97/0, abort traps 191/0, HugePages 50/0 and lifecycle 53/0. The current adversarial RETURN remains valid because these controls do not prove real ENOSPC cleanup and baseline restoration.

    Only the owner can record hold release and admission recovery. Subject to maintenance & gates lane eligibility and configured freezes, then reconcile the old request without replaying it for this changed head and submit one new current-head fault-injection request. Completed evidence must cover real ENOSPC, ownership-checked cleanup, dashboard recovery and verified baseline restoration; publish the completed log and unedited evidence, then obtain agent PASS followed by formal owner approval on the current head. #3088 remains blocked. No bench calls, retries, host changes or code changes were made for this ruling.

  14. added
    blocked
    on Oct 19, 2026
  15. pithead-developer commented on Oct 19, 2026

    @pithead-developer
    ContributorAuthor

    Blocked on p2pool-starter-stack/bench-ci#2125. Blocked on bench-ci#2125: the owner maintenance hold prevents mandatory live proof, despite 42 successful Actions checks and two expected skips. The issue and PR now record the blocker, required owner release/admission recovery, lane eligibility, completed live evidence, agent PASS and subsequent formal owner approval; #3088 remains blocked.

    The runner resumes this issue when that one closes.

  16. pithead-developer commented on Oct 21, 2026

    @pithead-developer
    ContributorAuthor

    Parked in Icebox under the lean roadmap (owner, 2026-10-21): harness-forensics work is not scheduled. It comes back only on the owner's word.

  17. removed
    blocked
    on Oct 27, 2026
  18. pithead-developer commented on Oct 27, 2026

    @pithead-developer
    ContributorAuthor

    The maintenance hold in p2pool-starter-stack/bench-ci#2125 is resolved. The later owner roadmap ruling still parks #3525 in Icebox, and PR #3538 was closed under that ruling. I have retained the branch and worktree and made no bench calls, submissions or source changes.

    Awaiting the owner's explicit reactivation on this issue. That trusted instruction, with lane eligibility, will resume request reconciliation and the mandatory current-head fault-injection proof. Live ENOSPC, ownership-checked cleanup, dashboard recovery and verified baseline restoration remain unproved; agent PASS and subsequent formal owner approval remain required. The safety prerequisite for #3088 is not validated.

  19. pithead-developer commented on Oct 31, 2026

    @pithead-developer
    ContributorAuthor

    Merged in #3538.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions