-
-
Notifications
You must be signed in to change notification settings - Fork 13.6k
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
hide boot messages when plymouth is enabled #32556
Comments
Yep, not great. With latest nixos-unstable |
Yeah, currently we install Plymouth into the stage 2 of the initrd. So you don't get it until then, and if if stage 2 is very fast, you won't see much of it at all! I don't know why it goes into stage 2, @abbradar set it up initially, so might know. |
And to fix
We need to provide systemd units for each display manager. See https://wiki.archlinux.org/index.php/plymouth#Smooth_transition |
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
I have patches here, but cleaned up yet and ready for submission. With the latest plymouth we can show the UEFI vendor logo during boot which is quite nifty. Also just sitting in my local patch queue....... |
@peterhoeg that sounds great! Did you submit your patches somewhere already? |
Crucially I had left out a "not" in my earlier comment that should have been "but not cleaned up yet and ready for submisssion"... So there's that. I'll allocate some time for this Soonish(tm). I'll ping you guys here when it's ready for testing. I have it working on one laptop here but not another although I'm not sure if this is related to what I did or the laptop in question. |
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
Does anyone know a fix for this issue on 22.11? Or is it impossible to install the package into the stage1 initramfs? |
I'm using {
console = {
font = "ter-132n";
packages = [pkgs.terminus_font];
useXkbConfig = true;
earlySetup = false;
};
boot = {
consoleLogLevel = 0;
initrd.verbose = false;
plymouth.enable = true;
kernelParams = [
"quiet"
"splash"
"boot.shell_on_fail"
"i915.fastboot=1"
"loglevel=3"
"rd.systemd.show_status=false"
"rd.udev.log_level=3"
"udev.log_priority=3"
];
loader = {
timeout = lib.mkDefault 0;
efi.canTouchEfiVariables = true;
systemd-boot = {
enable = true;
editor = false;
configurationLimit = 100;
};
};
};
} It works flawlessly, displays the logo, without any text on boot/shutdown |
That "flawlessly" is somewhat arguable, the point of plymouth in my mind has always been that you can get logs by pressing escape, in case you need them, so disabling all logging seems a bit counter that :) Using boot.initrd.systemd.enable is probably the way forward, but from my experimentation this still shows the stage1 logs (and a line stating something along the lines of "starting plymouth"), followed by some console flickering when switching to lightdm. |
Stuck on grub2 for now due to zfs-on-root (although if someone wants to provide a guide to get zfs-on-root working with systemd-boot, that'd be great!), and would also like the option to see a nicer boot and making console text optional. When you work on your nixos config for hours to get things just right, this kind of thing is the icing on the cake. I don't use LUKS, so I'm fine with an option that doesn't yet work with LUKS (some protection in place for those who do but try to enable plymouth, might be warranted) |
EDIT: I got it to work. Plymouth is now uninterrupted. My (current) config is on my profile, I'm not sure exactly which combination of bits makes it work but one of the configs suggested in the recent comments helped. Note that a previous incarnation/attempt at this actually hid a real error/problem (regarding mounting my bpool in time), and the only symptom of that was that it kept dumping me into a root login at boot which I could just control-D out of, so be aware that you might want to turn it off sometimes. |
So pressing escape to see the boot logs is not possible? |
@mainrs |
@mainrs |
Just FYI, this is my config to suppress boot messages on my machines:
|
@heywoodlh that has no effect on my system using grub2. Do you use systemd-boot? |
@davidak Ah yes, sorry, should have clarified: I am using systemd-boot. |
Most of that appears to be grub showing stuff, which happens before even the Linux kernel takes over, and won't be affected by any of the systemd/plymouth configuration. That's up to configuring grub. After grub finishes "booting the kernel" you get a blank screen for a while, which I assume is most of stage 1. It's blank because you've disabled all logging for that portion of the boot - ideally plymouth would start much earlier here, so you don't need to disable stage 1 logging (and can make it visible through escape). Finally just before stage 1 hands over to stage 2 plymouth finally starts (so that it can ask for decryption stuff), but as lightdm takes over you get tty1 flickering again. I'm pretty sure it's possible to resolve that as well, I've seen fedora systems boot without that flicker. I think the current state is:
|
I was having a similar issue and just wanted to post my solution to this (Tho I am a newbie, so take this with caution). I'm currently using grub on an intel system and could only get plymouth to show on system shutdown but not on system boot. What fixed it for me was add the 'i915' kernel module to my initrd.kernalModules like so:
What led me to the answer was this reddit post linked here. Also, I'm not sure if this is necessary, but I also added these lines of code to hide logs on boot:
|
@codeiimon Thank you! This comment led me down the right track. It also does work without the lines to disable the logs, for what it's worth. An alternative method that doesn't require adding any new modules in the initrd image is to force Plymouth to use the SimpleDRM driver. By default it hesitates to do so (waiting for some udev probing to detect "better" options), but reluctantly ends up using it after an annoyingly long timeout. You can tell it to go for SimpleDRM immediately by adding
(It seems that the Plymouth developers are considering making this the default in future versions: https://gitlab.freedesktop.org/plymouth/plymouth/-/issues/110) Here is a full, minimal, example:
(note that As for the flicker free boot sequence mentioned in previous posts, I found this summary of how Fedora does it on Intel GPU machines, though it might be out of date compared to what they're currently doing: https://fedoraproject.org/wiki/Changes/FlickerFreeBoot It relies on that |
Issue description
Plymouth is used to prevent boot messages from being displayed. That does not work completely.
/cc @abbradar @michaelpj
Steps to reproduce
NixOS system with Grub 2 and Xfce.
boot.plymouth.enable = true;
nixos-rebuild switch
reboot
Technical details
"x86_64-linux"
Linux 4.9.66, NixOS, 17.09.2281.b4a0c011e81 (Hummingbird)
yes
yes
nix-env (Nix) 1.11.15
/nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs
The text was updated successfully, but these errors were encountered: