Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot get themed password prompt to show #10

Closed
rhysperry111 opened this issue May 25, 2020 · 41 comments
Closed

Cannot get themed password prompt to show #10

rhysperry111 opened this issue May 25, 2020 · 41 comments

Comments

@rhysperry111
Copy link

Hi,

I just installed the colorful-loop theme from the aur. It works perfectly on shutdown but on login (with luks encryption) I get the default prompt providid with plymouth.

Would you know what I am doing wrong?

My plymouthd.conf:

[Daemon]
Theme=colorful_loop
ShowDelay=0
DeviceTimeout=5

mkinitcpio hooks:

HOOKS=(base systemd sd-plymouth autodetect keyboard sd-vconsole modconf block sd-encrypt filesystems)
@rhysperry111
Copy link
Author

Ok; my issue has changed. I had originally forgotten to rebuild my EFISTUB.

Now, on boot I get the colorful_loop theme but no password prompt at all. I managed to work around this by turning silent boot off, but that then stops Plymouth from showing at all

@adi1090x
Copy link
Owner

I don't know that the aur version is updated or not, I've not created these packages.

I recommend you to use the one on my github.

@rhysperry111
Copy link
Author

@adi1090x The AUR version produces the same as your github.

After a bit more experimenting I have found that:

  • If I boot while plymouth is visible it will hang
  • If I boot with plymouth hidden (pressing esc) then it does not hang

There is still no password prompt on the theme
Would you like a video of the issue?

@rhysperry111
Copy link
Author

Ok, sorry for spamming this bugtracker as this issue is now also happening with the default theme. I will go and ask the question upstream

@rhysperry111
Copy link
Author

rhysperry111 commented May 27, 2020

Ok, I have fixed the issue of it hanging as that was a problem with my configuration.

I am reopening because I still cannot get the password prompt to show. It let's me type a password, but it feels weird as there is no prompt/visual feedback

@rhysperry111 rhysperry111 reopened this May 27, 2020
@pinpox
Copy link

pinpox commented Jun 5, 2020

@rhysperry111 having the exact same issue on Void linux. I can type the password without problems, but no prompt is shown. I have tryed the default themes that come with plymouth and those work normally, so it seems to be a theme problem. Did you make any progress on this?

BTW: @adi1090x I'm using the version directly downloaded from your github, since there is no package for Void (yet). So it seems to not be only AUR-specific

@rhysperry111
Copy link
Author

rhysperry111 commented Jun 5, 2020 via email

@pinpox
Copy link

pinpox commented Jun 5, 2020

@rhysperry111 I just tried a different theme to make sure the problem is this theme and it works and shows the prompt correctly.
Could you do me a favor and tell me if this theme: https://www.gnome-look.org/p/1390331/ works for you too and shows the password prompt?

@pinpox
Copy link

pinpox commented Jun 8, 2020

@adi1090x Any help on this?

@adi1090x
Copy link
Owner

adi1090x commented Jun 8, 2020

S00608-203812(1)

You guy's aren't getting this?

@pinpox
Copy link

pinpox commented Jun 8, 2020

Nope. But now that I see your screenshot, could it be that the prompt is cut off if the resolution is lower than 1080?

@pinpox
Copy link

pinpox commented Jun 8, 2020

For me it looks like this right now:
image

But I can type anyway, it's just not showing the prompt

@rhysperry111
Copy link
Author

rhysperry111 commented Jun 8, 2020 via email

@pinpox
Copy link

pinpox commented Jun 8, 2020

I'm running it in a VM, not sure how to set the resolution for the boot process. But is there a way to move the prompt up to test this?

@pinpox
Copy link

pinpox commented Jun 8, 2020

Maybe a missing font?

@rhysperry111
Copy link
Author

rhysperry111 commented Jun 8, 2020 via email

@pinpox
Copy link

pinpox commented Jun 8, 2020

I'm using Roboto Mono for everything else in my system. Can I didn't change anything in the theme yet, wanted to get the prompt working at all first. The missing font was just a guess, can you tell me how to test this?

@rhysperry111
Copy link
Author

rhysperry111 commented Jun 8, 2020

If the problem is because the font is not in the initramfs it should be able to be solved easily.

Here are the instructions for distros using mkinitcpio (Arch):

  • Locate the missing font
  • Edit /etc/mkinitcpio.conf:
    Find the line FILES=() and change it to FILES=(/path/to/my/font)
  • Rebuid the initramfs with sudo mkinitcpio -P

