Bug 785603

Summary: No USB keyboard when booting Xen kernel, so can't unlock encrypted LVM and boot
Product: [openSUSE] openSUSE 12.2 Reporter: Earl Ruby <eruby>
Component: BasesystemAssignee: Forgotten User sM9JzehKpy <forgotten_sM9JzehKpy>
Status: RESOLVED NORESPONSE QA Contact: E-mail List <qa-bugs>
Severity: Major    
Priority: P5 - None CC: carnold, jbeulich, mmarek, ohering
Version: Final   
Target Milestone: ---   
Hardware: x86-64   
OS: openSUSE 12.2   
Whiteboard:
Found By: Community User Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Attachments: Results from "cat /lib/mkinitrd/scripts/boot-usb.sh" and "mkinitrd"
bug785603-lsinitrd-l-initrd-xen.txt

Description Earl Ruby 2012-10-18 04:35:06 UTC
Created attachment 509955 [details]
Results from "cat /lib/mkinitrd/scripts/boot-usb.sh" and "mkinitrd"

User-Agent:       Mozilla/5.0 (X11; Linux x86_64; rv:16.0) Gecko/20100101 Firefox/16.0

From GRUB2 I can select the and boot the vmlinux-3.4.6-2.10-desktop.gz kernel and then enter my passphrase to unlock the encrypted LVM where the root and all other partitions besides /boot reside.

However, if I select the Xen kernel (vmlinux-3.4.6-2.10-xen.gz) when I get the prompt for the passphrase my USB keyboard no longer works. 

Reproducible: Always

Steps to Reproduce:
1. Reboot machine with encrypted LVM and Xen kernel installed
2. Select Xen kernel
3. Can't unlock encrypted LVM
Actual Results:  
Can't boot.

Expected Results:  
Machine boots with Xen kernel.

This sounds very similar to the bug reported with the 3.5 kernel here:

https://bugzilla.novell.com/show_bug.cgi?id=773559

However, when I tried to work-around by adding 'hid-generic' to the /lib/mkinitrd/scripts/boot-usb.sh file I found that 'hid-generic' ***was already listed.*** HOWEVER, running mkinitrd throws the error "modprobe: Module hid_generic not found." and searching for packages containing the file 'hid-generic' using the YaST2 Software Management tool returns no results.
Comment 1 Olaf Hering 2012-10-18 13:07:16 UTC
This is similar to bug #775669
Comment 2 Jan Beulich 2012-10-18 13:14:40 UTC
As can be seen from the mkinitrd output, the -desktop flavor gets (among others)

ohci-hcd uhci-hcd ehci-hcd xhci-hcd hid usbhid

whereas the -xen flavor out of these only gets xhci-hcd. Why this is (or how to get mkinitrd to produce sufficiently verbose output to determine the reason) needs to be looked at (suggested by) a mkinitrd person.

