7

I just upgraded my laptop from 18.04.5 to 20.04 and my keyboard and mouse have stopped working. The keyboard works in BIOS and when entering my password for cryptsetup but as soon as it's all fully loaded up, the mouse and keyboard stop working. I've tried using the terminal/command line to enter sudo alt-get install xserver-xorg-input-all as suggested on a few sites. This has not helped at all! Does anyone have any suggestions? I'm completely lost without my laptop!! Thanks in advance.

  • 3
    Bug in kernel 5.4.0-44 and 0-45 so far. External keyboard or dropping down to kernel 5.4.0-42 works in recovery mode. – crip659 Sep 13 '20 at 21:05
  • Thank you @crip659 - feels much better to know there's a "known" problem. Will a USB mouse work as well as a USB keyboard? I'm also not sure how to play with kernels in recovery mode! Bit of a n00b, I'm afraid! – MisterChrisL Sep 14 '20 at 08:54
  • Was a bit fast suggesting it is this bug. It sounds like it, but so far for HP and Acer's using the 5.4.0-45 Kernels. Should list your computer and your kernel to make sure. uname -a in terminal for kernel. External USB or wireless keyboards and mice do seem to work. – crip659 Sep 14 '20 at 11:29
  • @crip659 Thanks for the help - I think this is everything, I just did a quick copy and paste of the information that came up when I entered uname -a - so I have an HP-Stream-x360-Convertible running 5.4.0-47-generic #51-Ubuntu SMP. Does this mean anything? – MisterChrisL Sep 14 '20 at 19:53
  • Just that bug does not seem to be fixed yet. Would try to check updates so they don't try to remove kernel 5.4.0-42(last known to have keyboard work). Might not have it since you just upgraded. – crip659 Sep 14 '20 at 20:39
  • Can report am still having this problem with 5.4.0-53 – Williams Nov 11 '20 at 06:33
  • got the same issue and this worked for me : https://askubuntu.com/questions/1360683/keyboard-not-working-after-shutdown-asus-zenbook-13-oled-um325s – Adrien090888 Nov 02 '21 at 09:08
  • I cannot type anything to take advantage of these workarounds. – uberdave Feb 03 '22 at 23:41

6 Answers6

6

The problem is Ubuntu thinks your PC is a tablet and diables the keyboard. The fix below works if the following command gives you any number that is not 31 or 32.

cat /sys/class/dmi/id/chassis_type