These instructions work on Arch, other distros may be different

@pinpox
Copy link

pinpox commented Jun 8, 2020

Will look into it tomorrow. I'm using dracut instead mkinitcpio, not sure yet how I have to include the font, but it seems to be doable.

@pinpox
Copy link

pinpox commented Jun 9, 2020

It might not be the font after all. I tried looking into the .script and .plymouth files, there is no font explicitely set there. For reference I'm trying with the deus_ex theme from pack number 2. I'm not sure where to go from here.

@real-or-random
Copy link

I have the same issue here on Arch Linux.

@rhysperry111
Copy link
Author

In order to debug this it would help to get some system info. For everyone that is experiencing this issue could you provide:

  • Kernel and version
  • Plymouth version
  • Plymouth config
  • Kernel parameters
  • UEFI or BIOS?
  • Bootloader
  • Graphics setup (GPUs and display info)
  • Favourite icecream flavour

@rhysperry111
Copy link
Author

Sorry for the close/open.

Kernel version: linux 5.7.1-arch1-1
Plymouth Version: Plymouth-git 0.9.4.r269.g23afdeb-1
Plymouth config:

[Daemon]
Theme=colorful_loop
ShowDelay=0
DeviceTimeout=8

Kernel parameters: initrd=\initramfs-linux.img rd.luks.name=XXX-XXX-XXX=cryptroot root=/dev/mapper/cryptroot rw quiet splash loglevel=3 rd.udev.log_priority=3 vt.global_cursor_default=0
UEFI or BIOS: UEFI
Bootloader: EFISTUB
Graphics: Intel iGPU (i915, main), nVidia 1050Ti (nouveau, secondary), 1920x1080 eDP display
Icecream flavour: Rum'n'Raisin

@real-or-random
Copy link

Kernel version: linux 5.7.2-arch1-1
Plymouth Version: 0.9.4-7
Plymouth config:

[Daemon]
Theme=motion
ShowDelay=0
DeviceTimeout=2