(In reply to comment #1)
> This is similar to bug #775669

I'm not sure - there the ?hci-hcd modules all appear to be present.
Comment 3 Charles Arnold 2012-11-08 13:43:39 UTC
(In reply to comment #2)
> As can be seen from the mkinitrd output, the -desktop flavor gets (among
> others)
> 
> ohci-hcd uhci-hcd ehci-hcd xhci-hcd hid usbhid
> 
> whereas the -xen flavor out of these only gets xhci-hcd. Why this is (or how to
> get mkinitrd to produce sufficiently verbose output to determine the reason)
> needs to be looked at (suggested by) a mkinitrd person.

Michal Marek owns the mkinitrd package.
Perhaps he can answer this question.
Comment 4 Jiaying Ren 2012-11-20 08:20:04 UTC
Long time no response.So closed. Feel free to reopen it.Thanks:)
Comment 5 Earl Ruby 2012-11-22 01:09:13 UTC
Since the bug is still present and breaks Xen on OpenSUSE with encrypted LVM, I am reopening this bug.
Comment 6 Earl Ruby 2012-11-22 01:40:34 UTC
The -xen flavor *does* have ohci-hcd uhci-hcd ehci-hcd xhci-hcd hid usbhid. Scroll your window to the left when viewing http://bugzillafiles.novell.org/attachment.cgi?id=509955

The missing module is hid-generic, which is listed in the /lib/mkinitrd/scripts/boot-usb.sh script but which can't be found and is not included.

Weird mkinitrd behavior #1, probably not related: modprobe gives the error "Module hid_generic not found" for *both* the -desktop and -xen flavors, but the USB keyboard only fails to be active when booting the Xen kernel. I can unlock the encrypted LVM just fine when booting the -desktop kernel.

Weird mkinitrd behavior #2, probably not related: The /lib/mkinitrd/scripts/boot-usb.sh script lists ohci_hcd and ehci_hcd (names with underscores), mkinitrd shows ohci-hcd and ehci-hcd as successfully included modules (names with dashes). They're included in both the -desktop and -xen flavors, so it appears to work, but seems odd that the names don't match.

Possibly relevant clue: When booting -desktop, I get a graphical screen with a prompt for the passphrase to unlock the LVM. When booting -xen, I get textmode (no graphics) and when I get the text prompt to unlock the LVM, my keyboard does nothing.



(In reply to comment #2)
> As can be seen from the mkinitrd output, the -desktop flavor gets (among
> others)
> 
> ohci-hcd uhci-hcd ehci-hcd xhci-hcd hid usbhid
> 
> whereas the -xen flavor out of these only gets xhci-hcd. Why this is (or how to
> get mkinitrd to produce sufficiently verbose output to determine the reason)
> needs to be looked at (suggested by) a mkinitrd person.
> 
> (In reply to comment #1)
> > This is similar to bug #775669
> 
> I'm not sure - there the ?hci-hcd modules all appear to be present.
Comment 7 Jan Beulich 2012-11-22 08:21:36 UTC
(In reply to comment #6)
> The -xen flavor *does* have ohci-hcd uhci-hcd ehci-hcd xhci-hcd hid usbhid.
> Scroll your window to the left when viewing
> http://bugzillafiles.novell.org/attachment.cgi?id=509955

Yeah, sorry, it's the -desktop flavor that only gets xhci-hcd ([uoe]hci-hcd are all built in there).

> The missing module is hid-generic, which is listed in the
> /lib/mkinitrd/scripts/boot-usb.sh script but which can't be found and is not
> included.

As mentioned elsewhere (perhaps in the referenced bug): 3.4 simply doesn't have such a module, it got introduced in 3.5 only.

> Possibly relevant clue: When booting -desktop, I get a graphical screen with a
> prompt for the passphrase to unlock the LVM. When booting -xen, I get textmode
> (no graphics) and when I get the text prompt to unlock the LVM, my keyboard
> does nothing.

So why don't you make Xen match (by passing "vga=mode-<number>" to the hypervisor, with <number> matching the value passed via "vga=" to the native kernel)?
Comment 8 Olaf Hering 2012-11-25 15:43:05 UTC
In my testing the keyboard appears to be dead when plymouth asks for password.
However, shortly before it starts I can press space and see the cursor move. So overall the usbkbd works in initrd. For some reason kernel-xen does not display the 'ask for passphrase' screen as splash screen, instead it is displayed in textmode (not vga mode!), while kernel-desktop shows the splashscreen.
I will dig into it further.
Comment 9 Olaf Hering 2012-11-25 16:09:41 UTC
booting with 'rd.plymouth=0' solves the "dead keyboard".

Issue #1: the plymouth textmode is broken.
Issue #2: plymouth does not display splash with kernel-xen in dom0, even with a working console DRM driver (radeondrmfb).

Therefor I reassing it to the plymouth maintainer, not a Xen issue.
Comment 10 Forgotten User sM9JzehKpy 2012-11-25 18:22:35 UTC
Olaf, 

Can you provide me with the following :

output of the lsinitrd command for the initrd used by the kernel-xen
Comment 11 Olaf Hering 2012-11-26 09:41:50 UTC
Created attachment 514440 [details]
bug785603-lsinitrd-l-initrd-xen.txt

lsinitrd -l initrd-xen, its identical to initrd-desktop

Note that rd.plymouth=0 will disable splash in initrd with kernel-desktop, but once booting proceeds in real root, the splash screen is shown. This does not happen with kernel-xen, no splash screen shown.
Somehow plymouth can not deal with kernel-xen.
Comment 12 Earl Ruby 2012-12-05 20:09:24 UTC
Olaf: I can confirm that the work-around of adding "rd.plymouth=0" to the Xen module line in /boot/grub2/grub.cfg allowed me to type in the password for my LVM and boot with the Xen kernel. The boot sequence is in text mode, not graphical.

Jan: the video mode is set to "video=1680x1050" for all of the boot options in my grub.cfg file and has been since I started this thread. I was using the OpenSUSE setup for Grub without making any manual changes. The first manual change I made was adding "rd.plymouth=0".
Comment 13 Jan Beulich 2012-12-06 10:31:28 UTC
Don't know what "video=" option you're talking about - I outlined above how the correct mode setting options would look like.
Comment 14 Forgotten User sM9JzehKpy 2014-02-07 08:45:39 UTC
Is this still a valid bug ?
Comment 15 Forgotten User sM9JzehKpy 2014-11-26 14:15:10 UTC
Closing