chacham
Posts: 18
Joined: Wed Nov 23, 2011 2:59 pm
Contact: ICQ Website AOL

Re: Keyboard and mouse not working

Thu Mar 24, 2016 5:48 pm

ivancreations wrote:Okay so we have a clue: evdev module is not loaded and that means there is no one to channel the events to the X server (mouse is recognized correctly)

Can you do:

Code: Select all

ls /lib/modules/<your_kernel_version>
i think your version is 4.1.19-v7+ then the command should be

Code: Select all

ls /lib/modules/4.1.19-v7+
That is to check do you have the module there.

It is always good to know the precise reason for the issue. If the error is now fixed with a reinstall (currently reinstall is easy as you are freshly installed) but imagine how painful would be to do a reinstall in the future when you already loaded your PI with lots of applications and configuration. Happened to me a few times.
Haven't upgraded yet. My mother broke her wrist and i just got back from the hospital. I hope to upgrade later today.

In the meanwhile:

Code: Select all

pi@raspberrypi:~ $ ls /lib/modules/4.1.18+/
kernel  modules.alias  modules.alias.bin  modules.builtin  modules.builtin.bin  modules.dep  modules.dep.bin  modules.devname  modules.order  modules.softdep  modules.symbols  modules.symbols.bin
pi@raspberrypi:~ $ ls /lib/modules/4.1.18-v7+/
kernel  modules.alias  modules.alias.bin  modules.builtin  modules.builtin.bin  modules.dep  modules.dep.bin  modules.devname  modules.order  modules.softdep  modules.symbols  modules.symbols.bin

ivancreations
Posts: 15
Joined: Fri Jul 26, 2013 11:06 am
Contact: Website

Re: Keyboard and mouse not working

Thu Mar 24, 2016 9:57 pm

Good thing you noted that there are two kernel dirs under /lib/modules
That means that kernel update has happened. And it happens from time to time to break some things (like modules not being loaded). Now if that is the case do a

Code: Select all

sudo depmod -a
then reboot and check if mouse/kbd is working.

if depmod does not make the trick to a

Code: Select all

rpi-update
it should also handle the modules correctly.

p.s.
Wishing your mother a fast recovery!

chacham
Posts: 18
Joined: Wed Nov 23, 2011 2:59 pm
Contact: ICQ Website AOL

Re: Keyboard and mouse not working

Thu Mar 24, 2016 11:58 pm

ivancreations wrote:Good thing you noted that there are two kernel dirs under /lib/modules
That means that kernel update has happened. And it happens from time to time to break some things (like modules not being loaded).
Heh. The one version you mentioned didn't work, so i had to try, and found two. Heh, one, two, try. Okay, not really funny. :)
Now if that is the case do a

Code: Select all

sudo depmod -a
pi@raspberrypi:~ $ sudo depmod -a
depmod: ERROR: could not open directory /lib/modules/4.1.19-v7+: No such file or directory
depmod: FATAL: could not search modules: No such file or directory
if depmod does not make the trick to a

Code: Select all

rpi-update
it should also handle the modules correctly.

Code: Select all

pi@raspberrypi:~ $ sudo rpi-update
 *** Raspberry Pi firmware updater by Hexxeh, enhanced by AndrewS and Dom
 *** Performing self-update
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 10670  100 10670    0     0  37476      0 --:--:-- --:--:-- --:--:-- 37836
 *** Relaunching after update
 *** Raspberry Pi firmware updater by Hexxeh, enhanced by AndrewS and Dom
 *** We're running for the first time
 *** Backing up files (this will take a few minutes)
 *** Backing up firmware
 *** Backing up modules 4.1.19-v7+
#############################################################
This update bumps to rpi-4.1.y linux tree
Be aware there could be compatibility issues with some drivers
Discussion here:
https://www.raspberrypi.org/forums/viewtopic.php?f=29&t=113753
##############################################################
 *** Downloading specific firmware revision (this will take a few minutes)
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   168    0   168    0     0    844      0 --:--:-- --:--:-- --:--:--   857
100 49.3M  100 49.3M    0     0   425k      0  0:01:58  0:01:58 --:--:--  536k
 *** Updating firmware
 *** Updating kernel modules
 *** depmod 4.1.20-v7+
 *** depmod 4.1.20+
 *** Updating VideoCore libraries
 *** Using HardFP libraries
 *** Updating SDK
 *** Running ldconfig
 *** Storing current firmware revision
 *** Deleting downloaded files
 *** Syncing changes to disk
 *** If no errors appeared, your firmware was successfully updated to 37f187cd887f67235f3b84e0a2cd67807196c70f
 *** A reboot is needed to activate the new firmware
