#1860 Issue closed: keyboard input not working on real metal machines during restore/menu choices

Labels: support / question, fixed / solved / done

slopesoarer opened issue at 2018-07-12 19:21:

Relax-and-Recover (ReaR) Issue Template

Fill in the following items before submitting a new issue
(quick response is not guaranteed with free support):

  • ReaR version ("/usr/sbin/rear -V"):
    Relax-and-Recover 2.4 / 2018-06-21
    (..same in the newer stable version there ..)

  • OS version ("cat /etc/rear/os.conf" or "lsb_release -a" or "cat /etc/os-release"):

PRETTY_NAME="Debian GNU/Linux 9 (stretch)"
NAME="Debian GNU/Linux"
VERSION="9 (stretch)"
  • ReaR configuration files ("cat /etc/rear/site.conf" or "cat /etc/rear/local.conf"):
# Default is to create Relax-and-Recover rescue media as ISO image
# set OUTPUT to change that
# set BACKUP to activate an automated (backup and) restore of your data
# Possible configuration values can be found in /usr/share/rear/conf/default.conf
# This file (local.conf) is intended for manual configuration. For configuration
# through packages and other automated means we recommend creating a new
# file named site.conf next to this file and to leave the local.conf as it is. 
# Our packages will never ship with a site.conf.


  • System architecture (x86 compatible or POWER and/or what kind of virtual machine):

  • Are you using BIOS or UEFI or another way to boot?

  • Brief description of the issue:
    keyboard fails after boot, I can not choose any numbers or options wher restoring on a bare-metal machine. keyboard input works though (selecting numbers from menu), when I choose a virtual/libvirt/kvm machine as target. On a real machine the keyboard is dead after boot during select..

  • Work-around, if any:
    .. still looking for one ..

jsmeix commented at 2018-07-13 07:30:

I am really not at all an expert for keyboad issues,
nevertheless I try some mostly 'blind' guesses:

What kind of keyboard do you use on your virtual machine
compared to your bare-metal machine?

On my KVM virtual machines I have the keyboard
as virtual input device of type "Generic PS2 Keyboard"
while on my real hardware I use USB keyboards.

To use any USB device you need some USB kernel modules.
Perhaps some kernel modules are missing?

Cf. https://github.com/rear/rear/pull/1359#issuecomment-300687841

In particular regarding USB keyboards have a look
at the comments in https://github.com/rear/rear/pull/1244

Accordingly the usual USB kernel modules should be there by default, cf.

Perhaps you need some more special kernel modules for your keyboard?
In this case see the config variables MODULES and MODULES_LOAD
in usr/share/rear/conf/default.conf

In general it does not work when you made the recovery ISO image
on one kind of machine (e.g. on a virtual machine)
and try to use that on another kind of machine.
I.e. in general it does not work when you boot a ReaR recovery system
that was created by rear mkrescue/mkbackup on one kind of machine
on another kind of machine.
In general the ReaR recovery system is specific for the machine
where it was created, see the section
"Fully compatible replacement hardware is needed" in

(unknown) commented at 2018-07-16 14:00:

I was having a similar problem on a real-metal machine: USB keyboard worked during boot, but once I got to the ReaR login, I couldn't do anything. Plugging in a PS2 keyboard solved my issue. THANK YOU @jsmeix! If you hadn't mentioned it, I never would have thought to plug in a PS2 keyboard, since the USB keyboard worked for all the boot menus.

I hope this helps somebody else!

gdha commented at 2018-07-16 14:46:

@slopesoarer Thank you for the feedback. Out of curiosity which loadable module do you need for your USB keyboard? And, was this copied to the ReaR rescue image?

jsmeix commented at 2018-07-17 07:46:

In general I think in such cases (i.e. kernel modules in the ReaR recovery system)

MODULES=( 'all_modules' )

is a fail safe setting, cf. usr/share/rear/conf/default.conf
perhaps if needed plus explicit specifying MODULES_LOAD

good to know that my "mostly 'blind' guesses" helped at least you.
I appreciate your feedback because it helps me to better understand things
so that next time I could do some "less 'blind' guesses".

because we got no feedback from you
I assume "no news is good news" so that
I assume the issue is also solved for you.

slopesoarer commented at 2018-07-17 09:58:


Sorry for my late reply..
MODULES=('all') in /usr/share/conf/default.conf did the trick. I wanted to be more specific about the actually needed modules for an USB keyboard to work, therefore I have delayed my answer. I think 'usbhid' should be a 'must-have' on the loadlist. It would be fine, if loaded by default in future, since usb keyboards are becoming more and more the dominant species here and PS2 could be extinct soon... ;-))

jsmeix commented at 2018-07-17 11:43:


there is already usbhid so that this one should get already included
in the recovery system by default.

Furthermore I think the udev magic plus module dependencies and
whatever else module loading magic should normally load the neded modules
depending on what hardware is present so that a USB keyboard should
normally "just work" - provided all needed modules exist.

This would also explain why MODULES=( 'all_modules' ) helped
(I assume your MODULES=('all') is a typo) without the need
to explicitly load modules via e.g. MODULES_LOAD=( usbhid ).


What USB related modules are loaded on my openSUSE Leap 42.3
system on real hardware where I use a USB keyboard (and a USB printer):

# lsmod | grep usb

usblp                  20480  0 
usbhid                 53248  0 
usbcore               266240  6 usblp,ehci_hcd,ehci_pci,usbhid,xhci_hcd,xhci_pci
usb_common             16384  1 usbcore

What USB related modules are loaded on my SLES12 system
on a QEMU/KVM virtual machine where I use a
virtual input device of type "Generic PS2 Keyboard":

# lsmod | grep usb

usbcore               262144  3 uhci_hcd,ehci_hcd,ehci_pci
usb_common             16384  1 usbcore

and what modules get included in the recovery system by default
when I run rear mkrescue on that SLES12 virtual machine
(with KEEP_BUILD_DIR="yes"):

# pushd /tmp/rear.jq2VdJtPpGuEJAa/rootfs/lib/modules/ ; find | grep usb ; popd

[Export of Github issue for rear/rear.]