Kernel parameters: initrd=\initramfs-linux.img [... won't tell ...] rw quiet splash i915.fastboot=1
UEFI or BIOS: UEFI
Bootloader: EFISTUB
Graphics: Intel iGPU (i915, main), nVidia second graphics, 3840x2160 eDP display

@real-or-random
Copy link

@rhysperry111 do you use the sd-encrypt hook? I do. Maybe this is the same issue as https://aur.archlinux.org/packages/breeze-plymouth/#comment-682741 (and also the follow-up comment by the same author two days later)

@rhysperry111
Copy link
Author

@real-or-random Here is a full list of my mkinitcpio hooks: systemd sd-plymouth autodetect keyboard block sd-encrypt fsck

@adi1090x
Copy link
Owner

Hmm, i see... Only people who use systemd and relative systemd hooks , facing this issue.
Have you guys tried it without systemd, normal plymouth & plymouth-encrypt

@real-or-random
Copy link

That's indeed the issue. It works when I paste

  add_binary "/usr/lib/plymouth/label.so"
  add_binary "/usr/lib/plymouth/text.so"
  add_file "/usr/share/fonts/TTF/DejaVuSans.ttf"
  add_file "/etc/fonts/fonts.conf"
  add_file "/etc/fonts/conf.d/60-latin.conf"

from /usr/lib/initcpio/install/plymouth-encrypt to /usr/lib/initcpio/install/sd-plymouth. The issue is probably that the sd-plymouth hook is generic. It does not know about encryption, and it seems the idea here was to copy those plugins only for encryption (under the assumption that this is the only thing that needs text rendering).

Those files are owned by the plymouth package. Maintainer is @nullptrT. He's not very active on GitHub, let's see if he sees that mention. Otherwise I'll write him.

@adi1090x
Copy link
Owner

Also, why using systemd?
Are you using a separate partition for /usr or just for hibernation/resume purpose?

@real-or-random
Copy link

Also, why using systemd?

I mean, why not? :P It does it's job and it's one of two possible supported options according to the Arch Wiki. I think I had some trouble with the normal hooks when I set up my system. But I can't really remember, this is a few years ago...

@pinpox
Copy link

pinpox commented Jun 13, 2020

Hmm, i see... Only people who use systemd and relative systemd hooks , facing this issue.
Have you guys tried it without systemd, normal plymouth & plymouth-encrypt

I'm not using systemd, but still having the issue. Void linux comes with runit instead of systemd. How would I fix this anyway? Other themes (e.g. the ones included by default in void) work though, so I guess I'm not missing any hooks?

@rhysperry111
Copy link
Author

rhysperry111 commented Jun 13, 2020

@pinpox Could you run lsinitcpio /path/to/your/initramfs.img and post the output (preferably in some sort of pastebin)

@pinpox
Copy link

pinpox commented Jun 13, 2020

@rhysperry111 I guess the command is called lsinitrd in Void since it uses dracut. Here is the output:
https://gist.github.com/pinpox/2a859e716e6195fb48a85c45465b5e76

@rhysperry111
Copy link
Author

rhysperry111 commented Jun 13, 2020

@pinpox It looks to be the same issue (shared objects, fonts and font configs are not in the initrd). I'm not sure how dracut works, but you'll need to add things from var/cache/fontconfig, usr/share/fonts and etc/fonts in the initrd.

You'll also need to add usr/lib/plymouth/label.so and usr/lib/plymouth/text.so

@pinpox
Copy link

pinpox commented Jun 13, 2020

FIXED, Thanks for the help!
The fix on Void Linux was to add this line to /etc/dracut.conf.d/fonts.conf:

install_items+="/usr/lib/plymouth/label.so /usr/lib/plymouth/text.so /usr/share/fonts/TTF/DejaVuSans.ttf /etc/fonts/fonts.conf"

and then run sudo plymouth-set-default-theme -R deus_ex again to rebuild

@rhysperry111
Copy link
Author

rhysperry111 commented Jun 13, 2020

I believe the font is set by /etc/fonts. I have no idea how it works, but I had to include etc/fonts/config.d/66-noto-sans.conf, etc/fonts/config.d/66-noto-serif.conf, etc/fonts/fonts.conf, usr/share/fonts/noto/NotoSans-Regular.ttf and usr/share/fonts/noto/NotoSerif-Regular.ttf in my initrd

@rhysperry111
Copy link
Author

rhysperry111 commented Jun 13, 2020

I'll close this now as it appears to be an upstream bug.
Feel free to reopen if anything discussed above did not fix your issue

Upstream bug report: https://gitlab.freedesktop.org/plymouth/plymouth/-/issues/116

@Davincible
Copy link

Im having the same issue, but with systemd-boot. It works with normal plymouth-encrypt hook, but not the sd-encrypt hook. However, when trying a different theme it does work, suggesting that the issue is in this theme specifically.

@samyak-jain
Copy link

I'm having the same issue. All the default themes bundled with plymouth show the password prompt. However, none of the themes that I've tested from this repo seem to show it.

@lox-enterprises
Copy link

For those of you who've installed Plymouth through the AUR and use systemd-encrypt (so sd-plymouth & sd-encrypt hooks), if you take a look at /usr/lib/initcpio/install/sd-plymouth:

if [ -f "/usr/share/fonts/TTF/DejaVuSans.ttf" -o -f "/usr/share/fonts/cantarell/Cantarell-Thin.otf" ]; then
        add_binary ${PLYMOUTH_PLUGIN_PATH}/label.so
        add_file "/etc/fonts/fonts.conf"
fi

if [ -f "/usr/share/fonts/TTF/DejaVuSans.ttf" ]; then
        add_file "/usr/share/fonts/TTF/DejaVuSans.ttf"
        if [ -f "/etc/fonts/conf.d/57-dejavu-sans.conf" ]; then
          add_file "/etc/fonts/conf.d/57-dejavu-sans.conf"
        fi
fi

if [ -f "/usr/share/fonts/cantarell/Cantarell-Thin.otf" ]; then
        add_file "/usr/share/fonts/cantarell/Cantarell-Thin.otf"
        add_file "/usr/share/fonts/cantarell/Cantarell-Regular.otf"
        if [ -f "/etc/fonts/conf.d/60-latin.conf" ]; then
          add_file "/etc/fonts/conf.d/60-latin.conf"
        fi
fi

It's specifically looking for either the DejaVu or Cantarell font. If you don't have those installed, it will not display the 'Enter Password' text.

You can either edit this file and point to the font you do have and hope it works like that, or you can add the DejaVu font:

sudo pacman -S ttf-dejavu

and then rebuild:

sudo su
mkinitcpio -P

@samyak-jain
Copy link

I am not using systemd-encrypt and the changes suggested by @1202software worked for me. This looks like an issue that should affect anyone not having these fonts installed. Is there a better way to change fonts rather than changing this script? I'm guessing this script would be overwrriten in an update?

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

No branches or pull requests

7 participants