Skip to content

fix(dracut-rescue): use entry token instead of machine-id for path construction#2444

Open
mxsb wants to merge 1 commit into
dracut-ng:mainfrom
mxsb:fix/rescue-install-uki-entry-token
Open

fix(dracut-rescue): use entry token instead of machine-id for path construction#2444
mxsb wants to merge 1 commit into
dracut-ng:mainfrom
mxsb:fix/rescue-install-uki-entry-token

Conversation

@mxsb
Copy link
Copy Markdown

@mxsb mxsb commented May 15, 2026

51-dracut-rescue.install hardcodes $MACHINE_ID for boot directory and loader entry paths. When kernel-install is configured with a non-machine-id entry token (e.g. via bootctl --entry-token=os-id), the paths diverge from the actual boot directory layout, breaking rescue image creation.

Use $KERNEL_INSTALL_ENTRY_TOKEN (exported by kernel-install since systemd 253) with a fallback to $MACHINE_ID for path construction. Rescue image filenames and BLS content fields keep using $MACHINE_ID as an identifier.

Fixes: #2443

Checklist

  • I have tested it locally
  • I have reviewed and updated any documentation if relevant
  • I am providing new code and test(s) for it

…nstruction

51-dracut-rescue.install hardcodes $MACHINE_ID for boot directory and
loader entry paths. When kernel-install is configured with a
non-machine-id entry token (e.g. via bootctl --entry-token=os-id),
the paths diverge from the actual boot directory layout, breaking
rescue image creation.

Use $KERNEL_INSTALL_ENTRY_TOKEN (exported by kernel-install since
systemd 253) with a fallback to $MACHINE_ID for path construction.
Rescue image filenames and BLS content fields keep using $MACHINE_ID
as an identifier.

Add a test variant to TEST-43 that runs kernel-install with a custom
entry token and verifies the rescue initrd is placed correctly.

Fixes: dracut-ng#2443
@mxsb mxsb requested a review from a team as a code owner May 15, 2026 10:06
@github-actions github-actions Bot added test Issues related to testing kernel-install labels May 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kernel-install test Issues related to testing

Projects

None yet

Development

Successfully merging this pull request may close these issues.

51-dracut-rescue.install builds broken paths with non-machine-id entry tokens

1 participant