Glitch disables keyboard and mouse after sleep, can't log in without forcing reboot

I’m dealing with a pretty nasty bug, has anyone else seen this?
Using the KDE Plasma flavor of Endeavour. Honestly I’m not even sure how to tell if this question belongs in this forum or on the DE’s forum.
When my PC goes to sleep (idle timer), the mouse and keyboard are completely unresponsive. It’ll only respond to the power button, but all that does is open the password field.

This is a homebuilt x64 PC, if it matters. What information is useful here?

Check your logs around the time it fails. What video card?

I’ll check the logs next time it happens. Forget when the last time it happened was so I’m not sure what to look for.

Graphics card: Nvidia GTX 1650 Super. (Forget which driver pack I installed, how do I check?)

oh also I have wayland installed. Thinking that may be messing with it, heard from others that it’s still glitchy. I’m gonna try uninstalling it and seeing if the bug still happens.

Hang on - have you tried:

nVidia resume from suspend

sudo nano /etc/modprobe.d/nvidia-power-management.conf

Then add the following line

options nvidia NVreg_PreserveVideoMemoryAllocations=1 NVreg_TemporaryFilePath=/var/tmp

See point 10 here:

And have you enabled the nVidia services?

The above worked for me on a Legion 5.

Can you clarify what you mean by this? If it brings up your display manager (the login page) after you wake up from sleep, then it means that your system logged out when it went to sleep.

By this, do you mean that pressing the keys and moving the mouse doesn’t cause your system to wake up from suspend? If that’s the case, please post the output of

$ cat /proc/acpi/wakeup

No, my PC can wake up from the power button being pressed, but on the login screen, the keyboard and mouse do not respond. I get picture, but I cannot type or click anything.

To be unreasonably precise:

  • After a normal browsing session, I leave the PC idle.
  • PC goes to sleep as expected after five minutes.
  • I press the power button, things light up, and I’m looking at the login screen as expected.
  • I start to type, and… no response. No response from the mouse either.
  • I press the power button, and it takes that as a cue to select the password field.
  • Start typing again, zero effect, only interaction I can make is pulling the plug.

Sorry it took a while for me to get back.
I’m looking at the logging tool, but I’m not sure which logs to select?
// And it seems switching back to x11 didn’t help the issue.

Trying out editing the config file as you said, though I don’t understand what this did, the issue doesn’t seem related to graphics?

Didn’t see anything about having to manually activate these… How do I tell, or what ones do I need to activate?

That doesn’t necessary mean that the keyboard or mouse were disabled. It could also mean that SDDM (since you’re using KDE Plasma, I assume you’re using SDDM as the display manager) was frozen entirely and couldn’t respond to keyboard events even though the keyboard wasn’t disabled.

  1. Was the password field active after your system woke up from sleep? Was the cursor blinking? If the cursor isn’t blinking, chances are that SDDM has frozen.
  2. Are you able to access the TTY from the greeter using the keyboard shortcut? If you can, please do so and post the journal logs.
$ journalctl -b 0

First one. No, I don’t think it’s frozen. When I first wake it, I’m shown a wallpaper and a clock. After I press the power button again, I get the password field. Don’t see a blinking cursor though?

… Didn’t get around to the second. Huh, it was working correctly after I manually set it to sleep. Strange, I guess it really was that thing about nvidia config?
What did this line added to nvidia-power-management.conf mean again?
options nvidia NVreg_PreserveVideoMemoryAllocations=1 NVreg_TemporaryFilePath=/var/tmp

It forces the PC to use your main drive to store the temporary files the video card needs to restore correctly. It normally uses swap, which may not be big enough or may not exist.

nvidia service:

sudo systemctl enable nvidia-suspend.service


It is all in the link I posted:

huh. Surprised that actually helped, this seemed to have nothing to do with graphics issues… But that’s 100% the solution to my problem. (well, had to reboot for it to work but you knew that I’m sure.)
Thanks for the help, guys


This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.