How to fix this: (from https://askubuntu.com/a/1282269/558457)

There is a bug in recent kernels that disables some laptop keyboards. Mainly Acer and HP so far. Can usually go to recovery and boot from kernel 5.4.0-42 or use an external keyboard.

Blacklisting the intel_vbtn kernel module is a workaround for this, as seen in Why my laptop's keyboard screwed up since kernel 5.4.0-47 till 5.8.0-20

To implement this, you can either create a new file in /etc/modprobe.d with the suffix .conf or use the main blacklist.conf file. The former may be preferable, since you can then just delete the file when it is no longer required (i.e. when the bug is fixed):

sudoedit /etc/modprobe.d/blacklist-intel_vbtn.conf

Add a line to the file, optionally with a comment explaining why you are doing this

# bug in module breaks keyboard, so don't load it
blacklist intel_vbtn

Save the file, exit and reboot.

p0wl
  • 248
  • 1
    I have the same issue here on a Dell XPS 1500 however your workaround didn't work. Do you have any other workaround so I can give it a try? My current kernel is 5.8.0-48. Going back to the 5.8.0-45 also didn't work. – leoheck Mar 29 '21 at 13:39
  • I'm sorry, I'm not an expert on this. Did you check the original answer I linked to as well as the comments there? – p0wl Mar 30 '21 at 08:57
  • Same solution offered here, but they note it may not work if you have chassis_type 31 or 32: https://askubuntu.com/questions/1280217/why-is-my-laptops-keyboard-screwed-up-since-kernel-5-4-0-47-till-5-8-0-20 – Owen Jun 13 '21 at 02:52
  • 1
    Thanks so much p0wl; it fixed my no keyboard problem. I had a desktop PC using an Intel motherboard. I changed it to using a Gigabyte motherboard and the problem persisted. My system was duel boot: Windows-10/ XUbuntu 20.04. I could only boot the default Windows without the keyboard working. The new motherboard had a plug for a PS-2 keyboard, however. I plugged that in and unplugged my Logitech USB keyboard. Then I was able to boot into XUbuntu 20.04. I added your file ( blacklist-intel_vbtn.conf) and now have keyboard working even with only the USB Logitech keyboard plugged in. – Nicholas Bourbaki Jun 29 '21 at 18:58
  • Worked for me on a Dell XPS 8940. I could not type or click the mouse in X, but oddly the mouse did move normally! – Haydentech Sep 04 '21 at 20:14
  • Oh, restart? The thing I was trying to avoid? I might not know if this fixed anything at all. – TastyWheat Jan 09 '22 at 23:51
  • I updated to 20.04 from 18.04 and I had the same issue with keyboard and mouse , I boot in kernel mode form advanced settings to kernel 5.4.0-97 my chassis_type is 10 I created the blacklisted file for intel as mentioned and still the keyboard and mouse do not work after I enter my credentials at Ubuntu load. Can anyone help with a workaround ? I have a Huawei matebook pro – curious Feb 05 '22 at 17:19
  • Thanks a lot!! Even Ubuntu 22.04 still has this issue. Unfortunately it does not do the trick if I change to display manager sddm. Only gdm3 will work together with the described workaround. This is a pitty since sddm avoids the sudden death by energy saver settings before the laptop (or desktop) is logged in with user credentials. – opinion_no9 Mar 10 '22 at 19:48
2

Right! Have found a workaround. Have access to GNU GRUB menu as i have dual boot with windows. From There if i select 'advanced options' instead of the default and boot from Linux 5.4.0-42-generic i have access to all keyboard and trackpad features.

2

I had the same issue. I fixed it. In my case, 'slow keys' was turned on. If you are using ubuntu like me, on top right area of your screen beside brightness settings you will find an option with human icon.

There you will see slow key is turned on. Just turn it off. Check this way!

  • This was it! My kid grabbed my laptop to right corner and all of a sudden my keyboard stopped working. Note: a clue is that the on-screen keyboard didn't work either. – Matthias Mar 16 '24 at 18:58
0

Maybe it can be because of broken packages, try to fix files of ubuntu by going to the recovery mode and there will be many options to fix packages,boot file etc.

Grub Loader>advanced ubuntu settings>Recovey version a,b,c

  • 2
    still a f#$* issue in Ubuntu 18.04.4 and 20.10 and 22.04 Jammy Jellyfish - keyboard and ALL input buttons get deactivated - including the on/off button! Wow that's really a f#$*up & sacrifice for these fashionate tablet devices. – opinion_no9 Mar 10 '22 at 19:53
0

Ubuntu 20.04 / CHUWI AEROBOOK Have the same issue, although in my case the keyboard stopped working after a few reboots right after install and config.

  1. Still works with USB keyboard after normal boot
  2. Laptop keyboard works after a recovery boot, but display settings are gone - no brightness control, no external monitor.
  3. Tried most of the solutions in posts online to no effect.
  • Thanks - good to know it's not just me! Just to clarify (I'm quite new to Ubuntu), what is a recovery boot? – MisterChrisL Sep 14 '20 at 08:49
  • When grub shows you have choice of booting into main/most recent kernel of Ubuntu(boot into Ubuntu) or the next line down is recovery. If you do not have grub set to show on loading/startup(only ubuntu on computer) might need to hit shift button a few times when computer logo shows on power up. – crip659 Sep 14 '20 at 10:38
  • 1
    @MisterChrisL Try this - Access to GNU GRUB. From There select 'advanced options' instead of the default and boot from Linux 5.4.0-42-generic i have access to all keyboard and trackpad features since. – Invisible Man Sep 14 '20 at 10:54
  • 1
    Right, as @crip659 said, but instead of selecting any of the recovery modes select the previous kernel version 5.4.0-42-generic.This worked for me – Invisible Man Sep 14 '20 at 11:07
  • Thanks mate, and @crip659 - I've got an old wired USB mouse and keyboard plugged in and working, will try to fiddle around with kernels tomorrow! Hopefully this will be fixed pronto? – MisterChrisL Sep 14 '20 at 19:56
0

I have solved the keyboard problem in a different way: on a HP laptop with ubuntu 20.04 i had an external (USB) keyboard, and also a USB mouse. All integrated and external keyboards and mouse were working for long time. One day i connected another device (a monitor) to a USB port, apparently after that the external keyboard stopped working while the external mouse kept working. I tried two solutions in this page ("/etc/modprobe.d/blacklist-intel_vbtn.conf" and "slow keys") but did not solve the problem. I swapped the USB ports for keyboard and mouse, restarted the computer, and everything started to work fine again

tigi
  • 1
  • From reading the question and all the purposed answers I do not think this is a fix. Yes it may work for you at this time but not a long term solution. – David May 03 '23 at 08:22