Skip to content

fix(services): give gssproxy its state directories and enable nfs-client.target - #1287

Closed
hanthor wants to merge 1 commit into
feat/dakota-upstream-preset-unitsfrom
fix/nfs-client-gssproxy
Closed

hanthor wants to merge 1 commit into
feat/dakota-upstream-preset-unitsfrom
fix/nfs-client-gssproxy

Conversation

@hanthor

@hanthor hanthor commented Nov 16, 2026

Copy link
Copy Markdown
Member

What

  • New system_files/shared/usr/lib/tmpfiles.d/utah-gssproxy.conf creates gssproxy's directories with the owner and modes from its RPM's %files:
    d /var/lib/gssproxy 0755 root root -
    d /var/lib/gssproxy/clients 0700 root root -
    d /var/lib/gssproxy/rcache 0700 root root -
    
  • nfs-client.target is enabled in 85-utah-desktop.preset, configure-services.sh and [services].enabled. This replaces the disable lines and their "cause not diagnosed" comments. Note: the contract's disabled list never named the target, so there was nothing to remove there.
  • Docs: dakota-services.md, factory-consumption.md, and the packages/utah.toml comment. ServiceMaskParityTests gets a test that checks the three-way wiring and the tmpfiles lines.

Root cause

  • What pulls gssproxy in: nfs-client.target → auth-rpcgss-module.service → Wants=gssproxy.service rpc-gssd.service. That Wants= applies even though auth-rpcgss-module itself is skipped by ConditionPathExists=/etc/krb5.keytab, so gssproxy starts on every boot.
  • What the unit needs: gssproxy's unit has StateDirectory=gssproxy/clients gssproxy/rcache with StateDirectoryMode=0700. On Fedora the RPM ships those directories, so systemd never creates them.
  • Why Utah lacks them: clean-stage.sh strips all of /var except caches. The only gssproxy tmpfiles line is the RPM's L /var/lib/gssproxy/default.sock. So at boot systemd itself has to create clients/ and rcache/ inside /var/lib/gssproxy.
  • Why systemd can't: /var/lib/gssproxy is labelled gssproxy_var_lib_t. In Hummingbird's selinux-policy-targeted-45.24 (policy.35), sesearch -A -s init_t -t gssproxy_var_lib_t -c dir gives init_t create, setattr and write (the init_create_dirs boolean), but no add_name. Creating an entry in that directory is denied, which matches the status=238/STATE_DIRECTORY, Permission denied the review VM saw.
  • Why tmpfiles can: systemd_tmpfiles_t has add_name create … relabelto on non_auth_file_type dirs, and tmpfiles runs before services. Once the directories exist with the right mode and owner, StateDirectory= has nothing to create.

Dakota builds nfs-utils --disable-gss (elements/bluefin/nfs-utils.bst), so it runs no gssproxy at all. Utah keeps the factory's GSS-capable build, as Fedora does, and fixes the state directory instead.

Stacked on #1285.

Closes #1269

Verification

  • sesearch against Hummingbird's own policy RPM, as described above. Fedora 44's policy gives the same result.
  • Read the nfs-client.target, auth-rpcgss-module, rpc-gssd, rpc-statd-notify and gssproxy units in fedora:44.
  • just check passes (1333 tests).
  • Not verified at runtime: this needs a booted image to confirm gssproxy.service is active and systemctl --failed is empty.

…ent.target

nfs-client.target pulls in gssproxy.service through
auth-rpcgss-module.service, whose Wants= applies even without a keytab.
gssproxy's StateDirectory=gssproxy/clients gssproxy/rcache failed with
238/STATE_DIRECTORY: clean-stage strips /var, so systemd has to create the
directories, and the SELinux policy gives init_t no add_name on
gssproxy_var_lib_t. Ship tmpfiles.d/utah-gssproxy.conf with the RPM's three
directories and modes; systemd-tmpfiles may create and label them.

With gssproxy fixed, enable nfs-client.target as Dakota's
elements/bluefin/nfs-utils.bst presets it, in the preset,
configure-services.sh and the desktop contract.

Closes #1269

Assisted-by: Claude Opus via GitHub Copilot
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@github-actions github-actions Bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Nov 16, 2026
@github-actions

github-actions Bot commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: danathar, hanthor

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@hivecommons-hive hivecommons-hive Bot linked an issue Nov 16, 2026 that may be closed by this pull request
@hivecommons-hive hivecommons-hive Bot added author/clanker A contributor's own hive authored this PR under their login no-dco A commit is missing Signed-off-by — run `git rebase --signoff` role/trusted Author is trusted for unattended merge (trusted-author role or registry/claim tier in require_tiers) stage/072-returned-to-contributor Contributor PR: CI red, changes requested or conflicting; diagnosis posted, author must act labels Nov 16, 2026
@hivecommons-hive

hivecommons-hive Bot commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

@hanthor this PR is back in your court (stage/072-returned-to-contributor). The hive will not merge it until the head changes.

Failing checks:

  • contract

Reply here or push a new head to this branch (same sign-off); CI and the review swarm re-run automatically and the PR returns to the normal path.

Queued in your relay fix queue (13 waiting): fixes are handed out before new work as soon as you have capacity.

@hivecommons-hive hivecommons-hive Bot added stage/050-review-pending Review swarm requested; awaiting a verdict for the current head stage/072-returned-to-contributor Contributor PR: CI red, changes requested or conflicting; diagnosis posted, author must act and removed stage/072-returned-to-contributor Contributor PR: CI red, changes requested or conflicting; diagnosis posted, author must act stage/050-review-pending Review swarm requested; awaiting a verdict for the current head labels Nov 16, 2026

@Danathar Danathar left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Stand-in review (the hive's reviewers are out of quota). Approving. The cause and the fix check out independently. Cause: Fedora's gssproxy 0.9.2 (the same as the factory recipe) has StateDirectory=gssproxy/clients gssproxy/rcache with StateDirectoryMode=0700. In Hummingbird's selinux-policy-targeted 45.24, sesearch shows init_t has create/setattr/write on gssproxy_var_lib_t dirs but no add_name, so systemd can create /var/lib/gssproxy but not clients/ and rcache/ inside it. That matches the review VM's 238/STATE_DIRECTORY, Permission denied. systemd_tmpfiles_t has add_name and create, so the new tmpfiles lines, which match the RPM's directories and modes, are the right fix. Why it matters: nfs-client.target → auth-rpcgss-module.service → Wants=gssproxy.service, and a failed ConditionPathExists doesn't cancel the Wants, so gssproxy starts every boot. Risk to watch: gssproxy.service isn't in the smoke "No failed systemd units" allowlist, so if it still fails for a reason not visible here, the first booted :testing build goes red. Check systemctl status gssproxy there.

@hivecommons-hive hivecommons-hive Bot added stage/050-review-pending Review swarm requested; awaiting a verdict for the current head stage/072-returned-to-contributor Contributor PR: CI red, changes requested or conflicting; diagnosis posted, author must act and removed stage/072-returned-to-contributor Contributor PR: CI red, changes requested or conflicting; diagnosis posted, author must act stage/050-review-pending Review swarm requested; awaiting a verdict for the current head labels Nov 16, 2026
@hanthor

hanthor commented Nov 16, 2026

Copy link
Copy Markdown
Member Author

Folded into the part-2 landing PR (fold/dakota-sq) with this change unchanged apart from rebase and conflict resolution. Closing here; review continues there.

@hanthor hanthor closed this Nov 16, 2026
@hivecommons-hive hivecommons-hive Bot removed role/trusted Author is trusted for unattended merge (trusted-author role or registry/claim tier in require_tiers) stage/072-returned-to-contributor Contributor PR: CI red, changes requested or conflicting; diagnosis posted, author must act labels Nov 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. author/clanker A contributor's own hive authored this PR under their login no-dco A commit is missing Signed-off-by — run `git rebase --signoff`

Projects

None yet

Development

Successfully merging this pull request may close these issues.

parity(dakota): nfs-client.target

2 participants