Skip to content

Use dracut to generate initramfs - #2833

Merged
enoch85 merged 1 commit into
nextcloud:mainfrom
pq2:patch-5
Aug 3, 2026
Merged

Use dracut to generate initramfs#2833
enoch85 merged 1 commit into
nextcloud:mainfrom
pq2:patch-5

Conversation

@pq2

@pq2 pq2 commented Aug 3, 2026

Copy link
Copy Markdown
Contributor

tpm2-unlock.sh wasn't working for me using Ubuntu 26.04. After the reboot the initramfs could not be loaded and the device started a busybox shell.

After using dracut instead of update-initramfs as described here it worked.

🤖 AI (if applicable)

  • The content of this PR was partly or fully generated using AI

tpm2-unlock.sh wasn't working for me using Ubuntu 26.04. After the reboot the initramfs could not be loaded and the device started a busybox shell.

After using dracut instead of update-initramfs as described [here](https://ubuntu.com/server/docs/how-to/security/tpm-backed-luks-decryption-with-clevis/) it worked.

Signed-off-by: pq2 <github@nhelmschmidt.de>
@enoch85

enoch85 commented Aug 3, 2026

Copy link
Copy Markdown
Member

Thanks for the PR! 🚀

@enoch85
enoch85 merged commit 58af3bc into nextcloud:main Aug 3, 2026
4 checks passed
fi
print_text_in_color "$ICyan" "Updating initramfs..."
if ! update-initramfs -u -k 'all'
if ! dracut -f

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Hi, I am not sure if this will continue to work on Ubuntu 24.04. Maybe we should use dracut on 26.04 and update-initramfs on ubuntu 24.04. WDYT @pq2?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I'm not entirely sure about that either. While clevis-dracut is available in the repositories for 24.04 (Source), dracut doesn't seem to be the default tool for creating the initramfs in 24.04. It can't hurt to use both, depending on the version, as you suggested.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Yes lets do that. Would you be able to create a PR?

@enoch85 enoch85 Aug 6, 2026

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Note, we have variables for OS checks.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

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.

3 participants