pi@raspberrypi:~ $ sudo reboot
Bingo! It works! It works! I'm not crazy after all! :)

This must be the reason why it worked for the other poster. 1_9_0 didn't fix the issue, it got rid of the problem of an update. Just wondering, maybe it is worthwhile to do a lsmod before and after an update, as part of the update process, to see if anything broke,

But, shall i just do a clean install of 1_9_0 anyway? It's been downloaded already, and its easy enough.
Wishing your mother a fast recovery!
Thank you. It was a bad break, and resetting it wasn't working, so they're waiting for the swelling to go down so she can have her wrist reset in surgery. She's been sent home, and staying with a sibling right now.

Anyway, thank you so so much for all the patient and friendly help. I would like to tell you how happy i am. Though small and simple, i am not sure i can express it with words. Thank you for all the help. And too all the helpers too.

DirkS
Posts: 7732
Joined: Tue Jun 19, 2012 9:46 pm
Location: Essex, UK

Re: Keyboard and mouse not working

Fri Mar 25, 2016 12:49 am

ivancreations wrote:Good thing you noted that there are two kernel dirs under /lib/modules
That means that kernel update has happened.
:?: The two kernel dirs mentioned in the post above yours are actually the same but for different models Pi.
/lib/modules/4.1.18-v7+/ is for Pi2 and Pi3
/lib/modules/4.1.18+/ is for all other models
If rpi-update installs a new kernel version you would see 2 additional directories appear; a standard one and a v7 one.

chacham
Posts: 18
Joined: Wed Nov 23, 2011 2:59 pm
Contact: ICQ Website AOL

Re: Keyboard and mouse not working

Fri Mar 25, 2016 2:07 am

FWIW, i wiped and installed 1_9_0, and it all works out well. I'm glad we went through all the steps though.

ivancreations
Posts: 15
Joined: Fri Jul 26, 2013 11:06 am
Contact: Website

Re: Keyboard and mouse not working

Fri Mar 25, 2016 10:45 am

@DirkS: You are correct about the difference between the two kernel dirs. So kernel update cannot be the reason.

@chacham: Glad it worked, just for the future: Maybe in your case everything was in place but for some reason the permissions were lost and depmod was not able to read the confuguration for the modules

these errors make me believe so:
depmod: ERROR: could not open directory /lib/modules/4.1.19-v7+: No such file or directory
depmod: FATAL: could not search modules: No such file or directory

I wish I had told you to do

Code: Select all

ls -la
instead of

Code: Select all

ls
so that we could know for sure but ... anyway for now that is my best guess. If that happens the next time, you have a fairly painless way out that does not require wiping out everything.

To summarize for all the people that might read that thread: Masue and Kbd were good, power was good, devices were recognized just the events from them were not reaching the X server because the evdev module was not loaded. Why it was not loaded is not 100% clear but rpi-update (if 'sudo depmod -a' does not work) will do the trick.

@chacham: It is a good practice to put "[Solved]" in front of the title so that is clear this problem has a solution.

laziegoblin
Posts: 2
Joined: Sun Dec 03, 2017 12:41 pm

Re: [Solved] Keyboard and mouse not working

Thu Dec 07, 2017 7:47 pm

I've seen lots of posts about the mouse and keyboard not working but not one solved it for me.
Power supply was good.
Other suggestions always involve putting some code or text in the command line, but how would you do that without the keyboard working?!

I use the NOOB SD to install stuff and installing anything else but the raspbian got the mouse and keyboard working. So as a final desperate attempt, I installed the lite version of raspbian.

When launching that I got the command screen and my keyboard still worked. Soooo. I used the commands to update the version.
It updated and that was that. Now, I still wasn't on the Raspbian full version and honestly I wouldn't know how to operate through commands in the lite version so I installed the full version AND lite version again.

I don't know what part of what I did fixed the issue, but when launching my full version I didn't get the "failed to load KERNEL module" thing anymore.
And yes, mouse and keyboard are working and I'm typing this out on my raspberry pi.

Hope this is helpfull to someone someday. Didn't know where else to put it.

Lazie

Return to “Beginners”

Who is online

Users browsing this forum: No registered users and 48 guests