-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
initramfs: setup keymapping and video for prompts #9723
Conversation
From Steve Langasek <steve.langasek@canonical.com>: > The poorly-named 'FRAMEBUFFER' option in initramfs-tools controls > whether the console_setup and plymouth scripts are included and used > in the initramfs. These are required for any initramfs which will be > prompting for user input: console_setup because without it the user's > configured keymap will not be set up, and plymouth because you are > not guaranteed to have working video output in the initramfs without > it (e.g. some nvidia+UEFI configurations with the default GRUB > behavior). > The zfs initramfs script may need to prompt the user for passphrases > for encrypted zfs datasets, and we don't know definitively whether > this is the case or not at the time the initramfs is constructed (and > it's difficult to dynamically populate initramfs config variables > anyway), therefore the zfs-initramfs package should just set > FRAMEBUFFER=yes in a conf snippet the same way that the > cryptsetup-initramfs package does > (/usr/share/initramfs-tools/conf-hooks.d/cryptsetup). https://bugs.launchpad.net/ubuntu/+source/zfs-linux/+bug/1856408 Signed-off-by: Richard Laager <rlaager@wiktel.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Setting keymap and framebuffer shouldn't cause any issues, even if unused. afaik.
Codecov Report
@@ Coverage Diff @@
## master #9723 +/- ##
========================================
- Coverage 79% 79% -<1%
========================================
Files 420 420
Lines 123654 123654
========================================
- Hits 98069 98017 -52
- Misses 25585 25637 +52
Continue to review full report at Codecov.
|
I need to follow up on whether KEYMAP is still used in Debian. Ubuntu says it is not. |
According to the Debian wiki https://wiki.debian.org/Keyboard#How_to_set_keyboard_layout_in_initramfs |
That sounds good to me. |
FYI: These are set in `/usr/share/initramfs-tools/conf-hooks.d/cryptsetup' under Ubuntu when cryptsetup is installed. EDIT (accidentally submitted comment early): These two entries are enough to allow |
From Steve Langasek <steve.langasek@canonical.com>: > The poorly-named 'FRAMEBUFFER' option in initramfs-tools controls > whether the console_setup and plymouth scripts are included and used > in the initramfs. These are required for any initramfs which will be > prompting for user input: console_setup because without it the user's > configured keymap will not be set up, and plymouth because you are > not guaranteed to have working video output in the initramfs without > it (e.g. some nvidia+UEFI configurations with the default GRUB > behavior). > The zfs initramfs script may need to prompt the user for passphrases > for encrypted zfs datasets, and we don't know definitively whether > this is the case or not at the time the initramfs is constructed (and > it's difficult to dynamically populate initramfs config variables > anyway), therefore the zfs-initramfs package should just set > FRAMEBUFFER=yes in a conf snippet the same way that the > cryptsetup-initramfs package does > (/usr/share/initramfs-tools/conf-hooks.d/cryptsetup). https://bugs.launchpad.net/ubuntu/+source/zfs-linux/+bug/1856408 Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Kjeld Schouten <kjeld@schouten-lebbing.nl> Signed-off-by: Steve Langasek <steve.langasek@canonical.com> Signed-off-by: Richard Laager <rlaager@wiktel.com> Closes openzfs#9723
From Steve Langasek <steve.langasek@canonical.com>: > The poorly-named 'FRAMEBUFFER' option in initramfs-tools controls > whether the console_setup and plymouth scripts are included and used > in the initramfs. These are required for any initramfs which will be > prompting for user input: console_setup because without it the user's > configured keymap will not be set up, and plymouth because you are > not guaranteed to have working video output in the initramfs without > it (e.g. some nvidia+UEFI configurations with the default GRUB > behavior). > The zfs initramfs script may need to prompt the user for passphrases > for encrypted zfs datasets, and we don't know definitively whether > this is the case or not at the time the initramfs is constructed (and > it's difficult to dynamically populate initramfs config variables > anyway), therefore the zfs-initramfs package should just set > FRAMEBUFFER=yes in a conf snippet the same way that the > cryptsetup-initramfs package does > (/usr/share/initramfs-tools/conf-hooks.d/cryptsetup). https://bugs.launchpad.net/ubuntu/+source/zfs-linux/+bug/1856408 Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Kjeld Schouten <kjeld@schouten-lebbing.nl> Signed-off-by: Steve Langasek <steve.langasek@canonical.com> Signed-off-by: Richard Laager <rlaager@wiktel.com> Closes openzfs#9723
From Steve Langasek <steve.langasek@canonical.com>: > The poorly-named 'FRAMEBUFFER' option in initramfs-tools controls > whether the console_setup and plymouth scripts are included and used > in the initramfs. These are required for any initramfs which will be > prompting for user input: console_setup because without it the user's > configured keymap will not be set up, and plymouth because you are > not guaranteed to have working video output in the initramfs without > it (e.g. some nvidia+UEFI configurations with the default GRUB > behavior). > The zfs initramfs script may need to prompt the user for passphrases > for encrypted zfs datasets, and we don't know definitively whether > this is the case or not at the time the initramfs is constructed (and > it's difficult to dynamically populate initramfs config variables > anyway), therefore the zfs-initramfs package should just set > FRAMEBUFFER=yes in a conf snippet the same way that the > cryptsetup-initramfs package does > (/usr/share/initramfs-tools/conf-hooks.d/cryptsetup). https://bugs.launchpad.net/ubuntu/+source/zfs-linux/+bug/1856408 Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Kjeld Schouten <kjeld@schouten-lebbing.nl> Signed-off-by: Steve Langasek <steve.langasek@canonical.com> Signed-off-by: Richard Laager <rlaager@wiktel.com> Closes #9723
Motivation and Context
From Steve Langasek steve.langasek@canonical.com:
https://bugs.launchpad.net/ubuntu/+source/zfs-linux/+bug/1856408
Description
This sets the
KEYMAP
andFRAMEBUFFER
variables toy
in the initramfs script, just like cryptsetup does.How Has This Been Tested?
I tested this on an Ubuntu 18.04 system with an encrypted root.
I ran
update-initramfs -c -k all
. It complained that I did not have console-setup installed, saying,setupcon is missing. Please install the 'console-setup' package.
I tested with and without console-setup installed. This did not break anything. I was not experiencing any problem to start with, though, so I cannot confirm it fixes the issue. However, the analysis above seems correct to me, and in any case, we are just matching cryptsetup.
I also added "
quiet splash
" back to the kernel command line and tested that. That also worked.Types of changes
Checklist:
Signed-off-by
.