Skip to content

dracut: fix some portability issues in non-systemd environments#561

Open
oxiez wants to merge 2 commits into
latchset:masterfrom
oxiez:master
Open

dracut: fix some portability issues in non-systemd environments#561
oxiez wants to merge 2 commits into
latchset:masterfrom
oxiez:master

Conversation

@oxiez

@oxiez oxiez commented May 31, 2026

Copy link
Copy Markdown

Fixes some issues I ran into when trying to use Clevis in Void Linux:

  • Missing chmod install in my init environment but is used by unlocker scripts.
  • systemd-reply-password path was required during build time. It falls back to empty string since it's not used with the dracut hooks path.

Thanks.

oxiez added 2 commits May 31, 2026 19:00
Fixes dracut module issue in non-systemd environments where
systemd-reply-password.path() is called when it doesn't exist,
causing an error. The path isn't used for the non-systemd flow.
Fixes issue in non-systemd environments that may not
have chmod included in the init environment already.
@louiszn

louiszn commented Jun 29, 2026

Copy link
Copy Markdown

I independently tested this PR while updating the Void Linux clevis package from 20 to 23.

Test environment:

Void Linux x86_64
runit / non-systemd
dracut 109
clevis 23
TPM2-bound LUKS root

Before applying these patches, Clevis 23 failed to configure on this non-systemd setup because systemd-reply-password was not available:

Run-time dependency systemd found: NO
Program ... systemd-reply-password found: NO
src/luks/systemd/meson.build:55: WARNING: Will not install systemd support due to missing dependencies!
Run-time dependency dracut found: YES 109
src/luks/dracut/clevis/meson.build:8: ERROR: Unable to get the path of a not-found external program

I also reproduced the missing chmod issue during early boot after TPM2 auto-unlock:

/bin/clevis-password-unlocker-prepare: line 25: chmod: command not found
/bin/clevis-password-unlocker: line 183: chmod: command not found

After applying this PR's patches, Clevis 23 configures and builds successfully on Void Linux, the dracut module is generated correctly without systemd-reply-password, and TPM2-bound LUKS auto-unlock continues to work. chmod is now included in the initramfs and the early-boot warning disappears.

So this PR fixes the issue for my Void Linux non-systemd/dracut test case as well.

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