Skip to content

docs(trinity): the photo disk passes no SMART; revert the SMART job's lock dir - #1598

Merged
Gerrrt merged 3 commits into
mainfrom
docs/trinity-photo-disk-smart
Nov 21, 2026
Merged

Gerrrt merged 3 commits into
mainfrom
docs/trinity-photo-disk-smart

Conversation

@Gerrrt

@Gerrrt Gerrrt commented Nov 21, 2026 •

Copy link
Copy Markdown
Owner

What changed

Two fixes left over from #1597:

  1. The photo disk is recorded as unreadable by SMART. Its Seagate enclosure (0bc2:ab18, on the uas driver) fails "Read Device Identity" under -d sat, -d sat,12 and -T permissive. hardware.md, the build runbook's step 12, schedule-maintenance.md, systemd/README.md and the unit's header now say the job reads the NVMe, and that the photo disk is counted but has no health series.
  2. The lock goes back to /run/lock. feat(trinity): collect SMART from trinity's own disks #1597 merged with a commit that set HOMELAB_LOCK_DIR to the textfile directory, which left a lock file beside the metrics. The override is removed, and /run/lock is named in ReadWritePaths so the lock opens under ProtectSystem=strict either way. The directory is world-writable, so this grants nothing new.

Why

On 2026-11-21 the first run on trinity read nvme0n1 and the HOUSEHOLD drive, and returned nothing for sda, the photo disk. The three smartctl modes above were tried by hand and all failed. Dropping the disk off uas with a kernel quirk was judged not worth a reboot and slower transfers. The disk's protection stays as it was: the nightly copy to oracle and verify-backups-sensitive.

On the lock: the monitoring host's homelab-smart-state.service uses /run/lock under the same ProtectSystem=strict and exits 0 daily (2026-11-19, 2026-11-20). Review on this PR pointed out that systemd documents /run/lock as read-only under strict. Naming it in ReadWritePaths makes trinity's unit correct under either reading.

Blast radius

trinity's SMART unit only. After merge it locks in /run/lock again, with that path named writable. Everything else here is docs.

  • No change to network segmentation or firewall rules
  • No new port published to a VLAN that could not already reach the service
  • No credential added outside secrets/*.sops.yaml

Verification

  • python3 scripts/check_docs.py: docs OK.

  • ./scripts/install-timers.sh --check --profile sensitive: 0 FAIL.

  • ./scripts/lint.sh: passed. 4 tools were unavailable and skipped (yamllint, ruff ×2, ansible-lint), so CI covers them.

  • I did not run full make validate; CI does.

  • After merge, make install-timers PROFILE=sensitive on trinity re-renders the unit without the Environment= line and with /run/lock in ReadWritePaths. The stale homelab-smart-state-sensitive.lock in the textfile directory can then be deleted.

  • make validate passes

  • Deployed to the lab and confirmed working

  • Docs updated (docs/, service README, or docs/roadmap.md)

🤖 Generated with Claude Code

… lock dir

The photo disk's Seagate enclosure (0bc2:ab18, uas) answers no ATA
pass-through, so the docs that promised a health row for it now say it has
none. The lock-directory commit merged with #1597 rested on a false claim
that /run/lock is read-only under ProtectSystem=strict; the monitoring host's
identically sandboxed unit locks there daily, so this unit goes back to it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Copilot AI balanced review requested due to automatic review settings November 21, 2026 04:59
@Gerrrt
Gerrrt enabled auto-merge (squash) November 21, 2026 05:03

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The service’s strict filesystem protection leaves the default /run/lock read-only, causing lock creation to fail before SMART collection unless a writable HOMELAB_LOCK_DIR is configured.

1 open issue
What changed in this PR

This PR updates trinity’s SMART monitoring documentation after #1597 to reflect the photo enclosure’s lack of SMART pass-through. It also reverts the sensitive service’s lock-directory override.

Changes:

  • Clarifies that the photo disk is counted but provides no SMART health series.
  • Updates first-run checks to expect NVMe health data and HOUSEHOLD drive data while connected.
  • Removes the lock override and records both changes in the changelog.
File Description
systemd/​sensitive/​homelab-smart-state-sensitive.service Removes the lock override and documents the photo disk’s SMART limitation.
systemd/​README.md Corrects the sensitive SMART job’s coverage description.
docs/​runbooks/​schedule-maintenance.md Explains the photo enclosure’s SMART limitation.
docs/​runbooks/​build-the-sensitive-tier-host.md Updates expected first-run health metrics.
docs/​hardware.md Records failed SMART pass-through attempts and monitoring limitations.
docs/​changelog.md Adds a dated record of the coverage correction and lock revert.

Review effort: Balanced

Gerrrt and others added 2 commits November 21, 2026 05:23
run-scheduled.sh opens its lock in /run/lock, and ProtectSystem=strict is
documented to leave it read-only. The directory is world-writable already, so
naming it costs nothing and removes the question.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Gerrrt
Gerrrt merged commit b283927 into main Nov 21, 2026
10 of 11 checks passed
@Gerrrt
Gerrrt deleted the docs/trinity-photo-disk-smart branch November 21, 2026 05:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants