View previous topic :: View next topic |
Author |
Message |
AprilGrimoire n00b
Joined: 05 Jun 2020 Posts: 57
|
Posted: Sat Aug 10, 2024 2:19 pm Post subject: Possibly outdated documentation: dracut, systemd-cryptsetup |
|
|
The Gentoo handbook https://wiki.gentoo.org/wiki/Handbook:AMD64/Installation/Kernel suggests using dracut with generating initramfs, and I followed https://wiki.gentoo.org/wiki/Dracut to configure the list of dracut modules to use. However, it listed systemd-cryptsetup, which depends on a package sys-fs/systemd which does not exist now. I'm using both systemd and cryptsetup, and I wonder do I need it?
Thanks! |
|
Back to top |
|
|
Hu Administrator
Joined: 06 Mar 2007 Posts: 22771
|
Posted: Sat Aug 10, 2024 3:17 pm Post subject: |
|
|
That appears to be a typographic error in the documentation. systemd is sys-apps/systemd, not sys-fs/systemd. I think systemd has always been in sys-apps, so this is likely just that someone copied an adjoining line and failed to fully edit it. |
|
Back to top |
|
|
AprilGrimoire n00b
Joined: 05 Jun 2020 Posts: 57
|
Posted: Sat Aug 10, 2024 3:44 pm Post subject: |
|
|
Hu wrote: | That appears to be a typographic error in the documentation. systemd is sys-apps/systemd, not sys-fs/systemd. I think systemd has always been in sys-apps, so this is likely just that someone copied an adjoining line and failed to fully edit it. |
Thanks for helping!
I've already had systemd installed, however this module is not showing up. |
|
Back to top |
|
|
Hu Administrator
Joined: 06 Mar 2007 Posts: 22771
|
Posted: Sat Aug 10, 2024 3:57 pm Post subject: |
|
|
What error are you seeing? Does your use of cryptsetup require that it be run in the initramfs, or are you only using it for drives unlocked after the init system starts? |
|
Back to top |
|
|
AprilGrimoire n00b
Joined: 05 Jun 2020 Posts: 57
|
Posted: Sat Aug 10, 2024 4:04 pm Post subject: |
|
|
Hu wrote: | What error are you seeing? Does your use of cryptsetup require that it be run in the initramfs, or are you only using it for drives unlocked after the init system starts? |
When running on linux kernel, I saw 'module not found' error when running dracut. |
|
Back to top |
|
|
Zucca Moderator
Joined: 14 Jun 2007 Posts: 3759 Location: Rasi, Finland
|
Posted: Sat Aug 10, 2024 4:28 pm Post subject: |
|
|
AprilGrimoire wrote: | When running on linux kernel, I saw 'module not found' error when running dracut. | Please provide more of the log. Or even better; use wgetpaste and paste the url to the whole output. _________________ ..: Zucca :..
My gentoo installs: | init=/sbin/openrc-init
-systemd -logind -elogind seatd |
Quote: | I am NaN! I am a man! |
|
|
Back to top |
|
|
AprilGrimoire n00b
Joined: 05 Jun 2020 Posts: 57
|
Posted: Sun Aug 11, 2024 8:15 pm Post subject: |
|
|
Zucca wrote: | AprilGrimoire wrote: | When running on linux kernel, I saw 'module not found' error when running dracut. | Please provide more of the log. Or even better; use wgetpaste and paste the url to the whole output. |
Sorry.
Code: |
(base) april@AprilGrimoire-Mechrevo /usr/src/linux-6.6.38-gentoo $ doas dracut --add systemd-cryptsetup /tmp/test.img 6.6.38-gentoo
dracut[I]: Executing: /usr/bin/dracut --add systemd-cryptsetup /tmp/test.img 6.6.38-gentoo
dracut[E]: Module 'systemd-cryptsetup' cannot be found.
|
Now I've managed to make it work (barely) by removing the systemd-cryptsetup module. crypt alone seems working, however the ask for passphrase prompt is usually flooded by many lines of log at boot-time. |
|
Back to top |
|
|
pjp Administrator
Joined: 16 Apr 2002 Posts: 20501
|
Posted: Sun Aug 11, 2024 10:42 pm Post subject: |
|
|
Do you have sys-fs/cryptsetup installed? From the output of installing dracut there is this: Code: | Install additional packages for optional runtime features:
sys-fs/cryptsetup[-static-libs] for Decrypt devices encrypted with cryptsetup/LUKS | (other listed packages excluded for brevity) _________________ Quis separabit? Quo animo? |
|
Back to top |
|
|
Hu Administrator
Joined: 06 Mar 2007 Posts: 22771
|
Posted: Sun Aug 11, 2024 11:09 pm Post subject: |
|
|
AprilGrimoire wrote: | however the ask for passphrase prompt is usually flooded by many lines of log at boot-time. | This is normal. The kernel usually does not complete all setup for all devices before the cryptsetup prompt is printed, so some kernel messages are displayed afterward. This has no effect on cryptsetup, and you can enter your password normally. |
|
Back to top |
|
|
AprilGrimoire n00b
Joined: 05 Jun 2020 Posts: 57
|
Posted: Mon Aug 12, 2024 4:59 am Post subject: |
|
|
pjp wrote: | Do you have sys-fs/cryptsetup installed? From the output of installing dracut there is this: Code: | Install additional packages for optional runtime features:
sys-fs/cryptsetup[-static-libs] for Decrypt devices encrypted with cryptsetup/LUKS | (other listed packages excluded for brevity) |
Thank you!
cryptsetup is installed, otherwise I wouldn't be able to boot.
Code: |
(base) april@AprilGrimoire-Mechrevo ~ $ eix cryptsetup
[I] sys-fs/cryptsetup
Available versions: 2.6.1(0/12)^t 2.7.2(0/12)^t ~2.7.3(0/12)^t {+argon2 fips gcrypt kernel nettle nls +openssl pwquality ssh static static-libs test +udev urandom}
Installed versions: 2.7.2(0/12)^t(05:23:25 AM 08/10/2024)(argon2 nls openssl udev -fips -gcrypt -kernel -nettle -pwquality -ssh -static -static-libs -test -urandom)
Homepage: https://gitlab.com/cryptsetup/cryptsetup
Description: Tool to setup encrypted devices with dm-crypt
|
|
|
Back to top |
|
|
AprilGrimoire n00b
Joined: 05 Jun 2020 Posts: 57
|
Posted: Mon Aug 12, 2024 5:01 am Post subject: |
|
|
Hu wrote: | AprilGrimoire wrote: | however the ask for passphrase prompt is usually flooded by many lines of log at boot-time. | This is normal. The kernel usually does not complete all setup for all devices before the cryptsetup prompt is printed, so some kernel messages are displayed afterward. This has no effect on cryptsetup, and you can enter your password normally. |
Thank you! However it looks confusing, and gives me no indication of whether I could start typing the passphrase. How can I make the passphrase prompt persistent, for example on the bottom of the screen? |
|
Back to top |
|
|
Hu Administrator
Joined: 06 Mar 2007 Posts: 22771
|
Posted: Mon Aug 12, 2024 1:43 pm Post subject: |
|
|
The passphrase prompt should be printed when cryptsetup is ready. However, nothing prevents the kernel from printing more messages after the prompt, and the prompt will not be reprinted. You could look upward in the output to check for the prompt. You could change the kernel's verbosity to a quieter setting before printing the prompt. You could add an artificial delay before printing the prompt, to give the kernel more time to finish device probes. Personally, I only get a dozen or so lines of post-prompt output, which isn't enough to scroll the prompt out, so I just live with not having the prompt at the bottom. |
|
Back to top |
|
|
|