FS#39564 - [systemd] a start job is running for dev-mapper-home
Attached to Project:
Arch Linux
Opened by Lukas B (teateawhy) - Friday, 21 March 2014, 10:16 GMT
Last edited by Dave Reisner (falconindy) - Saturday, 05 April 2014, 16:47 GMT
Opened by Lukas B (teateawhy) - Friday, 21 March 2014, 10:16 GMT
Last edited by Dave Reisner (falconindy) - Saturday, 05 April 2014, 16:47 GMT
|
Details
During boot sytemd's start messages are shown, even if
'quiet' is specified on the kernel commandline.
Instead of showing a password prompt for dev-mapper-home, the following message appears: "A start job is running for dev-mapper-home (1s / no limit)" When typing in the password, '*' characters appear, but are repeatedly overwritten by this message, so one must type in the password blindly. The encrypted container unlocks successfully and boot continues properly afterwards. This is purely a visual problem of it showing the wrong message instead of the "enter password" prompt and not respecting the 'quiet' option. Forum thread: https://bbs.archlinux.org/viewtopic.php?pid=1394953 package version: systemd 211-1 Steps to reproduce: Configure /etc/crypttab, reboot. |
This task depends upon
Closed by Dave Reisner (falconindy)
Saturday, 05 April 2014, 16:47 GMT
Reason for closing: Not a bug
Additional comments about closing: Limitation in the implementation of the console password client
Saturday, 05 April 2014, 16:47 GMT
Reason for closing: Not a bug
Additional comments about closing: Limitation in the implementation of the console password client
PS: This is more funny if you want to mount / from an encrypted device on initramfs, you can see two of these "waiting" messages overwriting among themselves.
- Create a hook file containing the open command:
# vi /lib/initcpio/hooks/openhome
-----------------------------------------------------------
# vim: set ft=sh:
run_hook ()
{
cryptsetup open --type luks /dev/<device> home
}
-----------------------------------------------------------
- Then create and edit the hook setup file:
#vi /lib/initcpio/install/openhome
-----------------------------------------------------------
# vim: set ft=sh:
build ()
{
add_runscript
}
help ()
{
cat<<HELPEOF
This opens the home encrypted partition /dev/<device> in /dev/mapper/home
HELPEOF
}
-----------------------------------------------------------
- Add the hook openhome in the HOOKS array in /etc/mkinitcpio.conf, before filesystem but after encrypt.
#vi /etc/mkinitcpio.conf
-----------------------------------------------------------
HOOKS="...lvm2 encrypt openhome filesystems ..."
-----------------------------------------------------------
- Add home to /etc/fstab:
#vi /etc/fstab
-----------------------------------------------------------
# home
/dev/mapper/home /home <filesystem> rw,relatime,data=ordered 0 2
-----------------------------------------------------------
- Delete any entry for home in /etc/crypttab
- Then re-create the initcpio:
# mkinitcpio -p linux
I am using LUKS on LVM but I guess it works if not using LVM at all (just remove lvm2 in the hooks array in /etc/mkinitcpio.conf). This is based on Swap Encryption found here: https://wiki.archlinux.org/index.php/Dm-crypt/Swap_Encryption#mkinitcpio_hook
As I said, this needs to be solved by adding a password agent that hides the console output and will not be disturbed by these messages. Can anyone try setting up plymouth for this purpose? I never did this, but I heard it's a good solution.